CAN/LIN 导入和导出功能
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
using AutoMapper;
|
||||
using AutoMapper;
|
||||
using CapMachine.Core;
|
||||
using CapMachine.Model;
|
||||
using CapMachine.Model.CANLIN;
|
||||
@@ -152,12 +152,13 @@ namespace CapMachine.Wpf.ViewModels
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// CAN/LIN配置变更事件处理
|
||||
/// CAN/LIN 配置导入后刷新当前页面。
|
||||
/// </summary>
|
||||
/// <param name="msg"></param>
|
||||
/// <param name="msg">事件消息。</param>
|
||||
private void CanLinConfigChangedEventCall(string msg)
|
||||
{
|
||||
RefreshConfigList();
|
||||
InitLoadCanConfigPro();
|
||||
InitWriteRuleCbx();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -948,18 +949,12 @@ namespace CapMachine.Wpf.ViewModels
|
||||
/// <exception cref="NotImplementedException"></exception>
|
||||
private void SchEnableCmdCall(object par)
|
||||
{
|
||||
var dd = SelectedCANConfigExdDto.SchEnable;
|
||||
var Result = (bool)par;
|
||||
if (Result)
|
||||
if (SelectedCANConfigExdDto == null)
|
||||
{
|
||||
CanDriveService.ToomossCanDrive.SchEnable = true;
|
||||
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
CanDriveService.ToomossCanDrive.SchEnable = false;
|
||||
|
||||
}
|
||||
CanDriveService.ToomossCanDrive.SchEnable = SelectedCANConfigExdDto.SchEnable;
|
||||
}
|
||||
|
||||
|
||||
@@ -1362,22 +1357,22 @@ namespace CapMachine.Wpf.ViewModels
|
||||
{ "SelectCanLinConfigProId",SelectCanLinConfigPro.Id},
|
||||
|
||||
}, (par) =>
|
||||
{
|
||||
if (par.Result == ButtonResult.OK)
|
||||
{
|
||||
////程序名称
|
||||
ListCANScheduleConfigDto = par.Parameters.GetValue<ObservableCollection<CANScheduleConfigDto>>("ReturnValue");
|
||||
//把更新后的最新值给当前的主集合中
|
||||
SelectCanLinConfigPro.CanScheduleConfigs = Mapper.Map<List<CANScheduleConfig>>(ListCANScheduleConfigDto.ToList());
|
||||
{
|
||||
if (par.Result == ButtonResult.OK)
|
||||
{
|
||||
////程序名称
|
||||
ListCANScheduleConfigDto = par.Parameters.GetValue<ObservableCollection<CANScheduleConfigDto>>("ReturnValue");
|
||||
//把更新后的最新值给当前的主集合中
|
||||
SelectCanLinConfigPro.CanScheduleConfigs = Mapper.Map<List<CANScheduleConfig>>(ListCANScheduleConfigDto.ToList());
|
||||
|
||||
}
|
||||
else if (par.Result == ButtonResult.Cancel)
|
||||
{
|
||||
//取消
|
||||
}
|
||||
else if (par.Result == ButtonResult.Cancel)
|
||||
{
|
||||
//取消
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
});
|
||||
});
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user