using System.ComponentModel; using System.ComponentModel.DataAnnotations.Schema; using System.Xml.Serialization; using YLErp.Modules.SuperviseReportModule.SAC.Common; using static YLErp.DBModels.Consts.ConsReport; namespace YLErp.Modules.SuperviseReportModule.SAC.Model { /// /// 履约保证书 /// [Table("A1008_PerformanceGuaranteeAgrmt")] public class PerformanceGuaranteeAgrmtModel : ReportBaseModel { /// /// 操作标识 /// 长度:1 /// 必填:是 /// 说明: /// [XmlIgnore] [SacDescription("OperationType", "操作标识", "1", true, "")] public OptFlagsEnum OperationType { get; set; } /// /// 主协议编号(双方约定) /// 长度:100 /// 必填:是 /// 说明: /// [CheckStringMaxLength(MaxLength = 100)] [DefaultValue("")] [SacDescription("MasterAgrmtNo", "主协议编号(双方约定)", "100", true, "")] public string MasterAgrmtNo { get; set; } /// /// 补充协议编号(双方约定) /// 长度:100 /// 必填:是 /// 说明: /// [CheckStringMaxLength(MaxLength = 100)] [DefaultValue("")] [SacDescription("SupAgrmtNo", "补充协议编号(双方约定)", "100", true, "")] public string SupAgrmtNo { get; set; } /// /// 履约担保协议编号 /// 长度:32 /// 必填:否 /// 说明:校验规则:补正时必填 /// [CheckConditionStringValue(ConditionName = nameof(OperationType), ConditionValue = "A", CheckHandleNameArr = new[] { "B" })] [CheckConditionStringNEQValue(ConditionName = nameof(OperationType), ConditionValue = "A", CheckHandleNameArr = new[] { "A" })] [CheckStringMaxLength(MaxLength = 32, CheckHandleName = "A")] [CheckStringMaxLength(MaxLength = 32, Required = false, CheckHandleName = "B")] [DefaultValue("")] [SacDescription("PerformanceGuaranteeAgrmtID", "履约担保协议编号", "32", false, "校验规则:补正时必填;")] public string PerformanceGuaranteeAgrmtID { get; set; } /// /// 履约担保协议(附件) /// 长度:100 /// 必填:是 /// 说明:校验规则:只支持PDF格式 /// [CheckStringMaxLength(MaxLength = 100)] [CheckStringEndsWith(EndsWithString = ".pdf")] [DefaultValue("")] [SacDescription("PerformanceGuaranteeAgrmt", "履约担保协议(附件)", "100", true, "校验规则:只支持PDF格式;")] public string PerformanceGuaranteeAgrmt { get; set; } /// /// 签署时间 /// 长度:10 /// 必填:是 /// 说明:校验规则:必须是yyyy-MM-dd /// [CheckStringLength(Length = 10)] [CheckStringIsDateTimeFormat(FormatString = "yyyy-MM-dd")] [DefaultValue("")] [SacDescription("SigningDate", "签署时间", "10", true, "校验规则:必须是YYYY-MM-DD;")] public string SigningDate { get; set; } } }