using System; using System.ComponentModel.DataAnnotations; using System.Text.Json.Serialization; namespace Mirle.Component.API.ProgrammableLogicController.Models { /// /// 釋放維修門回報類別 /// public class TP033ReleaseRepairDoorReportDto : CommonMessage { /// /// 維修門編號 /// [Required, StringLength(9), JsonPropertyName("repair_door_id"), JsonPropertyOrder(101)] public string RepairDoorID { get; set; } /// /// 維修門狀態 /// /// /// 0 = Open
/// 1 = Force Open
/// 2 = Close ///
[Required, JsonPropertyName("repair_door_status"), JsonPropertyOrder(102)] public RepairDoorStatus RepairDoorStatus { get; set; } /// /// 取得釋放維修門回報 /// /// 交易名稱 /// 軟體編號 /// 維修門編號 /// 維修門狀態 /// 釋放維修門回報 public static TP033ReleaseRepairDoorReportDto Get(TransactionName transName, string softwareID, string repairDoorID, RepairDoorStatus repairDoorStatus) { return new TP033ReleaseRepairDoorReportDto() { Timetick = DateTime.Now, TransactionName = transName.ToTransactionName(), SoftwareID = softwareID, RepairDoorID = repairDoorID, RepairDoorStatus = repairDoorStatus }; } } /// /// 釋放維修門回應類別 /// public class FP034ReleaseRepairDoorAckDto : CommonMessage { /// /// 維修門編號 /// [Required, StringLength(9), JsonPropertyName("repair_door_id"), JsonPropertyOrder(101)] public string RepairDoorID { get; set; } /// /// 回應代碼 /// /// /// 0 = OK
/// 1 = NG
///
[Required, JsonPropertyName("reply_code"), JsonPropertyOrder(102)] public ReplyCode ReplyCode { get; set; } } }