WIP: Document administration

This commit is contained in:
Frede Hundewadt 2023-04-10 17:22:24 +02:00
parent d0ac78028d
commit 97608df37b
131 changed files with 2975 additions and 924 deletions

View file

@ -0,0 +1,31 @@
using Wonky.Entity.DTO;
namespace Wonky.Client.HttpRepository;
public interface ISystemLabelsRepository
{
Task<KrvEmergencyLabels> GetKrvEmergencyLabels();
Task UpdateKrvEmergencyLabels(KrvEmergencyLabels model);
Task<KrvFirstAidLabels> GetKrvFirstAidLabels();
Task UpdateKrvFirstAidLabels(KrvFirstAidLabels model);
Task<KrvKapvLabels> GetKrvKapvLabels();
Task UpdateKrvKapvLabels(KrvKapvLabels model);
Task<KrvProductLabels> GetKrvProductLabels();
Task UpdateKrvProductLabels(KrvProductLabels model);
Task<KrvProtectionLabels> GetKrvProtectionLabels();
Task UpdateKrvProtectionLabels(KrvProtectionLabels model);
Task<KrvSignatureLabels> GetKrvSignatureLabels();
Task UpdateKrvSignatureLabels(KrvSignatureLabels model);
Task<KrvWasteLabels> GetKrvWasteLabels();
Task UpdateKrvWasteLabels(KrvWasteLabels model);
Task<SystemQuoteLabels> GetSystemQuoteLabels();
Task UpdateSystemQuoteLabels(SystemQuoteLabels model);
}

View file

@ -0,0 +1,72 @@
using Wonky.Entity.DTO;
namespace Wonky.Client.HttpRepository;
public interface ISystemTextsRepository
{
Task<KrvEmergencyTexts> GetKrvEmergencyTexts();
Task UpdateKrvEmergencyTexts(KrvEmergencyTexts model);
Task<KrvFirstAidTexts> GetKrvFirstAidTexts();
Task UpdateKrvFirstAidTexts(KrvFirstAidTexts model);
Task<KrvWasteTexts> GetKrvWasteTexts();
Task UpdateKrvWasteTexts(KrvWasteTexts model);
Task<KrvClpPictogramTexts> GetKrvClpPictogramTexts();
Task UpdateKrvClpPictogramTexts(KrvClpPictogramTexts model);
Task<KrvCommonPrintTexts> GetKrvCommonPrintTexts();
Task UpdateKrvCommonPrintTexts(KrvCommonPrintTexts model);
Task<KrvCommonProductTexts> GetKrvCommonProductTexts();
Task UpdateKrvCommonProductTexts(KrvCommonProductTexts model);
Task<KrvKapvDefaultTexts> GetKrvKapvDefaultTexts();
Task UpdateKrvKapvDefaultTexts(KrvKapvDefaultTexts model);
Task<KrvSection0Texts> GetKrvKapvSection0Texts();
Task UpdateKrvKapvSection0Texts(KrvSection0Texts model);
Task<KrvSection1Texts> GetKrvKapvSection1Texts();
Task UpdateKrvKapvSection1Texts(KrvSection1Texts model);
Task<KrvSection2Texts> GetKrvKapvSection2Texts();
Task UpdateKrvKapvSection2Texts(KrvSection2Texts model);
Task<KrvSection3Texts> GetKrvKapvSection3Texts();
Task UpdateKrvKapvSection3Texts(KrvSection3Texts model);
Task<KrvSection4Texts> GetKrvKapvSection4Texts();
Task UpdateKrvKapvSection4Texts(KrvSection4Texts model);
Task<KrvSection5Texts> GetKrvKapvSection5Texts();
Task UpdateKrvKapvSection5Texts(KrvSection5Texts model);
Task<KrvSection6Texts> GetKrvKapvSection6Texts();
Task UpdateKrvKapvSection6Texts(KrvSection6Texts model);
Task<KrvSection7Texts> GetKrvKapvSection7Texts();
Task UpdateKrvKapvSection7Texts(KrvSection7Texts model);
Task<KrvSection8Texts> GetKrvKapvSection8Texts();
Task UpdateKrvKapvSection8Texts(KrvSection8Texts model);
Task<KrvSection9Texts> GetKrvKapvSection9Texts();
Task UpdateKrvKapvSection9Texts(KrvSection9Texts model);
Task<KrvEPhraseTexts> GetKrvEPhraseTexts();
Task UpdateKrvEPhraseTexts(KrvEPhraseTexts model);
Task<KrvHPhraseTexts> GetKrvHPhraseTexts();
Task UpdateKrvHPhraseTexts(KrvHPhraseTexts model);
Task<KrvPPhraseTexts> GetKrvPPhraseTexts();
Task UpdateKrvPPhraseTexts(KrvPPhraseTexts model);
Task<SystemQuoteTexts> GetSystemQuoteTexts();
Task UpdateSystemQuoteTexts(SystemQuoteTexts model);
Task<SystemQuoteMailTexts> GetSystemQuoteMailTexts();
Task UpdateSystemQuoteMailTexts(SystemQuoteMailTexts model);
}

View file

@ -14,6 +14,7 @@
//
using System.Net.Http.Json;
using System.Reflection.Metadata.Ecma335;
using System.Text.Json;
using Microsoft.AspNetCore.Components;
using Microsoft.Extensions.Options;
@ -53,7 +54,8 @@ public class OrderProcessRepository : IOrderProcessRepository
/// <returns></returns>
public async Task<List<WarehouseOrderView>> GetWarehouseOrderListByDate(string date)
{
return await _client.GetFromJsonAsync<List<WarehouseOrderView>>($"{_api.Warehouse}/date?date={date}", _options);
var result = await _client.GetFromJsonAsync<List<WarehouseOrderView>>($"{_api.Warehouse}/date?date={date}", _options);
return result ?? new List<WarehouseOrderView>();
}
/// <summary>
@ -64,8 +66,9 @@ public class OrderProcessRepository : IOrderProcessRepository
/// <returns></returns>
public async Task<List<WarehouseOrderView>> GetWarehouseOrderListByStatus(string status, string express = "")
{
return await _client.GetFromJsonAsync<List<WarehouseOrderView>>(
var result = await _client.GetFromJsonAsync<List<WarehouseOrderView>>(
$"{_api.Warehouse}?status={status}&express={express}/state", _options);
return result ?? new List<WarehouseOrderView>();
}
/// <summary>
@ -75,7 +78,8 @@ public class OrderProcessRepository : IOrderProcessRepository
/// <returns></returns>
public async Task<WarehouseOrderView> GetWarehouseOrder(string orderId)
{
return await _client.GetFromJsonAsync<WarehouseOrderView>($"{_api.Warehouse}/{orderId}", _options);
var result = await _client.GetFromJsonAsync<WarehouseOrderView>($"{_api.Warehouse}/{orderId}", _options);
return result ?? new WarehouseOrderView();
}
/// <summary>

View file

@ -0,0 +1,118 @@
using System.Net.Http.Json;
using System.Text.Json;
using Microsoft.AspNetCore.Components;
using Microsoft.Extensions.Options;
using Wonky.Entity.Configuration;
using Wonky.Entity.DTO;
namespace Wonky.Client.HttpRepository;
public class SystemLabelsRepository : ISystemLabelsRepository
{
private readonly JsonSerializerOptions? _options = new JsonSerializerOptions
{
PropertyNameCaseInsensitive = true
};
private readonly NavigationManager _navigation;
private ILogger<SystemLabelsRepository> _logger;
private readonly HttpClient _client;
private readonly ApiConfig _api;
public SystemLabelsRepository(HttpClient client, ILogger<SystemLabelsRepository> logger,
NavigationManager navigation, IOptions<ApiConfig> configuration)
{
_client = client;
_logger = logger;
_navigation = navigation;
_api = configuration.Value;
}
public async Task<KrvEmergencyLabels> GetKrvEmergencyLabels()
{
var result = await _client.GetFromJsonAsync<KrvEmergencyLabels>($"{_api.SystemLabels}/emergency", _options);
return result ?? new KrvEmergencyLabels();
}
public async Task UpdateKrvEmergencyLabels(KrvEmergencyLabels model)
{
await _client.PutAsJsonAsync($"{_api.SystemLabels}/emergency", model, _options);
}
public async Task<KrvFirstAidLabels> GetKrvFirstAidLabels()
{
var result = await _client.GetFromJsonAsync<KrvFirstAidLabels>($"{_api.SystemLabels}/firstaid", _options);
return result ?? new KrvFirstAidLabels();
}
public async Task UpdateKrvFirstAidLabels(KrvFirstAidLabels model)
{
await _client.PutAsJsonAsync($"{_api.SystemLabels}/firstaid", model, _options);
}
public async Task<KrvKapvLabels> GetKrvKapvLabels()
{
var result = await _client.GetFromJsonAsync<KrvKapvLabels>($"{_api.SystemLabels}/kapv", _options);
return result ?? new KrvKapvLabels();
}
public async Task UpdateKrvKapvLabels(KrvKapvLabels model)
{
await _client.PutAsJsonAsync($"{_api.SystemLabels}/kapv", model, _options);
}
public async Task<KrvProductLabels> GetKrvProductLabels()
{
var result = await _client.GetFromJsonAsync<KrvProductLabels>($"{_api.SystemLabels}/product", _options);
return result ?? new KrvProductLabels();
}
public async Task UpdateKrvProductLabels(KrvProductLabels model)
{
await _client.PutAsJsonAsync($"{_api.SystemLabels}/product", model, _options);
}
public async Task<KrvProtectionLabels> GetKrvProtectionLabels()
{
var result = await _client.GetFromJsonAsync<KrvProtectionLabels>($"{_api.SystemLabels}/protection", _options);
return result ?? new KrvProtectionLabels();
}
public async Task UpdateKrvProtectionLabels(KrvProtectionLabels model)
{
await _client.PutAsJsonAsync($"{_api.SystemLabels}/protection", model, _options);
}
public async Task<KrvSignatureLabels> GetKrvSignatureLabels()
{
var result = await _client.GetFromJsonAsync<KrvSignatureLabels>($"{_api.SystemLabels}/signature", _options);
return result ?? new KrvSignatureLabels();
}
public async Task UpdateKrvSignatureLabels(KrvSignatureLabels model)
{
await _client.PutAsJsonAsync($"{_api.SystemLabels}/signature", model, _options);
}
public async Task<KrvWasteLabels> GetKrvWasteLabels()
{
var result = await _client.GetFromJsonAsync<KrvWasteLabels>($"{_api.SystemLabels}/waste", _options);
return result ?? new KrvWasteLabels();
}
public async Task UpdateKrvWasteLabels(KrvWasteLabels model)
{
await _client.PutAsJsonAsync($"{_api.SystemLabels}/waste", model, _options);
}
public async Task<SystemQuoteLabels> GetSystemQuoteLabels()
{
var result = await _client.GetFromJsonAsync<SystemQuoteLabels>($"{_api.SystemLabels}/quote", _options);
return result ?? new SystemQuoteLabels();
}
public async Task UpdateSystemQuoteLabels(SystemQuoteLabels model)
{
await _client.PutAsJsonAsync($"{_api.SystemLabels}/quote", model, _options);
}
}

View file

@ -0,0 +1,272 @@
using System.Net.Http.Json;
using System.Text.Json;
using Microsoft.AspNetCore.Components;
using Microsoft.Extensions.Options;
using Wonky.Entity.Configuration;
using Wonky.Entity.DTO;
namespace Wonky.Client.HttpRepository;
public class SystemTextsRepository : ISystemTextsRepository
{
private readonly JsonSerializerOptions? _options = new JsonSerializerOptions
{
PropertyNameCaseInsensitive = true
};
private readonly NavigationManager _navigation;
private ILogger<SystemTextsRepository> _logger;
private readonly HttpClient _client;
private readonly ApiConfig _api;
public SystemTextsRepository(HttpClient client, ILogger<SystemTextsRepository> logger,
NavigationManager navigation, IOptions<ApiConfig> configuration)
{
_client = client;
_logger = logger;
_navigation = navigation;
_api = configuration.Value;
}
public async Task<KrvEmergencyTexts> GetKrvEmergencyTexts()
{
var result = await _client.GetFromJsonAsync<KrvEmergencyTexts>($"{_api.SystemTexts}/emergency", _options);
return result ?? new KrvEmergencyTexts();
}
public async Task UpdateKrvEmergencyTexts(KrvEmergencyTexts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/emergency", model, _options);
}
public async Task<KrvFirstAidTexts> GetKrvFirstAidTexts()
{
var result = await _client.GetFromJsonAsync<KrvFirstAidTexts>($"{_api.SystemTexts}/firstaid", _options);
return result ?? new KrvFirstAidTexts();
}
public async Task UpdateKrvFirstAidTexts(KrvFirstAidTexts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/firstaid", model, _options);
}
public async Task<KrvWasteTexts> GetKrvWasteTexts()
{
var result = await _client.GetFromJsonAsync<KrvWasteTexts>($"{_api.SystemTexts}/waste", _options);
return result ?? new KrvWasteTexts();
}
public async Task UpdateKrvWasteTexts(KrvWasteTexts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/waste", model, _options);
}
public async Task<KrvClpPictogramTexts> GetKrvClpPictogramTexts()
{
var result = await _client.GetFromJsonAsync<KrvClpPictogramTexts>($"{_api.SystemTexts}/clp", _options);
return result ?? new KrvClpPictogramTexts();
}
public async Task UpdateKrvClpPictogramTexts(KrvClpPictogramTexts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/clp", model, _options);
}
public async Task<KrvCommonPrintTexts> GetKrvCommonPrintTexts()
{
var result = await _client.GetFromJsonAsync<KrvCommonPrintTexts>($"{_api.SystemTexts}/print", _options);
return result ?? new KrvCommonPrintTexts();
}
public async Task UpdateKrvCommonPrintTexts(KrvCommonPrintTexts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/print", model, _options);
}
public async Task<KrvCommonProductTexts> GetKrvCommonProductTexts()
{
var result = await _client.GetFromJsonAsync<KrvCommonProductTexts>($"{_api.SystemTexts}/product", _options);
return result ?? new KrvCommonProductTexts();
}
public async Task UpdateKrvCommonProductTexts(KrvCommonProductTexts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/product", model, _options);
}
public async Task<KrvKapvDefaultTexts> GetKrvKapvDefaultTexts()
{
var result = await _client.GetFromJsonAsync<KrvKapvDefaultTexts>($"{_api.SystemTexts}/kapv", _options);
return result ?? new KrvKapvDefaultTexts();
}
public async Task UpdateKrvKapvDefaultTexts(KrvKapvDefaultTexts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/kapv", model, _options);
}
public async Task<KrvSection0Texts> GetKrvKapvSection0Texts()
{
var result = await _client.GetFromJsonAsync<KrvSection0Texts>($"{_api.SystemTexts}/s0", _options);
return result ?? new KrvSection0Texts();
}
public async Task UpdateKrvKapvSection0Texts(KrvSection0Texts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/s0", model, _options);
}
public async Task<KrvSection1Texts> GetKrvKapvSection1Texts()
{
var result = await _client.GetFromJsonAsync<KrvSection1Texts>($"{_api.SystemTexts}/s1", _options);
return result ?? new KrvSection1Texts();
}
public async Task UpdateKrvKapvSection1Texts(KrvSection1Texts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/s1", model, _options);
}
public async Task<KrvSection2Texts> GetKrvKapvSection2Texts()
{
var result = await _client.GetFromJsonAsync<KrvSection2Texts>($"{_api.SystemTexts}/s2", _options);
return result ?? new KrvSection2Texts();
}
public async Task UpdateKrvKapvSection2Texts(KrvSection2Texts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/s0", model, _options);
}
public async Task<KrvSection3Texts> GetKrvKapvSection3Texts()
{
var result = await _client.GetFromJsonAsync<KrvSection3Texts>($"{_api.SystemTexts}/s3", _options);
return result ?? new KrvSection3Texts();
}
public async Task UpdateKrvKapvSection3Texts(KrvSection3Texts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/s3", model, _options);
}
public async Task<KrvSection4Texts> GetKrvKapvSection4Texts()
{
var result = await _client.GetFromJsonAsync<KrvSection4Texts>($"{_api.SystemTexts}/s4", _options);
return result ?? new KrvSection4Texts();
}
public async Task UpdateKrvKapvSection4Texts(KrvSection4Texts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/s4", model, _options);
}
public async Task<KrvSection5Texts> GetKrvKapvSection5Texts()
{
var result = await _client.GetFromJsonAsync<KrvSection5Texts>($"{_api.SystemTexts}/s5", _options);
return result ?? new KrvSection5Texts();
}
public async Task UpdateKrvKapvSection5Texts(KrvSection5Texts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/s5", model, _options);
}
public async Task<KrvSection6Texts> GetKrvKapvSection6Texts()
{
var result = await _client.GetFromJsonAsync<KrvSection6Texts>($"{_api.SystemTexts}/s6", _options);
return result ?? new KrvSection6Texts();
}
public async Task UpdateKrvKapvSection6Texts(KrvSection6Texts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/s6", model, _options);
}
public async Task<KrvSection7Texts> GetKrvKapvSection7Texts()
{
var result = await _client.GetFromJsonAsync<KrvSection7Texts>($"{_api.SystemTexts}/s7", _options);
return result ?? new KrvSection7Texts();
}
public async Task UpdateKrvKapvSection7Texts(KrvSection7Texts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/s7", model, _options);
}
public async Task<KrvSection8Texts> GetKrvKapvSection8Texts()
{
var result = await _client.GetFromJsonAsync<KrvSection8Texts>($"{_api.SystemTexts}/s8", _options);
return result ?? new KrvSection8Texts();
}
public async Task UpdateKrvKapvSection8Texts(KrvSection8Texts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/s8", model, _options);
}
public async Task<KrvSection9Texts> GetKrvKapvSection9Texts()
{
var result = await _client.GetFromJsonAsync<KrvSection9Texts>($"{_api.SystemTexts}/s9", _options);
return result ?? new KrvSection9Texts();
}
public async Task UpdateKrvKapvSection9Texts(KrvSection9Texts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/s9", model, _options);
}
public async Task<KrvEPhraseTexts> GetKrvEPhraseTexts()
{
var result = await _client.GetFromJsonAsync<KrvEPhraseTexts>($"{_api.SystemTexts}/erisk", _options);
return result ?? new KrvEPhraseTexts();
}
public async Task UpdateKrvEPhraseTexts(KrvEPhraseTexts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/erisk", model, _options);
}
public async Task<KrvHPhraseTexts> GetKrvHPhraseTexts()
{
var result = await _client.GetFromJsonAsync<KrvHPhraseTexts>($"{_api.SystemTexts}/hrisk", _options);
return result ?? new KrvHPhraseTexts();
}
public async Task UpdateKrvHPhraseTexts(KrvHPhraseTexts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/hrisk", model, _options);
}
public async Task<KrvPPhraseTexts> GetKrvPPhraseTexts()
{
var result = await _client.GetFromJsonAsync<KrvPPhraseTexts>($"{_api.SystemTexts}/prisk", _options);
return result ?? new KrvPPhraseTexts();
}
public async Task UpdateKrvPPhraseTexts(KrvPPhraseTexts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/prisk", model, _options);
}
public async Task<SystemQuoteTexts> GetSystemQuoteTexts()
{
var result = await _client.GetFromJsonAsync<SystemQuoteTexts>($"{_api.SystemTexts}/quote", _options);
return result ?? new SystemQuoteTexts();
}
public async Task UpdateSystemQuoteTexts(SystemQuoteTexts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/quote", model, _options);
}
public async Task<SystemQuoteMailTexts> GetSystemQuoteMailTexts()
{
var result = await _client.GetFromJsonAsync<SystemQuoteMailTexts>($"{_api.SystemTexts}/quotemail", _options);
return result ?? new SystemQuoteMailTexts();
}
public async Task UpdateSystemQuoteMailTexts(SystemQuoteMailTexts model)
{
await _client.PutAsJsonAsync($"{_api.SystemTexts}/quotemail", model, _options);
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/danger"
<PageTitle>Tekster for 'Faremærkning Tekster'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Faremærkning CLP</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,35 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemClpPictogramTextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvClpPictogramTexts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvClpPictogramTexts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,56 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/print"
<PageTitle>Tekster for 'Udskrift Tekster'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Udskrift tekster</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,35 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemCommonPrintTextsiewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvCommonPrintTexts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvCommonPrintTexts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/labels/emergency"
<PageTitle>Labels for 'Nødsituationer APB Dokument'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Ved Uheld</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,35 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentEmergencyLabelsViewEditPage
{
[Inject] public ISystemLabelsRepository LabelsRepo { get; set; }
private KrvEmergencyLabels Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await LabelsRepo.GetKrvEmergencyLabels();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/labels/firstaid"
<PageTitle>Labels for 'Førstehjælp APB Dokument'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Førstehjælp</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,35 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentFirstAidLabelsViewEditPage
{
[Inject] public ISystemLabelsRepository LabelsRepo { get; set; }
private KrvFirstAidLabels Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await LabelsRepo.GetKrvFirstAidLabels();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,40 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@page "/system/labels/"
<div class="card">
<div class="card-header bg-dark text-white">
<div class="mt-3 h3 card-title">
Dokument Labels (beskrivelse af feltindhold)
</div>
</div>
<div class="card-body">
<div class="list-group">
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/labels/emergency">Ved Uheld - APB</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/labels/firstaid">Førstehjælp - APB</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/labels/product">Produkt - APB</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/labels/protection">Værnemidler - APB</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/labels/signature">Signatur - APB</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/labels/waste">Affald og Spild - APB</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/labels/kapv">Kemisk Risiko Vurdering - KAPV</a>
</div>
</div>
<div class="card-body">
<div class="list-group">
<a class="list-group-item list-group-item-action list-group-item-success" href="/system/labels/quote">Tilbud Dokument</a>
</div>
</div>
</div>

View file

@ -0,0 +1,8 @@
namespace Wonky.Client.Pages;
#pragma warning disable CS8618
public partial class SystemDocumentLabelsAdminPage
{
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/labels/kapv"
<PageTitle>Labels for 'KRV Dokument'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Kemisk Risiko Vurdering</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,35 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentLabelsKapvViewEditPage
{
[Inject] public ISystemLabelsRepository LabelsRepo { get; set; }
private KrvKapvLabels Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await LabelsRepo.GetKrvKapvLabels();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/labels/product"
<PageTitle>Labels for 'Produkt APB Dokument'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Produkt</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,35 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentProductLabelsViewEditPage
{
[Inject] public ISystemLabelsRepository LabelsRepo { get; set; }
private KrvProductLabels Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await LabelsRepo.GetKrvProductLabels();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -14,7 +14,7 @@
*@
@page "/system/krv/products"
@page "/system/products"
<div class="card">
<div class="card-header bg-dark text-white">

View file

@ -0,0 +1,6 @@
namespace Wonky.Client.Pages;
public partial class SystemDocumentProductListPage
{
}

View file

@ -16,7 +16,7 @@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/products/{ProductId}/variants"
@page "/system/products/{ProductId}/variants"
<div class="card">
<div class="card-header bg-dark text-white">

View file

@ -17,7 +17,8 @@ using Microsoft.AspNetCore.Components;
namespace Wonky.Client.Pages;
public partial class SystemProductViewEditPage
public partial class SystemDocumentProductVariantListPage
{
[Parameter] public string ProductId { get; set; } = "";
}

View file

@ -16,7 +16,7 @@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/products/{ProductId}/variants/{VariantId}"
@page "/system/products/{ProductId}/variants/{VariantId}"
<div class="card">
<div class="card-header bg-dark text-white">
<div class="mt-3 h3 card-title">

View file

@ -17,7 +17,7 @@ using Microsoft.AspNetCore.Components;
namespace Wonky.Client.Pages;
public partial class SystemProductVariantViewEditPage
public partial class SystemDocumentProductVariantViewEditPage
{
[Parameter]
public string ProductId { get; set; } = "";

View file

@ -16,7 +16,7 @@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/products/{ProductId}"
@page "/system/products/{ProductId}"
<div class="card">
<div class="card-header bg-dark text-white">
<div class="mt-3 h3 card-title">

View file

@ -17,8 +17,7 @@ using Microsoft.AspNetCore.Components;
namespace Wonky.Client.Pages;
public partial class SystemProductVariantListPage
public partial class SystemDocumentProductViewEditPage
{
[Parameter] public string ProductId { get; set; } = "";
}

View file

@ -16,7 +16,7 @@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/protective-equipment/{ProtectionId}/items"
@page "/system/protective-equipment/{ProtectionId}/items"
<div class="card">
<div class="card-header bg-dark text-white">

View file

@ -17,7 +17,7 @@ using Microsoft.AspNetCore.Components;
namespace Wonky.Client.Pages;
public partial class SystemKrvProtectionItemListPage
public partial class SystemDocumentProtectionItemListPage
{
[Parameter] public string ProtectionId { get; set; } = "";
}

View file

@ -16,7 +16,7 @@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/protective-equipment/{ProtectionId}/items/{ItemId}"
@page "/system/protective-equipment/{ProtectionId}/items/{ItemId}"
<div class="card">
<div class="card-header bg-dark text-white">

View file

@ -17,7 +17,7 @@ using Microsoft.AspNetCore.Components;
namespace Wonky.Client.Pages;
public partial class SystemKrvProtectionItemViewEditPage
public partial class SystemDocumentProtectionItemViewEditPage
{
[Parameter] public string ProtectionId { get; set; } = "";
[Parameter] public string ItemId { get; set; } = "";

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/labels/protection"
<PageTitle>Labels for 'Værnemidler APB Dokument'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Værnemidlerd</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,35 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentProtectionLabelsViewEditPage
{
[Inject] public ISystemLabelsRepository LabelsRepo { get; set; }
private KrvProtectionLabels Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await LabelsRepo.GetKrvProtectionLabels();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -14,7 +14,7 @@
*@
@page "/system/krv/protections"
@page "/system/protections"
<div class="card">
<div class="card-header bg-dark text-white">
<div class="mt-3 h3 card-title">

View file

@ -0,0 +1,6 @@
namespace Wonky.Client.Pages;
public partial class SystemDocumentProtectionListPage
{
}

View file

@ -16,7 +16,7 @@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/protective-equipment"
@page "/system/protective-equipment"
<div class="card">
<div class="card-header bg-dark text-white">

View file

@ -15,7 +15,7 @@
namespace Wonky.Client.Pages;
public partial class SystemKrvProtectionTypeListPage
public partial class SystemDocumentProtectionTypeListPage
{
}

View file

@ -16,7 +16,7 @@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/protective-equipment/{ProtectionId}/"
@page "/system/protective-equipment/{ProtectionId}/"
<div class="card">
<div class="card-header bg-dark text-white">

View file

@ -18,7 +18,7 @@ using Microsoft.AspNetCore.Components;
namespace Wonky.Client.Pages;
public partial class SystemKrvProtectionTypeViewEditPage
public partial class SystemDocumentProtectionTypeViewEditPage
{
[Parameter] public string ProtectionId { get; set; } = "";
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/labels/quote"
<PageTitle>Labels for 'Affald og Spild APB/KRV Dokument'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Affald og Spild</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,35 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentQuoteLabelsViewEditPage
{
[Inject] public ISystemLabelsRepository LabelsRepo { get; set; }
private SystemQuoteLabels Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await LabelsRepo.GetSystemQuoteLabels();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/riske"
<PageTitle>Tekster for 'Risiko Tekster EUH'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Risiko tekster gruppe EUH</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,35 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentRiskETextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvEPhraseTexts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvEPhraseTexts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/riskh"
<PageTitle>Tekster for 'Risiko Tekster H'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Risiko tekster gruppe H</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,37 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentRiskHTextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvHPhraseTexts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvHPhraseTexts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/riskp"
<PageTitle>Tekster for 'Risiko Tekster P'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Risiko tekster gruppe P</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,36 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentRiskPTextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvPPhraseTexts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvPPhraseTexts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,58 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/section0"
<PageTitle>Tekster for 'Forudsætninger for risikovurdering'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Forudsætninger for udarbejdelse af risikovurdering</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,37 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentSection0TextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvSection0Texts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvKapvSection0Texts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/section1"
<PageTitle>Tekster for 'Produkt/Anvendelse'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Produkt/Anvendelse</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,36 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentSection1TextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvSection1Texts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvKapvSection1Texts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/section2"
<PageTitle>Tekster for 'Egenskaber'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Egenskaber</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,36 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentSection2TextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvSection2Texts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvKapvSection2Texts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/section3"
<PageTitle>Tekster for 'Påvirkning/Mængde'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Påvirkning og Mængde</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,37 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentSection3TextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvSection3Texts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvKapvSection3Texts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/section4"
<PageTitle>Tekster for 'Forebyggelse'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Forebyggelse</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,37 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentSection4TextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvSection5Texts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvKapvSection5Texts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/section5"
<PageTitle>Tekster for 'Arbejdsmedicinske Referencer'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Arbejdsmedicinske undersøgelser og referencer</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,37 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentSection5TextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvSection5Texts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvKapvSection5Texts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/section6"
<PageTitle>Tekster for 'Substitution/Alternativer'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Substitution/Alternativer</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,37 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentSection6TextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvSection6Texts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvKapvSection6Texts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/section7"
<PageTitle>Tekster for 'Fastsatte grænseværdier'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Grænseværdier fastsat af arbejdstilsynet</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,37 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentSection7TextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvSection7Texts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvKapvSection7Texts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/section8"
<PageTitle>Tekster for 'Uddannelse'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Kræves særlig uddannnelse</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,37 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentSection8TextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvSection8Texts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvKapvSection8Texts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/section9"
<PageTitle>Tekster for 'Afvigelser'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Er der afvigelser</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,37 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentSection9TextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvSection9Texts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvKapvSection9Texts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/labels/signature"
<PageTitle>Labels for 'Signatur APB/KRV Dokument'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Signaturer</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,35 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentSignatureLabelsViewEditPage
{
[Inject] public ISystemLabelsRepository LabelsRepo { get; set; }
private KrvSignatureLabels Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await LabelsRepo.GetKrvSignatureLabels();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -14,34 +14,47 @@
*@
@page "/system/krv/texts/"
@page "/system/texts/"
<div class="card">
<div class="card-header bg-dark text-white">
<div class="mt-3 h3 card-title">
KRV Risiko Tekst Vedligeholdelse
Dokument Tekster
</div>
</div>
<div class="card-body">
<div class="list-group">
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/krv/texts/section1">Produkt/Anvendelse</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/krv/texts/section2">Egenskaber</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/krv/texts/section3">Påvirkning/Mængde</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/krv/texts/section4">Forebyggelse</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/krv/texts/section5">Arbejdsmedicinske undersøgelser og referencer</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/krv/texts/section6">Substitution/Alternativer</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/krv/texts/section7">Grænseværdier fastsat af arbejdstilsynet</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/krv/texts/section8">Kræves særlig uddannnelse</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/krv/texts/section9">Er der afvigelser</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/krv/texts/sectiona">Anslået mængde anvendt årligt</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/krv/texts/section0">Forudsætninger for udarbejdelse af risikovurdering</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/krv/texts/firstaid">Førstehjælp</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/krv/texts/accident">Ved Uheld</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/krv/texts/waste">Affald og Spild</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/krv/texts/danger">Faremærkning CLP</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/krv/texts/print">Udskrift</a>
<a class="list-group-item list-group-item-action list-group-item-danger" href="/system/krv/texts/riskh">Risikosætninger gruppe H</a>
<a class="list-group-item list-group-item-action list-group-item-danger" href="/system/krv/texts/riskp">Risikosætninger gruppe P</a>
<a class="list-group-item list-group-item-action list-group-item-danger" href="/system/krv/texts/riske">Risikosætninger gruppe EUH</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/texts/section1">Produkt/Anvendelse</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/texts/section2">Egenskaber</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/texts/section3">Påvirkning/Mængde</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/texts/section4">Forebyggelse</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/texts/section5">Arbejdsmedicinske undersøgelser og referencer</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/texts/section6">Substitution/Alternativer</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/texts/section7">Grænseværdier fastsat af arbejdstilsynet</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/texts/section8">Kræves særlig uddannnelse</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/texts/section9">Er der afvigelser</a>
<a class="list-group-item list-group-item-action list-group-item-info" href="/system/texts/section0">Forudsætninger for udarbejdelse af risikovurdering</a>
</div>
</div>
<div class="card-body">
<div class="list-group">
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/texts/firstaid">Førstehjælp</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/texts/accident">Ved Uheld</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/texts/waste">Affald og Spild</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/texts/danger">Faremærkning CLP</a>
<a class="list-group-item list-group-item-action list-group-item-warning" href="/system/texts/print">Udskrift</a>
</div>
</div>
<div class="card-body">
<div class="list-group">
<a class="list-group-item list-group-item-action list-group-item-danger" href="/system/texts/riskh">Risikosætninger gruppe H</a>
<a class="list-group-item list-group-item-action list-group-item-danger" href="/system/texts/riskp">Risikosætninger gruppe P</a>
<a class="list-group-item list-group-item-action list-group-item-danger" href="/system/texts/riske">Risikosætninger gruppe EUH</a>
</div>
</div>
<div class="card-body">
<div class="list-group">
<a class="list-group-item list-group-item-action list-group-item-success" href="/system/texts/quote">Tilbud tekster</a>
<a class="list-group-item list-group-item-action list-group-item-success" href="/system/texts/quotemail">Tilbud mail tekster</a>
</div>
</div>
</div>

View file

@ -0,0 +1,6 @@
namespace Wonky.Client.Pages;
public partial class SystemDocumentTextsAdminPage
{
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/labels/waste"
<PageTitle>Labels for 'Affald og Spild APB/KRV Dokument'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Affald og Spild</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,35 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemDocumentWasteLabelsViewEditPage
{
[Inject] public ISystemLabelsRepository LabelsRepo { get; set; }
private KrvWasteLabels Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await LabelsRepo.GetKrvWasteLabels();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/accident"
<PageTitle>Tekster for 'Nødsituationer'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Ved Uheld</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,33 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
namespace Wonky.Client.Pages;
public partial class SystemEmergcencyTextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvEmergencyTexts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvEmergencyTexts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -0,0 +1,54 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/texts/firstaid"
<PageTitle>Tekster for 'Førstehjælp Tekster'</PageTitle>
<div class="card">
<div class="card-header">
<div class="card-title">
<h3>Førstehjælp</h3>
</div>
</div>
<div class="card-body">
@if (TextProps.Any())
{
<table class="table table-striped">
<thead>
<tr>
<td>Navn</td>
<td>Tekst</td>
</tr>
</thead>
<tbody>
@foreach (var textProp in TextProps)
{
<tr>
<td>@textProp.Name</td>
<td><input type="text" class="form-control" name="@textProp.Name" value="@textProp.GetValue(Section, null)"/></td>
</tr>
}
</tbody>
</table>
}
else
{
<div>Ingen data!</div>
}
</div>
</div>

View file

@ -0,0 +1,35 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
using System.Reflection;
using Microsoft.AspNetCore.Components;
using Wonky.Client.HttpRepository;
using Wonky.Entity.DTO;
#pragma warning disable CS8618
namespace Wonky.Client.Pages;
public partial class SystemFirstAidTextsViewEditPage
{
[Inject] public ISystemTextsRepository TextsRepo { get; set; }
private KrvFirstAidTexts Section { get; set; } = new();
private PropertyInfo[] TextProps { get; set; }
protected override async Task OnInitializedAsync()
{
Section = await TextsRepo.GetKrvFirstAidTexts();
TextProps = Section.GetType().GetProperties();
}
}

View file

@ -1,6 +0,0 @@
namespace Wonky.Client.Pages;
public partial class SystemKrvProtectionListPage
{
}

View file

@ -1,21 +0,0 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/texts/accident"
<h3>Ved Uheld</h3>

View file

@ -1,21 +0,0 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
namespace Wonky.Client.Pages;
public partial class SystemKrvTextsAccidentViewEditPage
{
}

View file

@ -1,6 +0,0 @@
namespace Wonky.Client.Pages;
public partial class SystemKrvTextsAdminPage
{
}

View file

@ -1,20 +0,0 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/texts/danger"
<h3>Faremærkning CLP</h3>

View file

@ -1,22 +0,0 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
namespace Wonky.Client.Pages;
public partial class SystemKrvTextsDangerMarkingViewEditPage
{
}

View file

@ -1,21 +0,0 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/texts/firstaid"
<h3>Førstehjælp</h3>

View file

@ -1,22 +0,0 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
namespace Wonky.Client.Pages;
public partial class SystemKrvTextsFirstAidViewEditPage
{
}

View file

@ -1,21 +0,0 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/texts/print"
<h3>Udskrift tekster</h3>

View file

@ -1,22 +0,0 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
namespace Wonky.Client.Pages;
public partial class SystemKrvTextsPrintingViewEditPage
{
}

View file

@ -1,25 +0,0 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/texts/riske"
<h3>Risiko tekster gruppe EUH</h3>
@code {
}

View file

@ -1,21 +0,0 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
namespace Wonky.Client.Pages;
public partial class SystemKrvTextsRiskPhraseEViewEditPage
{
}

View file

@ -1,25 +0,0 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/texts/riskh"
<h3>Risiko tekster gruppe H</h3>
@code {
}

View file

@ -1,21 +0,0 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
namespace Wonky.Client.Pages;
public partial class SystemKrvTextsRiskPhraseHViewEditPage
{
}

View file

@ -1,25 +0,0 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/texts/riskp"
<h3>Risiko tekster gruppe P</h3>
@code {
}

View file

@ -1,21 +0,0 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
namespace Wonky.Client.Pages;
public partial class SystemKrvTextsRiskPhrasePViewEditPage
{
}

View file

@ -1,21 +0,0 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/texts/section0"
<h3>Forudsætninger for udarbejdelse af risikovurdering</h3>

View file

@ -1,22 +0,0 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
namespace Wonky.Client.Pages;
public partial class SystemKrvTextsSection0ViewEditPage
{
}

View file

@ -1,20 +0,0 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/texts/section1"
<h3>Produkt/Anvendelse</h3>

View file

@ -1,21 +0,0 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
namespace Wonky.Client.Pages;
public partial class SystemKrvTextsSection1ViewEditPage
{
}

View file

@ -1,21 +0,0 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/texts/section2"
<h3>Egenskaber</h3>

View file

@ -1,21 +0,0 @@
// Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
//
namespace Wonky.Client.Pages;
public partial class SystemKrvTextsSection2ViewEditPage
{
}

View file

@ -1,21 +0,0 @@
@* Copyright (C) 2022 FCS Frede's Computer Services.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see [https://www.gnu.org/licenses/agpl-3.0.en.html]
*@
@using Microsoft.AspNetCore.Authorization
@attribute [Authorize(Roles = "Admin")]
@page "/system/krv/texts/section3"
<h3>Påvirkning og mængde</h3>

Some files were not shown because too many files have changed in this diff Show more