From afaafbe713de0cb57debdaa8fe80dd6307de05a4 Mon Sep 17 00:00:00 2001 From: Jonathan McCaffrey Date: Sun, 24 Apr 2022 19:33:18 -0400 Subject: [PATCH] feat(Permission) Added start of the Storage feature. Detailed/Plain default toggle --- Components/Components.csproj | 16 +-- Components/Form/FormToggleComponent.razor | 122 ++++++++++++++++++ Components/Inputs/SearchButtonComponent.razor | 10 +- IGP/App.razor | 6 +- IGP/Database.db | Bin 278528 -> 278528 bytes IGP/IGP.csproj | 1 + IGP/Index.razor | 2 +- .../Parts/EntityClickViewComponent.razor | 55 +++++--- ...icsPage.razor => DataCollectionPage.razor} | 2 +- IGP/Pages/PermissionsPage.razor | 65 +++++++++- IGP/Pages/StoragePage.razor | 64 +++++++-- IGP/Program.cs | 24 +++- IGP/wwwroot/generated/AgileTaskModels.json | 2 +- IGP/wwwroot/generated/WebPageModels.json | 2 +- IGP/wwwroot/index.html | 1 + Services/IServices.cs | 28 +++- Services/Immortal/EntityDisplayService.cs | 26 +++- Services/Services.csproj | 7 +- Services/Website/PermissionService.cs | 64 +++++++++ Services/Website/StorageService.cs | 106 +++++++++++++++ 20 files changed, 538 insertions(+), 65 deletions(-) create mode 100644 Components/Form/FormToggleComponent.razor rename IGP/Pages/{AnaltyicsPage.razor => DataCollectionPage.razor} (83%) create mode 100644 Services/Website/PermissionService.cs create mode 100644 Services/Website/StorageService.cs diff --git a/Components/Components.csproj b/Components/Components.csproj index 3dc3012..a2fe5ef 100644 --- a/Components/Components.csproj +++ b/Components/Components.csproj @@ -15,24 +15,24 @@ - + - - - + + + - + - - + + - + diff --git a/Components/Form/FormToggleComponent.razor b/Components/Form/FormToggleComponent.razor new file mode 100644 index 0000000..bd9823a --- /dev/null +++ b/Components/Form/FormToggleComponent.razor @@ -0,0 +1,122 @@ +
+
+
+ @Label: +
+ +
+ @if (Info != "") + { +
+ @Info +
+ } +
+ + +@code { + + [Parameter] + public string Label { get; set; } = ""; + + [Parameter] + public string Info { get; set; } = ""; + + [Parameter] + public EventCallback OnChange { get; set; } + + [Parameter] + public bool ReadOnly { get; set; } + + [Parameter] + public bool Value { get; set; } + + private string labelId = ""; + + protected override void OnInitialized() + { + labelId = Label.ToLower().Replace(" ", "_"); + } + +} \ No newline at end of file diff --git a/Components/Inputs/SearchButtonComponent.razor b/Components/Inputs/SearchButtonComponent.razor index 818ec9d..aaa1d9a 100644 --- a/Components/Inputs/SearchButtonComponent.razor +++ b/Components/Inputs/SearchButtonComponent.razor @@ -1,6 +1,6 @@ -@inject ISearchService searchService -@inject NavigationManager navigationManager -@inject IJSRuntime jsRuntime +@inject ISearchService SearchService +@inject NavigationManager NavigationManager +@inject IJSRuntime JsRuntime