generated from Integry/Template_NetMauiBlazorHybrid
Valorizzato tipoAnag
This commit is contained in:
@@ -214,7 +214,8 @@
|
|||||||
@if (item.p.Type == AttachedDTO.TypeAttached.Position)
|
@if (item.p.Type == AttachedDTO.TypeAttached.Position)
|
||||||
{
|
{
|
||||||
<MudChip T="string" Icon="@Icons.Material.Rounded.LocationOn" Color="Color.Success"
|
<MudChip T="string" Icon="@Icons.Material.Rounded.LocationOn" Color="Color.Success"
|
||||||
OnClick="@(() => OpenPosition(item.p))" OnClose="@(() => OnRemoveAttached(item.index))">
|
OnClick="@(() => OpenPosition(item.p))"
|
||||||
|
OnClose="@(() => OnRemoveAttached(item.index))">
|
||||||
@item.p.Description
|
@item.p.Description
|
||||||
</MudChip>
|
</MudChip>
|
||||||
}
|
}
|
||||||
@@ -234,7 +235,8 @@
|
|||||||
{
|
{
|
||||||
foreach (var file in ActivityFileList)
|
foreach (var file in ActivityFileList)
|
||||||
{
|
{
|
||||||
<MudChip T="string" OnClick="@(() => OpenAttached(file.Id, file.FileName))" OnClose="@(() => DeleteAttach(file))" Color="Color.Default">
|
<MudChip T="string" OnClick="@(() => OpenAttached(file.Id, file.FileName))"
|
||||||
|
OnClose="@(() => DeleteAttach(file))" Color="Color.Default">
|
||||||
@file.FileName
|
@file.FileName
|
||||||
</MudChip>
|
</MudChip>
|
||||||
}
|
}
|
||||||
@@ -242,7 +244,7 @@
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
<MudProgressLinear Color="Color.Primary" Indeterminate="true" Class="my-7" />
|
<MudProgressLinear Color="Color.Primary" Indeterminate="true" Class="my-7"/>
|
||||||
}
|
}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -453,7 +455,7 @@
|
|||||||
{
|
{
|
||||||
IsLoading = true;
|
IsLoading = true;
|
||||||
await InvokeAsync(StateHasChanged);
|
await InvokeAsync(StateHasChanged);
|
||||||
|
|
||||||
SelectedComessa = ActivityModel.Commessa;
|
SelectedComessa = ActivityModel.Commessa;
|
||||||
|
|
||||||
Users = await ManageData.GetTable<StbUser>();
|
Users = await ManageData.GetTable<StbUser>();
|
||||||
@@ -576,6 +578,9 @@
|
|||||||
{
|
{
|
||||||
ActivityModel.CodAnag = parts[0];
|
ActivityModel.CodAnag = parts[0];
|
||||||
ActivityModel.Cliente = parts[1];
|
ActivityModel.Cliente = parts[1];
|
||||||
|
|
||||||
|
var isCliente = Clienti.FirstOrDefault(x => x.CodAnag != null && x.CodAnag.Equals(ActivityModel.CodAnag));
|
||||||
|
ActivityModel.TipoAnag = isCliente == null ? "P" : "C";
|
||||||
}
|
}
|
||||||
|
|
||||||
OnAfterChangeValue();
|
OnAfterChangeValue();
|
||||||
@@ -593,6 +598,7 @@
|
|||||||
if (com.CodAnag != null)
|
if (com.CodAnag != null)
|
||||||
{
|
{
|
||||||
ActivityModel.CodAnag = com.CodAnag;
|
ActivityModel.CodAnag = com.CodAnag;
|
||||||
|
ActivityModel.TipoAnag = com.TipoAnag;
|
||||||
ActivityModel.Cliente = Clienti
|
ActivityModel.Cliente = Clienti
|
||||||
.Where(x => x.CodAnag != null && x.CodAnag.Equals(com.CodAnag))
|
.Where(x => x.CodAnag != null && x.CodAnag.Equals(com.CodAnag))
|
||||||
.Select(x => x.RagSoc)
|
.Select(x => x.RagSoc)
|
||||||
@@ -605,6 +611,7 @@
|
|||||||
{
|
{
|
||||||
ActivityModel.CodAnag = null;
|
ActivityModel.CodAnag = null;
|
||||||
ActivityModel.Cliente = null;
|
ActivityModel.Cliente = null;
|
||||||
|
ActivityModel.TipoAnag = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -613,6 +620,7 @@
|
|||||||
ActivityModel.Commessa = null;
|
ActivityModel.Commessa = null;
|
||||||
ActivityModel.CodAnag = null;
|
ActivityModel.CodAnag = null;
|
||||||
ActivityModel.Cliente = null;
|
ActivityModel.Cliente = null;
|
||||||
|
ActivityModel.TipoAnag = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
OnAfterChangeValue();
|
OnAfterChangeValue();
|
||||||
@@ -786,7 +794,7 @@
|
|||||||
Snackbar.Add("Impossibile aprire il file", Severity.Error);
|
Snackbar.Add("Impossibile aprire il file", Severity.Error);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private async Task DeleteAttach(ActivityFileDto file)
|
private async Task DeleteAttach(ActivityFileDto file)
|
||||||
{
|
{
|
||||||
Snackbar.Clear();
|
Snackbar.Clear();
|
||||||
|
|||||||
Reference in New Issue
Block a user