Merge branch 'develop' of https://gitlab.steamware.net/egalware/webdoorcreator into develop
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
<body>
|
||||
<i>WebDoorCreator - Egalware</i>
|
||||
<h4>Version: 0.9.2305.2319</h4>
|
||||
<h4>Version: 0.9.2305.2414</h4>
|
||||
<br /> Release note:
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
@@ -1 +1 @@
|
||||
0.9.2305.2319
|
||||
0.9.2305.2414
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<item>
|
||||
<version>0.9.2305.2319</version>
|
||||
<version>0.9.2305.2414</version>
|
||||
<url>http://nexus.steamware.net/repository/SWS/WDC/stable/WDC.UI.zip</url>
|
||||
<changelog>http://nexus.steamware.net/repository/SWS/WDC/stable/ChangeLog.html</changelog>
|
||||
<mandatory>false</mandatory>
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
@if (isAdd)
|
||||
{
|
||||
<button class="btn btn-sm btn-success" @onclick="()=>addOrRemoveOneDoorNumber()"><i class="fa-solid fa-plus"></i> <i class="fa-solid fa-1"></i></button>
|
||||
}
|
||||
else
|
||||
{
|
||||
<button class="btn btn-sm btn-danger" @onclick="()=>addOrRemoveOneDoorNumber()"><i class="fa-solid fa-minus"></i> <i class="fa-solid fa-1"></i></button>
|
||||
}
|
||||
@@ -1,47 +0,0 @@
|
||||
using Microsoft.AspNetCore.Components;
|
||||
using Microsoft.AspNetCore.Identity;
|
||||
using Microsoft.JSInterop;
|
||||
using WebDoorCreator.Data.Services;
|
||||
using WebDoorCreator.UI.Data;
|
||||
|
||||
namespace WebDoorCreator.UI.Components.Buttons
|
||||
{
|
||||
public partial class ButtonAddRemDoor
|
||||
{
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
|
||||
[Inject]
|
||||
protected IJSRuntime JSRuntime { get; set; } = null!;
|
||||
|
||||
[Inject]
|
||||
protected NavigationManager NavManager { get; set; } = null!;
|
||||
|
||||
[Parameter]
|
||||
public int DoorId { get; set; } = 0;
|
||||
[Parameter]
|
||||
public int OrderId { get; set; } = 0;
|
||||
|
||||
[Parameter]
|
||||
public bool isAdd { get; set; }
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<bool> E_isChange { get; set; }
|
||||
|
||||
protected bool doorChange { get; set; } = false;
|
||||
|
||||
protected async Task addOrRemoveOneDoorNumber()
|
||||
{
|
||||
#if false
|
||||
//var door = new DoorModel();
|
||||
doorChange = false;
|
||||
var done = await WDService.DoorModQty(OrderId, DoorId, isAdd);
|
||||
if (done)
|
||||
{
|
||||
doorChange = true;
|
||||
await E_isChange.InvokeAsync(doorChange);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -2,6 +2,7 @@
|
||||
@if (B_doorOpUpd || true)
|
||||
{
|
||||
<button class="btn btn-success" @onclick="() => doSave()"><i class="fa-solid fa-rotate-right"></i></button>
|
||||
<button class="btn btn-info" @onclick="() => doRecalcAll()"><i class="fa-solid fa-window-restore"></i></button>
|
||||
<a class="btn btn-warning" href="https://iis01.egalware.com/Test3D/Doors041122/EXB_0267100040/EXB_0267100040.html" target="_blank"><i class="fa-solid fa-cube"></i></a>
|
||||
@if (IsErr)
|
||||
{
|
||||
@@ -13,7 +14,6 @@
|
||||
<button class="btn btn-secondary"><i class="fa-solid fa-rotate-right"></i></button>
|
||||
<button class="btn btn-secondary"><i class="fa-solid fa-cube"></i></button>
|
||||
}
|
||||
@*<button class="btn btn-success" @onclick="() => toOrderPage()">Return to Order <b>@idOrd</b></button>*@
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
@@ -28,9 +28,7 @@ namespace WebDoorCreator.UI.Components.Buttons
|
||||
|
||||
#endregion Public Properties
|
||||
|
||||
#region Public Methods
|
||||
|
||||
#endregion Public Methods
|
||||
|
||||
#region Protected Properties
|
||||
|
||||
@@ -128,6 +126,14 @@ namespace WebDoorCreator.UI.Components.Buttons
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
protected async Task doRecalcAll()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
await QDataServ.ResetQueue();
|
||||
await doSave();
|
||||
}
|
||||
|
||||
protected override void OnInitialized()
|
||||
{
|
||||
base.OnInitialized();
|
||||
@@ -145,17 +151,6 @@ namespace WebDoorCreator.UI.Components.Buttons
|
||||
//change = paramsChanged;
|
||||
}
|
||||
|
||||
#if false
|
||||
protected async Task toOrderPage()
|
||||
{
|
||||
if (!await JSRuntime.InvokeAsync<bool>("confirm", $"Do you really want to return to the order page without saving current work?"))
|
||||
return;
|
||||
|
||||
await Task.Delay(1);
|
||||
NavManager.NavigateTo($"OrdersHomePage?idOrd={idOrd}");
|
||||
}
|
||||
#endif
|
||||
|
||||
#endregion Protected Methods
|
||||
|
||||
#region Private Methods
|
||||
|
||||
@@ -8,7 +8,6 @@ else
|
||||
<thead>
|
||||
<tr class="bg-dark text-light">
|
||||
<th>
|
||||
@*<button class="btn btn-success btn-sm" @onclick="() => toggleAddNew()"><i class="fas fa-plus"></i></button>*@
|
||||
</th>
|
||||
<th>Company</th>
|
||||
<th>VAT</th>
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
using Microsoft.AspNetCore.Components;
|
||||
using WebDoorCreator.Data.DbModels;
|
||||
using WebDoorCreator.Data.Services;
|
||||
using WebDoorCreator.UI.Data;
|
||||
|
||||
namespace WebDoorCreator.UI.Components.CompMan
|
||||
{
|
||||
@@ -9,12 +8,12 @@ namespace WebDoorCreator.UI.Components.CompMan
|
||||
{
|
||||
#region Protected Properties
|
||||
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<CompanyModel> E_currCompany { get; set; }
|
||||
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
|
||||
#endregion Protected Properties
|
||||
|
||||
#region Protected Methods
|
||||
@@ -34,6 +33,11 @@ namespace WebDoorCreator.UI.Components.CompMan
|
||||
|
||||
#region Private Methods
|
||||
|
||||
private async Task editRec(CompanyModel currComp)
|
||||
{
|
||||
await E_currCompany.InvokeAsync(currComp);
|
||||
}
|
||||
|
||||
private async Task ReloadData()
|
||||
{
|
||||
ListRecords = null;
|
||||
@@ -43,11 +47,6 @@ namespace WebDoorCreator.UI.Components.CompMan
|
||||
await InvokeAsync(StateHasChanged);
|
||||
}
|
||||
|
||||
private async Task editRec(CompanyModel currComp)
|
||||
{
|
||||
await E_currCompany.InvokeAsync(currComp);
|
||||
}
|
||||
|
||||
#endregion Private Methods
|
||||
}
|
||||
}
|
||||
@@ -13,7 +13,7 @@ else
|
||||
}
|
||||
</div>
|
||||
<div class="col-4">
|
||||
<ButtonsDoorDef></ButtonsDoorDef>
|
||||
@*<ButtonsDoorDef></ButtonsDoorDef>*@
|
||||
</div>
|
||||
|
||||
@if (paramsChanged)
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
using Microsoft.AspNetCore.Components;
|
||||
using WebDoorCreator.Data.DbModels;
|
||||
using WebDoorCreator.Data.Services;
|
||||
using WebDoorCreator.UI.Data;
|
||||
|
||||
namespace WebDoorCreator.UI.Components.DoorDef
|
||||
{
|
||||
|
||||
@@ -34,7 +34,6 @@
|
||||
}
|
||||
}
|
||||
</div>
|
||||
@*<hr />*@
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
@@ -51,6 +51,9 @@ namespace WebDoorCreator.UI.Components.DoorDef
|
||||
|
||||
#region Protected Properties
|
||||
|
||||
[Parameter]
|
||||
public bool paramsChanged { get; set; } = false;
|
||||
|
||||
/// <summary>
|
||||
/// Lista delle conf assocaite alle BlockDoorOp
|
||||
/// </summary>
|
||||
@@ -60,19 +63,17 @@ namespace WebDoorCreator.UI.Components.DoorDef
|
||||
/// Lista delle BlockDoorOp da passare
|
||||
/// </summary>
|
||||
protected Dictionary<string, Dictionary<string, string>> bdoList { get; set; } = new Dictionary<string, Dictionary<string, string>>();
|
||||
|
||||
[Parameter]
|
||||
public bool paramsChanged { get; set; } = false;
|
||||
protected string userLang { get; set; } = "EN";
|
||||
|
||||
#endregion Protected Properties
|
||||
|
||||
#region Protected Methods
|
||||
|
||||
protected bool showCirc { get; set; } = false;
|
||||
|
||||
[Inject]
|
||||
protected WDCRefreshService WDCRService { get; set; } = null!;
|
||||
|
||||
|
||||
protected async Task doSaveBlock(Dictionary<string, Dictionary<string, string>> updSet)
|
||||
{
|
||||
await Task.Delay(1);
|
||||
@@ -101,9 +102,6 @@ namespace WebDoorCreator.UI.Components.DoorDef
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected bool showCirc { get; set; } = false;
|
||||
|
||||
protected Dictionary<string, List<string>> getParamsConfig(string paramName)
|
||||
{
|
||||
Dictionary<string, List<string>> answ = new Dictionary<string, List<string>>();
|
||||
|
||||
@@ -9,19 +9,15 @@
|
||||
<button class="btn btn-danger" @onclick="() => deleteRecord()">Delete Door <i class="fa-solid fa-trash"></i></button>
|
||||
</div>
|
||||
<div class="d-flex justify-content-between">
|
||||
@*<div class="badge rounded-pilll bg-dark text-light">Insert Date</div>*@
|
||||
<div>Insert Date: <b>@currOrderStatus.DateIns</b></div>
|
||||
</div>
|
||||
<div class="d-flex justify-content-between">
|
||||
@*<div class="badge rounded-pilll bg-dark text-light">Order External Code</div>*@
|
||||
<div>Order External Code: <b>@currOrderStatus.OrderExtCode</b></div>
|
||||
</div>
|
||||
<div class="d-flex justify-content-between">
|
||||
@*<div class="badge rounded-pilll bg-dark text-light">Models Number</div>*@
|
||||
<div class="text-center">Models Number: <b>@currOrderStatus.NumType</b></div>
|
||||
</div>
|
||||
<div class="d-flex justify-content-between">
|
||||
@*<div class="badge rounded-pilll bg-dark text-light">Doors Number</div>*@
|
||||
<div class="text-center">Doors Number: <b>@currOrderStatus.NumDoors</b></div>
|
||||
</div>
|
||||
<div style="background: #AFCFD1; text-align: end">
|
||||
|
||||
@@ -2,7 +2,6 @@ using Microsoft.AspNetCore.Components;
|
||||
using Microsoft.JSInterop;
|
||||
using WebDoorCreator.Data.DbModels;
|
||||
using WebDoorCreator.Data.Services;
|
||||
using WebDoorCreator.UI.Data;
|
||||
|
||||
namespace WebDoorCreator.UI.Components.DoorDef
|
||||
{
|
||||
@@ -13,12 +12,11 @@ namespace WebDoorCreator.UI.Components.DoorDef
|
||||
[Parameter]
|
||||
public string bgColor { get; set; } = "";
|
||||
|
||||
[CascadingParameter]
|
||||
public int idDoor { get; set; } = 0;
|
||||
|
||||
[Parameter]
|
||||
public OrderStatusViewModel? currOrderStatus { get; set; } = null;
|
||||
|
||||
[CascadingParameter]
|
||||
public int idDoor { get; set; } = 0;
|
||||
#endregion Public Properties
|
||||
|
||||
#region Protected Properties
|
||||
@@ -26,11 +24,11 @@ namespace WebDoorCreator.UI.Components.DoorDef
|
||||
[Inject]
|
||||
protected IJSRuntime JSRuntime { get; set; } = null!;
|
||||
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDCService { get; set; } = null!;
|
||||
[Inject]
|
||||
protected NavigationManager NavManager { get; set; } = null!;
|
||||
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDCService { get; set; } = null!;
|
||||
#endregion Protected Properties
|
||||
|
||||
#region Protected Methods
|
||||
|
||||
@@ -41,7 +41,7 @@ namespace WebDoorCreator.UI.Components.DoorDef
|
||||
|
||||
#region Protected Properties
|
||||
|
||||
Dictionary<string, string> _currVal = new Dictionary<string, string>();
|
||||
private Dictionary<string, string> _currVal = new Dictionary<string, string>();
|
||||
|
||||
/// <summary>
|
||||
/// Array dati effettivo x gestione modifiche
|
||||
@@ -109,8 +109,6 @@ namespace WebDoorCreator.UI.Components.DoorDef
|
||||
return answ;
|
||||
}
|
||||
|
||||
|
||||
|
||||
protected async Task doSave()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
|
||||
@@ -1,26 +1,29 @@
|
||||
using Microsoft.AspNetCore.Components;
|
||||
using Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage;
|
||||
using WebDoorCreator.Data.DbModels;
|
||||
using WebDoorCreator.Data.Services;
|
||||
using WebDoorCreator.UI.Data;
|
||||
|
||||
namespace WebDoorCreator.UI.Components.DoorDef
|
||||
{
|
||||
public partial class DoorDefStepList
|
||||
{
|
||||
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
|
||||
[Parameter]
|
||||
public int CurrDoorDefStatus { get; set; } = 10;
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<int> E_CurrStep { get; set; }
|
||||
|
||||
protected override async Task OnParametersSetAsync()
|
||||
protected string currColor { get; set; } = "";
|
||||
|
||||
protected List<ListValuesModel>? currListDoorDefStatus { get; set; } = null;
|
||||
|
||||
protected List<string> listBord01 { get; set; } = new();
|
||||
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
protected async Task changeStep(int step)
|
||||
{
|
||||
await Task.Delay(1);
|
||||
await E_CurrStep.InvokeAsync(step);
|
||||
StateHasChanged();
|
||||
}
|
||||
|
||||
protected async Task doChangeStep(string actDoorDefStep)
|
||||
@@ -30,9 +33,6 @@ namespace WebDoorCreator.UI.Components.DoorDef
|
||||
//await E_StepChanged.InvokeAsync(actDoorDefStep);
|
||||
}
|
||||
|
||||
protected List<ListValuesModel>? currListDoorDefStatus { get; set; } = null;
|
||||
protected string currColor { get; set; } = "";
|
||||
|
||||
protected override async Task OnInitializedAsync()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
@@ -44,7 +44,6 @@ namespace WebDoorCreator.UI.Components.DoorDef
|
||||
if (stat2Display != null)
|
||||
{
|
||||
currColor = stat2Display.DefaultVal;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -55,13 +54,9 @@ namespace WebDoorCreator.UI.Components.DoorDef
|
||||
listBord01.Add("White");
|
||||
}
|
||||
|
||||
protected List<string> listBord01 { get; set; } = new();
|
||||
|
||||
protected async Task changeStep(int step)
|
||||
protected override async Task OnParametersSetAsync()
|
||||
{
|
||||
await E_CurrStep.InvokeAsync(step);
|
||||
StateHasChanged();
|
||||
await Task.Delay(1);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
+1
-20
@@ -1,22 +1,6 @@
|
||||
@*@page "/DoorDefinition"*@
|
||||
|
||||
@*<div class="d-flex justify-content-between">
|
||||
<div>
|
||||
<h3>Door Definition</h3>
|
||||
</div>
|
||||
<ButtonsDoorDef idOrd="@idOrd" paramsChanged="@B_doorOpUpd" DoorId="@idDoor"></ButtonsDoorDef>
|
||||
</div>*@
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12 px-0">
|
||||
@*<CascadingValue Value="@idDoor">
|
||||
<CascadingValue Value="B_doorOpUpd">
|
||||
<CascadingValue Value="IsErr">
|
||||
<CascadingValue Value="ErrCode">
|
||||
@*<DoorDefOrderTopRow currOrderStatus="@orderStatus" bgColor="#AFCFD1"></DoorDefOrderTopRow>
|
||||
</CascadingValue>
|
||||
</CascadingValue>
|
||||
</CascadingValue>
|
||||
</CascadingValue>*@
|
||||
</div>
|
||||
<div class="col-8 pe-0">
|
||||
<div class="mb-3 ps-1 pe-0">
|
||||
@@ -28,10 +12,8 @@
|
||||
<CascadingValue Value="B_doorOpUpd">
|
||||
<CascadingValue Value="IsErr">
|
||||
<CascadingValue Value="ErrCode">
|
||||
@*<DoorDefOrderTopRow currOrderStatus="@orderStatus" bgColor="#AFCFD1"></DoorDefOrderTopRow>*@
|
||||
@if (orderStatus != null)
|
||||
{
|
||||
@*<ButtonsDoorDef idOrd="@orderStatus.OrderId"></ButtonsDoorDef>*@
|
||||
}
|
||||
@if (currDefStep == 10)
|
||||
{
|
||||
@@ -40,7 +22,6 @@
|
||||
|
||||
<BaseParamList CurrBaseDoorOp="@ListBaseDoorOp" E_DoorOpReqRel="doReload"></BaseParamList>
|
||||
}
|
||||
@*<DoorSizingStep E_paramChanged="catchParamChange" DoorId="@idDoor"></DoorSizingStep>*@
|
||||
}
|
||||
else if (currDefStep == 20)
|
||||
{
|
||||
+1
-1
@@ -7,7 +7,7 @@ using WebDoorCreator.Data.DbModels;
|
||||
using WebDoorCreator.Data.Services;
|
||||
using WebDoorCreator.UI.Data;
|
||||
|
||||
namespace WebDoorCreator.UI.Pages
|
||||
namespace WebDoorCreator.UI.Components.DoorDef
|
||||
{
|
||||
public partial class DoorDefinition : IDisposable
|
||||
{
|
||||
@@ -1,10 +1,7 @@
|
||||
@*<div class="" style="height:100%; width:100%; position:sticky; background: linear-gradient(#AFCFD1, #92B2C4);min-height: 55rem;max-height: 55rem;">*@
|
||||
|
||||
<div class="" style="height:100%; width:100%; background: linear-gradient(#AFCFD1, #92B2C4);min-height: 50rem;">
|
||||
<div class="" style="height:100%; width:100%; background: linear-gradient(#AFCFD1, #92B2C4);min-height: 50rem;">
|
||||
<ButtonsDoorDef></ButtonsDoorDef>
|
||||
@if (!string.IsNullOrEmpty(@SvgContent))
|
||||
{
|
||||
@*<div style="height: 0;width: 15rem;align-items: center;display: flex;flex-wrap: wrap;justify-content: center;">*@
|
||||
<div style="align-items: center;display: flex;flex-wrap: wrap;justify-content: center;">
|
||||
<div style="width: @doorW; max-height: 30rem;">
|
||||
@svgPreview
|
||||
|
||||
@@ -7,6 +7,11 @@ namespace WebDoorCreator.UI.Components.DoorDef
|
||||
{
|
||||
#region Public Properties
|
||||
|
||||
private static Logger Log = LogManager.GetCurrentClassLogger();
|
||||
|
||||
[Parameter]
|
||||
public string doorW { get; set; } = "";
|
||||
|
||||
[Parameter]
|
||||
public string SvgContent
|
||||
{
|
||||
@@ -16,13 +21,8 @@ namespace WebDoorCreator.UI.Components.DoorDef
|
||||
_svgContent = value;
|
||||
}
|
||||
}
|
||||
|
||||
[Parameter]
|
||||
public string doorW { get; set; } = "";
|
||||
|
||||
private static Logger Log = LogManager.GetCurrentClassLogger();
|
||||
|
||||
protected string _svgContent { get; set; } = "";
|
||||
|
||||
#endregion Public Properties
|
||||
|
||||
#region Protected Properties
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
<HwSvgObj LineColor="#CFD8DC" LineWidth="8" ObjH="200" ObjW="700" EC_ExeFunct="@(()=> createDoor(""))" ObjId="-1" ItemName="Add new door" ItemCount="0" ShowPlus="true" ImagePath="images/icons/PlusWhite.svg"></HwSvgObj>
|
||||
</div>
|
||||
<div class=" py-1">
|
||||
@*<HwSvgObj LineColor="#CFD8DC" LineWidth="8" ObjH="200" ObjW="700" ObjId="-2" ItemName="Add from template" ItemCount="0" ShowPlus="true" ImagePath="images/icons/clipboard-regular.svg"></HwSvgObj>*@
|
||||
<HwSvgObj LineColor="#CFD8DC" LineWidth="8" ObjH="200" ObjW="700" ObjId="-2" ItemName="Calculate total cost" ItemCount="0" ShowPlus="true" ImagePath="images/icons/calculator-solid.svg"></HwSvgObj>
|
||||
</div>
|
||||
<div class=" py-1">
|
||||
@@ -33,9 +32,4 @@
|
||||
}
|
||||
}
|
||||
</div>
|
||||
|
||||
@*@if (currDoor != null)
|
||||
{
|
||||
<DoorModal CurrDoor="@currDoor"></DoorModal>
|
||||
}*@
|
||||
}
|
||||
@@ -17,16 +17,17 @@ namespace WebDoorCreator.UI.Components.DoorMan
|
||||
[Parameter]
|
||||
public int currOrderId { get; set; } = 0;
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<DoorModel> E_CurrDoor { get; set; }
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<DoorModel> E_CurrDoorModal { get; set; }
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<bool> E_DoorChanged { get; set; }
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<int> updateRecordCount { get; set; }
|
||||
[Parameter]
|
||||
public EventCallback<DoorModel> E_CurrDoor { get; set; }
|
||||
[Parameter]
|
||||
public EventCallback<DoorModel> E_CurrDoorModal { get; set; }
|
||||
|
||||
public string userId
|
||||
{
|
||||
get
|
||||
@@ -73,6 +74,7 @@ namespace WebDoorCreator.UI.Components.DoorMan
|
||||
|
||||
#region Protected Methods
|
||||
|
||||
protected DoorModel? currDoor { get; set; } = null;
|
||||
|
||||
protected async Task catchDoorChange(bool isChanged)
|
||||
{
|
||||
@@ -94,9 +96,6 @@ namespace WebDoorCreator.UI.Components.DoorMan
|
||||
await InvokeAsync(StateHasChanged);
|
||||
await E_CurrDoor.InvokeAsync(door);
|
||||
}
|
||||
|
||||
// rimando alla pagina... dettaglio...
|
||||
//NavManager.NavigateTo($"DoorDefinition?idOrd={currOrderId}&idDoor={doorId}");
|
||||
}
|
||||
|
||||
protected async Task deleteRecord(DoorModel currRec)
|
||||
@@ -170,7 +169,6 @@ namespace WebDoorCreator.UI.Components.DoorMan
|
||||
await E_CurrDoor.InvokeAsync(door);
|
||||
}
|
||||
}
|
||||
//NavManager.NavigateTo($"DoorDefinition?idOrd={currOrderId}&idDoor={doorId}");
|
||||
}
|
||||
|
||||
protected async Task ExecDoorReq(DoorSvgObj.DoorAct currAct)
|
||||
@@ -182,40 +180,26 @@ namespace WebDoorCreator.UI.Components.DoorMan
|
||||
// TODO
|
||||
//await removeOneDoorNumber("", "");
|
||||
break;
|
||||
|
||||
case DoorSvgObj.ActionReq.Plus:
|
||||
// TODO
|
||||
//await addOneDoorNumber("", "");
|
||||
break;
|
||||
|
||||
case DoorSvgObj.ActionReq.ReqOptions:
|
||||
// TODO
|
||||
// aprire la modale di editing...
|
||||
await setModalShow(currAct.DoorId);
|
||||
break;
|
||||
|
||||
case DoorSvgObj.ActionReq.Select:
|
||||
await editRec(currAct.DoorId);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
protected DoorModel? currDoor { get; set; } = null;
|
||||
|
||||
protected async Task setModalShow(int doorId)
|
||||
{
|
||||
await Task.Delay(1);
|
||||
|
||||
if (DoorsList != null)
|
||||
{
|
||||
var door = DoorsList.Where(x => x.DoorId == doorId).FirstOrDefault();
|
||||
if (door != null)
|
||||
{
|
||||
//currDoor = door;
|
||||
await E_CurrDoorModal.InvokeAsync(door);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected async Task getBackStatus()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
@@ -279,12 +263,10 @@ namespace WebDoorCreator.UI.Components.DoorMan
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
protected async void sendToCompany(int ordId, int orderStat)
|
||||
{
|
||||
if (orderStat == 10)
|
||||
{
|
||||
//int doorId = await WDService.createDoor(currOrderId, userId, "mm");
|
||||
bool done = await WDService.OrderUpdate(ordId, 20);
|
||||
if (done)
|
||||
{
|
||||
@@ -295,8 +277,20 @@ namespace WebDoorCreator.UI.Components.DoorMan
|
||||
await ReloadData();
|
||||
}
|
||||
|
||||
protected async Task setModalShow(int doorId)
|
||||
{
|
||||
await Task.Delay(1);
|
||||
|
||||
|
||||
if (DoorsList != null)
|
||||
{
|
||||
var door = DoorsList.Where(x => x.DoorId == doorId).FirstOrDefault();
|
||||
if (door != null)
|
||||
{
|
||||
//currDoor = door;
|
||||
await E_CurrDoorModal.InvokeAsync(door);
|
||||
}
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// Prepara il dictionary dei testi da riportare nell'oggetto ordine
|
||||
/// </summary>
|
||||
|
||||
@@ -37,11 +37,6 @@
|
||||
<button class="btn btn-primary w-100" type="button" @onclick="()=>doClone()">Clone door</button>
|
||||
</div>
|
||||
</div>
|
||||
@*<div class="pb-1">
|
||||
<div class="input-group mb-3">
|
||||
<button class="btn btn-info w-100" type="button">Save as template</button>
|
||||
</div>
|
||||
</div>*@
|
||||
<div class="pb-1">
|
||||
<div class="input-group mb-3">
|
||||
<button class="btn btn-danger w-100" type="button" @onclick="()=>deleteRecord()">Delete door</button>
|
||||
@@ -51,7 +46,6 @@
|
||||
|
||||
</div>
|
||||
<div class="w-75">
|
||||
@*<DoorPreview doorW="45%" SvgContent="@DoorSvgContent"></DoorPreview>*@
|
||||
<div class="doorSvgCont" style="height:100%; width:100%; background: linear-gradient(#AFCFD1, #92B2C4);min-height: 50rem;">
|
||||
<div style="align-items: center;display: flex;flex-wrap: wrap;justify-content: center;">
|
||||
<div style="width: 45%; max-height: 30rem;">
|
||||
|
||||
@@ -1,84 +1,64 @@
|
||||
using Microsoft.AspNetCore.Components;
|
||||
using Microsoft.CodeAnalysis.Text;
|
||||
using Microsoft.JSInterop;
|
||||
using WebDoorCreator.Data;
|
||||
using WebDoorCreator.Data.DbModels;
|
||||
using WebDoorCreator.Data.DTO;
|
||||
using WebDoorCreator.Data.Services;
|
||||
using WebDoorCreator.UI.Data;
|
||||
using static Org.BouncyCastle.Math.EC.ECCurve;
|
||||
using static System.Runtime.CompilerServices.RuntimeHelpers;
|
||||
|
||||
namespace WebDoorCreator.UI.Components.DoorMan
|
||||
{
|
||||
public partial class DoorModal
|
||||
{
|
||||
protected List<DoorOpModel> doorOps2Add = new List<DoorOpModel>();
|
||||
|
||||
public DoorModel CurrDoor { get; set; } = new DoorModel();
|
||||
|
||||
public DoorModel CurrDoorClone { get; set; } = new DoorModel();
|
||||
|
||||
[Parameter]
|
||||
public int CurrDoorId { get; set; } = 0;
|
||||
[Parameter]
|
||||
public int OrderId { get; set; } = 0;
|
||||
[Parameter]
|
||||
public string userId { get; set; } = "";
|
||||
public DoorModel CurrDoorClone { get; set; } = new DoorModel();
|
||||
public DoorModel CurrDoor { get; set; } = new DoorModel();
|
||||
|
||||
public List<DoorModel> DoorsList { get; set; } = new List<DoorModel>();
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<DoorModel> E_DoorClose { get; set; }
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<bool> E_isChange { get; set; }
|
||||
|
||||
[Parameter]
|
||||
public int OrderId { get; set; } = 0;
|
||||
|
||||
[Parameter]
|
||||
public string userId { get; set; } = "";
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
protected IConfiguration config { get; set; } = null!;
|
||||
|
||||
protected WebDoorCreator.Data.DDF.Converter currDdfConv { get; set; } = null!;
|
||||
|
||||
protected DDFDto CurrentConf { get; set; } = new DDFDto();
|
||||
|
||||
protected int doorQty
|
||||
{
|
||||
get => CurrDoor.Quantity;
|
||||
set => CurrDoor.Quantity = value;
|
||||
}
|
||||
|
||||
protected string DoorSvgContent { get; set; } = "";
|
||||
|
||||
protected async override Task OnInitializedAsync()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
string vers = config.GetValue<string>("ConfDDF:VersNumber");
|
||||
bool remDoorOp = config.GetValue<bool>("ConfDDF:RemoveDoorOps");
|
||||
var headRows = config.GetSection("ConfDDF:Header").Get<List<string>>();
|
||||
var footRows = config.GetSection("ConfDDF:Footer").Get<List<string>>();
|
||||
currDdfConv = new WebDoorCreator.Data.DDF.Converter(vers, remDoorOp, headRows, footRows);
|
||||
}
|
||||
protected WebDoorCreator.Data.DDF.Converter currDdfConv { get; set; } = null!;
|
||||
protected bool IsErr { get; set; } = false;
|
||||
|
||||
[Inject]
|
||||
protected IConfiguration config { get; set; } = null!;
|
||||
protected DDFDto CurrentConf { get; set; } = new DDFDto();
|
||||
protected async Task closeModal()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
var fakeDoor = new DoorModel();
|
||||
protected IJSRuntime JSRuntime { get; set; } = null!;
|
||||
|
||||
await E_DoorClose.InvokeAsync(fakeDoor);
|
||||
}
|
||||
protected int newDoorId { get; set; } = 0;
|
||||
|
||||
protected override async Task OnParametersSetAsync()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
await ReloadData();
|
||||
}
|
||||
protected List<string> ordListVal { get; set; } = new List<string>();
|
||||
|
||||
protected async Task ReloadData()
|
||||
{
|
||||
var SearchRecords = await WDService.DoorGetByOrderId(OrderId);
|
||||
if (SearchRecords != null)
|
||||
{
|
||||
DoorsList = SearchRecords;
|
||||
|
||||
if (DoorsList != null)
|
||||
{
|
||||
var door = DoorsList.Where(x => x.DoorId == CurrDoorId).FirstOrDefault();
|
||||
if (door != null)
|
||||
{
|
||||
CurrDoor = door;
|
||||
}
|
||||
}
|
||||
}
|
||||
CurrDoorClone = CurrDoor.ObjClone("");
|
||||
}
|
||||
[Inject]
|
||||
protected QueueDataService QDataServ { get; set; } = null!;
|
||||
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
protected async Task addOrRemoveOneDoorNumber(bool isAdd)
|
||||
{
|
||||
//var door = new DoorModel();
|
||||
@@ -89,18 +69,42 @@ namespace WebDoorCreator.UI.Components.DoorMan
|
||||
await ReloadData();
|
||||
}
|
||||
}
|
||||
|
||||
protected async Task ChangeDoorNumber(bool isAdd)
|
||||
{
|
||||
//var door = new DoorModel();
|
||||
var done = await WDService.DoorModQty(doorQty, CurrDoor.OrderId, CurrDoor.DoorId, isAdd);
|
||||
if (done)
|
||||
{
|
||||
//await E_isChange.InvokeAsync(true);
|
||||
await ReloadData();
|
||||
}
|
||||
}
|
||||
|
||||
protected int newDoorId { get; set; } = 0;
|
||||
protected async Task closeModal()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
var fakeDoor = new DoorModel();
|
||||
|
||||
await E_DoorClose.InvokeAsync(fakeDoor);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Elimina porta se richiesto
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
protected async Task deleteRecord()
|
||||
{
|
||||
if (!await JSRuntime.InvokeAsync<bool>("confirm", $"Do you really want to delete this door?"))
|
||||
return;
|
||||
await Task.Delay(1);
|
||||
if (CurrDoor != null)
|
||||
{
|
||||
var done = await WDService.DoorDelete(CurrDoor);
|
||||
if (done)
|
||||
{
|
||||
await closeModal();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Clona la porta selezionata con annesse door operations
|
||||
@@ -140,8 +144,6 @@ namespace WebDoorCreator.UI.Components.DoorMan
|
||||
}
|
||||
}
|
||||
|
||||
protected List<string> ordListVal { get; set; } = new List<string>();
|
||||
|
||||
/// <summary>
|
||||
/// Effettua salvataggio record e generazione DDF
|
||||
/// </summary>
|
||||
@@ -169,7 +171,6 @@ namespace WebDoorCreator.UI.Components.DoorMan
|
||||
|
||||
string currDdf = currDdfConv.GetSerialized(listOp);
|
||||
// FIXME TODO: si potrebbe eliminare in futuro che va su REDIS
|
||||
//await SaveYaml(currDdf);
|
||||
// versione corrente del DDF generato
|
||||
int currVers = await QDataServ.SendCalcReq(newDoorId, currDdf);
|
||||
|
||||
@@ -181,50 +182,38 @@ namespace WebDoorCreator.UI.Components.DoorMan
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Path del servizio di recupero SVG delle porte
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
#if false
|
||||
protected string DoorSvgUrl()
|
||||
protected override async Task OnInitializedAsync()
|
||||
{
|
||||
return $"api/DoorImage/GetImage.svg?DoorId={CurrDoorId}";
|
||||
}
|
||||
#endif
|
||||
|
||||
[Inject]
|
||||
protected QueueDataService QDataServ { get; set; } = null!;
|
||||
|
||||
protected bool IsErr { get; set; } = false;
|
||||
|
||||
protected List<DoorOpModel> doorOps2Add = new List<DoorOpModel>();
|
||||
protected int doorQty
|
||||
await Task.Delay(1);
|
||||
string vers = config.GetValue<string>("ConfDDF:VersNumber");
|
||||
bool remDoorOp = config.GetValue<bool>("ConfDDF:RemoveDoorOps");
|
||||
var headRows = config.GetSection("ConfDDF:Header").Get<List<string>>();
|
||||
var footRows = config.GetSection("ConfDDF:Footer").Get<List<string>>();
|
||||
currDdfConv = new WebDoorCreator.Data.DDF.Converter(vers, remDoorOp, headRows, footRows);
|
||||
}
|
||||
protected override async Task OnParametersSetAsync()
|
||||
{
|
||||
get => CurrDoor.Quantity;
|
||||
set => CurrDoor.Quantity = value;
|
||||
await Task.Delay(1);
|
||||
await ReloadData();
|
||||
}
|
||||
|
||||
[Inject]
|
||||
protected IJSRuntime JSRuntime { get; set; } = null!;
|
||||
/// <summary>
|
||||
/// Elimina porta se richiesto
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
protected async Task deleteRecord()
|
||||
protected async Task ReloadData()
|
||||
{
|
||||
if (!await JSRuntime.InvokeAsync<bool>("confirm", $"Do you really want to delete this door?"))
|
||||
return;
|
||||
await Task.Delay(1);
|
||||
if (CurrDoor != null)
|
||||
var SearchRecords = await WDService.DoorGetByOrderId(OrderId);
|
||||
if (SearchRecords != null)
|
||||
{
|
||||
var done = await WDService.DoorDelete(CurrDoor);
|
||||
if (done)
|
||||
DoorsList = SearchRecords;
|
||||
|
||||
if (DoorsList != null)
|
||||
{
|
||||
await closeModal();
|
||||
var door = DoorsList.Where(x => x.DoorId == CurrDoorId).FirstOrDefault();
|
||||
if (door != null)
|
||||
{
|
||||
CurrDoor = door;
|
||||
}
|
||||
}
|
||||
}
|
||||
CurrDoorClone = CurrDoor.ObjClone("");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -28,7 +28,6 @@
|
||||
}
|
||||
}
|
||||
</select>
|
||||
@*<input id="orderStatus" @bind="@orderStatus" class="form-control" />*@
|
||||
<label for="orderStatus">Order Status</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -7,40 +7,16 @@ namespace WebDoorCreator.UI.Components.Filters
|
||||
{
|
||||
public partial class OrderFilter
|
||||
{
|
||||
[Parameter]
|
||||
public EventCallback<OrderSelectFilter> FilterUpdated { get; set; }
|
||||
private List<ListValuesModel>? ListValuesAll = null;
|
||||
|
||||
[Parameter]
|
||||
public OrderSelectFilter actFilter { get; set; } = new OrderSelectFilter();
|
||||
private List<ListValuesModel>? ListValuesAll = null;
|
||||
protected override async Task OnParametersSetAsync()
|
||||
{
|
||||
ListValuesAll = await WDService.ListValuesGetAll("All", "OrderStep");
|
||||
}
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<OrderSelectFilter> FilterUpdated { get; set; }
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
private string searchVal
|
||||
{
|
||||
get => actFilter.searchValue;
|
||||
set
|
||||
{
|
||||
actFilter.CurrPage = 1;
|
||||
actFilter.searchValue = value;
|
||||
StateHasChanged();
|
||||
ReportChange();
|
||||
}
|
||||
}
|
||||
private int orderStatus
|
||||
{
|
||||
get => actFilter.OrderStatus;
|
||||
set
|
||||
{
|
||||
actFilter.CurrPage = 1;
|
||||
actFilter.OrderStatus = value;
|
||||
StateHasChanged();
|
||||
ReportChange();
|
||||
}
|
||||
}
|
||||
|
||||
private DateTime dateFrom
|
||||
{
|
||||
get => actFilter.DateFrom;
|
||||
@@ -52,6 +28,7 @@ namespace WebDoorCreator.UI.Components.Filters
|
||||
ReportChange();
|
||||
}
|
||||
}
|
||||
|
||||
private DateTime dateTo
|
||||
{
|
||||
get => actFilter.DateTo;
|
||||
@@ -64,7 +41,34 @@ namespace WebDoorCreator.UI.Components.Filters
|
||||
}
|
||||
}
|
||||
|
||||
private int orderStatus
|
||||
{
|
||||
get => actFilter.OrderStatus;
|
||||
set
|
||||
{
|
||||
actFilter.CurrPage = 1;
|
||||
actFilter.OrderStatus = value;
|
||||
StateHasChanged();
|
||||
ReportChange();
|
||||
}
|
||||
}
|
||||
|
||||
private string searchVal
|
||||
{
|
||||
get => actFilter.searchValue;
|
||||
set
|
||||
{
|
||||
actFilter.CurrPage = 1;
|
||||
actFilter.searchValue = value;
|
||||
StateHasChanged();
|
||||
ReportChange();
|
||||
}
|
||||
}
|
||||
|
||||
protected override async Task OnParametersSetAsync()
|
||||
{
|
||||
ListValuesAll = await WDService.ListValuesGetAll("All", "OrderStep");
|
||||
}
|
||||
private void ReportChange()
|
||||
{
|
||||
FilterUpdated.InvokeAsync(actFilter);
|
||||
|
||||
@@ -32,12 +32,6 @@
|
||||
</Authorized>
|
||||
</AuthorizeView>
|
||||
</div>
|
||||
|
||||
@*<div class="nav-item px-3 d-flex flex-warp align-items-center">
|
||||
<NavLink class="nav-link" href="DoorDefinition">
|
||||
<span class="bi bi-door-open-fill pe-3" aria-hidden="true"></span> Door definition page
|
||||
</NavLink>
|
||||
</div>*@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -100,41 +94,6 @@
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
@*<div class="d-flex justify-content-between small">
|
||||
<div class="d-flex justify-content-between">
|
||||
<a href="Identity/Account/Manage" class="text-decoration-none text-dark" style="">@context.User.Identity?.Name</a>
|
||||
<div class="text-decoration-none text-secondary small" style="">
|
||||
@if (listCompanies != null)
|
||||
{
|
||||
@if (listCompanies.Count > 1)
|
||||
{
|
||||
<select @bind="userCurrCompany" class="form-select form-select-sm">
|
||||
@foreach (var item in listCompanies)
|
||||
{
|
||||
<option value="@item.CompanyId">@item.CompanyName</option>
|
||||
}
|
||||
</select>
|
||||
}
|
||||
else
|
||||
{
|
||||
@if (compToShow != null)
|
||||
{
|
||||
<div>@compToShow.CompanyName</div>
|
||||
}
|
||||
}
|
||||
}
|
||||
</div>
|
||||
<div>
|
||||
<select @bind="userLang" class="form-select form-select-sm">
|
||||
<option>EN</option>
|
||||
<option>IT</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<form method="post" action="Identity/Account/LogOut">
|
||||
<button type="submit" class="btnLogout">Log out</button>
|
||||
</form>
|
||||
</div>*@
|
||||
</div>
|
||||
</nav>
|
||||
</Authorized>
|
||||
|
||||
@@ -4,11 +4,10 @@
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="d-flex justify-content-between small">
|
||||
@*<div class="d-flex justify-content-between small">
|
||||
<div style="width: 90%" class="me-2">
|
||||
<div class="btnHead d-flex justify-content-between">
|
||||
<div class="testata">
|
||||
@*<div class="borderTop"></div>*@
|
||||
<div class="row borderTop">
|
||||
<div class="fs-3 text-end col-8">
|
||||
@($"{translate(DoorOpInst.ObjectId)} #{instanceN}")
|
||||
@@ -155,11 +154,6 @@ else
|
||||
</div>
|
||||
</div>
|
||||
<div class="row borderBottom">
|
||||
@*<div class="col-10">
|
||||
<button class="btn btn-outline-dark" style="cursor: pointer;" @onclick="()=>doConfirm()">
|
||||
CONFIRM
|
||||
</button>
|
||||
</div>*@
|
||||
<div class="text-end col-2">
|
||||
<NavLink href="@pathFinder(DoorOpInst.DoorOpId)" target="_blank">
|
||||
<button class="btnPDFPending">
|
||||
@@ -174,6 +168,131 @@ else
|
||||
}
|
||||
|
||||
</div>
|
||||
</div>*@
|
||||
|
||||
<div class="w-100 h-100 small p-2 mt-2" style="border: 2px solid black; border-radius: 15px;">
|
||||
|
||||
<div class="text-center d-flex justify-content-between px-2 mb-3">
|
||||
@if (DoorOpInst.userConfirm != "" && DoorOpInst.DtConfirm != null)
|
||||
{
|
||||
<button class="btnPDFSuccess">
|
||||
<i class="fa-solid fa-file-pdf"></i>
|
||||
</button>
|
||||
}
|
||||
<div>
|
||||
<h5>@($"{@getTrad(DoorOpInst.ObjectId)} #{instanceN}")</h5>
|
||||
</div>
|
||||
@if (isChangedVal())
|
||||
{
|
||||
<div class="circle pulse blue"></div>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="circle grey"></div>
|
||||
}
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-4 d-flex flex-wrap align-items-center">
|
||||
<span>Folder</span>
|
||||
</div>
|
||||
<select class="col-7" @bind="@folderName">
|
||||
@if (listValuesFname != null)
|
||||
{
|
||||
@foreach (var folder in listValuesFname)
|
||||
{
|
||||
<option value="@folder.Value">@folder.Label</option>
|
||||
}
|
||||
}
|
||||
</select>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-4 d-flex flex-wrap align-items-center">
|
||||
<span>Folder</span>
|
||||
</div>
|
||||
@if (listValuesFiles != null && listValuesFiles.Count > 0 && !string.IsNullOrEmpty(templateName))
|
||||
{
|
||||
<select class="col-7" @bind="@templateName">
|
||||
@foreach (var val in listValuesFiles)
|
||||
{
|
||||
<option value="@val.Value">@val.Label</option>
|
||||
}
|
||||
</select>
|
||||
}
|
||||
else
|
||||
{
|
||||
<input class="col-7" disabled>
|
||||
}
|
||||
</div>
|
||||
<div class="mb-3">
|
||||
|
||||
@foreach (var item in currVal)
|
||||
{
|
||||
|
||||
@if (item.Key != "Folder" && item.Key != "template" && item.Key != "shape")
|
||||
{
|
||||
@if (isCombo(item.Key))
|
||||
{
|
||||
<div class="row my-1">
|
||||
<div class="col-4 d-flex flex-wrap align-items-center">
|
||||
<span>@translate(item.Key)</span>
|
||||
</div>
|
||||
|
||||
<select class="col-7" @bind="@currVal[item.Key]">
|
||||
@foreach (var param in comboSet(item.Key))
|
||||
{
|
||||
<option value="@param.Split("/")[0]">
|
||||
@(translate(@param.Split("/")[1]))
|
||||
</option>
|
||||
}
|
||||
</select>
|
||||
</div>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="row my-1">
|
||||
<div class="col-4 d-flex flex-wrap align-items-center">
|
||||
<span>@translate(item.Key)</span>
|
||||
</div>
|
||||
|
||||
<input type="text" class="col-7" @bind="@currVal[item.Key]" />
|
||||
</div>
|
||||
}
|
||||
}
|
||||
}
|
||||
</div>
|
||||
<hr />
|
||||
<div class="row">
|
||||
<div class="col-6 text-start">
|
||||
<button class="btnDelete" @onclick="() => doDeleteInst()">
|
||||
<i class="fa-solid fa-xmark"></i>
|
||||
</button>
|
||||
<button class="btnClone" @onclick="() => doClone()">
|
||||
<i class="fa-solid fa-copy"></i>
|
||||
</button>
|
||||
</div>
|
||||
<div class="col-6 text-end">
|
||||
@if (isChangedVal())
|
||||
{
|
||||
<button class="btnCancel" style="cursor: pointer; --colorCode:#E67E22;" @onclick="() => doCancel()">
|
||||
<i class="fa-solid fa-rotate"></i>
|
||||
</button>
|
||||
<button class="btnSave" style="cursor: pointer; --colorCode:#27AE60;" @onclick="() => doSave()">
|
||||
<i class="fa-solid fa-cloud-arrow-up"></i>
|
||||
</button>
|
||||
}
|
||||
else
|
||||
{
|
||||
<button class="btnCancel" style="cursor: pointer; --colorCode:#7F8C8D;" @onclick="() => doCancel()">
|
||||
<i class="fa-solid fa-rotate"></i>
|
||||
</button>
|
||||
<button class="btnSave" style="cursor: pointer; --colorCode:#7F8C8D;" @onclick="() => doSave()">
|
||||
<i class="fa-solid fa-cloud-arrow-up"></i>
|
||||
</button>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
}
|
||||
|
||||
@@ -1,12 +1,9 @@
|
||||
using Microsoft.AspNetCore.Components;
|
||||
using Microsoft.CodeAnalysis.CSharp.Syntax;
|
||||
using Microsoft.JSInterop;
|
||||
using Newtonsoft.Json;
|
||||
using System.Security.Policy;
|
||||
using WebDoorCreator.Data.DbModels;
|
||||
using WebDoorCreator.Data.Services;
|
||||
using WebDoorCreator.UI.Data;
|
||||
using static WebDoorCreator.UI.Data.WDCRefreshService;
|
||||
|
||||
namespace WebDoorCreator.UI.Components.Hardware
|
||||
{
|
||||
@@ -17,11 +14,11 @@ namespace WebDoorCreator.UI.Components.Hardware
|
||||
[Parameter]
|
||||
public DoorOpModel DoorOpInst { get; set; } = null!;
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<DoorOpModel> E_recordUpdate { get; set; }
|
||||
[Parameter]
|
||||
public EventCallback<bool> E_act2Rel { get; set; }
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<DoorOpModel> E_recordUpdate { get; set; }
|
||||
[Parameter]
|
||||
public string HwCode { get; set; } = "";
|
||||
|
||||
@@ -36,11 +33,8 @@ namespace WebDoorCreator.UI.Components.Hardware
|
||||
|
||||
#endregion Public Properties
|
||||
|
||||
#region Public Methods
|
||||
|
||||
|
||||
#endregion Public Methods
|
||||
|
||||
#region Protected Properties
|
||||
|
||||
protected Dictionary<string, string> _currVal { get; set; } = new Dictionary<string, string>();
|
||||
@@ -60,6 +54,7 @@ namespace WebDoorCreator.UI.Components.Hardware
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected string folderName
|
||||
{
|
||||
get => currVal != null ? tryGetCurrVal("Folder") : "";
|
||||
@@ -85,6 +80,7 @@ namespace WebDoorCreator.UI.Components.Hardware
|
||||
protected IJSRuntime JSRuntime { get; set; } = null!;
|
||||
|
||||
protected List<ListValuesModel>? listValuesFiles { get; set; } = null!;
|
||||
protected List<ListValuesModel>? listValuesHW { get; set; } = null!;
|
||||
|
||||
protected List<ListValuesModel>? listValuesFname { get; set; } = null!;
|
||||
|
||||
@@ -93,7 +89,6 @@ namespace WebDoorCreator.UI.Components.Hardware
|
||||
|
||||
protected string templateName
|
||||
{
|
||||
/*currVal != null ? tryGetCurrVal("template") : tryGetCurrVal("shape");*/
|
||||
get
|
||||
{
|
||||
string answ = "";
|
||||
@@ -208,6 +203,7 @@ namespace WebDoorCreator.UI.Components.Hardware
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
|
||||
protected bool isCombo(string pKey)
|
||||
{
|
||||
bool answ = false;
|
||||
@@ -223,7 +219,6 @@ namespace WebDoorCreator.UI.Components.Hardware
|
||||
await FullReloadData();
|
||||
}
|
||||
|
||||
|
||||
protected string translate(string lemma)
|
||||
{
|
||||
string answ = "";
|
||||
@@ -253,21 +248,23 @@ namespace WebDoorCreator.UI.Components.Hardware
|
||||
|
||||
#region Private Methods
|
||||
|
||||
protected string currTempOrSh { get; set; } = "";
|
||||
|
||||
private async Task FullReloadData()
|
||||
{
|
||||
currVal = DoorOpInst.CurrVals;
|
||||
graphicParams = DoorOpInst.GraphicParams;
|
||||
await SetSelectedData();
|
||||
}
|
||||
|
||||
protected string currTempOrSh { get; set; } = "";
|
||||
|
||||
private async Task SetSelectedData()
|
||||
{
|
||||
isLoading = true;
|
||||
await Task.Delay(1);
|
||||
// fix folder
|
||||
listValuesFiles = null;
|
||||
listValuesHW = null;
|
||||
listValuesHW = await WDCService.ListValuesGetAll(HwCode, "Hardware");
|
||||
|
||||
var tempListVal = await WDCService.ListValuesGetAll(HwCode, "Folder");
|
||||
if (tempListVal != null)
|
||||
{
|
||||
@@ -296,7 +293,6 @@ namespace WebDoorCreator.UI.Components.Hardware
|
||||
}
|
||||
try
|
||||
{
|
||||
|
||||
if (listValuesFiles != null && listValuesFiles.Count > 0)
|
||||
{
|
||||
currTempOrSh = listValuesFiles.FirstOrDefault()?.FieldName!;
|
||||
@@ -312,6 +308,23 @@ namespace WebDoorCreator.UI.Components.Hardware
|
||||
await InvokeAsync(StateHasChanged);
|
||||
}
|
||||
|
||||
|
||||
protected string getTrad(string objId)
|
||||
{
|
||||
string answ = "";
|
||||
|
||||
if (listValuesHW != null)
|
||||
{
|
||||
var currHw2Trad = listValuesHW.Where(x => x.TableName == objId).FirstOrDefault();
|
||||
if(currHw2Trad != null)
|
||||
{
|
||||
answ = translate(currHw2Trad.Label);
|
||||
}
|
||||
}
|
||||
|
||||
return answ;
|
||||
}
|
||||
|
||||
#endregion Private Methods
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,11 @@
|
||||
.btnGen {
|
||||
.btnPDF {
|
||||
border-radius: 50%;
|
||||
width: 1.5rem;
|
||||
height: 1.5rem;
|
||||
border: 2px solid #00838F;
|
||||
z-index: 99999;
|
||||
}
|
||||
.btnGen {
|
||||
border-radius: 50%;
|
||||
width: 3.5rem;
|
||||
height: 3.5rem;
|
||||
@@ -12,7 +19,7 @@
|
||||
border: 5px solid #00838F;
|
||||
z-index: 99999;
|
||||
background: #B71C1C;
|
||||
transform: translate(25px, -1rem);
|
||||
/*transform: translate(@xDelta, -@yDelta);*/
|
||||
}
|
||||
.btnClone {
|
||||
border-radius: 50%;
|
||||
@@ -21,25 +28,26 @@
|
||||
border: 5px solid #00838F;
|
||||
z-index: 99999;
|
||||
background: #FFF;
|
||||
transform: translate(1.6rem, -1rem);
|
||||
/*transform: translate(1.6rem, -1rem);*/
|
||||
}
|
||||
.btnPDFSuccess {
|
||||
border-radius: 50%;
|
||||
width: 3.5rem;
|
||||
height: 3.5rem;
|
||||
border: 5px solid #00838F;
|
||||
width: 1.5rem;
|
||||
height: 1.5rem;
|
||||
border: 2px solid #00838F;
|
||||
z-index: 99999;
|
||||
background: #8E44AD;
|
||||
transform: translate(1rem, 1rem);
|
||||
}
|
||||
.btnPDFPending {
|
||||
border-radius: 50%;
|
||||
width: 3.5rem;
|
||||
height: 3.5rem;
|
||||
border: 5px solid #00838F;
|
||||
width: 1.5rem;
|
||||
height: 1.5rem;
|
||||
border: 2px solid #00838F;
|
||||
z-index: 99999;
|
||||
background: #F1C40F;
|
||||
transform: translate(20.3rem, 1rem);
|
||||
}
|
||||
.btnPDFSuccess > i {
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
.btnHighlight {
|
||||
border-radius: 50%;
|
||||
@@ -57,7 +65,6 @@
|
||||
border: 5px solid #00838F;
|
||||
z-index: 99999;
|
||||
background: var(--colorCode);
|
||||
transform: translate(-7rem, 1rem);
|
||||
}
|
||||
.btnSave {
|
||||
border-radius: 50%;
|
||||
@@ -66,7 +73,6 @@
|
||||
border: 5px solid #00838F;
|
||||
z-index: 99999;
|
||||
background: var(--colorCode);
|
||||
transform: translate(-7.5rem, 1rem);
|
||||
}
|
||||
.btnHeadTail {
|
||||
width: 100%;
|
||||
@@ -117,4 +123,28 @@ i {
|
||||
justify-content: center;
|
||||
flex-wrap: wrap;
|
||||
font-size: 1.1rem;
|
||||
}
|
||||
.blue {
|
||||
background: #3652D9;
|
||||
}
|
||||
.grey {
|
||||
background: #7F8C8D;
|
||||
opacity: 50%;
|
||||
}
|
||||
.circle {
|
||||
width: 1rem;
|
||||
height: 1rem;
|
||||
border-radius: 50%;
|
||||
box-shadow: 0px 0px 1px 1px #0000001a;
|
||||
}
|
||||
.pulse {
|
||||
animation: pulse-animation 2s infinite;
|
||||
}
|
||||
@keyframes pulse-animation {
|
||||
0% {
|
||||
box-shadow: 0 0 0 0px rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
100% {
|
||||
box-shadow: 0 0 0 20px rgba(0, 0, 0, 0);
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,14 @@
|
||||
@xDelta: 25px;
|
||||
@yDelta: 1rem;
|
||||
|
||||
.btnPDF {
|
||||
border-radius: 50%;
|
||||
width: 1.5rem;
|
||||
height: 1.5rem;
|
||||
border: 2px solid #00838F;
|
||||
z-index: 99999;
|
||||
}
|
||||
|
||||
.btnGen {
|
||||
border-radius: 50%;
|
||||
width: 3.5rem;
|
||||
@@ -12,25 +20,28 @@
|
||||
.btnDelete {
|
||||
.btnGen;
|
||||
background: #B71C1C;
|
||||
transform: translate(@xDelta, -@yDelta);
|
||||
/*transform: translate(@xDelta, -@yDelta);*/
|
||||
}
|
||||
|
||||
.btnClone {
|
||||
.btnGen;
|
||||
background: #FFF;
|
||||
transform: translate(1.6rem, -1rem);
|
||||
/*transform: translate(1.6rem, -1rem);*/
|
||||
}
|
||||
|
||||
.btnPDFSuccess {
|
||||
.btnGen;
|
||||
.btnPDF;
|
||||
background: #8E44AD;
|
||||
transform: translate(1rem, @yDelta);
|
||||
}
|
||||
|
||||
.btnPDFPending {
|
||||
.btnGen;
|
||||
.btnPDF;
|
||||
background: #F1C40F;
|
||||
transform: translate(20.3rem, 1rem);
|
||||
//transform: translate(20.3rem, 1rem);
|
||||
}
|
||||
|
||||
.btnPDFSuccess > i {
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
.btnHighlight {
|
||||
@@ -38,15 +49,15 @@
|
||||
background: #03A9F4;
|
||||
transform: translate(10.3rem, -8rem);
|
||||
}
|
||||
|
||||
.btnCancel {
|
||||
.btnGen;
|
||||
background: var(--colorCode);
|
||||
transform: translate(-7rem, 1rem);
|
||||
}
|
||||
|
||||
.btnSave {
|
||||
.btnGen;
|
||||
background: var(--colorCode);
|
||||
transform: translate(-7.5rem, 1rem);
|
||||
}
|
||||
|
||||
|
||||
@@ -104,3 +115,36 @@ i {
|
||||
flex-wrap: wrap;
|
||||
font-size: 1.1rem;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.blue {
|
||||
background: #3652D9;
|
||||
}
|
||||
|
||||
.grey {
|
||||
background: #7F8C8D;
|
||||
opacity: 50%;
|
||||
}
|
||||
|
||||
|
||||
.circle {
|
||||
width: 1rem;
|
||||
height: 1rem;
|
||||
border-radius: 50%;
|
||||
box-shadow: 0px 0px 1px 1px #0000001a;
|
||||
}
|
||||
|
||||
.pulse {
|
||||
animation: pulse-animation 2s infinite;
|
||||
}
|
||||
|
||||
@keyframes pulse-animation {
|
||||
0% {
|
||||
box-shadow: 0 0 0 0px rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
|
||||
100% {
|
||||
box-shadow: 0 0 0 20px rgba(0, 0, 0, 0);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1 +1 @@
|
||||
.btnGen{border-radius:50%;width:3.5rem;height:3.5rem;border:5px solid #00838f;z-index:99999;}.btnDelete{border-radius:50%;width:3.5rem;height:3.5rem;border:5px solid #00838f;z-index:99999;background:#b71c1c;transform:translate(25px,-1rem);}.btnClone{border-radius:50%;width:3.5rem;height:3.5rem;border:5px solid #00838f;z-index:99999;background:#fff;transform:translate(1.6rem,-1rem);}.btnPDFSuccess{border-radius:50%;width:3.5rem;height:3.5rem;border:5px solid #00838f;z-index:99999;background:#8e44ad;transform:translate(1rem,1rem);}.btnPDFPending{border-radius:50%;width:3.5rem;height:3.5rem;border:5px solid #00838f;z-index:99999;background:#f1c40f;transform:translate(20.3rem,1rem);}.btnHighlight{border-radius:50%;width:3.5rem;height:3.5rem;border:5px solid #00838f;z-index:99999;background:#03a9f4;transform:translate(10.3rem,-8rem);}.btnCancel{border-radius:50%;width:3.5rem;height:3.5rem;border:5px solid #00838f;z-index:99999;background:var(--colorCode);transform:translate(-7rem,1rem);}.btnSave{border-radius:50%;width:3.5rem;height:3.5rem;border:5px solid #00838f;z-index:99999;background:var(--colorCode);transform:translate(-7.5rem,1rem);}.btnHeadTail{width:100%;padding:.8rem 0 .8rem 0;background:none;border:0;}.btnConfirm{width:100%;padding:.8rem 0 .8rem 0;background:none;border:0;border-bottom:3px solid #000;}.btnHead{width:100%;padding:.8rem 0 .8rem 0;background:none;border:0;}.borderTop{border-top:7px solid #00838f;}.borderBottom{border-bottom:7px solid #00838f;width:100%;}.modal-dialog{overflow-y:initial!important;}.modal-body{height:18.75rem;overflow-y:auto;}.testata{width:100%;}select,input{border:0;border-bottom:2px solid #000;background:none;height:2rem;}i{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;font-size:1.1rem;}
|
||||
.btnPDF{border-radius:50%;width:1.5rem;height:1.5rem;border:2px solid #00838f;z-index:99999;}.btnGen{border-radius:50%;width:3.5rem;height:3.5rem;border:5px solid #00838f;z-index:99999;}.btnDelete{border-radius:50%;width:3.5rem;height:3.5rem;border:5px solid #00838f;z-index:99999;background:#b71c1c;}.btnClone{border-radius:50%;width:3.5rem;height:3.5rem;border:5px solid #00838f;z-index:99999;background:#fff;}.btnPDFSuccess{border-radius:50%;width:1.5rem;height:1.5rem;border:2px solid #00838f;z-index:99999;background:#8e44ad;}.btnPDFPending{border-radius:50%;width:1.5rem;height:1.5rem;border:2px solid #00838f;z-index:99999;background:#f1c40f;}.btnPDFSuccess>i{font-size:.8rem;}.btnHighlight{border-radius:50%;width:3.5rem;height:3.5rem;border:5px solid #00838f;z-index:99999;background:#03a9f4;transform:translate(10.3rem,-8rem);}.btnCancel{border-radius:50%;width:3.5rem;height:3.5rem;border:5px solid #00838f;z-index:99999;background:var(--colorCode);}.btnSave{border-radius:50%;width:3.5rem;height:3.5rem;border:5px solid #00838f;z-index:99999;background:var(--colorCode);}.btnHeadTail{width:100%;padding:.8rem 0 .8rem 0;background:none;border:0;}.btnConfirm{width:100%;padding:.8rem 0 .8rem 0;background:none;border:0;border-bottom:3px solid #000;}.btnHead{width:100%;padding:.8rem 0 .8rem 0;background:none;border:0;}.borderTop{border-top:7px solid #00838f;}.borderBottom{border-bottom:7px solid #00838f;width:100%;}.modal-dialog{overflow-y:initial!important;}.modal-body{height:18.75rem;overflow-y:auto;}.testata{width:100%;}select,input{border:0;border-bottom:2px solid #000;background:none;height:2rem;}i{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;font-size:1.1rem;}.blue{background:#3652d9;}.grey{background:#7f8c8d;opacity:50%;}.circle{width:1rem;height:1rem;border-radius:50%;box-shadow:0 0 1px 1px #0000001a;}.pulse{animation:pulse-animation 2s infinite;}@keyframes pulse-animation{0%{box-shadow:0 0 0 0 rgba(0,0,0,.2);}100%{box-shadow:0 0 0 20px rgba(0,0,0,0);}}
|
||||
@@ -4,94 +4,43 @@
|
||||
}
|
||||
else
|
||||
{
|
||||
@*<div>
|
||||
COORDS:
|
||||
X=@screenX
|
||||
Y=@screenY
|
||||
<br />
|
||||
SIZE:
|
||||
HEIGHT: @Height
|
||||
WIDTH: @Width
|
||||
</div>*@
|
||||
|
||||
|
||||
@if (Ord2Show == null)
|
||||
{
|
||||
<table>
|
||||
<thead>
|
||||
<tr class="">
|
||||
<td></td>
|
||||
<th>Order Date <Sorter ParamName="OrderDate" IsAsc="@sortAsc" CurrParam="@sortField" sortReq="SortRequested"></Sorter></th>
|
||||
<th>Order Number <Sorter ParamName="OrderNumber" IsAsc="@sortAsc" CurrParam="@sortField" sortReq="SortRequested"></Sorter></th>
|
||||
<th>Order Description</th>
|
||||
<th class="text-end">Quantity</th>
|
||||
<th class="text-end">Model Number</th>
|
||||
<th class="text-end">Order Status</th>
|
||||
<th class="text-end">TOTAL COST</th>
|
||||
@*<th>PROGRESS</th>*@
|
||||
<th class="text-end"></th>
|
||||
<table>
|
||||
<thead>
|
||||
<tr class="">
|
||||
<td></td>
|
||||
<th>Order Date <Sorter ParamName="OrderDate" IsAsc="@sortAsc" CurrParam="@sortField" sortReq="SortRequested"></Sorter></th>
|
||||
<th>Order Number <Sorter ParamName="OrderNumber" IsAsc="@sortAsc" CurrParam="@sortField" sortReq="SortRequested"></Sorter></th>
|
||||
<th>Order Description</th>
|
||||
<th class="text-end">Quantity</th>
|
||||
<th class="text-end">Model Number</th>
|
||||
<th class="text-end">Order Status</th>
|
||||
<th class="text-end">TOTAL COST</th>
|
||||
<th class="text-end"></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach (var item in ListOrdersStatus)
|
||||
{
|
||||
<tr>
|
||||
<td>
|
||||
<button class="btn btn-sm btn-primary" @onclick="()=>setOrd2Show(item.OrderId)" title="Order detail"><i class="fa-solid fa-magnifying-glass"></i></button>
|
||||
<a class="btn btn-sm btn-info" target="_blank" href="@reportUrl(item.OrderId)" title="Download pdf report"><i class="fa-regular fa-file-pdf"></i></a>
|
||||
</td>
|
||||
<td>@item.DateIns</td>
|
||||
<td>@item.OrderExtCode</td>
|
||||
<td>@item.OrderDescript</td>
|
||||
<td class="text-end">@item.NumDoors</td>
|
||||
<td class="text-end">@item.NumType</td>
|
||||
<td class="text-end">@getOrderStatusLabel(item.OrderStatus)</td>
|
||||
<td class="text-end">@($"{item.TotCost:C2}")</td>
|
||||
<td class="text-end">
|
||||
@if (item.OrderStatus <= 10)
|
||||
{
|
||||
<button class="btn btn-sm btn-danger" @onclick="() => deleteRecord(item)"><i class="fa-solid fa-trash-can"></i></button>
|
||||
}
|
||||
</td>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach (var item in ListOrdersStatus)
|
||||
{
|
||||
@*<tr id="@item.OrderId" @onclick="getElementCoords">*@
|
||||
<tr>
|
||||
@*<a class="btn btn-sm btn-warning" href="OrderDetails?idOrd=@item.OrderId&orderStat=@item.OrderStatus" target="_blank"><i class="fa-solid fa-pen-to-square"></i></a>*@
|
||||
<td>
|
||||
<button class="btn btn-sm btn-primary" @onclick="()=>setOrd2Show(item.OrderId)" title="Order detail"><i class="fa-solid fa-magnifying-glass"></i></button>
|
||||
<a class="btn btn-sm btn-info" target="_blank" href="@reportUrl(item.OrderId)" title="Download pdf report"><i class="fa-regular fa-file-pdf"></i></a>
|
||||
</td>
|
||||
<td>@item.DateIns</td>
|
||||
<td>@item.OrderExtCode</td>
|
||||
<td>@item.OrderDescript</td>
|
||||
<td class="text-end">@item.NumDoors</td>
|
||||
<td class="text-end">@item.NumType</td>
|
||||
<td class="text-end">@getOrderStatusLabel(item.OrderStatus)</td>
|
||||
<td class="text-end">@($"{item.TotCost:C2}")</td>
|
||||
@*<td>
|
||||
<div class="progress">
|
||||
<div class="progress-bar" role="progressbar" aria-label="Basic example" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100" style="width: calc(20%item.OrderStatus); background-color: @setPgColor(item.OrderStatus)"></div>
|
||||
</div>
|
||||
</td>*@
|
||||
<td class="text-end">
|
||||
@if (item.OrderStatus <= 10)
|
||||
{
|
||||
<button class="btn btn-sm btn-danger" @onclick="() => deleteRecord(item)"><i class="fa-solid fa-trash-can"></i></button>
|
||||
}
|
||||
</td>
|
||||
</tr>
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
}
|
||||
else
|
||||
{
|
||||
@*<tr class="slideUp" style="--elFirstY: @($"{(Height) + screenY}px")">*@
|
||||
@*<a class="btn btn-sm btn-warning" href="OrderDetails?idOrd=@item.OrderId&orderStat=@item.OrderStatus" target="_blank"><i class="fa-solid fa-pen-to-square"></i></a>*@
|
||||
@*<tr>
|
||||
<td><a class="btn btn-sm btn-warning"><i class="fa-solid fa-pen-to-square"></i></a></td>
|
||||
<td>@Ord2Show.DateIns</td>
|
||||
<td>@Ord2Show.OrderExtCode</td>
|
||||
<td>@Ord2Show.OrderDescript</td>
|
||||
<td class="text-end">@Ord2Show.NumDoors</td>
|
||||
<td class="text-end">@Ord2Show.NumType</td>
|
||||
<td class="text-end">@getOrderStatusLabel(Ord2Show.OrderStatus)</td>
|
||||
<td class="text-end">@($"{Ord2Show.TotCost:C2}")</td>
|
||||
<td>
|
||||
<div class="progress">
|
||||
<div class="progress-bar" role="progressbar" aria-label="Basic example" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100" style="width: calc(20%item.OrderStatus); background-color: @setPgColor(item.OrderStatus)"></div>
|
||||
</div>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
@if (Ord2Show.OrderStatus <= 10)
|
||||
{
|
||||
<button class="btn btn-sm btn-danger" @onclick="() => deleteRecord(Ord2Show)"><i class="fa-solid fa-trash-can"></i></button>
|
||||
}
|
||||
</td>
|
||||
</tr>*@
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
}
|
||||
|
||||
@@ -1,18 +1,11 @@
|
||||
using EgwCoreLib.Razor;
|
||||
using Microsoft.AspNetCore.Components;
|
||||
using Microsoft.AspNetCore.Components.Authorization;
|
||||
using Microsoft.AspNetCore.Components.Web;
|
||||
using Microsoft.AspNetCore.DataProtection;
|
||||
using Microsoft.AspNetCore.Identity;
|
||||
using Microsoft.AspNetCore.WebUtilities;
|
||||
using Microsoft.Build.Framework;
|
||||
using Microsoft.JSInterop;
|
||||
using NLog.LayoutRenderers;
|
||||
using System.Linq;
|
||||
using WebDoorCreator.Data.DbModels;
|
||||
using WebDoorCreator.Data.Services;
|
||||
using WebDoorCreator.UI.Data;
|
||||
using static Microsoft.AspNetCore.Razor.Language.TagHelperMetadata;
|
||||
using static WebDoorCreator.Core.Enum;
|
||||
|
||||
namespace WebDoorCreator.UI.Components.Order
|
||||
@@ -21,11 +14,17 @@ namespace WebDoorCreator.UI.Components.Order
|
||||
{
|
||||
[Parameter]
|
||||
public bool B_doorChaged { get; set; }
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<int> E_currOrderStatus { get; set; }
|
||||
|
||||
public int Height { get; set; }
|
||||
|
||||
public string reportBaseUrl { get; set; } = "http://w2019-sql-steam/reportserver?/Test/WebDoor/";
|
||||
|
||||
[Parameter]
|
||||
public int UserCurrCompany { get; set; }
|
||||
|
||||
#region Protected Properties
|
||||
|
||||
private bool sortAsc = true;
|
||||
@@ -35,13 +34,13 @@ namespace WebDoorCreator.UI.Components.Order
|
||||
[Parameter]
|
||||
public OrderSelectFilter actFilter { get; set; } = new OrderSelectFilter();
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<int> updateRecordCount { get; set; }
|
||||
[Parameter]
|
||||
public EventCallback<OrderStatusViewModel> E_SetOrd2Show { get; set; }
|
||||
|
||||
public OrderStatusViewModel? Ord2Show { get; set; }
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<int> updateRecordCount { get; set; }
|
||||
protected string currUser { get; set; } = "";
|
||||
|
||||
[Inject]
|
||||
@@ -49,6 +48,7 @@ namespace WebDoorCreator.UI.Components.Order
|
||||
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
|
||||
private int _totalCount { get; set; } = 0;
|
||||
|
||||
private int currPage
|
||||
@@ -106,6 +106,7 @@ namespace WebDoorCreator.UI.Components.Order
|
||||
sortAsc = e.IsAscending;
|
||||
await ReloadData();
|
||||
}
|
||||
|
||||
#endregion Protected Properties
|
||||
|
||||
#region Protected Methods
|
||||
@@ -131,6 +132,9 @@ namespace WebDoorCreator.UI.Components.Order
|
||||
|
||||
protected bool isModRole { get; set; } = false;
|
||||
|
||||
[Inject]
|
||||
protected NavigationManager NavManager { get; set; } = null!;
|
||||
|
||||
protected bool ordByCode { get; set; } = false;
|
||||
|
||||
protected bool ordByDate { get; set; } = false;
|
||||
@@ -155,7 +159,6 @@ namespace WebDoorCreator.UI.Components.Order
|
||||
|
||||
protected async Task deleteRecord(OrderStatusViewModel currRec)
|
||||
{
|
||||
|
||||
if (!await JSRuntime.InvokeAsync<bool>("confirm", $"Order Deletion requested: are you sure to remove {currRec.OrderExtCode}?"))
|
||||
return;
|
||||
|
||||
@@ -219,6 +222,7 @@ namespace WebDoorCreator.UI.Components.Order
|
||||
|
||||
return answ;
|
||||
}
|
||||
|
||||
private async Task ReloadData()
|
||||
{
|
||||
ListOrdersStatus = null;
|
||||
@@ -265,6 +269,7 @@ namespace WebDoorCreator.UI.Components.Order
|
||||
ListOrdersStatus = ListOrdersStatus.OrderByDescending(x => x.DateIns).ToList();
|
||||
}
|
||||
break;
|
||||
|
||||
case "OrderNumber":
|
||||
if (sortAsc)
|
||||
{
|
||||
@@ -275,12 +280,12 @@ namespace WebDoorCreator.UI.Components.Order
|
||||
ListOrdersStatus = ListOrdersStatus.OrderByDescending(x => x.OrderExtCode).ToList();
|
||||
}
|
||||
break;
|
||||
|
||||
default:
|
||||
ListOrdersStatus = ListOrdersStatus.OrderByDescending(x => x.DateIns).ToList();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -293,11 +298,16 @@ namespace WebDoorCreator.UI.Components.Order
|
||||
await Task.Delay(1);
|
||||
await InvokeAsync(StateHasChanged);
|
||||
}
|
||||
#endregion Private Methods
|
||||
|
||||
public int Width { get; set; }
|
||||
|
||||
[Inject]
|
||||
protected NavigationManager NavManager { get; set; } = null!;
|
||||
protected IJSRuntime JsRuntime { get; set; } = null!;
|
||||
|
||||
#endregion Private Methods
|
||||
protected int screenX { get; set; } = 0;
|
||||
|
||||
protected int screenY { get; set; } = 0;
|
||||
|
||||
protected string getOrderStatusLabel(int orderStat)
|
||||
{
|
||||
@@ -314,9 +324,6 @@ namespace WebDoorCreator.UI.Components.Order
|
||||
|
||||
return answ;
|
||||
}
|
||||
|
||||
public string reportBaseUrl { get; set; } = "http://w2019-sql-steam/reportserver?/Test/WebDoor/";
|
||||
|
||||
protected string reportUrl(int orderId)
|
||||
{
|
||||
return $"{reportBaseUrl}ReportOrder&OrderID={orderId}&rs:Command=Render&rs:format=PDF";
|
||||
@@ -335,22 +342,6 @@ namespace WebDoorCreator.UI.Components.Order
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected int screenX { get; set; } = 0;
|
||||
protected int screenY { get; set; } = 0;
|
||||
|
||||
private void getElementCoords(MouseEventArgs e)
|
||||
{
|
||||
screenX = (int)(e.ClientX);
|
||||
screenY = (int)(e.ClientY);
|
||||
}
|
||||
|
||||
public int Height { get; set; }
|
||||
public int Width { get; set; }
|
||||
|
||||
[Inject]
|
||||
protected IJSRuntime JsRuntime { get; set; } = null!;
|
||||
|
||||
private async Task getDim()
|
||||
{
|
||||
var dimension = await JsRuntime.InvokeAsync<WindowDimension>("getWindowDimensions");
|
||||
@@ -358,11 +349,15 @@ namespace WebDoorCreator.UI.Components.Order
|
||||
Width = dimension.Width;
|
||||
}
|
||||
|
||||
private void getElementCoords(MouseEventArgs e)
|
||||
{
|
||||
screenX = (int)(e.ClientX);
|
||||
screenY = (int)(e.ClientY);
|
||||
}
|
||||
public class WindowDimension
|
||||
{
|
||||
public int Width { get; set; }
|
||||
public int Height { get; set; }
|
||||
public int Width { get; set; }
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -1,38 +1,29 @@
|
||||
using Microsoft.AspNetCore.Components;
|
||||
using Microsoft.AspNetCore.Components.Server.ProtectedBrowserStorage;
|
||||
using WebDoorCreator.Data.DbModels;
|
||||
using WebDoorCreator.Data.Services;
|
||||
using WebDoorCreator.UI.Data;
|
||||
|
||||
namespace WebDoorCreator.UI.Components.Order
|
||||
{
|
||||
public partial class OrderStatusStep
|
||||
{
|
||||
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
|
||||
[Parameter]
|
||||
public int CurrOrderStatus { get; set; } = 10;
|
||||
|
||||
[Parameter]
|
||||
public EventCallback<string> E_CurrStepColor { get; set; }
|
||||
|
||||
protected override async Task OnParametersSetAsync()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
}
|
||||
protected string currColor { get; set; } = "";
|
||||
|
||||
protected List<ListValuesModel>? currListOrderStatus { get; set; } = null;
|
||||
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
protected async Task doChangeStep(string actDoorDefStep)
|
||||
{
|
||||
await Task.Delay(1);
|
||||
|
||||
//await E_StepChanged.InvokeAsync(actDoorDefStep);
|
||||
}
|
||||
|
||||
protected List<ListValuesModel>? currListOrderStatus { get; set; } = null;
|
||||
protected string currColor { get; set; } = "";
|
||||
|
||||
protected override async Task OnInitializedAsync()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
@@ -50,5 +41,9 @@ namespace WebDoorCreator.UI.Components.Order
|
||||
}
|
||||
}
|
||||
|
||||
protected override async Task OnParametersSetAsync()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,7 +1,4 @@
|
||||
using Microsoft.AspNetCore.Components;
|
||||
using Microsoft.AspNetCore.Razor.Language.Extensions;
|
||||
using Microsoft.Build.Framework;
|
||||
using Microsoft.CodeAnalysis.CSharp.Syntax;
|
||||
using WebDoorCreator.Data.DbModels;
|
||||
using WebDoorCreator.Data.Services;
|
||||
using WebDoorCreator.UI.Data;
|
||||
@@ -20,6 +17,7 @@ namespace WebDoorCreator.UI.Components.Report
|
||||
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
|
||||
[Inject]
|
||||
protected WDCVocabularyService WDVService { get; set; } = null!;
|
||||
|
||||
@@ -37,7 +35,6 @@ namespace WebDoorCreator.UI.Components.Report
|
||||
}
|
||||
|
||||
return answ;
|
||||
|
||||
}
|
||||
|
||||
protected string getTranslatedLabel(string HwId)
|
||||
@@ -49,14 +46,13 @@ namespace WebDoorCreator.UI.Components.Report
|
||||
var hw2Translate = listHw.FirstOrDefault();
|
||||
if (hw2Translate != null)
|
||||
{
|
||||
|
||||
answ = translate(hw2Translate.Label);
|
||||
}
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
|
||||
protected async override Task OnParametersSetAsync()
|
||||
protected override async Task OnParametersSetAsync()
|
||||
{
|
||||
var result = await WDService.DoorOpGetByDoorId(doorId);
|
||||
if (result != null)
|
||||
@@ -64,6 +60,7 @@ namespace WebDoorCreator.UI.Components.Report
|
||||
DoorOps = result.Where(x => x.ObjectId != "Size" && x.ObjectId != "Profiles" && x.ObjectId != "Swing" && x.ObjectId != "Properties" && x.ObjectId != "Finishing").ToList();
|
||||
}
|
||||
}
|
||||
|
||||
protected string translate(string lemma)
|
||||
{
|
||||
string answ = "";
|
||||
|
||||
@@ -3,24 +3,13 @@
|
||||
@if (currDoorOp != null)
|
||||
{
|
||||
<div>
|
||||
@*@if (currDoorOp.DtConfirm != null && currDoorOp.userConfirm != "")
|
||||
{*@
|
||||
<div class="col-10 text-center mb-2">
|
||||
Please press
|
||||
|
||||
<button class="btn btn-outline-dark" style="cursor: pointer;" @onclick="()=>doConfirm()">
|
||||
CONFIRM
|
||||
</button>
|
||||
|
||||
after reading the whole file
|
||||
after reading the whole Document
|
||||
</div>
|
||||
@*}
|
||||
else
|
||||
{
|
||||
<div class="col-10 text-center mb-2">
|
||||
<span>Template already confirmed by user: <b>@currDoorOp.userConfirm</b> on <b>@currDoorOp.DtConfirm</b></span>
|
||||
</div>
|
||||
}*@
|
||||
<embed src="Docs/1001.pdf" width="100%" height="800px" />
|
||||
</div>
|
||||
}
|
||||
@@ -9,20 +9,75 @@ namespace WebDoorCreator.UI.Pages
|
||||
{
|
||||
public partial class HwPdfConfirm
|
||||
{
|
||||
protected int doorId = 0;
|
||||
|
||||
protected string objectId = "";
|
||||
|
||||
protected List<DoorOpModel> allDoorOps { get; set; } = new List<DoorOpModel>();
|
||||
|
||||
protected DoorOpModel currDoorOp { get; set; } = new DoorOpModel();
|
||||
|
||||
protected int doorOpId { get; set; } = 0;
|
||||
|
||||
[Inject]
|
||||
protected NavigationManager NavManager { get; set; } = null!;
|
||||
[Inject]
|
||||
protected WDCUserService WDCUService { get; set; } = null!;
|
||||
|
||||
protected string userLang
|
||||
{
|
||||
get => WDCUService.currLanguage ?? "EN";
|
||||
set => WDCUService.currLanguage = value;
|
||||
}
|
||||
|
||||
[Inject]
|
||||
protected WDCRefreshService WDCRService { get; set; } = null!;
|
||||
|
||||
protected int doorOpId { get; set; } = 0;
|
||||
protected int doorId = 0;
|
||||
protected string objectId = "";
|
||||
protected DoorOpModel currDoorOp { get; set; } = new DoorOpModel();
|
||||
protected List<DoorOpModel> allDoorOps { get; set; } = new List<DoorOpModel>();
|
||||
[Inject]
|
||||
protected WDCUserService WDCUService { get; set; } = null!;
|
||||
[Inject]
|
||||
protected WDCRefreshService WDRService { get; set; } = null!;
|
||||
|
||||
protected async override Task OnInitializedAsync()
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
|
||||
protected bool checkIfConf()
|
||||
{
|
||||
bool answ = false;
|
||||
if (allDoorOps != null)
|
||||
{
|
||||
var rawObj = JsonConvert.DeserializeObject<Dictionary<string, Dictionary<string, string>>>(currDoorOp.JsoncActVal!);
|
||||
if (rawObj != null)
|
||||
{
|
||||
foreach (var op in allDoorOps)
|
||||
{
|
||||
var opObj = JsonConvert.DeserializeObject<Dictionary<string, Dictionary<string, string>>>(op.JsoncActVal!);
|
||||
if (opObj != null)
|
||||
{
|
||||
if (rawObj["template"] == opObj["template"] && op.DtConfirm != null && op.userConfirm != "")
|
||||
{
|
||||
answ = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
|
||||
protected async Task doConfirm()
|
||||
{
|
||||
currDoorOp.userConfirm = WDCUService.userId;
|
||||
currDoorOp.DtConfirm = DateTime.Now;
|
||||
|
||||
var doorOps2Save = new List<DoorOpModel>() { currDoorOp };
|
||||
|
||||
var done = await WDService.DoorOpUpdate(doorOps2Save);
|
||||
if (done)
|
||||
{
|
||||
WDRService.ReportDoorOpConf(doorId, doorOpId, objectId);
|
||||
}
|
||||
}
|
||||
|
||||
protected override async Task OnInitializedAsync()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
var uri = NavManager.ToAbsoluteUri(NavManager.Uri);
|
||||
@@ -41,7 +96,6 @@ namespace WebDoorCreator.UI.Pages
|
||||
doorOpId = int.Parse(sDoorOpId);
|
||||
await ReloadData();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
protected async Task ReloadData()
|
||||
@@ -50,59 +104,8 @@ namespace WebDoorCreator.UI.Pages
|
||||
if (currDoorOp != null)
|
||||
{
|
||||
allDoorOps = await WDService.DoorOpGetByDoorId(currDoorOp.DoorId);
|
||||
|
||||
}
|
||||
await Task.Delay(1);
|
||||
}
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
[Inject]
|
||||
protected WDCRefreshService WDRService { get; set; } = null!;
|
||||
|
||||
protected async Task doConfirm()
|
||||
{
|
||||
currDoorOp.userConfirm = WDCUService.userId;
|
||||
currDoorOp.DtConfirm = DateTime.Now;
|
||||
|
||||
var doorOps2Save = new List<DoorOpModel>() { currDoorOp };
|
||||
|
||||
var done = await WDService.DoorOpUpdate(doorOps2Save);
|
||||
if (done)
|
||||
{
|
||||
WDRService.ReportDoorOpConf(doorId, doorOpId, objectId);
|
||||
}
|
||||
}
|
||||
|
||||
protected string userLang
|
||||
{
|
||||
get => WDCUService.currLanguage ?? "EN";
|
||||
set => WDCUService.currLanguage = value;
|
||||
}
|
||||
|
||||
protected bool checkIfConf()
|
||||
{
|
||||
bool answ = false;
|
||||
if (allDoorOps != null)
|
||||
{
|
||||
var rawObj = JsonConvert.DeserializeObject<Dictionary<string, Dictionary<string, string>>>(currDoorOp.JsoncActVal!);
|
||||
if (rawObj != null)
|
||||
{
|
||||
foreach (var op in allDoorOps)
|
||||
{
|
||||
var opObj = JsonConvert.DeserializeObject<Dictionary<string, Dictionary<string, string>>>(op.JsoncActVal!);
|
||||
if (opObj != null)
|
||||
{
|
||||
|
||||
if (rawObj["template"] == opObj["template"] && op.DtConfirm != null && op.userConfirm != "")
|
||||
{
|
||||
answ = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -1,31 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.Components;
|
||||
using System.Net.Http;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Components.Authorization;
|
||||
using Microsoft.AspNetCore.Components.Forms;
|
||||
using Microsoft.AspNetCore.Components.Routing;
|
||||
using Microsoft.AspNetCore.Components.Web;
|
||||
using Microsoft.AspNetCore.Components.Web.Virtualization;
|
||||
using Microsoft.JSInterop;
|
||||
using WebDoorCreator.UI;
|
||||
using WebDoorCreator.UI.Components;
|
||||
using WebDoorCreator.UI.Components.Buttons;
|
||||
using WebDoorCreator.UI.Components.CompMan;
|
||||
using WebDoorCreator.UI.Components.DoorMan;
|
||||
using WebDoorCreator.UI.Components.DoorDef;
|
||||
using WebDoorCreator.UI.Components.Gen;
|
||||
using WebDoorCreator.UI.Components.Order;
|
||||
using WebDoorCreator.UI.Components.Users;
|
||||
using WebDoorCreator.UI.Components.Hardware;
|
||||
using WebDoorCreator.UI.Components.SvgComp;
|
||||
using WebDoorCreator.UI.Components.Filters;
|
||||
using WebDoorCreator.UI.Shared;
|
||||
using WebDoorCreator.Data.DbModels;
|
||||
using EgwCoreLib.Razor;
|
||||
|
||||
namespace WebDoorCreator.UI.Pages
|
||||
{
|
||||
@@ -33,6 +6,7 @@ namespace WebDoorCreator.UI.Pages
|
||||
{
|
||||
[Inject]
|
||||
protected NavigationManager NavManager { get; set; } = null!;
|
||||
|
||||
protected async Task changePage(bool newPage)
|
||||
{
|
||||
await Task.Delay(1);
|
||||
|
||||
@@ -1,27 +1,62 @@
|
||||
using Microsoft.AspNetCore.Components;
|
||||
using WebDoorCreator.Data.DbModels;
|
||||
using WebDoorCreator.Data.Services;
|
||||
using WebDoorCreator.UI.Data;
|
||||
|
||||
namespace WebDoorCreator.UI.Pages
|
||||
{
|
||||
public partial class Utils
|
||||
{
|
||||
protected string _keyWord { get; set; } = "";
|
||||
[Inject]
|
||||
protected IConfiguration config { get; set; } = null!;
|
||||
|
||||
protected WebDoorCreator.Data.DDF.Converter currDdfConv { get; set; } = null!;
|
||||
protected bool done { get; set; } = false;
|
||||
protected List<DoorOpModel>? DoorOpsList { get; set; }
|
||||
|
||||
protected List<DoorModel> DoorsList { get; set; } = new List<DoorModel>();
|
||||
|
||||
protected string keyWord
|
||||
{
|
||||
get => _keyWord;
|
||||
set => _keyWord = value;
|
||||
}
|
||||
|
||||
protected List<DoorOpModel> listOp { get; set; } = new List<DoorOpModel>();
|
||||
protected List<DoorOpModel> listOpAll { get; set; } = new List<DoorOpModel>();
|
||||
[Inject]
|
||||
protected NavigationManager NavManager { get; set; } = null!;
|
||||
|
||||
protected List<OrderStatusViewModel>? OrdersList { get; set; }
|
||||
|
||||
protected List<string> ordListVal { get; set; } = new List<string>();
|
||||
protected List<DoorOpModel> listOp { get; set; } = new List<DoorOpModel>();
|
||||
protected List<DoorOpModel> listOpAll { get; set; } = new List<DoorOpModel>();
|
||||
|
||||
[Inject]
|
||||
protected QueueDataService QDataServ { get; set; } = null!;
|
||||
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDCService { get; set; } = null!;
|
||||
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
|
||||
public async Task flushCache()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
await WDService.FlushRedisCache();
|
||||
await Task.Delay(1);
|
||||
// rimando a pagina corrente
|
||||
NavManager.NavigateTo("/", true);
|
||||
}
|
||||
|
||||
public async Task FlushCustomPattern()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
await WDService.FlushCustomPattern(keyWord);
|
||||
await Task.Delay(1);
|
||||
// rimando a pagina corrente
|
||||
NavManager.NavigateTo("/", true);
|
||||
}
|
||||
|
||||
protected async Task doorsGetAll()
|
||||
{
|
||||
await ordersGetAll();
|
||||
@@ -39,24 +74,7 @@ namespace WebDoorCreator.UI.Pages
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
protected bool done { get; set; } = false;
|
||||
|
||||
[Inject]
|
||||
protected IConfiguration config { get; set; } = null!;
|
||||
|
||||
protected override void OnInitialized()
|
||||
{
|
||||
base.OnInitialized();
|
||||
string vers = config.GetValue<string>("ConfDDF:VersNumber");
|
||||
bool remDoorOp = config.GetValue<bool>("ConfDDF:RemoveDoorOps");
|
||||
var headRows = config.GetSection("ConfDDF:Header").Get<List<string>>();
|
||||
var footRows = config.GetSection("ConfDDF:Footer").Get<List<string>>();
|
||||
currDdfConv = new WebDoorCreator.Data.DDF.Converter(vers, remDoorOp, headRows, footRows);
|
||||
}
|
||||
|
||||
protected WebDoorCreator.Data.DDF.Converter currDdfConv { get; set; } = null!;
|
||||
/// <summary>
|
||||
/// Effettua salvataggio record e generazione DDF
|
||||
/// </summary>
|
||||
@@ -97,7 +115,6 @@ namespace WebDoorCreator.UI.Pages
|
||||
// versione corrente del DDF generato
|
||||
int currVers = await QDataServ.SendCalcReq(door.DoorId, currDdf);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -106,44 +123,20 @@ namespace WebDoorCreator.UI.Pages
|
||||
done = true;
|
||||
}
|
||||
|
||||
protected override void OnInitialized()
|
||||
{
|
||||
base.OnInitialized();
|
||||
string vers = config.GetValue<string>("ConfDDF:VersNumber");
|
||||
bool remDoorOp = config.GetValue<bool>("ConfDDF:RemoveDoorOps");
|
||||
var headRows = config.GetSection("ConfDDF:Header").Get<List<string>>();
|
||||
var footRows = config.GetSection("ConfDDF:Footer").Get<List<string>>();
|
||||
currDdfConv = new WebDoorCreator.Data.DDF.Converter(vers, remDoorOp, headRows, footRows);
|
||||
}
|
||||
protected async Task ordersGetAll()
|
||||
{
|
||||
DateTime adesso = DateTime.Today;
|
||||
|
||||
OrdersList = await WDCService.OrderStatusGetFilt(0, 0, adesso.AddYears(-200), adesso.AddYears(200));
|
||||
}
|
||||
|
||||
public async Task flushCache()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
await WDService.FlushRedisCache();
|
||||
await Task.Delay(1);
|
||||
// rimando a pagina corrente
|
||||
NavManager.NavigateTo("/", true);
|
||||
}
|
||||
|
||||
protected string _keyWord { get; set; } = "";
|
||||
protected string keyWord
|
||||
{
|
||||
get => _keyWord;
|
||||
set => _keyWord = value;
|
||||
}
|
||||
|
||||
|
||||
public async Task FlushCustomPattern()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
await WDService.FlushCustomPattern(keyWord);
|
||||
await Task.Delay(1);
|
||||
// rimando a pagina corrente
|
||||
NavManager.NavigateTo("/", true);
|
||||
}
|
||||
|
||||
|
||||
[Inject]
|
||||
protected NavigationManager NavManager { get; set; } = null!;
|
||||
|
||||
[Inject]
|
||||
protected WebDoorCreatorService WDService { get; set; } = null!;
|
||||
}
|
||||
}
|
||||
@@ -3,7 +3,7 @@
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<Nullable>enable</Nullable>
|
||||
<Version>0.9.2305.2319</Version>
|
||||
<Version>0.9.2305.2414</Version>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<UserSecretsId>aspnet-WebDoorCreator.UI-dfe95fed-1398-4144-bd43-8b3a765d6608</UserSecretsId>
|
||||
</PropertyGroup>
|
||||
|
||||
Reference in New Issue
Block a user