public JISEditForm() { InitializeComponent(); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_ExportReportId, new AA(Properties.Resources.NumsIsNotNull, this.TxtOrderId)); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_ProductId, new AA(Properties.Resources.Noproduct, this.TxtProduct)); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_InvoiceCusXOId, new AA("客戶訂單編號不能為空", this.TxtCustomersId)); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_CustomerId, new AA("客戶不能為空", this.NccCustomer)); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_Amount, new AA("訂單數量不能為空", this.SpinOrderAmount)); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_AmountTest, new AA("測試數量不能為空", this.SpinTestAmount)); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_EmployeeId, new AA(Properties.Resources.EmployeeNotNull, this.NccTestPerson)); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_ReportDate, new AA(Properties.Resources.DateNotNull, this.DateReportDate)); //this.invalidValueExceptions.Add(Model.PCExportReportANSI.PRO_AmountTest + "_ForInvoiceXoQuantity", new AA("測試數量未達標:測試數量≈訂單數量/500(不齊不足1)", this.SpinTestAmount)); //this.invalidValueExceptions.Add(Model.PCExportReportANSI.PRO_AmountTest + "_ForDetailsCount", new AA("測試數量未達標:測試數量詳細測試數量總和", this.SpinTestAmount)); this.NccCustomer.Choose = new Settings.BasicData.Customs.ChooseCustoms(); this.NccTestPerson.Choose = new Settings.BasicData.Employees.ChooseEmployee(); this.NccTestPerson2.Choose = new Settings.BasicData.Employees.ChooseEmployee(); this.NccTestPerson3.Choose = new Settings.BasicData.Employees.ChooseEmployee(); this.NccTestPerson4.Choose = new Settings.BasicData.Employees.ChooseEmployee(); this.newChooseContorlAuditEmp.Choose = new Settings.BasicData.Employees.ChooseEmployee(); this.bindingSourceUnit.DataSource = (new BL.ProductUnitManager()).Select();; this.action = "view"; var jiShuBiaoZhun = new BL.SettingManager().SelectByName("JISJiShuBiaoZhun"); jiShuBiaoZhun = jiShuBiaoZhun.OrderByDescending(j => j.IdNO).ToList(); foreach (var item in jiShuBiaoZhun) { comboBoxEdit1.Properties.Items.Add(item.SettingCurrentValue); } comboBoxEdit1.SelectedIndex = 0; }
public ANSI2015() { InitializeComponent(); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_ExportReportId, new AA(Properties.Resources.NumsIsNotNull, this.TxtOrderId)); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_ProductId, new AA(Properties.Resources.Noproduct, this.TxtProduct)); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_InvoiceCusXOId, new AA("客戶訂單編號不能為空", this.TxtCustomersId)); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_CustomerId, new AA("客戶不能為空", this.NccCustomer)); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_Amount, new AA("訂單數量不能為空", this.SpinOrderAmount)); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_AmountTest, new AA("測試數量不能為空", this.SpinTestAmount)); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_EmployeeId, new AA(Properties.Resources.EmployeeNotNull, this.NccTestPerson)); this.requireValueExceptions.Add(Model.PCExportReportANSI.PRO_ReportDate, new AA(Properties.Resources.DateNotNull, this.DateReportDate)); this.NccCustomer.Choose = new Settings.BasicData.Customs.ChooseCustoms(); this.NccTestPerson.Choose = new Settings.BasicData.Employees.ChooseEmployee(); this.NccTestPerson2.Choose = new Settings.BasicData.Employees.ChooseEmployee(); this.NccTestPerson3.Choose = new Settings.BasicData.Employees.ChooseEmployee(); this.NccTestPerson4.Choose = new Settings.BasicData.Employees.ChooseEmployee(); this.newChooseContorlAuditEmp.Choose = new Settings.BasicData.Employees.ChooseEmployee(); this.bindingSourceUnit.DataSource = UnitList = (new BL.ProductUnitManager()).Select(); this.action = "view"; var jiShuBiaoZhun = new BL.SettingManager().SelectByName("ANSI2015JiShuBiaoZhun"); jiShuBiaoZhun = jiShuBiaoZhun.OrderByDescending(j => j.IdNO).ToList(); foreach (var item in jiShuBiaoZhun) { comboBoxEdit1.Properties.Items.Add(item.SettingCurrentValue); } var signature = new BL.SettingManager().SelectByName("ALANSignature"); foreach (var item in jiShuBiaoZhun) { cob_Singnature.Properties.Items.Add(item.SettingCurrentValue); } cob_Singnature.SelectedIndex = 0; }