Files

47 lines
1.1 KiB
C#

using Microsoft.AspNetCore.Components;
using MP.Core.Objects;
using MP.Data.Services;
namespace MP_TAB3.Components
{
public partial class IobInfoMan
{
#region Public Properties
[Parameter]
public string idxMacch { get; set; } = "";
#endregion Public Properties
#region Protected Properties
protected IOB_data IobInfo { get; set; } = new IOB_data();
protected Dictionary<string, string> MachineData { get; set; } = new Dictionary<string, string>();
[Inject]
protected TabDataService TabSrv { get; set; } = null!;
#endregion Protected Properties
#region Protected Methods
protected override async Task OnParametersSetAsync()
{
IobInfo = await TabSrv.IobInfoAsync(idxMacch);
MachineData = TabSrv.MachIobConf(idxMacch);
}
public string MacIobConf(string kReq)
{
string answ = "-";
if (MachineData.ContainsKey(kReq))
{
answ = MachineData[kReq];
}
return answ;
}
#endregion Protected Methods
}
}