public S7StructureAlarmsCreatorViewModel(PLCstructuresEnum structureType, PLCconnectionComboBoxModel plcConnectionModel, IRealmProvider realmProvider) { _realmProvider = realmProvider; _logger = NLog.LogManager.GetCurrentClassLogger(); PlcConnectionName = plcConnectionModel.ConnectionName; _plcConnectionID = plcConnectionModel.PLCconnectionID; _structureType = structureType; NameOfPLCstructure = ""; GetListOfActualProfiles(); GetListOfActualSMSgroups(); CreateListOfAvailableAlarms(); _logger.Info($"Window for creating alarms for standard PLC structure created. Structure: {structureType.ToString()}."); }
public DefaultS7AlarmHendlerViewModel(PLCconnectionComboBoxModel connectionData, bool windowMode, AlarmS7UImodel modifiedAlarmData, IRealmProvider realmProvider, IRuntimeData runtimeData) { _realmProvider = realmProvider; _runtimeData = runtimeData; _logger = NLog.LogManager.GetCurrentClassLogger(); //assign data of modified alarm _modifiedAlarmData = modifiedAlarmData; //assing window parameters _connectionData = connectionData; _windowMode = windowMode; //assign connection name ConnectionName = _connectionData.ConnectionName; //Assign data of modified alarm(in case of alarm modification) AssignWindowData(modifiedAlarmData); _logger.Info($"Default S7 alarm handler window created."); }