Compare commits
24 Commits
RC7
...
PageMarginFix
| Author | SHA1 | Date | |
|---|---|---|---|
| e3433962fa | |||
| 442d419460 | |||
| c82cd1ed8b | |||
| 23f7e9c726 | |||
| c71a592ab3 | |||
| c848168552 | |||
| d95a19af32 | |||
| c5e4f95b94 | |||
| 35e00bdb71 | |||
| 8948984b44 | |||
| 58f8d2aee3 | |||
| 951a704b52 | |||
| d518861228 | |||
| 32a0fa1287 | |||
| 33212941c8 | |||
| 59975a335d | |||
| 390046a0c7 | |||
| 149f6251f7 | |||
| 46a0efe748 | |||
| ace620b09d | |||
| 3d87f28004 | |||
| b7071dcbe1 | |||
| fdf937131c | |||
| 1b8a19b036 |
+8
-24
@@ -70,6 +70,8 @@ stages:
|
||||
|
||||
build:
|
||||
stage: build
|
||||
tags:
|
||||
- win
|
||||
before_script:
|
||||
- *nuget-fix
|
||||
- dotnet restore GWMS.sln
|
||||
@@ -78,38 +80,18 @@ build:
|
||||
|
||||
test:
|
||||
stage: test
|
||||
tags:
|
||||
- win
|
||||
only:
|
||||
- develop
|
||||
needs: ["build"]
|
||||
script:
|
||||
- dotnet test -p:Configuration=Release GWMS.UI/GWMS.UI.csproj
|
||||
|
||||
# IIS01:deploy:
|
||||
# stage: deploy
|
||||
# only:
|
||||
# - develop
|
||||
# needs: ["test"]
|
||||
# # before_script:
|
||||
# # - *nuget-fix
|
||||
# # - dotnet restore
|
||||
# script:
|
||||
# - dotnet publish -p:PublishProfile=IIS01.pubxml -p:RunCodeAnalysis=false -p:Configuration=Release -p:username=jenkins -p:Password=viadante16 -p:AllowUntrustedCertificate=true GWMS.UI/GWMS.UI.csproj
|
||||
|
||||
|
||||
# IIS02:deploy:
|
||||
# stage: deploy
|
||||
# only:
|
||||
# - master
|
||||
# needs: ["build"]
|
||||
# # before_script:
|
||||
# # - *nuget-fix
|
||||
# # - dotnet restore
|
||||
# script:
|
||||
# - dotnet publish -p:PublishProfile=IIS02.pubxml -p:RunCodeAnalysis=false -p:Configuration=Release -p:username=jenkins -p:Password=viadante16 -p:AllowUntrustedCertificate=true GWMS.UI/GWMS.UI.csproj
|
||||
# - dotnet publish -p:PublishProfile=W2019-IIS-DEVProfile.pubxml -p:RunCodeAnalysis=false -p:Configuration=Release -p:username=jenkins -p:Password=viadante16 -p:AllowUntrustedCertificate=true GWMS.UI/GWMS.UI.csproj
|
||||
|
||||
installer:
|
||||
stage: installer
|
||||
tags:
|
||||
- win
|
||||
only:
|
||||
- develop
|
||||
- master
|
||||
@@ -127,6 +109,8 @@ installer:
|
||||
|
||||
release:
|
||||
stage: release
|
||||
tags:
|
||||
- win
|
||||
only:
|
||||
#- feature/Deploy_CI_CD
|
||||
# - master
|
||||
|
||||
Vendored
+35
@@ -0,0 +1,35 @@
|
||||
{
|
||||
"version": "0.2.0",
|
||||
"configurations": [
|
||||
{
|
||||
// Use IntelliSense to find out which attributes exist for C# debugging
|
||||
// Use hover for the description of the existing attributes
|
||||
// For further information visit https://github.com/OmniSharp/omnisharp-vscode/blob/master/debugger-launchjson.md
|
||||
"name": ".NET Core Launch (web)",
|
||||
"type": "coreclr",
|
||||
"request": "launch",
|
||||
"preLaunchTask": "build",
|
||||
// If you have changed target frameworks, make sure to update the program path.
|
||||
"program": "${workspaceFolder}/GWMS.UI/bin/Debug/net5.0/GWMS.UI.dll",
|
||||
"args": [],
|
||||
"cwd": "${workspaceFolder}/GWMS.UI",
|
||||
"stopAtEntry": false,
|
||||
// Enable launching a web browser when ASP.NET Core starts. For more information: https://aka.ms/VSCode-CS-LaunchJson-WebBrowser
|
||||
"serverReadyAction": {
|
||||
"action": "openExternally",
|
||||
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
|
||||
},
|
||||
"env": {
|
||||
"ASPNETCORE_ENVIRONMENT": "Development"
|
||||
},
|
||||
"sourceFileMap": {
|
||||
"/Views": "${workspaceFolder}/Views"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": ".NET Core Attach",
|
||||
"type": "coreclr",
|
||||
"request": "attach"
|
||||
}
|
||||
]
|
||||
}
|
||||
Vendored
+42
@@ -0,0 +1,42 @@
|
||||
{
|
||||
"version": "2.0.0",
|
||||
"tasks": [
|
||||
{
|
||||
"label": "build",
|
||||
"command": "dotnet",
|
||||
"type": "process",
|
||||
"args": [
|
||||
"build",
|
||||
"${workspaceFolder}/GWMS.UI/GWMS.UI.csproj",
|
||||
"/property:GenerateFullPaths=true",
|
||||
"/consoleloggerparameters:NoSummary"
|
||||
],
|
||||
"problemMatcher": "$msCompile"
|
||||
},
|
||||
{
|
||||
"label": "publish",
|
||||
"command": "dotnet",
|
||||
"type": "process",
|
||||
"args": [
|
||||
"publish",
|
||||
"${workspaceFolder}/GWMS.UI/GWMS.UI.csproj",
|
||||
"/property:GenerateFullPaths=true",
|
||||
"/consoleloggerparameters:NoSummary"
|
||||
],
|
||||
"problemMatcher": "$msCompile"
|
||||
},
|
||||
{
|
||||
"label": "watch",
|
||||
"command": "dotnet",
|
||||
"type": "process",
|
||||
"args": [
|
||||
"watch",
|
||||
"run",
|
||||
"${workspaceFolder}/GWMS.UI/GWMS.UI.csproj",
|
||||
"/property:GenerateFullPaths=true",
|
||||
"/consoleloggerparameters:NoSummary"
|
||||
],
|
||||
"problemMatcher": "$msCompile"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -156,9 +156,9 @@ namespace GWMS.Data.Controllers
|
||||
public List<PlantDTO> GetPlantsDTO(int maxRecords)
|
||||
{
|
||||
List<PlantDTO> dbResult = new List<PlantDTO>();
|
||||
using (GWMSContext dbCtxMult = new GWMSContext(_configuration))
|
||||
using (GWMSContext localDbCtx = new GWMSContext(_configuration))
|
||||
{
|
||||
var plantList = dbCtxMult
|
||||
var plantList = localDbCtx
|
||||
.DbSetPlant
|
||||
.ToList();
|
||||
|
||||
@@ -225,7 +225,7 @@ namespace GWMS.Data.Controllers
|
||||
List<WeekPlanModel> dbResult = new List<WeekPlanModel>();
|
||||
using (GWMSContext localDbCtx = new GWMSContext(_configuration))
|
||||
{
|
||||
dbResult = dbCtx
|
||||
dbResult = localDbCtx
|
||||
.DbSetPlantSupplWeekPlan
|
||||
.Include(p => p.Plant)
|
||||
.Include(s => s.Supplier)
|
||||
@@ -357,10 +357,10 @@ namespace GWMS.Data.Controllers
|
||||
List<TSData> PressBLTS = new List<TSData>();
|
||||
List<TSData> OrderTS = new List<TSData>();
|
||||
|
||||
using (GWMSContext dbCtxMult = new GWMSContext(_configuration))
|
||||
using (GWMSContext localDbCtx = new GWMSContext(_configuration))
|
||||
{
|
||||
// recupero dal DB
|
||||
var rawLevelData = dbCtxMult
|
||||
var rawLevelData = localDbCtx
|
||||
.DbSetPlantLog
|
||||
.Where(x => x.FluxType == "Level" && x.PlantId == PlantId)
|
||||
.OrderByDescending(x => x.DtEvent)
|
||||
@@ -368,7 +368,7 @@ namespace GWMS.Data.Controllers
|
||||
.OrderBy(x => x.DtEvent)
|
||||
.ToList();
|
||||
|
||||
var rawMainPressData = dbCtxMult
|
||||
var rawMainPressData = localDbCtx
|
||||
.DbSetPlantLog
|
||||
.Where(x => x.FluxType == "MainPress" && x.PlantId == PlantId)
|
||||
.OrderByDescending(x => x.DtEvent)
|
||||
@@ -376,7 +376,7 @@ namespace GWMS.Data.Controllers
|
||||
.OrderBy(x => x.DtEvent)
|
||||
.ToList();
|
||||
|
||||
var rawBHPressData = dbCtxMult
|
||||
var rawBHPressData = localDbCtx
|
||||
.DbSetPlantLog
|
||||
.Where(x => x.FluxType == "PressBH" && x.PlantId == PlantId)
|
||||
.OrderByDescending(x => x.DtEvent)
|
||||
@@ -384,7 +384,7 @@ namespace GWMS.Data.Controllers
|
||||
.OrderBy(x => x.DtEvent)
|
||||
.ToList();
|
||||
|
||||
var rawBLPressData = dbCtxMult
|
||||
var rawBLPressData = localDbCtx
|
||||
.DbSetPlantLog
|
||||
.Where(x => x.FluxType == "PressBL" && x.PlantId == PlantId)
|
||||
.OrderByDescending(x => x.DtEvent)
|
||||
@@ -392,7 +392,7 @@ namespace GWMS.Data.Controllers
|
||||
.OrderBy(x => x.DtEvent)
|
||||
.ToList();
|
||||
|
||||
var rawOrderData = dbCtxMult
|
||||
var rawOrderData = localDbCtx
|
||||
.DbSetOrders
|
||||
.Where(x => x.PlantId == PlantId && x.ExecutionQty == 0)
|
||||
.OrderByDescending(x => x.DtOrder)
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace GWMS.Data.DTO
|
||||
public string PlantCode { get; set; } = "";
|
||||
public string PlantDesc { get; set; } = "";
|
||||
|
||||
public DateTime LastUpdate { get; set; } = DateTime.Today;
|
||||
public DateTime LastUpdate { get; set; } = DateTime.Today.AddDays(DateTime.Today.DayOfYear);
|
||||
|
||||
public double LevelMax { get; set; } = 99999;
|
||||
|
||||
|
||||
@@ -34,7 +34,9 @@ namespace GWMS.Data
|
||||
Database.Migrate();
|
||||
}
|
||||
catch (Exception exc)
|
||||
{ }
|
||||
{
|
||||
Log.Error(exc, "Exception during context initialization 01");
|
||||
}
|
||||
}
|
||||
|
||||
public GWMSContext(DbContextOptions<GWMSContext> options) : base(options)
|
||||
@@ -45,7 +47,9 @@ namespace GWMS.Data
|
||||
Database.Migrate();
|
||||
}
|
||||
catch (Exception exc)
|
||||
{ }
|
||||
{
|
||||
Log.Error(exc, "Exception during context initialization 02");
|
||||
}
|
||||
}
|
||||
|
||||
#endregion Public Constructors
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
<Router AppAssembly="@typeof(Program).Assembly" PreferExactMatches="@true">
|
||||
<Found Context="routeData">
|
||||
<RouteView RouteData="@routeData" DefaultLayout="@typeof(MainLayout)" />
|
||||
</Found>
|
||||
<NotFound>
|
||||
<LayoutView Layout="@typeof(MainLayout)">
|
||||
<p>Sorry, there's nothing at this address.</p>
|
||||
</LayoutView>
|
||||
</NotFound>
|
||||
</Router>
|
||||
@@ -68,10 +68,10 @@
|
||||
</div>
|
||||
<div class="col-12 col-lg-2">
|
||||
<div class="mb-2">
|
||||
<button type="button" class="btn btn-outline-success btn-block" value="Save" @onclick="saveUpdate">Save <i class="far fa-save"></i></button>
|
||||
<button type="button" class="btn btn-success btn-block" value="Save" @onclick="saveUpdate">Save <i class="far fa-save"></i></button>
|
||||
</div>
|
||||
<div>
|
||||
<button type="button" class="btn btn-outline-warning btn-block" value="Cancel" @onclick="cancelUpdate">Cancel <i class="fas fa-ban"></i></button>
|
||||
<button type="button" class="btn btn-warning btn-block" value="Cancel" @onclick="cancelUpdate">Cancel <i class="fas fa-ban"></i></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -17,21 +17,14 @@
|
||||
{
|
||||
<EditForm Model="@_currItem">
|
||||
<DataAnnotationsValidator />
|
||||
<div class="row">
|
||||
<div class="col-12 col-lg-2 text-center">
|
||||
<div class="d-flex flex-column text-center">
|
||||
<div class="p-1 flex-grow-1">
|
||||
<div id="qrCodeImg"></div>
|
||||
@_currItem.OrderCode
|
||||
@*<img src="@getImgUrl(_currItem.OrderCode)" class="img-fluid" />*@
|
||||
</div>
|
||||
<div class="col-12 col-lg-2">
|
||||
<div class="row">
|
||||
@*<div class="col">
|
||||
<button type="button" class="btn btn-sm btn-success btn-block" value="Save" @onclick="saveUpdate">Save <i class="far fa-save"></i></button>
|
||||
</div>*@
|
||||
<div class="col">
|
||||
<button type="button" class="btn btn-sm btn-warning btn-block" value="Cancel" @onclick="cancelUpdate">Cancel <i class="fas fa-ban"></i></button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="p-1 flex-grow-1">
|
||||
<button type="button" class="btn btn-sm btn-warning btn-block" value="Cancel" @onclick="cancelUpdate">Cancel <i class="fas fa-ban"></i></button>
|
||||
</div>
|
||||
</div>
|
||||
</EditForm>
|
||||
|
||||
@@ -54,23 +54,18 @@
|
||||
<span><i class="fas fa-database"></i> Livello:</span><span>@currItem.LevelAct.ToString("N0")/@currItem.LevelMax.ToString("N0")</span> | <span style="font-size:1.2em;"><b>@currItem.LevelRatio</b> <sub>%</sub></span>
|
||||
</div>
|
||||
</li>
|
||||
<li class="list-group-item d-flex justify-content-between align-items-center">
|
||||
<div class="row">
|
||||
@*<div class="col-12 text-center small">
|
||||
</div>*@
|
||||
<div class="col-12 small">
|
||||
<li class="list-group-item align-items-center px-1 py-2">
|
||||
<div class="d-flex flex-column">
|
||||
<div class="p-1 flex-grow-1">
|
||||
<Progress>
|
||||
<ProgressBar Value="@currItem.LevelRatio" Striped="false" Animated="false" />
|
||||
</Progress>
|
||||
</div>
|
||||
<div class="col-12 px-0 mt-2">
|
||||
<div class="px-1 py-2">
|
||||
<LineChart @ref="LevelVal" TItem="double" OptionsObject="lineChartOptions" />
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
@*<li class="list-group-item d-flex justify-content-between align-items-center">
|
||||
<span><i class="fas fa-database"></i> Livello</span> <span style="font-size:1.2em;"><b>@currItem.LevelRatio</b> <sub>%</sub></span>
|
||||
</li>*@
|
||||
<li class="list-group-item d-flex justify-content-between align-items-center">
|
||||
<span><i class="fas fa-compress-arrows-alt"></i> Pressione</span> <span style="font-size:1.2em;"><b>@currItem.PressAct["Main"].ToString("N1")</b> <span class="small"> <sub>bar</sub></span></span>
|
||||
</li>
|
||||
|
||||
@@ -57,7 +57,7 @@ namespace GWMS.UI.Components
|
||||
Mode = "nearest",
|
||||
Intersect = false
|
||||
},
|
||||
Animation = true,
|
||||
Animation = false,
|
||||
Responsive = true,
|
||||
AspectRatio = 2,
|
||||
type = "line",
|
||||
@@ -118,7 +118,7 @@ namespace GWMS.UI.Components
|
||||
|
||||
public string checkRTime
|
||||
{
|
||||
get => DateTime.Now.Subtract(_currItem.LastUpdate).TotalMinutes > 2 ? $"Ultimo aggiornamento: {_currItem.LastUpdate}" : "Dati Realtime";
|
||||
get => DateTime.Now.Subtract(_currItem.LastUpdate).TotalMinutes > 2 ? $"Mancata ricezione: ultimo aggiornamento {_currItem.LastUpdate}" : $"Dati Realtime aggiornati al {_currItem.LastUpdate}";
|
||||
}
|
||||
|
||||
[Parameter]
|
||||
@@ -165,13 +165,13 @@ namespace GWMS.UI.Components
|
||||
int numCount = _currItem.LevelTS.Count;
|
||||
// passo a 2h se > 3 gg
|
||||
if (numCount > 72)
|
||||
answ = 2;
|
||||
answ = 3;
|
||||
// passo a 3h se > 5 gg
|
||||
else if (numCount > 120)
|
||||
answ = 3;
|
||||
answ = 4;
|
||||
// passo a 4h se > 10 gg
|
||||
else if (numCount > 240)
|
||||
answ = 4;
|
||||
answ = 5;
|
||||
redFact = answ;
|
||||
}
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net5.0</TargetFramework>
|
||||
<Version>1.0.2108.3012</Version>
|
||||
<Version>1.0.2109.2218</Version>
|
||||
<UserSecretsId>95c9f021-52d1-4390-a670-5810b7b777b0</UserSecretsId>
|
||||
<EnableNETAnalyzers>true</EnableNETAnalyzers>
|
||||
<RunAnalyzersDuringBuild>true</RunAnalyzersDuringBuild>
|
||||
|
||||
@@ -143,7 +143,7 @@ namespace GWMS.UI.Pages
|
||||
NavManager.NavigateTo($"GasStation/{args.BarcodeText}");
|
||||
}
|
||||
|
||||
private async Task reloadData()
|
||||
private async Task ReloadAllData()
|
||||
{
|
||||
isLoading = true;
|
||||
PlantsList = null;
|
||||
@@ -175,7 +175,7 @@ namespace GWMS.UI.Pages
|
||||
MessageService.ShowSearch = false;
|
||||
MessageService.PageName = "Stazione";
|
||||
MessageService.PageIcon = "fas fa-gas-pump pr-2";
|
||||
await reloadData();
|
||||
await ReloadAllData();
|
||||
}
|
||||
|
||||
protected void ResetData()
|
||||
|
||||
+20
-16
@@ -24,22 +24,26 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-12 my-lg-5">
|
||||
<SetupDiagnostics></SetupDiagnostics>
|
||||
</div>
|
||||
<div class="col-12 text-center">
|
||||
<img class="img-fluid mb-3" src="./img/LogoPizzaferri.png" />
|
||||
<h4>
|
||||
Sistema di gestione e pianificazione logistica impianti distribuzione metano
|
||||
</h4>
|
||||
</div>
|
||||
<div class="col-12 text-center mt-5">
|
||||
<div class="col-4"></div>
|
||||
<div class="col-4"></div>
|
||||
<div class="col-4 badge badge-pill badge-dark">
|
||||
<div class="px-1">
|
||||
<a class="text-light" href="https://www.egalware.com/" target="_blank">powered by EgalWare <img width="24" class="img-fluid" src="img/LogoBlu.svg" /></a>
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
<div class="row">
|
||||
<div class="col-12 my-lg-5">
|
||||
<SetupDiagnostics></SetupDiagnostics>
|
||||
</div>
|
||||
<div class="col-12 text-center">
|
||||
<img class="img-fluid mb-3" src="./img/LogoPizzaferri.png" />
|
||||
<h4>
|
||||
Sistema di gestione e pianificazione logistica impianti distribuzione metano
|
||||
</h4>
|
||||
</div>
|
||||
<div class="col-12 text-center mt-5">
|
||||
<div class="col-4"></div>
|
||||
<div class="col-4"></div>
|
||||
<div class="col-4 badge badge-pill badge-dark">
|
||||
<div class="px-1">
|
||||
<a class="text-light" href="https://www.egalware.com/" target="_blank">powered by EgalWare <img width="24" class="img-fluid" src="img/LogoBlu.svg" /></a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -115,8 +115,6 @@ namespace GWMS.UI.Pages
|
||||
}
|
||||
}
|
||||
|
||||
private bool ShowCharts { get; set; } = false;
|
||||
|
||||
private bool ShowClosed
|
||||
{
|
||||
get
|
||||
@@ -308,9 +306,6 @@ namespace GWMS.UI.Pages
|
||||
protected void Edit(OrderModel selRecord)
|
||||
{
|
||||
// rileggo dal DB il record corrente...
|
||||
#if false
|
||||
currRecord = selRecord;
|
||||
#endif
|
||||
var pUpd = Task.Run(async () => currRecord = await DataService.OrderGetByCode(selRecord.OrderCode));
|
||||
pUpd.Wait();
|
||||
}
|
||||
@@ -338,8 +333,8 @@ namespace GWMS.UI.Pages
|
||||
protected async Task ReloadAllData()
|
||||
{
|
||||
isLoading = true;
|
||||
//PlantsList = await DataService.PlantsGetAll();
|
||||
SuppliersList = await DataService.SuppliersGetAll();
|
||||
SelPlantId = 0;
|
||||
PlantsList = null;
|
||||
await GetClaimsData();
|
||||
// se ho un plantId valido --> altrimenti non abilitato
|
||||
@@ -358,7 +353,6 @@ namespace GWMS.UI.Pages
|
||||
PlantsList = new List<PlantDTO>();
|
||||
}
|
||||
isLoading = false;
|
||||
|
||||
await ReloadData();
|
||||
}
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
@using GWMS.UI.Components
|
||||
|
||||
<div class="row">
|
||||
<div class="row mx-0">
|
||||
@if (ListRecords == null)
|
||||
{
|
||||
<div class="col-12">
|
||||
|
||||
@@ -99,7 +99,7 @@ namespace GWMS.UI.Pages
|
||||
}
|
||||
}
|
||||
|
||||
private async Task reloadData()
|
||||
private async Task ReloadAllData()
|
||||
{
|
||||
isLoading = true;
|
||||
ListRecords = null;
|
||||
@@ -131,7 +131,7 @@ namespace GWMS.UI.Pages
|
||||
MessageService.PageName = "Impianti";
|
||||
MessageService.PageIcon = "fas fa-gas-pump pr-2";
|
||||
MessageService.EA_SearchUpdated += OnSeachUpdated;
|
||||
await reloadData();
|
||||
await ReloadAllData();
|
||||
}
|
||||
|
||||
protected void Select(PlantDTO selRecord)
|
||||
@@ -143,7 +143,7 @@ namespace GWMS.UI.Pages
|
||||
protected async Task UpdateData()
|
||||
{
|
||||
currRecord = null;
|
||||
await reloadData();
|
||||
await ReloadAllData();
|
||||
}
|
||||
|
||||
#endregion Protected Methods
|
||||
|
||||
@@ -76,17 +76,17 @@ namespace GWMS.UI.Pages
|
||||
get
|
||||
{
|
||||
int answ = 0;
|
||||
if (MessageService.Order_Filter != null)
|
||||
if (AppMService.Order_Filter != null)
|
||||
{
|
||||
answ = MessageService.Order_Filter.PlantId;
|
||||
answ = AppMService.Order_Filter.PlantId;
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (!MessageService.Order_Filter.PlantId.Equals(value))
|
||||
if (!AppMService.Order_Filter.PlantId.Equals(value))
|
||||
{
|
||||
MessageService.Order_Filter.PlantId = value;
|
||||
AppMService.Order_Filter.PlantId = value;
|
||||
var pUpd = Task.Run(async () => await ReloadData());
|
||||
pUpd.Wait();
|
||||
}
|
||||
@@ -98,29 +98,30 @@ namespace GWMS.UI.Pages
|
||||
get
|
||||
{
|
||||
int answ = 0;
|
||||
if (MessageService.Order_Filter != null)
|
||||
if (AppMService.Order_Filter != null)
|
||||
{
|
||||
answ = MessageService.Order_Filter.SupplierId;
|
||||
answ = AppMService.Order_Filter.SupplierId;
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (!MessageService.Order_Filter.SupplierId.Equals(value))
|
||||
if (!AppMService.Order_Filter.SupplierId.Equals(value))
|
||||
{
|
||||
MessageService.Order_Filter.SupplierId = value;
|
||||
AppMService.Order_Filter.SupplierId = value;
|
||||
var pUpd = Task.Run(async () => await ReloadData());
|
||||
pUpd.Wait();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private bool ShowCharts { get; set; } = false;
|
||||
|
||||
#endregion Private Properties
|
||||
|
||||
#region Protected Properties
|
||||
|
||||
[Inject]
|
||||
protected MessageService AppMService { get; set; }
|
||||
|
||||
[Inject]
|
||||
protected AuthenticationStateProvider AuthenticationStateProvider { get; set; }
|
||||
|
||||
@@ -132,17 +133,17 @@ namespace GWMS.UI.Pages
|
||||
get
|
||||
{
|
||||
DateTime answ = DateTime.Today.AddDays(1);
|
||||
if (MessageService.Order_Filter != null)
|
||||
if (AppMService.Order_Filter != null)
|
||||
{
|
||||
answ = MessageService.Order_Filter.DateEnd;
|
||||
answ = AppMService.Order_Filter.DateEnd;
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (!MessageService.Order_Filter.DateEnd.Equals(value))
|
||||
if (!AppMService.Order_Filter.DateEnd.Equals(value))
|
||||
{
|
||||
MessageService.Order_Filter.DateEnd = value;
|
||||
AppMService.Order_Filter.DateEnd = value;
|
||||
var pUpd = Task.Run(async () => await ReloadData());
|
||||
pUpd.Wait();
|
||||
}
|
||||
@@ -154,17 +155,17 @@ namespace GWMS.UI.Pages
|
||||
get
|
||||
{
|
||||
DateTime answ = DateTime.Today.AddDays(-1);
|
||||
if (MessageService.Order_Filter != null)
|
||||
if (AppMService.Order_Filter != null)
|
||||
{
|
||||
answ = MessageService.Order_Filter.DateStart;
|
||||
answ = AppMService.Order_Filter.DateStart;
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (!MessageService.Order_Filter.DateStart.Equals(value))
|
||||
if (!AppMService.Order_Filter.DateStart.Equals(value))
|
||||
{
|
||||
MessageService.Order_Filter.DateStart = value;
|
||||
AppMService.Order_Filter.DateStart = value;
|
||||
var pUpd = Task.Run(async () => await ReloadData());
|
||||
pUpd.Wait();
|
||||
}
|
||||
@@ -174,9 +175,6 @@ namespace GWMS.UI.Pages
|
||||
[Inject]
|
||||
protected IJSRuntime JSRuntime { get; set; }
|
||||
|
||||
[Inject]
|
||||
protected MessageService MessageService { get; set; }
|
||||
|
||||
[Inject]
|
||||
protected NavigationManager NavManager { get; set; }
|
||||
|
||||
@@ -241,7 +239,7 @@ namespace GWMS.UI.Pages
|
||||
private async Task ReloadData()
|
||||
{
|
||||
isLoading = true;
|
||||
SearchRecords = await DataService.OrdersGetFilt(MessageService.Order_Filter);
|
||||
SearchRecords = await DataService.OrdersGetFilt(AppMService.Order_Filter);
|
||||
ListRecords = SearchRecords.Skip(numRecord * (currPage - 1)).Take(numRecord).ToList();
|
||||
isLoading = false;
|
||||
}
|
||||
@@ -252,7 +250,9 @@ namespace GWMS.UI.Pages
|
||||
|
||||
protected void Edit(OrderModel selRecord)
|
||||
{
|
||||
currRecord = selRecord;
|
||||
// rileggo dal DB il record corrente...
|
||||
var pUpd = Task.Run(async () => currRecord = await DataService.OrderGetByCode(selRecord.OrderCode));
|
||||
pUpd.Wait();
|
||||
}
|
||||
|
||||
protected void ForceReload(int newNum)
|
||||
@@ -267,19 +267,21 @@ namespace GWMS.UI.Pages
|
||||
|
||||
protected override async Task OnInitializedAsync()
|
||||
{
|
||||
MessageService.ShowSearch = false;
|
||||
MessageService.PageName = "Fornitore";
|
||||
MessageService.PageIcon = "fas fa-industry pr-2";
|
||||
MessageService.EA_SearchUpdated += OnSeachUpdated;
|
||||
DataService.ResetController();
|
||||
AppMService.ShowSearch = false;
|
||||
AppMService.PageName = "Fornitore";
|
||||
AppMService.PageIcon = "fas fa-industry pr-2";
|
||||
AppMService.EA_SearchUpdated += OnSeachUpdated;
|
||||
await ReloadAllData();
|
||||
}
|
||||
|
||||
protected async Task ReloadAllData()
|
||||
{
|
||||
isLoading = true;
|
||||
PlantsList = await DataService.PlantsGetAll();
|
||||
SelSupplierId = 0;
|
||||
SuppliersList = null;
|
||||
await GetClaimsData();
|
||||
PlantsList = await DataService.PlantsGetAll();
|
||||
// se ho un plantId valido --> altrimenti non abilitato
|
||||
if (ClaimSupplierId == 0)
|
||||
{
|
||||
@@ -310,7 +312,7 @@ namespace GWMS.UI.Pages
|
||||
currRecord = null;
|
||||
SearchRecords = null;
|
||||
ListRecords = null;
|
||||
MessageService.Order_Filter = SelectOrderData.Init(5, 7);
|
||||
AppMService.Order_Filter = SelectOrderData.Init(5, 7);
|
||||
await ReloadAllData();
|
||||
}
|
||||
|
||||
@@ -323,6 +325,7 @@ namespace GWMS.UI.Pages
|
||||
protected async Task UpdateData()
|
||||
{
|
||||
currRecord = null;
|
||||
DataService.ResetController();
|
||||
await ReloadData();
|
||||
}
|
||||
|
||||
@@ -347,7 +350,7 @@ namespace GWMS.UI.Pages
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
MessageService.EA_SearchUpdated -= OnSeachUpdated;
|
||||
AppMService.EA_SearchUpdated -= OnSeachUpdated;
|
||||
}
|
||||
|
||||
public async void OnSeachUpdated()
|
||||
|
||||
@@ -22,7 +22,6 @@ namespace GWMS.UI.Pages
|
||||
private List<OrderModel> ListRecords;
|
||||
private List<PlantDTO> PlantsList;
|
||||
private List<OrderModel> SearchRecords;
|
||||
|
||||
private List<TransporterModel> TransportersList;
|
||||
|
||||
#endregion Private Fields
|
||||
@@ -100,18 +99,18 @@ namespace GWMS.UI.Pages
|
||||
get
|
||||
{
|
||||
int answ = 0;
|
||||
if (MessageService.Order_Filter != null)
|
||||
if (AppMService.Order_Filter != null)
|
||||
{
|
||||
answ = MessageService.Order_Filter.PlantId;
|
||||
answ = AppMService.Order_Filter.PlantId;
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (!MessageService.Order_Filter.PlantId.Equals(value))
|
||||
if (!AppMService.Order_Filter.PlantId.Equals(value))
|
||||
{
|
||||
currRecord = null;
|
||||
MessageService.Order_Filter.PlantId = value;
|
||||
AppMService.Order_Filter.PlantId = value;
|
||||
var pUpd = Task.Run(async () => await ReloadData());
|
||||
pUpd.Wait();
|
||||
}
|
||||
@@ -123,18 +122,18 @@ namespace GWMS.UI.Pages
|
||||
get
|
||||
{
|
||||
int answ = 0;
|
||||
if (MessageService.Order_Filter != null)
|
||||
if (AppMService.Order_Filter != null)
|
||||
{
|
||||
answ = MessageService.Order_Filter.TransporterId;
|
||||
answ = AppMService.Order_Filter.TransporterId;
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (!MessageService.Order_Filter.TransporterId.Equals(value))
|
||||
if (!AppMService.Order_Filter.TransporterId.Equals(value))
|
||||
{
|
||||
currRecord = null;
|
||||
MessageService.Order_Filter.TransporterId = value;
|
||||
AppMService.Order_Filter.TransporterId = value;
|
||||
var pUpd = Task.Run(async () => await ReloadData());
|
||||
pUpd.Wait();
|
||||
}
|
||||
@@ -145,6 +144,9 @@ namespace GWMS.UI.Pages
|
||||
|
||||
#region Protected Properties
|
||||
|
||||
[Inject]
|
||||
protected MessageService AppMService { get; set; }
|
||||
|
||||
[Inject]
|
||||
protected AuthenticationStateProvider AuthenticationStateProvider { get; set; }
|
||||
|
||||
@@ -156,17 +158,17 @@ namespace GWMS.UI.Pages
|
||||
get
|
||||
{
|
||||
DateTime answ = DateTime.Today.AddDays(1);
|
||||
if (MessageService.Order_Filter != null)
|
||||
if (AppMService.Order_Filter != null)
|
||||
{
|
||||
answ = MessageService.Order_Filter.DateEnd;
|
||||
answ = AppMService.Order_Filter.DateEnd;
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (!MessageService.Order_Filter.DateEnd.Equals(value))
|
||||
if (!AppMService.Order_Filter.DateEnd.Equals(value))
|
||||
{
|
||||
MessageService.Order_Filter.DateEnd = value;
|
||||
AppMService.Order_Filter.DateEnd = value;
|
||||
var pUpd = Task.Run(async () => await ReloadData());
|
||||
pUpd.Wait();
|
||||
}
|
||||
@@ -178,17 +180,17 @@ namespace GWMS.UI.Pages
|
||||
get
|
||||
{
|
||||
DateTime answ = DateTime.Today.AddDays(-1);
|
||||
if (MessageService.Order_Filter != null)
|
||||
if (AppMService.Order_Filter != null)
|
||||
{
|
||||
answ = MessageService.Order_Filter.DateStart;
|
||||
answ = AppMService.Order_Filter.DateStart;
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (!MessageService.Order_Filter.DateStart.Equals(value))
|
||||
if (!AppMService.Order_Filter.DateStart.Equals(value))
|
||||
{
|
||||
MessageService.Order_Filter.DateStart = value;
|
||||
AppMService.Order_Filter.DateStart = value;
|
||||
var pUpd = Task.Run(async () => await ReloadData());
|
||||
pUpd.Wait();
|
||||
}
|
||||
@@ -198,9 +200,6 @@ namespace GWMS.UI.Pages
|
||||
[Inject]
|
||||
protected IJSRuntime JSRuntime { get; set; }
|
||||
|
||||
[Inject]
|
||||
protected MessageService MessageService { get; set; }
|
||||
|
||||
[Inject]
|
||||
protected NavigationManager NavManager { get; set; }
|
||||
|
||||
@@ -235,6 +234,7 @@ namespace GWMS.UI.Pages
|
||||
/// <returns></returns>
|
||||
private async Task GetClaimsData()
|
||||
{
|
||||
ClaimTransporterId = -1;
|
||||
// recupero auth
|
||||
var authState = await AuthenticationStateProvider.GetAuthenticationStateAsync();
|
||||
var user = authState.User;
|
||||
@@ -266,9 +266,8 @@ namespace GWMS.UI.Pages
|
||||
private async Task ReloadData()
|
||||
{
|
||||
isLoading = true;
|
||||
SearchRecords = await DataService.OrdersGetFilt(MessageService.Order_Filter);
|
||||
SearchRecords = await DataService.OrdersGetFilt(AppMService.Order_Filter);
|
||||
ListRecords = SearchRecords.Skip(numRecord * (currPage - 1)).Take(numRecord).ToList();
|
||||
//ListRecords = SearchRecords.Where(x => x.TransporterId == TransporterIdFilt).Skip(numRecord * (currPage - 1)).Take(numRecord).ToList();
|
||||
isLoading = false;
|
||||
}
|
||||
|
||||
@@ -278,7 +277,9 @@ namespace GWMS.UI.Pages
|
||||
|
||||
protected void Edit(OrderModel selRecord)
|
||||
{
|
||||
currRecord = selRecord;
|
||||
// rileggo dal DB il record corrente...
|
||||
var pUpd = Task.Run(async () => currRecord = await DataService.OrderGetByCode(selRecord.OrderCode));
|
||||
pUpd.Wait();
|
||||
}
|
||||
|
||||
protected void ForceReload(int newNum)
|
||||
@@ -293,12 +294,13 @@ namespace GWMS.UI.Pages
|
||||
|
||||
protected override async Task OnInitializedAsync()
|
||||
{
|
||||
DataService.ResetController();
|
||||
SelPlantId = 0;
|
||||
SelTranspId = 0;
|
||||
MessageService.ShowSearch = false;
|
||||
MessageService.PageName = "Fornitore";
|
||||
MessageService.PageIcon = "fas fa-industry pr-2";
|
||||
MessageService.EA_SearchUpdated += OnSeachUpdated;
|
||||
AppMService.ShowSearch = false;
|
||||
AppMService.PageName = "Fornitore";
|
||||
AppMService.PageIcon = "fas fa-industry pr-2";
|
||||
AppMService.EA_SearchUpdated += OnSeachUpdated;
|
||||
await ReloadAllData();
|
||||
}
|
||||
|
||||
@@ -306,6 +308,7 @@ namespace GWMS.UI.Pages
|
||||
{
|
||||
isLoading = true;
|
||||
PlantsList = await DataService.PlantsGetAll();
|
||||
SelTranspId = 0;
|
||||
TransportersList = null;
|
||||
await GetClaimsData();
|
||||
// se ho un plantId valido --> altrimenti non abilitato
|
||||
@@ -324,7 +327,6 @@ namespace GWMS.UI.Pages
|
||||
PlantsList = new List<PlantDTO>();
|
||||
}
|
||||
isLoading = false;
|
||||
|
||||
await ReloadData();
|
||||
}
|
||||
|
||||
@@ -339,7 +341,7 @@ namespace GWMS.UI.Pages
|
||||
currRecord = null;
|
||||
SearchRecords = null;
|
||||
ListRecords = null;
|
||||
MessageService.Order_Filter = SelectOrderData.Init(5, 7);
|
||||
AppMService.Order_Filter = SelectOrderData.Init(5, 7);
|
||||
await ReloadAllData();
|
||||
}
|
||||
|
||||
@@ -371,6 +373,7 @@ namespace GWMS.UI.Pages
|
||||
protected async Task UpdateData()
|
||||
{
|
||||
currRecord = null;
|
||||
DataService.ResetController();
|
||||
await ReloadData();
|
||||
}
|
||||
|
||||
@@ -395,7 +398,7 @@ namespace GWMS.UI.Pages
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
MessageService.EA_SearchUpdated -= OnSeachUpdated;
|
||||
AppMService.EA_SearchUpdated -= OnSeachUpdated;
|
||||
}
|
||||
|
||||
public async void OnSeachUpdated()
|
||||
|
||||
@@ -141,9 +141,18 @@
|
||||
</button>
|
||||
}
|
||||
</td>
|
||||
<td>@user.Identity.Id.Substring(0, 4)...</td>
|
||||
@*<td>@user.UserName</td>*@
|
||||
<td><span class="badge badge-pill @checkSem(user.Identity.EmailConfirmed)" title="Email validata"><span class="oi oi-check" aria-hidden="true"></span></span> @user.Identity.Email</td>
|
||||
<td>@user.Identity.Id.Substring(0, 8)...</td>
|
||||
<td>
|
||||
@if (user.Identity.EmailConfirmed)
|
||||
{
|
||||
<span class="badge badge-pill badge-success" title="Email validata"><span class="oi oi-check" aria-hidden="true"></span></span>
|
||||
}
|
||||
else
|
||||
{
|
||||
<span class="badge badge-pill badge-danger" title="Email NON ancora validata!"><span class="oi oi-check" aria-hidden="true"></span></span>
|
||||
}
|
||||
@user.Identity.Email
|
||||
</td>
|
||||
<td>
|
||||
@ShowRoles(user.Roles)
|
||||
</td>
|
||||
|
||||
@@ -452,11 +452,6 @@ namespace GWMS.UI.Pages
|
||||
|
||||
#region Public Methods
|
||||
|
||||
public string checkSem(bool valore)
|
||||
{
|
||||
return valore ? "badge-success" : "badge-danger";
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
AppMService.EA_SearchUpdated -= OnSeachUpdated;
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
@using GWMS.UI.Data
|
||||
@using GWMS.UI.Components
|
||||
|
||||
@inject MessageService MessageService
|
||||
@implements IDisposable
|
||||
|
||||
|
||||
@@ -94,6 +94,12 @@
|
||||
<span class="@hideText">Planner Consegne</span>
|
||||
</NavLink>
|
||||
</li>
|
||||
<li class="nav-item px-3" title="Setup Parametri">
|
||||
<NavLink class="nav-link" href="Parameters">
|
||||
<i class="fas fa-2x fa-wrench pr-2" aria-hidden="true"></i>
|
||||
<span class="@hideText">Setup Parametri</span>
|
||||
</NavLink>
|
||||
</li>
|
||||
<li class="nav-item px-3" title="Admin Utenti">
|
||||
<NavLink class="nav-link" href="UserAdmin">
|
||||
<i class="fas fa-2x fa-users pr-2" aria-hidden="true"></i>
|
||||
@@ -114,12 +120,6 @@
|
||||
<i class="fas fa-2x fa-calendar-alt pr-2" aria-hidden="true"></i>
|
||||
<span class="@hideText">Job Scheduler</span>
|
||||
</NavLink>
|
||||
</li>
|
||||
<li class="nav-item px-3" title="Setup Parametri">
|
||||
<NavLink class="nav-link" href="Parameters">
|
||||
<i class="fas fa-2x fa-wrench pr-2" aria-hidden="true"></i>
|
||||
<span class="@hideText">Setup Parametri</span>
|
||||
</NavLink>
|
||||
</li>*@
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<body>
|
||||
<i>GWMS - Gas Warehouse Management System</i>
|
||||
<h4>Versione: 1.0.2108.3012</h4>
|
||||
<h4>Versione: 1.0.2109.2218</h4>
|
||||
<br /> Note di rilascio:
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
@@ -1 +1 @@
|
||||
1.0.2108.3012
|
||||
1.0.2109.2218
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<item>
|
||||
<version>1.0.2108.3012</version>
|
||||
<version>1.0.2109.2218</version>
|
||||
<url>http://nexus.steamware.net/repository/SWS/GWMS/stable/0/GWMS.UI.zip</url>
|
||||
<changelog>http://nexus.steamware.net/repository/SWS/GWMS/stable/0/ChangeLog.html</changelog>
|
||||
<mandatory>false</mandatory>
|
||||
|
||||
Reference in New Issue
Block a user