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 MP.INVE; using MP.INVE.Shared; using MP.INVE.Components; using MP.INVE.Data; using MP.Data.DatabaseModels; namespace MP.INVE.Components { public partial class ProcSuggestion { [Inject] private MiDataService MIService { get; set; } = null!; [Parameter] public string lastScan { get; set; } = null!; private string tipo { get; set; } = ""; public List? searchrecords; public AnagUdcModel? udc; protected override async Task OnParametersSetAsync() { await Task.Delay(1); searchrecords = MIService.ElencoUDC(); udc = searchrecords.Where(x => x.UDC == lastScan).FirstOrDefault(); if (udc != null) { if (udc.UDC.Contains("MFI")) { tipo = "FINITO"; } } } protected string reqArtMod = "disabilita"; protected string reqQtaMod = "disabilita"; protected void cssDisableArt() { reqArtMod = ""; } protected void cssDisableQta() { reqQtaMod = ""; } } }