From 734dd2768a0fa2626dc40118581532cf9b4a0551 Mon Sep 17 00:00:00 2001 From: Frede Hundewadt <22748698+fhdk@users.noreply.github.com> Date: Tue, 15 Mar 2022 12:04:15 +0100 Subject: [PATCH] WIP - order draft with state --- Wonky.Client/AppId.cs | 4 +- Wonky.Client/Components/AppSpinner.razor | 3 + .../Components/CompanySortColumn.razor.cs | 3 +- Wonky.Client/Components/CompanyTable.razor | 3 +- Wonky.Client/Components/ItemTable.razor | 2 +- Wonky.Client/Components/ItemTable.razor.cs | 1 + Wonky.Client/Components/PoLineCreate.razor | 69 -------- Wonky.Client/Components/PoLineCreate.razor.cs | 41 ----- .../Components/PurchaseOrderLinesTable.razor | 66 -------- .../PurchaseOrderLinesTable.razor.cs | 25 --- .../PurchaseOrderLinesTable.razor.css | 0 .../Components/PurchaseOrderTable.razor | 51 ------ .../Components/PurchaseOrderTable.razor.cs | 25 --- .../Components/PurchaseOrderTable.razor.css | 2 - .../Components/RegLookupAddress.razor | 4 +- .../Components/RegLookupAddress.razor.css | 11 -- Wonky.Client/Components/RegLookupVatNo.razor | 4 +- .../HttpInterceptorService.cs | 5 +- Wonky.Client/Pages/OrderDraft.razor | 159 ++++++++++++++++++ Wonky.Client/Pages/OrderDraft.razor.cs | 95 +++++++++++ Wonky.Client/Pages/ShoppingCart.razor | 153 ----------------- Wonky.Client/Shared/MainLayout.razor.css | 2 +- Wonky.Client/Shared/NavMenu.razor | 10 +- Wonky.Client/wwwroot/index.html | 2 +- Wonky.Entity/Models/Cart.cs | 19 +-- 25 files changed, 289 insertions(+), 470 deletions(-) create mode 100644 Wonky.Client/Components/AppSpinner.razor delete mode 100644 Wonky.Client/Components/PoLineCreate.razor delete mode 100644 Wonky.Client/Components/PoLineCreate.razor.cs delete mode 100644 Wonky.Client/Components/PurchaseOrderLinesTable.razor delete mode 100644 Wonky.Client/Components/PurchaseOrderLinesTable.razor.cs delete mode 100644 Wonky.Client/Components/PurchaseOrderLinesTable.razor.css delete mode 100644 Wonky.Client/Components/PurchaseOrderTable.razor delete mode 100644 Wonky.Client/Components/PurchaseOrderTable.razor.cs delete mode 100644 Wonky.Client/Components/PurchaseOrderTable.razor.css delete mode 100644 Wonky.Client/Components/RegLookupAddress.razor.css create mode 100644 Wonky.Client/Pages/OrderDraft.razor create mode 100644 Wonky.Client/Pages/OrderDraft.razor.cs delete mode 100644 Wonky.Client/Pages/ShoppingCart.razor diff --git a/Wonky.Client/AppId.cs b/Wonky.Client/AppId.cs index 91b972b6..38a63d40 100644 --- a/Wonky.Client/AppId.cs +++ b/Wonky.Client/AppId.cs @@ -2,8 +2,8 @@ namespace Wonky.Client; public class AppId { - public string Version { get; set; } = "0.2.1"; - public string Name { get; set; } = "Inno Client"; + public string Version { get; set; } = "0.2.2"; + public string Name { get; set; } = "Wonky Online"; public bool IsBeta { get; set; } = false; } \ No newline at end of file diff --git a/Wonky.Client/Components/AppSpinner.razor b/Wonky.Client/Components/AppSpinner.razor new file mode 100644 index 00000000..aea463fa --- /dev/null +++ b/Wonky.Client/Components/AppSpinner.razor @@ -0,0 +1,3 @@ +
Navn | +Varenr | +Stk / Pris | ++ |
---|---|---|---|
+ @item.Name + | ++ @item.Sku + | +
+
|
+ + + | +
Navn | +Varenr | +Antal | +Enhedspris | +Linjesum | ++ |
---|---|---|---|---|---|
+ @cItem.Item.Name + | ++ @cItem.Item.Sku + | ++ @cItem.Quantity + | ++ @cItem.Price + | ++ @cItem.Total + | ++ + | +
+ | + | + | Total | +@CartStateProvider.ShoppingCart.Total | ++ |
Name: | -@SelectedItem.Name | -
Description: | -@SelectedItem.Description | -
Price: | -$@SelectedItem.Price | -
Add To Cart: | -- Quantity: - - - | -
- - |
- |
Name: | -@item.Item.Name | -
Description: | -@item.Item.Description | -
Price: | -$@item.Item.Price | -
Quantity: | -@item.Quantity | -
Total: | -$@item.Total | -
- @*Clicking this button passes the item so we can remove it*@ - - | -