diff --git a/Wonky.Client/Components/OfficeActivityTableComponent.razor b/Wonky.Client/Components/OfficeActivityTableComponent.razor index afe42dd8..6e0b7760 100644 --- a/Wonky.Client/Components/OfficeActivityTableComponent.razor +++ b/Wonky.Client/Components/OfficeActivityTableComponent.razor @@ -30,7 +30,7 @@ - + diff --git a/Wonky.Client/Components/ProcessStateComponent.razor b/Wonky.Client/Components/ProcessStateComponent.razor index 6e37b759..c217eff8 100644 --- a/Wonky.Client/Components/ProcessStateComponent.razor +++ b/Wonky.Client/Components/ProcessStateComponent.razor @@ -16,9 +16,7 @@ *@ -@* *@ -@* ... *@ -@* *@ + @code{ [Parameter] public string StateClass { get; set; } = ""; private string _icon { get; set; } = ""; @@ -27,9 +25,9 @@ { _icon = StateClass switch { - "the-ugly-fg" => "square", - "the-bad-fg" => "box2", - "the-good-fg" => "box-seam-fill", + "the-ugly-fg" => "file-earmark", + "the-bad-fg" => "file-earmark-check", + "the-good-fg" => "box2-fill", "the-draw-fg" => "truck", _ => "question-square" }; diff --git a/Wonky.Client/Components/ProcessStateComponent.razor.css b/Wonky.Client/Components/ProcessStateComponent.razor.css index e69de29b..f9b2768b 100644 --- a/Wonky.Client/Components/ProcessStateComponent.razor.css +++ b/Wonky.Client/Components/ProcessStateComponent.razor.css @@ -0,0 +1,12 @@ +.the-good-fg { + color: black; +} +.the-bad-fg { + color: black; +} +.the-ugly-fg { + color: black; +} +.the-draw-fg { + color: black; +} \ No newline at end of file diff --git a/Wonky.Client/Components/TopbarNavigation.razor b/Wonky.Client/Components/TopbarNavigation.razor index 8465c0a1..98f967d5 100644 --- a/Wonky.Client/Components/TopbarNavigation.razor +++ b/Wonky.Client/Components/TopbarNavigation.razor @@ -19,8 +19,9 @@
- LOG AF - HJÆLP + + +
\ No newline at end of file diff --git a/Wonky.Client/HttpInterfaces/ICrmActivityHttpRepository.cs b/Wonky.Client/HttpInterfaces/ICrmActivityHttpRepository.cs index b5ab49f3..e47671e3 100644 --- a/Wonky.Client/HttpInterfaces/ICrmActivityHttpRepository.cs +++ b/Wonky.Client/HttpInterfaces/ICrmActivityHttpRepository.cs @@ -27,4 +27,5 @@ public interface ICrmActivityHttpRepository Task GetActivities(string activityDate); Task> GetCustomerActivities(string customerId); Task UpdateOfficeNote(ActivityOfficeNote model); + Task UpdateExpressStatus(string id); } \ No newline at end of file diff --git a/Wonky.Client/HttpRepository/CrmActivityHttpRepository.cs b/Wonky.Client/HttpRepository/CrmActivityHttpRepository.cs index 88b94748..1a2671be 100644 --- a/Wonky.Client/HttpRepository/CrmActivityHttpRepository.cs +++ b/Wonky.Client/HttpRepository/CrmActivityHttpRepository.cs @@ -43,7 +43,7 @@ public class CrmActivityHttpRepository : ICrmActivityHttpRepository private readonly NavigationManager _navigation; private ILogger _logger; private readonly HttpClient _client; - private readonly ApiConfig _apiConfig; + private readonly ApiConfig _api; public CrmActivityHttpRepository(HttpClient client, ILogger logger, @@ -52,19 +52,24 @@ public class CrmActivityHttpRepository : ICrmActivityHttpRepository _client = client; _logger = logger; _navigation = navigation; - _apiConfig = configuration.Value; + _api = configuration.Value; } + public async Task UpdateExpressStatus(string id) + { + await _client.PostAsync($"{_api.CrmSales}/express/{id}/?status=express", null); + } + public async Task UpdateOfficeNote(ActivityOfficeNote model) { _logger.LogDebug("UpdateOfficeNote => model \n{}", JsonSerializer.Serialize(model) ); - _logger.LogDebug("UpdateOfficeNote => url \n{}", $"{_apiConfig.CrmSales}/activity/{model.ActivityId}" ); - await _client.PostAsJsonAsync($"{_apiConfig.CrmSales}/activity/{model.ActivityId}", model, _options); + _logger.LogDebug("UpdateOfficeNote => url \n{}", $"{_api.CrmSales}/activity/{model.ActivityId}" ); + await _client.PostAsJsonAsync($"{_api.CrmSales}/activity/{model.ActivityId}", model, _options); } public async Task GetActivities(string activityDate) { var response = await _client - .GetAsync($"{_apiConfig.CrmSales}/date/{activityDate}"); + .GetAsync($"{_api.CrmSales}/date/{activityDate}"); var content = await response.Content.ReadAsStringAsync(); return string.IsNullOrWhiteSpace(content) ? new ReportStatusView() @@ -73,7 +78,7 @@ public class CrmActivityHttpRepository : ICrmActivityHttpRepository public async Task> GetCustomerActivities(string customerId) { - var response = await _client.GetAsync($"{_apiConfig.CrmSales}/company/{customerId}"); + var response = await _client.GetAsync($"{_api.CrmSales}/company/{customerId}"); var content = await response.Content.ReadAsStringAsync(); return JsonSerializer.Deserialize>(content, _options); @@ -81,29 +86,32 @@ public class CrmActivityHttpRepository : ICrmActivityHttpRepository public async Task CreateActivity(ActivityDto model) { - var response = await _client.PostAsJsonAsync($"{_apiConfig.CrmSales}", model, _options); + var response = await _client.PostAsJsonAsync($"{_api.CrmSales}", model, _options); var content = await response.Content.ReadAsStringAsync(); - var result = JsonSerializer.Deserialize(content); + _logger.LogDebug("ActivityRepo => CreateActivity => ResponseContent <= {}", content); + var result = JsonSerializer.Deserialize(content, _options); + var msg = JsonSerializer.SerializeToElement(result.Message); + _logger.LogDebug("Message content <= {}", msg); return result!; } public async Task GetReportItem(string id) { var salesItem = await _client - .GetFromJsonAsync($"{_apiConfig.CrmSales}/{id}"); + .GetFromJsonAsync($"{_api.CrmSales}/{id}"); return salesItem ?? new ReportItemView(); } public async Task GetActivity(string id) { var salesItem = await _client - .GetFromJsonAsync($"{_apiConfig.CrmSales}/{id}"); + .GetFromJsonAsync($"{_api.CrmSales}/{id}"); return salesItem ?? new ActivityDto(); } public async Task AcceptOffer(string id) { - var response = await _client.PostAsJsonAsync($"{_apiConfig.CrmSales}/{id}/accept", id); + var response = await _client.PostAsJsonAsync($"{_api.CrmSales}/{id}/accept", id); var content = await response.Content.ReadAsStringAsync(); var result = JsonSerializer.Deserialize(content); return result!; diff --git a/Wonky.Client/Pages/CrmNewActivityPage.razor b/Wonky.Client/Pages/CrmNewActivityPage.razor index 3a095604..409c2e52 100644 --- a/Wonky.Client/Pages/CrmNewActivityPage.razor +++ b/Wonky.Client/Pages/CrmNewActivityPage.razor @@ -35,7 +35,7 @@
-

@_draft.Name - @_draft.Account

+

@_activity.Name - @_activity.Account

@@ -51,29 +51,29 @@ else
- + - +
- + - @if (!string.IsNullOrEmpty(_draft.VatNumber) && !string.IsNullOrWhiteSpace(_draft.Address1) && _company.HasFolded == 0) + @if (!string.IsNullOrEmpty(_activity.VatNumber) && !string.IsNullOrWhiteSpace(_activity.Address1) && _company.HasFolded == 0) { } - - @if (_draft.ActivityStatusEnum == "order") + + @if (_activity.ActivityStatusEnum == "order") {
- +
} @@ -83,63 +83,63 @@ else
- - + +
- - + +
- - + +
- - + +
- - + +
- - + +
- - + +
- - + +
@* Order lines *@ -
+

@@ -264,7 +264,7 @@ else

@* Delivery address *@ -
+

@@ -308,12 +308,6 @@ else
-@if (HideButtons) -{ - -} -else -{
Til Oversigt @@ -325,5 +319,4 @@ else
-} -} +} \ No newline at end of file diff --git a/Wonky.Client/Pages/CrmNewActivityPage.razor.cs b/Wonky.Client/Pages/CrmNewActivityPage.razor.cs index f06ebfbf..b4e0bf1d 100644 --- a/Wonky.Client/Pages/CrmNewActivityPage.razor.cs +++ b/Wonky.Client/Pages/CrmNewActivityPage.razor.cs @@ -36,29 +36,25 @@ public partial class CrmNewActivityPage : IDisposable [CascadingParameter] DraftStateProvider DraftStateProvider { get; set; } [Parameter] public string CompanyId { get; set; } // Services - [Inject] public ILogger _logger { get; set; } - [Inject] public HttpInterceptorService _interceptor { get; set; } - [Inject] public UserPreferenceService _userPrefs { get; set; } - [Inject] public IToastService _toast { get; set; } - [Inject] public NavigationManager _navigator { get; set; } - [Inject] public ILocalStorageService _storage { get; set; } - [Inject] public ICatalogHttpRepository _itemRepo { get; set; } - [Inject] public ICrmCompanyHttpRepository _companyRepo { get; set; } + [Inject] public ILogger Logger { get; set; } + [Inject] public HttpInterceptorService Interceptor { get; set; } + [Inject] public UserPreferenceService PreferenceService { get; set; } + [Inject] public IToastService Toast { get; set; } + [Inject] public NavigationManager Navigator { get; set; } + [Inject] public ILocalStorageService Storage { get; set; } + [Inject] public ICatalogHttpRepository Catalog { get; set; } + [Inject] public ICrmCompanyHttpRepository CompanyRepo { get; set; } [Inject] public ICrmActivityHttpRepository CrmActivityRepo { get; set; } [Inject] public ICrmReportHttpRepository CrmReportRepo { get; set; } // variables private readonly JsonSerializerOptions? _options = new JsonSerializerOptions{PropertyNameCaseInsensitive = true}; - private PriceListModal _priceListModal { get; set; } - private ProductHistoryModal _historyModal { get; set; } - private ProductPriceHistoryModal _priceHistoryModal { get; set; } private SalesItemView _selectedItem { get; set; } = new(); private Preferences _prefs { get; set; } = new(); - private ActivityDto _draft { get; set; } = new(); + private ActivityDto _activity { get; set; } = new(); private CompanyDto _company = new(); private EditContext _editContext { get; set; } private bool _poFormInvalid { get; set; } = true; private bool ShowItem { get; set; } - private bool HideButtons { get; set; } private string Quantity = "1"; private string Price = "0"; private string Discount = "0"; @@ -73,14 +69,17 @@ public partial class CrmNewActivityPage : IDisposable private DateTime _workDate { get; set; } = DateTime.Now; private string _selectedDate { get; set; } = ""; private string _phone { get; set; } = ""; + // MODAL DIALOGS + private PriceListModal _priceListModal { get; set; } + private ProductHistoryModal _historyModal { get; set; } + private ProductPriceHistoryModal _priceHistoryModal { get; set; } - protected override async Task OnParametersSetAsync() { - _interceptor.RegisterEvent(); - _interceptor.RegisterBeforeSendEvent(); + Interceptor.RegisterEvent(); + Interceptor.RegisterBeforeSendEvent(); - _prefs = await _userPrefs.GetPreferences(); + _prefs = await PreferenceService.GetPreferences(); if (!string.IsNullOrWhiteSpace(_prefs.WorkDate)) _workDate = DateTime.Parse(_prefs.WorkDate); @@ -91,16 +90,16 @@ public partial class CrmNewActivityPage : IDisposable protected override async Task OnInitializedAsync() { - _editContext = new EditContext(_draft); + _editContext = new EditContext(_activity); _editContext.OnFieldChanged += HandleFieldChanged; _editContext.OnValidationStateChanged += ValidationChanged; - _draft.ActivityDate = $"{_workDate:yyyy-MM-dd}" ; + _activity.ActivityDate = $"{_workDate:yyyy-MM-dd}" ; - _ux = await _storage.GetItemAsync("_xu"); + _ux = await Storage.GetItemAsync("_xu"); // get company - _company = await _companyRepo.GetCompanyById(CompanyId); + _company = await CompanyRepo.GetCompanyById(CompanyId); // variable to validate if customer needs phone number update _phone = _company.Phone; @@ -111,36 +110,36 @@ public partial class CrmNewActivityPage : IDisposable _company.Phone = _company.Account[..8]; } - _draft.BcId = _company.BcId; - _draft.ActivityStatusEnum = "noSale"; - _draft.VisitTypeEnum = _company.Account is "" or "NY" ? "new" : "recall"; + _activity.BcId = _company.BcId; + _activity.ActivityStatusEnum = "noSale"; + _activity.VisitTypeEnum = _company.Account is "" or "NY" ? "new" : "recall"; if (_company.HasFolded == 1) - _draft.OrderMessage = "Virksomheden er ophørt."; + _activity.OrderMessage = "Virksomheden er ophørt."; // permanent identifications - _draft.CompanyId = _company.CompanyId; - _draft.SalesRepId = _company.SalesRepId; - _draft.SalesRep = _company.SalesRep; - _draft.CountryCode = _company.CountryCode; + _activity.CompanyId = _company.CompanyId; + _activity.SalesRepId = _ux.Id; + _activity.SalesRep = _ux.Advisor; + _activity.CountryCode = _ux.CountryCode; - _draft.Account = _company.Account; - _draft.VatNumber = _company.VatNumber; - _draft.Email = _company.Email; - _draft.Phone = _company.Phone; - _draft.Mobile = _company.Mobile; + _activity.Account = _company.Account; + _activity.VatNumber = _company.VatNumber; + _activity.Email = _company.Email; + _activity.Phone = _company.Phone; + _activity.Mobile = _company.Mobile; - _draft.Name = _company.Name; - _draft.Address1 = _company.Address1; - _draft.Address2 = _company.Address2; - _draft.ZipCode = _company.ZipCode; - _draft.City = _company.City; + _activity.Name = _company.Name; + _activity.Address1 = _company.Address1; + _activity.Address2 = _company.Address2; + _activity.ZipCode = _company.ZipCode; + _activity.City = _company.City; - _draft.DlvName = _company.Name; - _draft.DlvAddress1 = _company.Address1; - _draft.DlvAddress2 = _company.Address2; - _draft.DlvZipCode = _company.ZipCode; - _draft.DlvCity = _company.City; + _activity.DlvName = _company.Name; + _activity.DlvAddress1 = _company.Address1; + _activity.DlvAddress2 = _company.Address2; + _activity.DlvZipCode = _company.ZipCode; + _activity.DlvCity = _company.City; } private void CallPriceListModal() @@ -154,7 +153,7 @@ public partial class CrmNewActivityPage : IDisposable if (string.IsNullOrWhiteSpace(sku.ItemId)) return; - _selectedItem = await _itemRepo.GetSalesItemId(sku.ItemId); + _selectedItem = await Catalog.GetSalesItemId(sku.ItemId); ShowItem = true; Price = sku.Rate; Quantity = sku.Quantity; @@ -181,46 +180,46 @@ public partial class CrmNewActivityPage : IDisposable { _selectedDate = workDate; _workDate = DateTime.Parse(_selectedDate); - _draft.ActivityDate = _selectedDate; + _activity.ActivityDate = _selectedDate; _reportClosdd = await CrmReportRepo.ReportExist(_selectedDate); } private async Task CreateActivity() { - if (string.IsNullOrWhiteSpace(_draft.Address1)) + _activity.CountryCode = ""; + if (string.IsNullOrWhiteSpace(_activity.Address1)) { - _toast.ShowError("Kunde adresse er ufuldstændig."); + Toast.ShowError("Kunde adresse er ufuldstændig."); return; } - if (_draft.ActivityStatusEnum == "order") + if (_activity.ActivityStatusEnum == "order") { if (DraftStateProvider.Draft.Items.Count == 0) { - _toast.ShowError("Ved bestilling skal der angives et eller flere varenumre."); + Toast.ShowError("Ved bestilling skal der angives et eller flere varenumre."); return; } - if (string.IsNullOrWhiteSpace(_draft.Phone)) + if (string.IsNullOrWhiteSpace(_activity.Phone)) { - _toast.ShowError("Ved bestilling til ny kunde skal telefon nummer angives."); + Toast.ShowError("Ved bestilling til ny kunde skal telefon nummer angives."); return; } } - HideButtons = true; - _draft.ActivityDate = $"{_workDate:yyyy-MM-dd}"; - _draft.OurRef = _draft.ActivityTypeEnum switch + _activity.ActivityDate = $"{_workDate:yyyy-MM-dd}"; + _activity.OurRef = _activity.ActivityTypeEnum switch { "phone" => $"T:{_ux.FullName.Split(" ")[0]}", "onSite" => $"B:{_ux.FullName.Split(" ")[0]}", _ => "" }; - if (_draft.Express) - _draft.OurRef = $"E{_draft.OurRef}"; + if (_activity.Express) + _activity.OurRef = $"E{_activity.OurRef}"; - _draft.Lines = new List(); + _activity.Lines = new List(); var ln = 0; if (DraftStateProvider.Draft.Items.Count != 0) { @@ -238,26 +237,39 @@ public partial class CrmNewActivityPage : IDisposable Location = item.Item.Location }) .ToList(); - _draft.Lines = lines; + _activity.Lines = lines; } - if (_phone != _draft.Phone) + if (_phone != _activity.Phone) { - _company.Phone = _draft.Phone; + _company.Phone = _activity.Phone; // update company phone record - await _companyRepo.UpdateCompany(_company.CompanyId, _company); + await CompanyRepo.UpdateCompany(_company.CompanyId, _company); } + + Logger.LogDebug("CrmNewActivityPage => \n {}", JsonSerializer.Serialize(_activity)); + // post to api - var result = await CrmActivityRepo.CreateActivity(_draft); + var result = await CrmActivityRepo.CreateActivity(_activity); + + Logger.LogDebug("ApiResponseView => \n {}", JsonSerializer.Serialize(result)); + // show result message - _toast.ShowSuccess($"{result.Message}."); + if (result.IsSuccess) + { + Toast.ShowSuccess($"{result.Message}", "RESULTAT"); + if(DraftStateProvider.Draft.Items.Any()) + Toast.ShowSuccess($"{result.Message}.", "BESTILLING OPRETTET"); + + await DraftStateProvider.DeleteDraftAsync(); + Navigator.NavigateTo($"/companies"); + } + Toast.ShowError(result.Message, "ORDRE FEJL"); _selectedItem = new SalesItemView(); - await DraftStateProvider.DeleteDraftAsync(); - _navigator.NavigateTo($"/companies"); } private void CheckActivity() { - InvalidActivityType = string.IsNullOrWhiteSpace(_draft.ActivityTypeEnum); + InvalidActivityType = string.IsNullOrWhiteSpace(_activity.ActivityTypeEnum); } private async Task DeleteDraft() @@ -301,8 +313,8 @@ public partial class CrmNewActivityPage : IDisposable InvalidActivity = InvalidActivityType || _poFormInvalid || DraftStateProvider.Draft.Items.Count == 0 - || (_draft.ActivityStatusEnum == "offer" && string.IsNullOrWhiteSpace(_draft.Email)); - if (_draft.YourRef.Length > 35 || _draft.ReferenceNumber.Length > 20) + || (_activity.ActivityStatusEnum == "offer" && string.IsNullOrWhiteSpace(_activity.Email)); + if (_activity.YourRef.Length > 35 || _activity.ReferenceNumber.Length > 20) { _poFormInvalid = true; return; @@ -319,9 +331,9 @@ public partial class CrmNewActivityPage : IDisposable } private void ValidationChanged(object sender, ValidationStateChangedEventArgs e) { - if (string.IsNullOrEmpty(_draft.ActivityTypeEnum) && !_reportClosdd) + if (string.IsNullOrEmpty(_activity.ActivityTypeEnum) && !_reportClosdd) { - _toast.ShowWarning("Aktivitet type kan ikke være tom"); + Toast.ShowWarning("Aktivitet type kan ikke være tom"); return; } @@ -329,14 +341,14 @@ public partial class CrmNewActivityPage : IDisposable _editContext.OnFieldChanged -= HandleFieldChanged; _editContext.OnValidationStateChanged -= ValidationChanged; - _editContext = new EditContext(_draft); + _editContext = new EditContext(_activity); _editContext.OnFieldChanged += HandleFieldChanged; _editContext.OnValidationStateChanged += ValidationChanged; } public void Dispose() { - _interceptor.DisposeEvent(); + Interceptor.DisposeEvent(); _editContext.OnFieldChanged -= HandleFieldChanged; _editContext.OnValidationStateChanged -= ValidationChanged; } diff --git a/Wonky.Client/Pages/CrmViewActivityPage.razor b/Wonky.Client/Pages/CrmViewActivityPage.razor index 91d753e3..8d496888 100644 --- a/Wonky.Client/Pages/CrmViewActivityPage.razor +++ b/Wonky.Client/Pages/CrmViewActivityPage.razor @@ -1,4 +1,6 @@ @using Microsoft.AspNetCore.Authorization +@using System.Security.Claims + @attribute [Authorize(Roles = "Admin,Office,Warehouse,Advisor")] @page "/companies/{CompanyId}/orders/{OrderId}" @@ -20,11 +22,33 @@ } @if (ReportItem.Express) { -

HASTER

+

HASTER

}
+ @if (ReportItem.Express && ReportItem.ProcessStatusEnum.ToLower() == "none") + { +
+ +
+ + + + + + + + + + + } + else + { +
+ +
+ } @@ -121,7 +145,10 @@ } else { -
-

@ReportItem.OfficeNote

-
+ @if (!string.IsNullOrWhiteSpace(ReportItem.OfficeNote)) + { +
+

@ReportItem.OfficeNote

+
+ } } diff --git a/Wonky.Client/Pages/CrmViewActivityPage.razor.cs b/Wonky.Client/Pages/CrmViewActivityPage.razor.cs index 3d4ce918..28ac032d 100644 --- a/Wonky.Client/Pages/CrmViewActivityPage.razor.cs +++ b/Wonky.Client/Pages/CrmViewActivityPage.razor.cs @@ -37,6 +37,11 @@ public partial class CrmViewActivityPage : IDisposable _logger.LogDebug("ReportItem => \n {}", JsonSerializer.Serialize(ReportItem)); } + private async Task SetExpressState() + { + + } + private void HandleFieldChanged(object sender, FieldChangedEventArgs e) { StateHasChanged(); diff --git a/Wonky.Client/Pages/CrmViewActivityPage.razor.css b/Wonky.Client/Pages/CrmViewActivityPage.razor.css index e69de29b..ae5e83ba 100644 --- a/Wonky.Client/Pages/CrmViewActivityPage.razor.css +++ b/Wonky.Client/Pages/CrmViewActivityPage.razor.css @@ -0,0 +1,6 @@ +#watermark { + position: fixed; + z-index: 999; + top: 30px; + right: 0; +} \ No newline at end of file diff --git a/Wonky.Client/Pages/ErrorPage404.razor.cs b/Wonky.Client/Pages/ErrorPage404.razor.cs index 5327505f..c22a2502 100644 --- a/Wonky.Client/Pages/ErrorPage404.razor.cs +++ b/Wonky.Client/Pages/ErrorPage404.razor.cs @@ -17,7 +17,7 @@ using Microsoft.AspNetCore.Components; namespace Wonky.Client.Pages; -public partial class Page404 +public partial class ErrorPage404 { [Inject] public NavigationManager NavigationManager { get; set; } diff --git a/Wonky.Client/Pages/ErrorReportPage.razor.cs b/Wonky.Client/Pages/ErrorReportPage.razor.cs index ee6104c5..3561c84d 100644 --- a/Wonky.Client/Pages/ErrorReportPage.razor.cs +++ b/Wonky.Client/Pages/ErrorReportPage.razor.cs @@ -17,7 +17,7 @@ using Microsoft.AspNetCore.Components; namespace Wonky.Client.Pages { - public partial class SiteErrorReport + public partial class ErrorReportPage { [Parameter] public int ErrorCode { get; set; } diff --git a/Wonky.Client/Pages/OfficeListCustomerPage.razor.cs b/Wonky.Client/Pages/OfficeListCustomerPage.razor.cs index 4704a488..5991046a 100644 --- a/Wonky.Client/Pages/OfficeListCustomerPage.razor.cs +++ b/Wonky.Client/Pages/OfficeListCustomerPage.razor.cs @@ -68,6 +68,7 @@ public partial class OfficeListCustomerPage : IDisposable _paging.HasFolded = _includeFolded ? 1 : 0; await GetCompanies(); } + private async Task SelectedPage(int page) { _companyList = new List(); diff --git a/Wonky.Client/Pages/OfficeViewReportPage.razor b/Wonky.Client/Pages/OfficeViewReportPage.razor index 5177e872..21457787 100644 --- a/Wonky.Client/Pages/OfficeViewReportPage.razor +++ b/Wonky.Client/Pages/OfficeViewReportPage.razor @@ -61,7 +61,7 @@ @if (_items.Any()) { - @foreach (var item in _items) + @foreach (var item in _items.Where(item => item.StatusTypeEnum.ToLower() != "offer" || item.ProcessStatusEnum.ToLower() == "none")) { } diff --git a/Wonky.Client/Pages/PreferencesPage.razor b/Wonky.Client/Pages/PreferencesPage.razor index 5f0a8a82..a375a499 100644 --- a/Wonky.Client/Pages/PreferencesPage.razor +++ b/Wonky.Client/Pages/PreferencesPage.razor @@ -1,5 +1,42 @@ -@page "/PreferencesPage" -

PreferencesPage

+@using Wonky.Client.Components +@page "/preferences" +

Indstillinger

+ +
+ +
+ +
+
+ +
+ +
+ +
+
+ +
+ +
+ +
+
+ +
+ +
+ +
+
+ +
+ +
+ +
+
+ @code { diff --git a/Wonky.Client/Shared/MainLayout.razor b/Wonky.Client/Shared/MainLayout.razor index 2b8defc3..7115255a 100644 --- a/Wonky.Client/Shared/MainLayout.razor +++ b/Wonky.Client/Shared/MainLayout.razor @@ -32,6 +32,6 @@
@Body
- +
diff --git a/Wonky.Client/Shared/PriceListModal.razor b/Wonky.Client/Shared/PriceListModal.razor index 818caae2..32160d5f 100644 --- a/Wonky.Client/Shared/PriceListModal.razor +++ b/Wonky.Client/Shared/PriceListModal.razor @@ -27,10 +27,10 @@
- +
- +
@*
*@ @* *@ diff --git a/Wonky.Client/wwwroot/appsettings.json b/Wonky.Client/wwwroot/appsettings.json index 4c42f59d..3b76c95a 100644 --- a/Wonky.Client/wwwroot/appsettings.json +++ b/Wonky.Client/wwwroot/appsettings.json @@ -1,7 +1,7 @@ { "appInfo": { "name": "Wonky Client", - "version": "0.22.1", + "version": "0.23.1", "rc": true, "sandBox": true, "image": "grumpy-coder.png" diff --git a/Wonky.Client/wwwroot/index.html b/Wonky.Client/wwwroot/index.html index 807bf0c0..e8ba2952 100644 --- a/Wonky.Client/wwwroot/index.html +++ b/Wonky.Client/wwwroot/index.html @@ -18,7 +18,7 @@ - + diff --git a/Wonky.Entity/DTO/ActivityDto.cs b/Wonky.Entity/DTO/ActivityDto.cs index aa532016..1e962cae 100644 --- a/Wonky.Entity/DTO/ActivityDto.cs +++ b/Wonky.Entity/DTO/ActivityDto.cs @@ -22,7 +22,7 @@ public class ActivityDto /// /// Activity entity id /// - public string ActivityId { get; set; } = ""; + public string SalesHeadId { get; set; } = ""; /// /// Sales representative identification diff --git a/Wonky.Entity/Views/ApiResponseView.cs b/Wonky.Entity/Views/ApiResponseView.cs index 9556dfed..76591b26 100644 --- a/Wonky.Entity/Views/ApiResponseView.cs +++ b/Wonky.Entity/Views/ApiResponseView.cs @@ -20,7 +20,7 @@ namespace Wonky.Entity.Views; public class ApiResponseView { public bool IsSuccess { get; set; } - public HttpStatusCode Code { get; set; } + public int Code { get; set; } public string Message { get; set; } = ""; public string Id { get; set; } = ""; } \ No newline at end of file