diff --git a/Wonky.Client/Components/OfficeActivityTableComponent.razor b/Wonky.Client/Components/OfficeActivityTableComponent.razor index 36ce9bbf..04af9c03 100644 --- a/Wonky.Client/Components/OfficeActivityTableComponent.razor +++ b/Wonky.Client/Components/OfficeActivityTableComponent.razor @@ -36,12 +36,12 @@ @foreach (var activity in Activities) { - + @activity.Company.Name @activity.Company.City @activity.Demo @activity.Sales - @activity.OfficeNote + @activity.OfficeNote @($"{activity.SasAmount:N2}") @(activity.StatusTypeEnum == "Quote" ? $"{0:N2}" : $"{activity.OrderAmount:N2}") @@ -64,12 +64,6 @@ } - - - Total - @Activities.Where(x => x.StatusTypeEnum == "Order").Sum(x => x.OrderAmount) - - } \ No newline at end of file diff --git a/Wonky.Client/Pages/CrmActivityNewPage.razor b/Wonky.Client/Pages/CrmActivityNewPage.razor index 63042de1..5ad861c6 100644 --- a/Wonky.Client/Pages/CrmActivityNewPage.razor +++ b/Wonky.Client/Pages/CrmActivityNewPage.razor @@ -26,6 +26,12 @@ +@if (!string.IsNullOrWhiteSpace(Company.Blocked)) +{ +
+

Ring til kontoret. Denne konto er spærret med kode '@Company.Blocked'

+
+}

@Activity.Name - @Activity.Account

diff --git a/Wonky.Client/Pages/CrmCompanyInvoiceListPage.razor b/Wonky.Client/Pages/CrmCompanyInvoiceListPage.razor new file mode 100644 index 00000000..d5729873 --- /dev/null +++ b/Wonky.Client/Pages/CrmCompanyInvoiceListPage.razor @@ -0,0 +1,6 @@ +@page "/companies/{CompanyId}/invoices" +
+
+

Faktura oversigt

+
+
\ No newline at end of file diff --git a/Wonky.Client/Pages/CrmCompanyInvoiceListPage.razor.cs b/Wonky.Client/Pages/CrmCompanyInvoiceListPage.razor.cs new file mode 100644 index 00000000..14c6bdc3 --- /dev/null +++ b/Wonky.Client/Pages/CrmCompanyInvoiceListPage.razor.cs @@ -0,0 +1,14 @@ +using Microsoft.AspNetCore.Components; +using Wonky.Client.HttpInterceptors; +using Wonky.Client.HttpInterfaces; + +namespace Wonky.Client.Pages; + +public partial class CrmCompanyInvoiceListPage +{ + [Parameter] public string CompanyId { get; set; } = ""; + [Inject] public ICrmCompanyHttpRepository CompanyRepo { get; set; } + [Inject] public HttpInterceptorService Interceptor { get; set; } + + +} \ No newline at end of file diff --git a/Wonky.Client/Pages/CrmCompanyViewPage.razor b/Wonky.Client/Pages/CrmCompanyViewPage.razor index 4fec1671..a6ea3382 100644 --- a/Wonky.Client/Pages/CrmCompanyViewPage.razor +++ b/Wonky.Client/Pages/CrmCompanyViewPage.razor @@ -21,11 +21,17 @@ @attribute [Authorize(Roles = "Advisor")] @page "/companies/{CompanyId}" -@if (!string.IsNullOrWhiteSpace(_company.Name)) +@if (!string.IsNullOrWhiteSpace(Company.Name)) { + @if (!string.IsNullOrWhiteSpace(Company.Blocked)) + { +
+

Ring til kontoret. Denne konto er spærret med kode '@Company.Blocked'

+
+ }
-

@_company.Name

+

@Company.Name

@if (_dk) { @@ -70,16 +76,16 @@ BEMÆRK - - @if (string.IsNullOrWhiteSpace(_company.Note)) + + @if (string.IsNullOrWhiteSpace(Company.Note)) { - + } else { - + } - + @@ -90,16 +96,15 @@ - - + + @* *@ - Telefon + Konto - - - + + @@ -108,15 +113,15 @@ - - + + Attention - - - + + + @@ -125,15 +130,15 @@ - - + + Adresse2 - - - + + + @@ -142,15 +147,15 @@ - - + + Bynavn - - - + + + @@ -159,15 +164,22 @@ - - + + + + + Telefon + + + + Mobil - - + + @@ -184,7 +196,7 @@ Besøgt - + @@ -194,11 +206,11 @@ - - + + - - @if (_company.HasFolded == 1) + + @if (Company.HasFolded == 1) { } @@ -207,28 +219,26 @@
-
-
- +
\ No newline at end of file diff --git a/Wonky.Client/Pages/CrmTaskItemListPage.razor.cs b/Wonky.Client/Pages/CrmTaskItemListPage.razor.cs index 8e5d5ca9..b100f79a 100644 --- a/Wonky.Client/Pages/CrmTaskItemListPage.razor.cs +++ b/Wonky.Client/Pages/CrmTaskItemListPage.razor.cs @@ -23,40 +23,40 @@ using Wonky.Client.Services; using Wonky.Entity.DTO; using Wonky.Entity.Views; -namespace Wonky.Client.Pages; +namespace Wonky.Client.Pages; public partial class CrmTaskItemListPage : IDisposable { - [Inject] public PreferenceService Prefs { get; set; } + [Inject] public PreferenceService PreferenceService { get; set; } [Inject] public ILogger Logger { get; set; } - [Inject] public HttpInterceptorService _interceptor { get; set; } - [Inject] public NavigationManager _navigator { get; set; } - [Inject] public ICrmTaskItemHttpRepository CrmTaskItemRepo { get; set; } - [Inject] public IToastService _toast { get; set; } - private Preferences _prefs { get; set; } = new(); - private string _workDate { get; set; } = $"{DateTime.Now:yyyy-MM-dd}"; - private bool _reportExist = false; - private List? _taskItems { get; set; } = new(); + [Inject] public HttpInterceptorService Interceptor { get; set; } + [Inject] public NavigationManager Navigator { get; set; } + [Inject] public ICrmTaskItemHttpRepository TaskItemRepo { get; set; } + [Inject] public IToastService Toaster { get; set; } + private Preferences Prefs { get; set; } = new(); + private string WorkDate { get; set; } = $"{DateTime.Now:yyyy-MM-dd}"; + private bool ReportExist = false; + private List TaskItems { get; set; } = new(); protected override async Task OnInitializedAsync() { - _prefs = await Prefs.GetPreferences(); - if(!string.IsNullOrWhiteSpace(_prefs.WorkDate)) - _workDate = _prefs.WorkDate; + Prefs = await PreferenceService.GetPreferences(); + if(!string.IsNullOrWhiteSpace(Prefs.WorkDate)) + WorkDate = Prefs.WorkDate; - _interceptor.RegisterEvent(); - _interceptor.RegisterBeforeSendEvent(); - await GetTaskItems(_workDate); + Interceptor.RegisterEvent(); + Interceptor.RegisterBeforeSendEvent(); + await GetTaskItems(WorkDate); } private async Task GetTaskItems(string workDate) { - _toast.ShowInfo("Vent nogle sekunder for data"); - _taskItems = await CrmTaskItemRepo.GetTaskList(workDate); + Toaster.ShowInfo("Vent nogle sekunder for data"); + TaskItems = await TaskItemRepo.GetTaskList(workDate); } public void Dispose() { - _interceptor.DisposeEvent(); + Interceptor.DisposeEvent(); } } \ No newline at end of file diff --git a/Wonky.Client/Pages/CrmTaskItemViewPage.razor b/Wonky.Client/Pages/CrmTaskItemViewPage.razor index a366482f..ec763ce9 100644 --- a/Wonky.Client/Pages/CrmTaskItemViewPage.razor +++ b/Wonky.Client/Pages/CrmTaskItemViewPage.razor @@ -19,8 +19,6 @@ @attribute [Authorize(Roles = "Advisor")] @page "/tasks/{TaskItemId}" -@* {"TaskItemId":"","ErpUserId":"","ReferenceId":"","Name":"","Description":"","DueTimestamp":"","TaskTypeEnum":"","Interval":0,"IsCompleted":false,"OverDue":false,"Recurring":false} *@ -

Opgave

diff --git a/Wonky.Client/Shared/ConfirmationModal.razor.cs b/Wonky.Client/Shared/ConfirmationModal.razor.cs index 253e82db..b52ff841 100644 --- a/Wonky.Client/Shared/ConfirmationModal.razor.cs +++ b/Wonky.Client/Shared/ConfirmationModal.razor.cs @@ -23,8 +23,6 @@ public partial class ConfirmationModal private bool _showBackdrop; [Parameter] public string BodyMessage { get; set; } = ""; [Parameter] public EventCallback OnOkClicked { get; set; } - - public void Show() { diff --git a/Wonky.Client/wwwroot/appsettings.json b/Wonky.Client/wwwroot/appsettings.json index f4dd6419..2211fbde 100644 --- a/Wonky.Client/wwwroot/appsettings.json +++ b/Wonky.Client/wwwroot/appsettings.json @@ -1,13 +1,13 @@ { "appInfo": { "name": "Wonky Client", - "version": "0.30.3", - "rc": false, + "version": "0.36.1", + "rc": true, "sandBox": false, "image": "grumpy-coder.png" }, "apiConfig": { - "innoBaseUrl": "https://app.innotec.dk", + "innoBaseUrl": "https://zeta.innotec.dk", "glsTrackUrl": "https://www.gls-group.eu/276-I-PORTAL-WEB/content/GLS/DK01/DA/5004.htm?txtAction=71000&txtRefNo=", "glsId": "", "serviceVirk": "api/v2/services/virk", diff --git a/Wonky.Entity/DTO/CompanyDto.cs b/Wonky.Entity/DTO/CompanyDto.cs index f6a29139..dc12956c 100644 --- a/Wonky.Entity/DTO/CompanyDto.cs +++ b/Wonky.Entity/DTO/CompanyDto.cs @@ -115,6 +115,12 @@ public class CompanyDto [MaxLength(100, ErrorMessage = "Du kan højst bruge 100 tegn")] public string Attention { get; set; } = ""; + /// + /// ERP block state + /// + /// Empty string - Customer not blocked + public string Blocked { get; set; } = ""; + /// /// Country code ISO ///