From f0df60c18a70080592287dc8691b8afd32c7bfc0 Mon Sep 17 00:00:00 2001 From: yibo <361071264@qq.com> Date: Wed, 18 Oct 2017 18:23:09 +0800 Subject: [PATCH] add --- BO/BO.csproj | 1 + BO/BO/Bill/OrderDetail/HurryRecord.cs | 6 +- BO/BO/Bill/OrderDetail/SelectHurryList.cs | 23 ++ BO/Utils/AfterLoginUtil.cs | 16 +- BO/Utils/BillRpc/OrderDetailRpc.cs | 31 +- ButcherManageClient/Login.cs | 2 +- QualityAndOrder/HurryRecordView.Designer.cs | 40 ++- QualityAndOrder/HurryRecordView.cs | 6 +- QualityAndOrder/HurryRecordView.resx | 8 +- QualityAndOrder/QualityOrderForm.Designer.cs | 355 ++++++++----------- QualityAndOrder/QualityOrderForm.resx | 57 ++- QualityAndOrder/QualityOrderFormForTab2.cs | 2 +- QualityAndOrder/QualityOrderFormForTab3.cs | 47 +-- 13 files changed, 296 insertions(+), 298 deletions(-) create mode 100644 BO/BO/Bill/OrderDetail/SelectHurryList.cs diff --git a/BO/BO.csproj b/BO/BO.csproj index 217555b..562ca17 100644 --- a/BO/BO.csproj +++ b/BO/BO.csproj @@ -61,6 +61,7 @@ + diff --git a/BO/BO/Bill/OrderDetail/HurryRecord.cs b/BO/BO/Bill/OrderDetail/HurryRecord.cs index 4fadd36..f9686b5 100644 --- a/BO/BO/Bill/OrderDetail/HurryRecord.cs +++ b/BO/BO/Bill/OrderDetail/HurryRecord.cs @@ -10,11 +10,13 @@ namespace BO.BO.Bill { public long ID { get; set; } - public long FromOrderDetail_ID { get; set; } + public long WeightBill_ID { get; set; } + + public long? B3WeighBill_ID { get; set; } public string Supplier_Name { get; set; } - public long? B3WeighBill_ID { get; set; } + public string LiveColonyHouse_Name { get; set; } public int? Order { get; set; } diff --git a/BO/BO/Bill/OrderDetail/SelectHurryList.cs b/BO/BO/Bill/OrderDetail/SelectHurryList.cs new file mode 100644 index 0000000..cca9a53 --- /dev/null +++ b/BO/BO/Bill/OrderDetail/SelectHurryList.cs @@ -0,0 +1,23 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace BO.BO.Bill +{ + public class SelectHurryList + { + public long WeightBill_ID { get; set; } + + public long? B3WeighBill_ID { get; set; } + + public string Supplier_Name { get; set; } + + public string LiveColonyHouse_Name { get; set; } + + public int WeightNumber { get; set; } + + public int HurryNumber { get; set; } + } +} diff --git a/BO/Utils/AfterLoginUtil.cs b/BO/Utils/AfterLoginUtil.cs index a944f39..00b76e1 100644 --- a/BO/Utils/AfterLoginUtil.cs +++ b/BO/Utils/AfterLoginUtil.cs @@ -19,13 +19,13 @@ namespace BO.Utils public static class AfterLoginUtil { - // static List> roleToAssemblies = new List>(){new Tuple("排宰员",@"C:\BwpB3Project\src\B3ButcherManageClient\ButcherOrder\bin\Debug\ButcherOrder"), - //new Tuple("过磅员",@"C:\BwpB3Project\src\B3ButcherManageClient\ButcherWeight\bin\Debug\ButcherWeight"), - // new Tuple("验质员",@"C:\BwpB3Project\src\B3ButcherManageClient\QualityAndOrder\bin\Debug\QualityAndOrder"),new Tuple("定级员",@"C:\BwpB3Project\src\B3ButcherManageClient\WeighAndGrading\bin\Debug\WeighAndGrading"),new Tuple("窒晕员",@"C:\BwpB3Project\src\B3ButcherManageClient\OrderConfirm\bin\Debug\OrderConfirm")}; + static List> roleToAssemblies = new List>(){new Tuple("排宰员",@"C:\BwpB3Project\src\B3ButcherManageClient\ButcherOrder\bin\Debug\ButcherOrder"), + new Tuple("过磅员",@"C:\BwpB3Project\src\B3ButcherManageClient\ButcherWeight\bin\Debug\ButcherWeight"), + new Tuple("验质员",@"C:\BwpB3Project\src\B3ButcherManageClient\QualityAndOrder\bin\Debug\QualityAndOrder"),new Tuple("定级员",@"C:\BwpB3Project\src\B3ButcherManageClient\WeighAndGrading\bin\Debug\WeighAndGrading"),new Tuple("窒晕员",@"C:\BwpB3Project\src\B3ButcherManageClient\OrderConfirm\bin\Debug\OrderConfirm")}; - static List> roleToAssemblies = new List>(){new Tuple("排宰员",@"ButcherOrder"), - new Tuple("过磅员",@"ButcherWeight"), - new Tuple("验质员",@"QualityAndOrder"),new Tuple("定级员",@"WeighAndGrading"),new Tuple("窒晕员",@"OrderConfirm")}; + //static List> roleToAssemblies = new List>(){new Tuple("排宰员",@"ButcherOrder"), + //new Tuple("过磅员",@"ButcherWeight"), + // new Tuple("验质员",@"QualityAndOrder"),new Tuple("定级员",@"WeighAndGrading"),new Tuple("窒晕员",@"OrderConfirm")}; public static Form CreateForm(string role) @@ -34,10 +34,10 @@ namespace BO.Utils if (first == null) throw new Exception("未注册的角色"); //#if debug - //var filePath = string.Format("{0}.dll", first.Item2); + var filePath = string.Format("{0}.dll", first.Item2); //#endif //#if !debug - var filePath = Path.Combine(Application.StartupPath, string.Format("{0}.dll", first.Item2)); + //var filePath = Path.Combine(Application.StartupPath, string.Format("{0}.dll", first.Item2)); //#endif if (!File.Exists(filePath)) throw new Exception("相关模块不存在"); diff --git a/BO/Utils/BillRpc/OrderDetailRpc.cs b/BO/Utils/BillRpc/OrderDetailRpc.cs index c70c2ba..b2aed38 100644 --- a/BO/Utils/BillRpc/OrderDetailRpc.cs +++ b/BO/Utils/BillRpc/OrderDetailRpc.cs @@ -39,10 +39,10 @@ namespace BO.Utils.BillRpc return RpcFacade.Call(method, id); } - public static List GetOrderDetail(DateTime date,bool onlyNormal) + public static List GetOrderDetail(DateTime date) { const string method = "/MainSystem/B3ClientService/Rpcs/BillRpc/OrderDetailRpc/GetOrderDetail"; - var result = RpcFacade.Call(method, date, onlyNormal); + var result = RpcFacade.Call(method, date); result = result.ESerializeDateTime(); return serializer.Deserialize>(result); } @@ -73,37 +73,46 @@ namespace BO.Utils.BillRpc RpcFacade.Call(method, weightBillID, show); } - public static List GetHurryRecordList(long orderID) + public static List GetHurryRecordList(long weightBillID) { const string method = "/MainSystem/B3ClientService/Rpcs/BillRpc/OrderDetailRpc/GetHurryRecords"; - var result = RpcFacade.Call(method, orderID); + var result = RpcFacade.Call(method, weightBillID); result = result.ESerializeDateTime(); return serializer.Deserialize>(result); } - public static void DeleteHurryRecord(long id) + public static bool DeleteHurryRecord(long id) { const string method = "/MainSystem/B3ClientService/Rpcs/BillRpc/OrderDetailRpc/DeleteHurryRecord"; - RpcFacade.Call(method, id); + return RpcFacade.Call(method, id) == -1; } - public static HurryRecord InsertHurryRecord(OrderDetail entity) + public static HurryRecord InsertHurryRecord(SelectHurryList entity,out bool withError) { var detail = new HurryRecord(); detail.HurryNumber = entity.HurryNumber; detail.Time = DateTime.Now; - detail.FromOrderDetail_ID = entity.ID; + detail.WeightBill_ID = entity.WeightBill_ID; const string method = "/MainSystem/B3ClientService/Rpcs/BillRpc/OrderDetailRpc/InsertHurryRecord"; - detail.ID= RpcFacade.Call(method, serializer.Serialize(detail)); + var r = RpcFacade.Call(method, serializer.Serialize(detail)).Split(new char[] { '|' }); + withError = r[0] == "-1"; + detail.ID = long.Parse(r[1]); detail.Supplier_Name = entity.Supplier_Name; detail.B3WeighBill_ID = entity.B3WeighBill_ID; + detail.LiveColonyHouse_Name = entity.LiveColonyHouse_Name; return detail; } - public static int GetHurryRecordNumber(long fromOrderID) + public static int GetHurryRecordNumber(long weightBillId) { const string method = "/MainSystem/B3ClientService/Rpcs/BillRpc/OrderDetailRpc/GetHurryRecordNumber"; - return RpcFacade.Call(method, fromOrderID); + return RpcFacade.Call(method, weightBillId); + } + + public static List GetSelectHurryList() + { + const string method = "/MainSystem/B3ClientService/Rpcs/BillRpc/OrderDetailRpc/GetSelectHurryList"; + return serializer.Deserialize>(RpcFacade.Call(method)); } } } diff --git a/ButcherManageClient/Login.cs b/ButcherManageClient/Login.cs index 3773f78..b685b34 100644 --- a/ButcherManageClient/Login.cs +++ b/ButcherManageClient/Login.cs @@ -122,7 +122,7 @@ namespace ButcherManageClient private void Login_Load(object sender, EventArgs e) { - AutoUpdate(); + // AutoUpdate(); } } } diff --git a/QualityAndOrder/HurryRecordView.Designer.cs b/QualityAndOrder/HurryRecordView.Designer.cs index 22a7a65..050a764 100644 --- a/QualityAndOrder/HurryRecordView.Designer.cs +++ b/QualityAndOrder/HurryRecordView.Designer.cs @@ -37,7 +37,9 @@ this.closeBtn = new System.Windows.Forms.Button(); this.recordGridView = new BWP.WinFormControl.UDataGridView(); this.R_ID = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.R_FromOrderDetail_ID = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.R_WeightBill_ID_ID = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.R_Supplier_Name = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.R_LiveColonyHouse_Name = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.R_B3WeighBill_ID = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.R_Order = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.R_HurryNumber = new System.Windows.Forms.DataGridViewTextBoxColumn(); @@ -78,7 +80,9 @@ this.recordGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; this.recordGridView.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { this.R_ID, - this.R_FromOrderDetail_ID, + this.R_WeightBill_ID_ID, + this.R_Supplier_Name, + this.R_LiveColonyHouse_Name, this.R_B3WeighBill_ID, this.R_Order, this.R_HurryNumber, @@ -107,13 +111,29 @@ this.R_ID.ReadOnly = true; this.R_ID.Visible = false; // - // R_FromOrderDetail_ID + // R_WeightBill_ID_ID // - this.R_FromOrderDetail_ID.DataPropertyName = "FromOrderDetail_ID"; - this.R_FromOrderDetail_ID.HeaderText = "FromOrderDetail_ID"; - this.R_FromOrderDetail_ID.Name = "R_FromOrderDetail_ID"; - this.R_FromOrderDetail_ID.ReadOnly = true; - this.R_FromOrderDetail_ID.Visible = false; + this.R_WeightBill_ID_ID.DataPropertyName = "WeightBill_ID"; + this.R_WeightBill_ID_ID.HeaderText = "WeightBill_ID"; + this.R_WeightBill_ID_ID.Name = "R_WeightBill_ID_ID"; + this.R_WeightBill_ID_ID.ReadOnly = true; + this.R_WeightBill_ID_ID.Visible = false; + // + // R_Supplier_Name + // + this.R_Supplier_Name.DataPropertyName = "Supplier_Name"; + this.R_Supplier_Name.HeaderText = "Supplier_Name"; + this.R_Supplier_Name.Name = "R_Supplier_Name"; + this.R_Supplier_Name.ReadOnly = true; + this.R_Supplier_Name.Visible = false; + // + // R_LiveColonyHouse_Name + // + this.R_LiveColonyHouse_Name.DataPropertyName = "LiveColonyHouse_Name"; + this.R_LiveColonyHouse_Name.HeaderText = "LiveColonyHouse_Name"; + this.R_LiveColonyHouse_Name.Name = "R_LiveColonyHouse_Name"; + this.R_LiveColonyHouse_Name.ReadOnly = true; + this.R_LiveColonyHouse_Name.Visible = false; // // R_B3WeighBill_ID // @@ -195,7 +215,9 @@ private System.Windows.Forms.Button closeBtn; private BWP.WinFormControl.UDataGridView recordGridView; private System.Windows.Forms.DataGridViewTextBoxColumn R_ID; - private System.Windows.Forms.DataGridViewTextBoxColumn R_FromOrderDetail_ID; + private System.Windows.Forms.DataGridViewTextBoxColumn R_WeightBill_ID_ID; + private System.Windows.Forms.DataGridViewTextBoxColumn R_Supplier_Name; + private System.Windows.Forms.DataGridViewTextBoxColumn R_LiveColonyHouse_Name; private System.Windows.Forms.DataGridViewTextBoxColumn R_B3WeighBill_ID; private System.Windows.Forms.DataGridViewTextBoxColumn R_Order; private System.Windows.Forms.DataGridViewTextBoxColumn R_HurryNumber; diff --git a/QualityAndOrder/HurryRecordView.cs b/QualityAndOrder/HurryRecordView.cs index 9cd0205..ac7f425 100644 --- a/QualityAndOrder/HurryRecordView.cs +++ b/QualityAndOrder/HurryRecordView.cs @@ -1,5 +1,6 @@ using BO.BO.Bill; using BO.Utils.BillRpc; +using BWP.WinFormControl; using System; using System.Collections.Generic; using System.ComponentModel; @@ -37,12 +38,13 @@ namespace QualityAndOrder { if (e.RowIndex == -1) return; - if (e.ColumnIndex <= recordGridView.ColumnCount - 2) + if (e.ColumnIndex < recordGridView.ColumnCount - 2) return; var entity = recordGridView.CurrentRow.DataBoundItem as HurryRecord; if (e.ColumnIndex == recordGridView.ColumnCount - 2) { - OrderDetailRpc.DeleteHurryRecord(entity.ID); + if (OrderDetailRpc.DeleteHurryRecord(entity.ID)) + UMessageBox.Show("排宰顺序出现多条记录,请手动修改", "注意"); _result += entity.HurryNumber; mRecords.Remove(entity); if (!changed) diff --git a/QualityAndOrder/HurryRecordView.resx b/QualityAndOrder/HurryRecordView.resx index 21438fd..9ba420f 100644 --- a/QualityAndOrder/HurryRecordView.resx +++ b/QualityAndOrder/HurryRecordView.resx @@ -120,7 +120,13 @@ True - + + True + + + True + + True diff --git a/QualityAndOrder/QualityOrderForm.Designer.cs b/QualityAndOrder/QualityOrderForm.Designer.cs index 773c4a4..1db1c9e 100644 --- a/QualityAndOrder/QualityOrderForm.Designer.cs +++ b/QualityAndOrder/QualityOrderForm.Designer.cs @@ -28,27 +28,27 @@ /// private void InitializeComponent() { - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle27 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle28 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle29 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle30 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle31 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle32 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle33 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle34 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle38 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle35 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle36 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle37 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle39 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle40 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle42 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle41 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle22 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle23 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle26 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle24 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle25 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle5 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle6 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle7 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle8 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle12 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle9 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle10 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle11 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle13 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle14 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle16 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle15 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle17 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle18 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle21 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle19 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle20 = new System.Windows.Forms.DataGridViewCellStyle(); this.uTabControl1 = new BWP.WinFormControl.UTabControl(); this.tabPage1 = new System.Windows.Forms.TabPage(); this.vScrollBar1 = new System.Windows.Forms.VScrollBar(); @@ -131,26 +131,21 @@ this.tab2DateSelect = new BWP.WinFormControl.UDatePicker(); this.label4 = new System.Windows.Forms.Label(); this.tabPage5 = new System.Windows.Forms.TabPage(); + this.tb3CloseBtn = new System.Windows.Forms.Button(); this.vScrollBar4 = new System.Windows.Forms.VScrollBar(); this.tab3SearchBtn = new System.Windows.Forms.Button(); - this.tab3DateSelect = new BWP.WinFormControl.UDatePicker(); - this.label7 = new System.Windows.Forms.Label(); this.panel4 = new System.Windows.Forms.Panel(); this.tab3KeyPanel = new System.Windows.Forms.FlowLayoutPanel(); this.label8 = new System.Windows.Forms.Label(); this.orderGrid3 = new BWP.WinFormControl.UDataGridView(); - this.H_ID = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.H_WeightBill_ID = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.H_SecondarySplit = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.H_Order = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.H_B3WeighBill_ID = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.H_Supplier_Name = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.H_LiveColonyHouse_Name = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.H_PlanNumber = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.H_WeightNumber = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.H_HurryNumber = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.dataGridViewButtonColumn1 = new System.Windows.Forms.DataGridViewButtonColumn(); this.H_View = new System.Windows.Forms.DataGridViewButtonColumn(); - this.tb3CloseBtn = new System.Windows.Forms.Button(); this.uTabControl1.SuspendLayout(); this.tabPage1.SuspendLayout(); this.panel1.SuspendLayout(); @@ -255,17 +250,17 @@ this.sanctionGrid.AllowUserToDeleteRows = false; this.sanctionGrid.AllowUserToResizeColumns = false; this.sanctionGrid.AllowUserToResizeRows = false; - dataGridViewCellStyle27.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(235)))), ((int)(((byte)(235)))), ((int)(((byte)(235))))); - this.sanctionGrid.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle27; + dataGridViewCellStyle1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(235)))), ((int)(((byte)(235)))), ((int)(((byte)(235))))); + this.sanctionGrid.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle1; this.sanctionGrid.BackgroundColor = System.Drawing.Color.White; - dataGridViewCellStyle28.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; - dataGridViewCellStyle28.BackColor = System.Drawing.SystemColors.Control; - dataGridViewCellStyle28.Font = new System.Drawing.Font("宋体", 12F); - dataGridViewCellStyle28.ForeColor = System.Drawing.SystemColors.WindowText; - dataGridViewCellStyle28.SelectionBackColor = System.Drawing.SystemColors.Highlight; - dataGridViewCellStyle28.SelectionForeColor = System.Drawing.SystemColors.HighlightText; - dataGridViewCellStyle28.WrapMode = System.Windows.Forms.DataGridViewTriState.True; - this.sanctionGrid.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle28; + dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; + dataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Control; + dataGridViewCellStyle2.Font = new System.Drawing.Font("宋体", 12F); + dataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.WindowText; + dataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight; + dataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText; + dataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.True; + this.sanctionGrid.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle2; this.sanctionGrid.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; this.sanctionGrid.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { this.S_AbnormalItem_Name1, @@ -286,9 +281,9 @@ this.sanctionGrid.Name = "sanctionGrid"; this.sanctionGrid.ReadOnly = true; this.sanctionGrid.RowHeadersVisible = false; - dataGridViewCellStyle29.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - dataGridViewCellStyle29.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(66)))), ((int)(((byte)(163)))), ((int)(((byte)(218))))); - this.sanctionGrid.RowsDefaultCellStyle = dataGridViewCellStyle29; + dataGridViewCellStyle3.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + dataGridViewCellStyle3.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(66)))), ((int)(((byte)(163)))), ((int)(((byte)(218))))); + this.sanctionGrid.RowsDefaultCellStyle = dataGridViewCellStyle3; this.sanctionGrid.RowTemplate.DefaultCellStyle.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.sanctionGrid.RowTemplate.Height = 50; this.sanctionGrid.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.CellSelect; @@ -497,17 +492,17 @@ this.weightBillGrid.AllowUserToDeleteRows = false; this.weightBillGrid.AllowUserToResizeColumns = false; this.weightBillGrid.AllowUserToResizeRows = false; - dataGridViewCellStyle30.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(235)))), ((int)(((byte)(235)))), ((int)(((byte)(235))))); - this.weightBillGrid.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle30; + dataGridViewCellStyle4.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(235)))), ((int)(((byte)(235)))), ((int)(((byte)(235))))); + this.weightBillGrid.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle4; this.weightBillGrid.BackgroundColor = System.Drawing.Color.White; - dataGridViewCellStyle31.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; - dataGridViewCellStyle31.BackColor = System.Drawing.SystemColors.Control; - dataGridViewCellStyle31.Font = new System.Drawing.Font("宋体", 12F); - dataGridViewCellStyle31.ForeColor = System.Drawing.SystemColors.WindowText; - dataGridViewCellStyle31.SelectionBackColor = System.Drawing.SystemColors.Highlight; - dataGridViewCellStyle31.SelectionForeColor = System.Drawing.SystemColors.HighlightText; - dataGridViewCellStyle31.WrapMode = System.Windows.Forms.DataGridViewTriState.True; - this.weightBillGrid.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle31; + dataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; + dataGridViewCellStyle5.BackColor = System.Drawing.SystemColors.Control; + dataGridViewCellStyle5.Font = new System.Drawing.Font("宋体", 12F); + dataGridViewCellStyle5.ForeColor = System.Drawing.SystemColors.WindowText; + dataGridViewCellStyle5.SelectionBackColor = System.Drawing.SystemColors.Highlight; + dataGridViewCellStyle5.SelectionForeColor = System.Drawing.SystemColors.HighlightText; + dataGridViewCellStyle5.WrapMode = System.Windows.Forms.DataGridViewTriState.True; + this.weightBillGrid.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle5; this.weightBillGrid.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; this.weightBillGrid.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { this.W_ID, @@ -522,11 +517,11 @@ this.weightBillGrid.Name = "weightBillGrid"; this.weightBillGrid.ReadOnly = true; this.weightBillGrid.RowHeadersVisible = false; - dataGridViewCellStyle32.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - dataGridViewCellStyle32.ForeColor = System.Drawing.Color.Black; - dataGridViewCellStyle32.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(66)))), ((int)(((byte)(163)))), ((int)(((byte)(218))))); - dataGridViewCellStyle32.SelectionForeColor = System.Drawing.Color.Black; - this.weightBillGrid.RowsDefaultCellStyle = dataGridViewCellStyle32; + dataGridViewCellStyle6.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + dataGridViewCellStyle6.ForeColor = System.Drawing.Color.Black; + dataGridViewCellStyle6.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(66)))), ((int)(((byte)(163)))), ((int)(((byte)(218))))); + dataGridViewCellStyle6.SelectionForeColor = System.Drawing.Color.Black; + this.weightBillGrid.RowsDefaultCellStyle = dataGridViewCellStyle6; this.weightBillGrid.RowTemplate.Height = 40; this.weightBillGrid.ScrollBars = System.Windows.Forms.ScrollBars.None; this.weightBillGrid.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect; @@ -802,17 +797,17 @@ this.preOrderGrid.AllowUserToDeleteRows = false; this.preOrderGrid.AllowUserToResizeColumns = false; this.preOrderGrid.AllowUserToResizeRows = false; - dataGridViewCellStyle33.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(235)))), ((int)(((byte)(235)))), ((int)(((byte)(235))))); - this.preOrderGrid.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle33; + dataGridViewCellStyle7.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(235)))), ((int)(((byte)(235)))), ((int)(((byte)(235))))); + this.preOrderGrid.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle7; this.preOrderGrid.BackgroundColor = System.Drawing.Color.White; - dataGridViewCellStyle34.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; - dataGridViewCellStyle34.BackColor = System.Drawing.SystemColors.Control; - dataGridViewCellStyle34.Font = new System.Drawing.Font("宋体", 12F); - dataGridViewCellStyle34.ForeColor = System.Drawing.SystemColors.WindowText; - dataGridViewCellStyle34.SelectionBackColor = System.Drawing.SystemColors.Highlight; - dataGridViewCellStyle34.SelectionForeColor = System.Drawing.SystemColors.HighlightText; - dataGridViewCellStyle34.WrapMode = System.Windows.Forms.DataGridViewTriState.True; - this.preOrderGrid.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle34; + dataGridViewCellStyle8.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; + dataGridViewCellStyle8.BackColor = System.Drawing.SystemColors.Control; + dataGridViewCellStyle8.Font = new System.Drawing.Font("宋体", 12F); + dataGridViewCellStyle8.ForeColor = System.Drawing.SystemColors.WindowText; + dataGridViewCellStyle8.SelectionBackColor = System.Drawing.SystemColors.Highlight; + dataGridViewCellStyle8.SelectionForeColor = System.Drawing.SystemColors.HighlightText; + dataGridViewCellStyle8.WrapMode = System.Windows.Forms.DataGridViewTriState.True; + this.preOrderGrid.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle8; this.preOrderGrid.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; this.preOrderGrid.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { this.P_WeightBill_ID, @@ -831,11 +826,11 @@ this.preOrderGrid.Name = "preOrderGrid"; this.preOrderGrid.ReadOnly = true; this.preOrderGrid.RowHeadersVisible = false; - dataGridViewCellStyle38.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - dataGridViewCellStyle38.ForeColor = System.Drawing.Color.Black; - dataGridViewCellStyle38.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(66)))), ((int)(((byte)(163)))), ((int)(((byte)(218))))); - dataGridViewCellStyle38.SelectionForeColor = System.Drawing.Color.Black; - this.preOrderGrid.RowsDefaultCellStyle = dataGridViewCellStyle38; + dataGridViewCellStyle12.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + dataGridViewCellStyle12.ForeColor = System.Drawing.Color.Black; + dataGridViewCellStyle12.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(66)))), ((int)(((byte)(163)))), ((int)(((byte)(218))))); + dataGridViewCellStyle12.SelectionForeColor = System.Drawing.Color.Black; + this.preOrderGrid.RowsDefaultCellStyle = dataGridViewCellStyle12; this.preOrderGrid.RowTemplate.Height = 60; this.preOrderGrid.ScrollBars = System.Windows.Forms.ScrollBars.None; this.preOrderGrid.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect; @@ -911,9 +906,9 @@ // P_WeighTime // this.P_WeighTime.DataPropertyName = "WeighTime"; - dataGridViewCellStyle35.Format = "MM/dd HH:mm"; - dataGridViewCellStyle35.NullValue = null; - this.P_WeighTime.DefaultCellStyle = dataGridViewCellStyle35; + dataGridViewCellStyle9.Format = "MM/dd HH:mm"; + dataGridViewCellStyle9.NullValue = null; + this.P_WeighTime.DefaultCellStyle = dataGridViewCellStyle9; this.P_WeighTime.HeaderText = "过磅时间"; this.P_WeighTime.Name = "P_WeighTime"; this.P_WeighTime.ReadOnly = true; @@ -921,9 +916,9 @@ // // P_OKBtn // - dataGridViewCellStyle36.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; - dataGridViewCellStyle36.Padding = new System.Windows.Forms.Padding(7, 10, 7, 10); - this.P_OKBtn.DefaultCellStyle = dataGridViewCellStyle36; + dataGridViewCellStyle10.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; + dataGridViewCellStyle10.Padding = new System.Windows.Forms.Padding(7, 10, 7, 10); + this.P_OKBtn.DefaultCellStyle = dataGridViewCellStyle10; this.P_OKBtn.HeaderText = "排宰"; this.P_OKBtn.Name = "P_OKBtn"; this.P_OKBtn.ReadOnly = true; @@ -935,9 +930,9 @@ // // P_Hidden // - dataGridViewCellStyle37.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; - dataGridViewCellStyle37.Padding = new System.Windows.Forms.Padding(7, 10, 7, 10); - this.P_Hidden.DefaultCellStyle = dataGridViewCellStyle37; + dataGridViewCellStyle11.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; + dataGridViewCellStyle11.Padding = new System.Windows.Forms.Padding(7, 10, 7, 10); + this.P_Hidden.DefaultCellStyle = dataGridViewCellStyle11; this.P_Hidden.HeaderText = "隐藏"; this.P_Hidden.Name = "P_Hidden"; this.P_Hidden.ReadOnly = true; @@ -950,17 +945,17 @@ this.orderGrid.AllowUserToDeleteRows = false; this.orderGrid.AllowUserToResizeColumns = false; this.orderGrid.AllowUserToResizeRows = false; - dataGridViewCellStyle39.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(235)))), ((int)(((byte)(235)))), ((int)(((byte)(235))))); - this.orderGrid.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle39; + dataGridViewCellStyle13.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(235)))), ((int)(((byte)(235)))), ((int)(((byte)(235))))); + this.orderGrid.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle13; this.orderGrid.BackgroundColor = System.Drawing.Color.White; - dataGridViewCellStyle40.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; - dataGridViewCellStyle40.BackColor = System.Drawing.SystemColors.Control; - dataGridViewCellStyle40.Font = new System.Drawing.Font("宋体", 12F); - dataGridViewCellStyle40.ForeColor = System.Drawing.SystemColors.WindowText; - dataGridViewCellStyle40.SelectionBackColor = System.Drawing.SystemColors.Highlight; - dataGridViewCellStyle40.SelectionForeColor = System.Drawing.SystemColors.HighlightText; - dataGridViewCellStyle40.WrapMode = System.Windows.Forms.DataGridViewTriState.True; - this.orderGrid.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle40; + dataGridViewCellStyle14.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; + dataGridViewCellStyle14.BackColor = System.Drawing.SystemColors.Control; + dataGridViewCellStyle14.Font = new System.Drawing.Font("宋体", 12F); + dataGridViewCellStyle14.ForeColor = System.Drawing.SystemColors.WindowText; + dataGridViewCellStyle14.SelectionBackColor = System.Drawing.SystemColors.Highlight; + dataGridViewCellStyle14.SelectionForeColor = System.Drawing.SystemColors.HighlightText; + dataGridViewCellStyle14.WrapMode = System.Windows.Forms.DataGridViewTriState.True; + this.orderGrid.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle14; this.orderGrid.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; this.orderGrid.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { this.O_ID, @@ -978,11 +973,11 @@ this.orderGrid.Name = "orderGrid"; this.orderGrid.ReadOnly = true; this.orderGrid.RowHeadersVisible = false; - dataGridViewCellStyle42.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - dataGridViewCellStyle42.ForeColor = System.Drawing.Color.Black; - dataGridViewCellStyle42.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(66)))), ((int)(((byte)(163)))), ((int)(((byte)(218))))); - dataGridViewCellStyle42.SelectionForeColor = System.Drawing.Color.Black; - this.orderGrid.RowsDefaultCellStyle = dataGridViewCellStyle42; + dataGridViewCellStyle16.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + dataGridViewCellStyle16.ForeColor = System.Drawing.Color.Black; + dataGridViewCellStyle16.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(66)))), ((int)(((byte)(163)))), ((int)(((byte)(218))))); + dataGridViewCellStyle16.SelectionForeColor = System.Drawing.Color.Black; + this.orderGrid.RowsDefaultCellStyle = dataGridViewCellStyle16; this.orderGrid.RowTemplate.Height = 60; this.orderGrid.ScrollBars = System.Windows.Forms.ScrollBars.None; this.orderGrid.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect; @@ -1064,9 +1059,9 @@ // // O_OKBtn // - dataGridViewCellStyle41.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; - dataGridViewCellStyle41.Padding = new System.Windows.Forms.Padding(7, 10, 7, 10); - this.O_OKBtn.DefaultCellStyle = dataGridViewCellStyle41; + dataGridViewCellStyle15.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; + dataGridViewCellStyle15.Padding = new System.Windows.Forms.Padding(7, 10, 7, 10); + this.O_OKBtn.DefaultCellStyle = dataGridViewCellStyle15; this.O_OKBtn.HeaderText = "确定"; this.O_OKBtn.Name = "O_OKBtn"; this.O_OKBtn.ReadOnly = true; @@ -1114,8 +1109,6 @@ this.tabPage5.Controls.Add(this.tb3CloseBtn); this.tabPage5.Controls.Add(this.vScrollBar4); this.tabPage5.Controls.Add(this.tab3SearchBtn); - this.tabPage5.Controls.Add(this.tab3DateSelect); - this.tabPage5.Controls.Add(this.label7); this.tabPage5.Controls.Add(this.panel4); this.tabPage5.Controls.Add(this.label8); this.tabPage5.Controls.Add(this.orderGrid3); @@ -1127,6 +1120,17 @@ this.tabPage5.Text = "急宰"; this.tabPage5.UseVisualStyleBackColor = true; // + // tb3CloseBtn + // + this.tb3CloseBtn.Font = new System.Drawing.Font("宋体", 15F); + this.tb3CloseBtn.Location = new System.Drawing.Point(1254, 9); + this.tb3CloseBtn.Name = "tb3CloseBtn"; + this.tb3CloseBtn.Size = new System.Drawing.Size(94, 56); + this.tb3CloseBtn.TabIndex = 65; + this.tb3CloseBtn.Text = "关闭"; + this.tb3CloseBtn.UseVisualStyleBackColor = true; + this.tb3CloseBtn.Click += new System.EventHandler(this.closeBtn_Click); + // // vScrollBar4 // this.vScrollBar4.Location = new System.Drawing.Point(760, 93); @@ -1137,38 +1141,14 @@ // tab3SearchBtn // this.tab3SearchBtn.Font = new System.Drawing.Font("宋体", 15F); - this.tab3SearchBtn.Location = new System.Drawing.Point(277, 6); + this.tab3SearchBtn.Location = new System.Drawing.Point(25, 6); this.tab3SearchBtn.Name = "tab3SearchBtn"; - this.tab3SearchBtn.Size = new System.Drawing.Size(94, 56); + this.tab3SearchBtn.Size = new System.Drawing.Size(94, 38); this.tab3SearchBtn.TabIndex = 63; this.tab3SearchBtn.Text = "查询"; this.tab3SearchBtn.UseVisualStyleBackColor = true; this.tab3SearchBtn.Click += new System.EventHandler(this.tab3SearchBtn_Click); // - // tab3DateSelect - // - this.tab3DateSelect.BackColor = System.Drawing.Color.White; - this.tab3DateSelect.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; - this.tab3DateSelect.Date = new System.DateTime(2017, 9, 8, 0, 0, 0, 0); - this.tab3DateSelect.Font = new System.Drawing.Font("宋体", 15F); - this.tab3DateSelect.Location = new System.Drawing.Point(124, 16); - this.tab3DateSelect.Name = "tab3DateSelect"; - this.tab3DateSelect.Size = new System.Drawing.Size(135, 30); - this.tab3DateSelect.TabIndex = 62; - this.tab3DateSelect.Text = "2017/09/08"; - this.tab3DateSelect.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; - this.tab3DateSelect.Type = BWP.WinFormControl.DateTimeType.Date; - // - // label7 - // - this.label7.AutoSize = true; - this.label7.Font = new System.Drawing.Font("宋体", 14F); - this.label7.Location = new System.Drawing.Point(23, 22); - this.label7.Name = "label7"; - this.label7.Size = new System.Drawing.Size(104, 19); - this.label7.TabIndex = 61; - this.label7.Text = "宰杀日期:"; - // // panel4 // this.panel4.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; @@ -1195,7 +1175,7 @@ this.label8.Name = "label8"; this.label8.Size = new System.Drawing.Size(89, 20); this.label8.TabIndex = 59; - this.label8.Text = "排宰明细"; + this.label8.Text = "过磅记录"; // // orderGrid3 // @@ -1203,27 +1183,24 @@ this.orderGrid3.AllowUserToDeleteRows = false; this.orderGrid3.AllowUserToResizeColumns = false; this.orderGrid3.AllowUserToResizeRows = false; - dataGridViewCellStyle22.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(235)))), ((int)(((byte)(235)))), ((int)(((byte)(235))))); - this.orderGrid3.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle22; + dataGridViewCellStyle17.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(235)))), ((int)(((byte)(235)))), ((int)(((byte)(235))))); + this.orderGrid3.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle17; this.orderGrid3.BackgroundColor = System.Drawing.Color.White; - dataGridViewCellStyle23.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; - dataGridViewCellStyle23.BackColor = System.Drawing.SystemColors.Control; - dataGridViewCellStyle23.Font = new System.Drawing.Font("宋体", 12F); - dataGridViewCellStyle23.ForeColor = System.Drawing.SystemColors.WindowText; - dataGridViewCellStyle23.SelectionBackColor = System.Drawing.SystemColors.Highlight; - dataGridViewCellStyle23.SelectionForeColor = System.Drawing.SystemColors.HighlightText; - dataGridViewCellStyle23.WrapMode = System.Windows.Forms.DataGridViewTriState.True; - this.orderGrid3.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle23; + dataGridViewCellStyle18.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; + dataGridViewCellStyle18.BackColor = System.Drawing.SystemColors.Control; + dataGridViewCellStyle18.Font = new System.Drawing.Font("宋体", 12F); + dataGridViewCellStyle18.ForeColor = System.Drawing.SystemColors.WindowText; + dataGridViewCellStyle18.SelectionBackColor = System.Drawing.SystemColors.Highlight; + dataGridViewCellStyle18.SelectionForeColor = System.Drawing.SystemColors.HighlightText; + dataGridViewCellStyle18.WrapMode = System.Windows.Forms.DataGridViewTriState.True; + this.orderGrid3.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle18; this.orderGrid3.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; this.orderGrid3.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { - this.H_ID, this.H_WeightBill_ID, - this.H_SecondarySplit, - this.H_Order, this.H_B3WeighBill_ID, this.H_Supplier_Name, this.H_LiveColonyHouse_Name, - this.H_PlanNumber, + this.H_WeightNumber, this.H_HurryNumber, this.dataGridViewButtonColumn1, this.H_View}); @@ -1232,11 +1209,11 @@ this.orderGrid3.Name = "orderGrid3"; this.orderGrid3.ReadOnly = true; this.orderGrid3.RowHeadersVisible = false; - dataGridViewCellStyle26.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - dataGridViewCellStyle26.ForeColor = System.Drawing.Color.Black; - dataGridViewCellStyle26.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(66)))), ((int)(((byte)(163)))), ((int)(((byte)(218))))); - dataGridViewCellStyle26.SelectionForeColor = System.Drawing.Color.Black; - this.orderGrid3.RowsDefaultCellStyle = dataGridViewCellStyle26; + dataGridViewCellStyle21.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + dataGridViewCellStyle21.ForeColor = System.Drawing.Color.Black; + dataGridViewCellStyle21.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(66)))), ((int)(((byte)(163)))), ((int)(((byte)(218))))); + dataGridViewCellStyle21.SelectionForeColor = System.Drawing.Color.Black; + this.orderGrid3.RowsDefaultCellStyle = dataGridViewCellStyle21; this.orderGrid3.RowTemplate.Height = 60; this.orderGrid3.ScrollBars = System.Windows.Forms.ScrollBars.None; this.orderGrid3.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect; @@ -1245,14 +1222,6 @@ this.orderGrid3.CellClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.orderGrid3_CellClick); this.orderGrid3.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.orderGrid3_CellContentClick); // - // H_ID - // - this.H_ID.DataPropertyName = "ID"; - this.H_ID.HeaderText = "ID"; - this.H_ID.Name = "H_ID"; - this.H_ID.ReadOnly = true; - this.H_ID.Visible = false; - // // H_WeightBill_ID // this.H_WeightBill_ID.DataPropertyName = "WeightBill_ID"; @@ -1261,29 +1230,13 @@ this.H_WeightBill_ID.ReadOnly = true; this.H_WeightBill_ID.Visible = false; // - // H_SecondarySplit - // - this.H_SecondarySplit.DataPropertyName = "SecondarySplit"; - this.H_SecondarySplit.HeaderText = "SecondarySplit"; - this.H_SecondarySplit.Name = "H_SecondarySplit"; - this.H_SecondarySplit.ReadOnly = true; - this.H_SecondarySplit.Visible = false; - // - // H_Order - // - this.H_Order.DataPropertyName = "Order"; - this.H_Order.HeaderText = "序号"; - this.H_Order.Name = "H_Order"; - this.H_Order.ReadOnly = true; - this.H_Order.Width = 70; - // // H_B3WeighBill_ID // this.H_B3WeighBill_ID.DataPropertyName = "B3WeighBill_ID"; this.H_B3WeighBill_ID.HeaderText = "磅单号"; this.H_B3WeighBill_ID.Name = "H_B3WeighBill_ID"; this.H_B3WeighBill_ID.ReadOnly = true; - this.H_B3WeighBill_ID.Width = 80; + this.H_B3WeighBill_ID.Width = 90; // // H_Supplier_Name // @@ -1291,6 +1244,7 @@ this.H_Supplier_Name.HeaderText = "供应商"; this.H_Supplier_Name.Name = "H_Supplier_Name"; this.H_Supplier_Name.ReadOnly = true; + this.H_Supplier_Name.Width = 110; // // H_LiveColonyHouse_Name // @@ -1298,14 +1252,15 @@ this.H_LiveColonyHouse_Name.HeaderText = "圈舍"; this.H_LiveColonyHouse_Name.Name = "H_LiveColonyHouse_Name"; this.H_LiveColonyHouse_Name.ReadOnly = true; + this.H_LiveColonyHouse_Name.Width = 130; // - // H_PlanNumber + // H_WeightNumber // - this.H_PlanNumber.DataPropertyName = "PlanNumber"; - this.H_PlanNumber.HeaderText = "头数"; - this.H_PlanNumber.Name = "H_PlanNumber"; - this.H_PlanNumber.ReadOnly = true; - this.H_PlanNumber.Width = 80; + this.H_WeightNumber.DataPropertyName = "WeightNumber"; + this.H_WeightNumber.HeaderText = "头数"; + this.H_WeightNumber.Name = "H_WeightNumber"; + this.H_WeightNumber.ReadOnly = true; + this.H_WeightNumber.Width = 90; // // H_HurryNumber // @@ -1313,13 +1268,13 @@ this.H_HurryNumber.HeaderText = "急宰"; this.H_HurryNumber.Name = "H_HurryNumber"; this.H_HurryNumber.ReadOnly = true; - this.H_HurryNumber.Width = 80; + this.H_HurryNumber.Width = 90; // // dataGridViewButtonColumn1 // - dataGridViewCellStyle24.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; - dataGridViewCellStyle24.Padding = new System.Windows.Forms.Padding(7, 10, 7, 10); - this.dataGridViewButtonColumn1.DefaultCellStyle = dataGridViewCellStyle24; + dataGridViewCellStyle19.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; + dataGridViewCellStyle19.Padding = new System.Windows.Forms.Padding(7, 10, 7, 10); + this.dataGridViewButtonColumn1.DefaultCellStyle = dataGridViewCellStyle19; this.dataGridViewButtonColumn1.HeaderText = "确定"; this.dataGridViewButtonColumn1.Name = "dataGridViewButtonColumn1"; this.dataGridViewButtonColumn1.ReadOnly = true; @@ -1329,9 +1284,9 @@ // // H_View // - dataGridViewCellStyle25.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; - dataGridViewCellStyle25.Padding = new System.Windows.Forms.Padding(7, 10, 7, 10); - this.H_View.DefaultCellStyle = dataGridViewCellStyle25; + dataGridViewCellStyle20.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; + dataGridViewCellStyle20.Padding = new System.Windows.Forms.Padding(7, 10, 7, 10); + this.H_View.DefaultCellStyle = dataGridViewCellStyle20; this.H_View.HeaderText = "查看"; this.H_View.Name = "H_View"; this.H_View.ReadOnly = true; @@ -1339,17 +1294,6 @@ this.H_View.UseColumnTextForButtonValue = true; this.H_View.Width = 110; // - // tb3CloseBtn - // - this.tb3CloseBtn.Font = new System.Drawing.Font("宋体", 15F); - this.tb3CloseBtn.Location = new System.Drawing.Point(1254, 9); - this.tb3CloseBtn.Name = "tb3CloseBtn"; - this.tb3CloseBtn.Size = new System.Drawing.Size(94, 56); - this.tb3CloseBtn.TabIndex = 65; - this.tb3CloseBtn.Text = "关闭"; - this.tb3CloseBtn.UseVisualStyleBackColor = true; - this.tb3CloseBtn.Click += new System.EventHandler(this.closeBtn_Click); - // // QualityOrderForm // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F); @@ -1461,23 +1405,10 @@ private System.Windows.Forms.TabPage tabPage5; private System.Windows.Forms.VScrollBar vScrollBar4; private System.Windows.Forms.Button tab3SearchBtn; - private BWP.WinFormControl.UDatePicker tab3DateSelect; - private System.Windows.Forms.Label label7; private System.Windows.Forms.Panel panel4; private System.Windows.Forms.FlowLayoutPanel tab3KeyPanel; private System.Windows.Forms.Label label8; private BWP.WinFormControl.UDataGridView orderGrid3; - private System.Windows.Forms.DataGridViewTextBoxColumn H_ID; - private System.Windows.Forms.DataGridViewTextBoxColumn H_WeightBill_ID; - private System.Windows.Forms.DataGridViewTextBoxColumn H_SecondarySplit; - private System.Windows.Forms.DataGridViewTextBoxColumn H_Order; - private System.Windows.Forms.DataGridViewTextBoxColumn H_B3WeighBill_ID; - private System.Windows.Forms.DataGridViewTextBoxColumn H_Supplier_Name; - private System.Windows.Forms.DataGridViewTextBoxColumn H_LiveColonyHouse_Name; - private System.Windows.Forms.DataGridViewTextBoxColumn H_PlanNumber; - private System.Windows.Forms.DataGridViewTextBoxColumn H_HurryNumber; - private System.Windows.Forms.DataGridViewButtonColumn dataGridViewButtonColumn1; - private System.Windows.Forms.DataGridViewButtonColumn H_View; private System.Windows.Forms.DataGridViewTextBoxColumn O_ID; private System.Windows.Forms.DataGridViewTextBoxColumn O_IsHurryButcher; private System.Windows.Forms.DataGridViewTextBoxColumn O_WeightBill_ID; @@ -1489,6 +1420,14 @@ private System.Windows.Forms.DataGridViewTextBoxColumn O_PlanNumber; private System.Windows.Forms.DataGridViewButtonColumn O_OKBtn; private System.Windows.Forms.Button tb3CloseBtn; + private System.Windows.Forms.DataGridViewTextBoxColumn H_WeightBill_ID; + private System.Windows.Forms.DataGridViewTextBoxColumn H_B3WeighBill_ID; + private System.Windows.Forms.DataGridViewTextBoxColumn H_Supplier_Name; + private System.Windows.Forms.DataGridViewTextBoxColumn H_LiveColonyHouse_Name; + private System.Windows.Forms.DataGridViewTextBoxColumn H_WeightNumber; + private System.Windows.Forms.DataGridViewTextBoxColumn H_HurryNumber; + private System.Windows.Forms.DataGridViewButtonColumn dataGridViewButtonColumn1; + private System.Windows.Forms.DataGridViewButtonColumn H_View; diff --git a/QualityAndOrder/QualityOrderForm.resx b/QualityAndOrder/QualityOrderForm.resx index 48effd5..01d2f56 100644 --- a/QualityAndOrder/QualityOrderForm.resx +++ b/QualityAndOrder/QualityOrderForm.resx @@ -117,39 +117,6 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - True - - - True - - - True - - - True - - - True - - - True - - - True - - - True - - - True - - - True - - - True - True @@ -270,4 +237,28 @@ True + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + \ No newline at end of file diff --git a/QualityAndOrder/QualityOrderFormForTab2.cs b/QualityAndOrder/QualityOrderFormForTab2.cs index 3b3cd09..9fcae47 100644 --- a/QualityAndOrder/QualityOrderFormForTab2.cs +++ b/QualityAndOrder/QualityOrderFormForTab2.cs @@ -168,7 +168,7 @@ namespace QualityAndOrder OrderDetail lastOrderDetail; void BindOrderGrid() { - orderList = OrderDetailRpc.GetOrderDetail(butcherDateInput.Date.Value, false); + orderList = OrderDetailRpc.GetOrderDetail(butcherDateInput.Date.Value); if (lastOrderDetail != null) { var t = orderList.FirstOrDefault(x => x.ID == lastOrderDetail.ID); diff --git a/QualityAndOrder/QualityOrderFormForTab3.cs b/QualityAndOrder/QualityOrderFormForTab3.cs index be9def7..391a5ea 100644 --- a/QualityAndOrder/QualityOrderFormForTab3.cs +++ b/QualityAndOrder/QualityOrderFormForTab3.cs @@ -1,5 +1,6 @@ using BO.BO.Bill; using BO.Utils.BillRpc; +using BWP.WinFormControl; using System; using System.Collections.Generic; using System.Drawing; @@ -13,12 +14,11 @@ namespace QualityAndOrder { partial class QualityOrderForm { - List orderList3; + List hurryList; Thread bt3SyncTask; void Tab3Init() { - tab3DateSelect.Date = DateTime.Today; orderGrid3.AutoGenerateColumns = false; orderGrid3.DataSource = null; @@ -60,9 +60,9 @@ namespace QualityAndOrder void InputHurryNumber(string input) { - if (lastOrder3Detail == null) + if (lastHurry == null) throw new Exception("请选择一条排宰明细"); - lastOrder3Detail.HurryNumber = GetAfterNumber(lastOrder3Detail.HurryNumber, input) ?? 0; + lastHurry.HurryNumber = GetAfterNumber(lastHurry.HurryNumber, input) ?? 0; orderGrid3.Refresh(); } @@ -95,23 +95,23 @@ namespace QualityAndOrder } } - OrderDetail lastOrder3Detail; + SelectHurryList lastHurry; private void BindOrderGrid3() { - orderList3 = OrderDetailRpc.GetOrderDetail(tab3DateSelect.Date.Value, true); - if (lastOrder3Detail != null) + hurryList = OrderDetailRpc.GetSelectHurryList(); + if (lastHurry != null) { - var t = orderList3.FirstOrDefault(x => x.ID == lastOrder3Detail.ID); + var t = hurryList.FirstOrDefault(x => x.WeightBill_ID == lastHurry.WeightBill_ID); if (t != null) - t.HurryNumber = lastOrder3Detail.HurryNumber; + t.HurryNumber = lastHurry.HurryNumber; } - orderGrid3.DataSource = orderList3.OrderByDescending(x => x.Order).ToList(); + orderGrid3.DataSource = hurryList.OrderByDescending(x => x.B3WeighBill_ID).ToList(); foreach (DataGridViewRow row in orderGrid3.Rows) { - if (lastOrder3Detail != null && lastOrder3Detail.ID == (long)row.Cells["H_ID"].Value) + if (lastHurry != null && lastHurry.WeightBill_ID == (long)row.Cells["H_WeightBill_ID"].Value) { - lastOrder3Detail = row.DataBoundItem as OrderDetail; + lastHurry = row.DataBoundItem as SelectHurryList; row.DefaultCellStyle.BackColor = orderGrid3.RowsDefaultCellStyle.SelectionBackColor; } } @@ -137,21 +137,24 @@ namespace QualityAndOrder return; if (e.ColumnIndex == orderGrid3.ColumnCount - 2)//确定 { - if (lastOrder3Detail.HurryNumber == 0) + if (lastHurry.HurryNumber == 0) return; - if (lastOrder3Detail.HurryNumber > lastOrder3Detail.PlanNumber) + if (lastHurry.HurryNumber > lastHurry.WeightNumber) throw new Exception("急宰头数多余排宰头数"); - var record = OrderDetailRpc.InsertHurryRecord(lastOrder3Detail); - lastOrder3Detail.HurryNumber = OrderDetailRpc.GetHurryRecordNumber(lastOrder3Detail.ID); + bool hasError = false; + var record = OrderDetailRpc.InsertHurryRecord(lastHurry,out hasError); + if (hasError) + UMessageBox.Show("排宰顺序出现多条记录,请手动修改", "注意"); + lastHurry.HurryNumber = OrderDetailRpc.GetHurryRecordNumber(lastHurry.WeightBill_ID); orderGrid3.Refresh(); HurryRecordPrint.Print(record); } else//查看 { - var view = new HurryRecordView(lastOrder3Detail.ID); + var view = new HurryRecordView(lastHurry.WeightBill_ID); if (view.ShowDialog() == DialogResult.OK) { - lastOrder3Detail.HurryNumber -= view.Result; + lastHurry.HurryNumber -= view.Result; orderGrid3.Refresh(); } } @@ -161,20 +164,20 @@ namespace QualityAndOrder { if (e.RowIndex == -1) return; - var entity = orderGrid3.CurrentRow.DataBoundItem as OrderDetail; + var entity = orderGrid3.CurrentRow.DataBoundItem as SelectHurryList; - if (lastOrder3Detail != null) + if (lastHurry != null) { foreach (DataGridViewRow row in orderGrid3.Rows) { - if (lastOrder3Detail.ID == (long)row.Cells["H_ID"].Value) + if (lastHurry.WeightBill_ID == (long)row.Cells["H_WeightBill_ID"].Value) { row.DefaultCellStyle.BackColor = orderGrid3.RowsDefaultCellStyle.BackColor; break; } } } - lastOrder3Detail = entity; + lastHurry = entity; if (e.ColumnIndex != orderGrid3.Columns.Count - 2)//非确定列 orderGrid3.Refresh(); }