Removed Code and BaseCode from Products
Management form almost fixed. Error testing now.
This commit is contained in:
@ -34,9 +34,6 @@
|
||||
this.Label7 = new System.Windows.Forms.Label();
|
||||
this.bsServiceTax = new System.Windows.Forms.BindingSource(this.components);
|
||||
this.label5 = new System.Windows.Forms.Label();
|
||||
this.label3 = new System.Windows.Forms.Label();
|
||||
this.txtProductID = new System.Windows.Forms.TextBox();
|
||||
this.txtCode = new System.Windows.Forms.TextBox();
|
||||
this.Label2 = new System.Windows.Forms.Label();
|
||||
this.txtUnits = new System.Windows.Forms.TextBox();
|
||||
this.txtName = new System.Windows.Forms.TextBox();
|
||||
@ -54,6 +51,7 @@
|
||||
this.label6 = new System.Windows.Forms.Label();
|
||||
this.chkIsScTaxable = new System.Windows.Forms.CheckBox();
|
||||
this.chkIsNotAvailable = new System.Windows.Forms.CheckBox();
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
((System.ComponentModel.ISupportInitialize)(this.bsProductGroups)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.bsServiceTax)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.bsVat)).BeginInit();
|
||||
@ -62,7 +60,7 @@
|
||||
// Label4
|
||||
//
|
||||
this.Label4.AutoSize = true;
|
||||
this.Label4.Location = new System.Drawing.Point(19, 67);
|
||||
this.Label4.Location = new System.Drawing.Point(19, 41);
|
||||
this.Label4.Name = "Label4";
|
||||
this.Label4.Size = new System.Drawing.Size(85, 13);
|
||||
this.Label4.TabIndex = 15;
|
||||
@ -75,7 +73,7 @@
|
||||
// Label7
|
||||
//
|
||||
this.Label7.AutoSize = true;
|
||||
this.Label7.Location = new System.Drawing.Point(70, 169);
|
||||
this.Label7.Location = new System.Drawing.Point(70, 143);
|
||||
this.Label7.Name = "Label7";
|
||||
this.Label7.Size = new System.Drawing.Size(36, 13);
|
||||
this.Label7.TabIndex = 17;
|
||||
@ -88,42 +86,16 @@
|
||||
// label5
|
||||
//
|
||||
this.label5.AutoSize = true;
|
||||
this.label5.Location = new System.Drawing.Point(26, 143);
|
||||
this.label5.Location = new System.Drawing.Point(26, 117);
|
||||
this.label5.Name = "label5";
|
||||
this.label5.Size = new System.Drawing.Size(80, 13);
|
||||
this.label5.TabIndex = 16;
|
||||
this.label5.Text = "Service Charge";
|
||||
//
|
||||
// label3
|
||||
//
|
||||
this.label3.AutoSize = true;
|
||||
this.label3.Location = new System.Drawing.Point(12, 15);
|
||||
this.label3.Name = "label3";
|
||||
this.label3.Size = new System.Drawing.Size(94, 13);
|
||||
this.label3.TabIndex = 13;
|
||||
this.label3.Text = "Product ID / Code";
|
||||
//
|
||||
// txtProductID
|
||||
//
|
||||
this.txtProductID.Location = new System.Drawing.Point(112, 12);
|
||||
this.txtProductID.Name = "txtProductID";
|
||||
this.txtProductID.ReadOnly = true;
|
||||
this.txtProductID.Size = new System.Drawing.Size(189, 20);
|
||||
this.txtProductID.TabIndex = 12;
|
||||
//
|
||||
// txtCode
|
||||
//
|
||||
this.txtCode.AccessibleName = "";
|
||||
this.txtCode.Location = new System.Drawing.Point(307, 12);
|
||||
this.txtCode.Name = "txtCode";
|
||||
this.txtCode.Size = new System.Drawing.Size(96, 20);
|
||||
this.txtCode.TabIndex = 0;
|
||||
this.txtCode.WordWrap = false;
|
||||
//
|
||||
// Label2
|
||||
//
|
||||
this.Label2.AutoSize = true;
|
||||
this.Label2.Location = new System.Drawing.Point(36, 41);
|
||||
this.Label2.Location = new System.Drawing.Point(36, 15);
|
||||
this.Label2.Name = "Label2";
|
||||
this.Label2.Size = new System.Drawing.Size(70, 13);
|
||||
this.Label2.TabIndex = 14;
|
||||
@ -132,7 +104,7 @@
|
||||
// txtUnits
|
||||
//
|
||||
this.txtUnits.AccessibleName = "";
|
||||
this.txtUnits.Location = new System.Drawing.Point(307, 38);
|
||||
this.txtUnits.Location = new System.Drawing.Point(307, 12);
|
||||
this.txtUnits.Name = "txtUnits";
|
||||
this.txtUnits.Size = new System.Drawing.Size(96, 20);
|
||||
this.txtUnits.TabIndex = 2;
|
||||
@ -140,7 +112,7 @@
|
||||
// txtName
|
||||
//
|
||||
this.txtName.AccessibleName = "";
|
||||
this.txtName.Location = new System.Drawing.Point(112, 38);
|
||||
this.txtName.Location = new System.Drawing.Point(112, 12);
|
||||
this.txtName.Name = "txtName";
|
||||
this.txtName.Size = new System.Drawing.Size(189, 20);
|
||||
this.txtName.TabIndex = 1;
|
||||
@ -148,7 +120,7 @@
|
||||
// txtPrice
|
||||
//
|
||||
this.txtPrice.AccessibleName = "";
|
||||
this.txtPrice.Location = new System.Drawing.Point(112, 64);
|
||||
this.txtPrice.Location = new System.Drawing.Point(112, 38);
|
||||
this.txtPrice.Name = "txtPrice";
|
||||
this.txtPrice.Size = new System.Drawing.Size(104, 20);
|
||||
this.txtPrice.TabIndex = 3;
|
||||
@ -159,7 +131,7 @@
|
||||
this.cmbVat.DataSource = this.bsVat;
|
||||
this.cmbVat.DisplayMember = "Name";
|
||||
this.cmbVat.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||
this.cmbVat.Location = new System.Drawing.Point(112, 114);
|
||||
this.cmbVat.Location = new System.Drawing.Point(112, 88);
|
||||
this.cmbVat.Name = "cmbVat";
|
||||
this.cmbVat.Size = new System.Drawing.Size(189, 21);
|
||||
this.cmbVat.TabIndex = 4;
|
||||
@ -172,7 +144,7 @@
|
||||
// chkIsActive
|
||||
//
|
||||
this.chkIsActive.AutoSize = true;
|
||||
this.chkIsActive.Location = new System.Drawing.Point(307, 89);
|
||||
this.chkIsActive.Location = new System.Drawing.Point(307, 66);
|
||||
this.chkIsActive.Name = "chkIsActive";
|
||||
this.chkIsActive.Size = new System.Drawing.Size(67, 17);
|
||||
this.chkIsActive.TabIndex = 7;
|
||||
@ -182,7 +154,7 @@
|
||||
// txtServiceCharge
|
||||
//
|
||||
this.txtServiceCharge.AccessibleName = "Phone 1";
|
||||
this.txtServiceCharge.Location = new System.Drawing.Point(112, 141);
|
||||
this.txtServiceCharge.Location = new System.Drawing.Point(112, 115);
|
||||
this.txtServiceCharge.Name = "txtServiceCharge";
|
||||
this.txtServiceCharge.Size = new System.Drawing.Size(189, 20);
|
||||
this.txtServiceCharge.TabIndex = 5;
|
||||
@ -190,7 +162,7 @@
|
||||
//
|
||||
// btnAddProductGroup
|
||||
//
|
||||
this.btnAddProductGroup.Location = new System.Drawing.Point(307, 167);
|
||||
this.btnAddProductGroup.Location = new System.Drawing.Point(307, 141);
|
||||
this.btnAddProductGroup.Name = "btnAddProductGroup";
|
||||
this.btnAddProductGroup.Size = new System.Drawing.Size(96, 21);
|
||||
this.btnAddProductGroup.TabIndex = 9;
|
||||
@ -203,7 +175,7 @@
|
||||
this.cmbProductGroup.DataSource = this.bsProductGroups;
|
||||
this.cmbProductGroup.DisplayMember = "Name";
|
||||
this.cmbProductGroup.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||
this.cmbProductGroup.Location = new System.Drawing.Point(112, 167);
|
||||
this.cmbProductGroup.Location = new System.Drawing.Point(112, 141);
|
||||
this.cmbProductGroup.Name = "cmbProductGroup";
|
||||
this.cmbProductGroup.Size = new System.Drawing.Size(189, 21);
|
||||
this.cmbProductGroup.TabIndex = 8;
|
||||
@ -211,7 +183,7 @@
|
||||
//
|
||||
// btnCancel
|
||||
//
|
||||
this.btnCancel.Location = new System.Drawing.Point(328, 195);
|
||||
this.btnCancel.Location = new System.Drawing.Point(328, 169);
|
||||
this.btnCancel.Name = "btnCancel";
|
||||
this.btnCancel.Size = new System.Drawing.Size(75, 75);
|
||||
this.btnCancel.TabIndex = 11;
|
||||
@ -221,7 +193,7 @@
|
||||
//
|
||||
// btnOk
|
||||
//
|
||||
this.btnOk.Location = new System.Drawing.Point(247, 195);
|
||||
this.btnOk.Location = new System.Drawing.Point(247, 169);
|
||||
this.btnOk.Name = "btnOk";
|
||||
this.btnOk.Size = new System.Drawing.Size(75, 75);
|
||||
this.btnOk.TabIndex = 10;
|
||||
@ -232,7 +204,7 @@
|
||||
// txtFullPrice
|
||||
//
|
||||
this.txtFullPrice.AccessibleName = "";
|
||||
this.txtFullPrice.Location = new System.Drawing.Point(222, 64);
|
||||
this.txtFullPrice.Location = new System.Drawing.Point(222, 38);
|
||||
this.txtFullPrice.Name = "txtFullPrice";
|
||||
this.txtFullPrice.Size = new System.Drawing.Size(79, 20);
|
||||
this.txtFullPrice.TabIndex = 19;
|
||||
@ -243,7 +215,7 @@
|
||||
this.cmbServiceTax.DataSource = this.bsServiceTax;
|
||||
this.cmbServiceTax.DisplayMember = "Name";
|
||||
this.cmbServiceTax.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||
this.cmbServiceTax.Location = new System.Drawing.Point(112, 87);
|
||||
this.cmbServiceTax.Location = new System.Drawing.Point(112, 61);
|
||||
this.cmbServiceTax.Name = "cmbServiceTax";
|
||||
this.cmbServiceTax.Size = new System.Drawing.Size(189, 21);
|
||||
this.cmbServiceTax.TabIndex = 20;
|
||||
@ -252,16 +224,16 @@
|
||||
// label6
|
||||
//
|
||||
this.label6.AutoSize = true;
|
||||
this.label6.Location = new System.Drawing.Point(19, 89);
|
||||
this.label6.Location = new System.Drawing.Point(42, 67);
|
||||
this.label6.Name = "label6";
|
||||
this.label6.Size = new System.Drawing.Size(91, 13);
|
||||
this.label6.Size = new System.Drawing.Size(64, 13);
|
||||
this.label6.TabIndex = 21;
|
||||
this.label6.Text = "Service Tax / Vat";
|
||||
this.label6.Text = "Service Tax";
|
||||
//
|
||||
// chkIsScTaxable
|
||||
//
|
||||
this.chkIsScTaxable.AutoSize = true;
|
||||
this.chkIsScTaxable.Location = new System.Drawing.Point(307, 144);
|
||||
this.chkIsScTaxable.Location = new System.Drawing.Point(307, 118);
|
||||
this.chkIsScTaxable.Name = "chkIsScTaxable";
|
||||
this.chkIsScTaxable.Size = new System.Drawing.Size(91, 17);
|
||||
this.chkIsScTaxable.TabIndex = 22;
|
||||
@ -271,18 +243,28 @@
|
||||
// chkIsNotAvailable
|
||||
//
|
||||
this.chkIsNotAvailable.AutoSize = true;
|
||||
this.chkIsNotAvailable.Location = new System.Drawing.Point(307, 116);
|
||||
this.chkIsNotAvailable.Location = new System.Drawing.Point(307, 93);
|
||||
this.chkIsNotAvailable.Name = "chkIsNotAvailable";
|
||||
this.chkIsNotAvailable.Size = new System.Drawing.Size(57, 17);
|
||||
this.chkIsNotAvailable.TabIndex = 23;
|
||||
this.chkIsNotAvailable.Text = "Is N/A";
|
||||
this.chkIsNotAvailable.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// label1
|
||||
//
|
||||
this.label1.AutoSize = true;
|
||||
this.label1.Location = new System.Drawing.Point(78, 94);
|
||||
this.label1.Name = "label1";
|
||||
this.label1.Size = new System.Drawing.Size(28, 13);
|
||||
this.label1.TabIndex = 24;
|
||||
this.label1.Text = "VAT";
|
||||
//
|
||||
// ProductForm
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(415, 282);
|
||||
this.Controls.Add(this.label1);
|
||||
this.Controls.Add(this.chkIsNotAvailable);
|
||||
this.Controls.Add(this.chkIsScTaxable);
|
||||
this.Controls.Add(this.label6);
|
||||
@ -301,9 +283,6 @@
|
||||
this.Controls.Add(this.txtUnits);
|
||||
this.Controls.Add(this.txtName);
|
||||
this.Controls.Add(this.Label2);
|
||||
this.Controls.Add(this.txtCode);
|
||||
this.Controls.Add(this.txtProductID);
|
||||
this.Controls.Add(this.label3);
|
||||
this.Controls.Add(this.Label4);
|
||||
this.MaximizeBox = false;
|
||||
this.MinimizeBox = false;
|
||||
@ -326,9 +305,6 @@
|
||||
private System.Windows.Forms.BindingSource bsProductGroups;
|
||||
private System.Windows.Forms.BindingSource bsServiceTax;
|
||||
internal System.Windows.Forms.Label label5;
|
||||
private System.Windows.Forms.Label label3;
|
||||
private System.Windows.Forms.TextBox txtProductID;
|
||||
internal System.Windows.Forms.TextBox txtCode;
|
||||
internal System.Windows.Forms.Label Label2;
|
||||
internal System.Windows.Forms.TextBox txtUnits;
|
||||
internal System.Windows.Forms.TextBox txtName;
|
||||
@ -346,5 +322,6 @@
|
||||
private System.Windows.Forms.CheckBox chkIsScTaxable;
|
||||
private System.Windows.Forms.BindingSource bsVat;
|
||||
private System.Windows.Forms.CheckBox chkIsNotAvailable;
|
||||
internal System.Windows.Forms.Label label1;
|
||||
}
|
||||
}
|
||||
@ -22,8 +22,6 @@ namespace Tanshu.Accounts.PointOfSale
|
||||
Product product;
|
||||
using (var bi = new ProductBI())
|
||||
product = bi.Get(x => x.ProductID == _productID.Value);
|
||||
txtProductID.Text = _productID.Value.ToString();
|
||||
txtCode.Text = product.Code.ToString();
|
||||
txtName.Text = product.Name;
|
||||
txtUnits.Text = product.Units;
|
||||
txtPrice.Text = product.Price.ToString("#.##");
|
||||
@ -38,7 +36,6 @@ namespace Tanshu.Accounts.PointOfSale
|
||||
}
|
||||
else
|
||||
{
|
||||
txtProductID.Text = "(Auto)";
|
||||
txtName.Focus();
|
||||
}
|
||||
}
|
||||
@ -69,29 +66,34 @@ namespace Tanshu.Accounts.PointOfSale
|
||||
if (_productID.HasValue)
|
||||
product.ProductID = _productID.Value;
|
||||
|
||||
int code;
|
||||
if (!int.TryParse(txtCode.Text, out code))
|
||||
return null;
|
||||
if (code < 0)
|
||||
return null;
|
||||
product.Code = code;
|
||||
|
||||
if (string.IsNullOrEmpty(txtName.Text.Trim()))
|
||||
return null;
|
||||
product.Name = txtName.Text.Trim();
|
||||
//if (string.IsNullOrEmpty(txtUnits.Text.Trim()))
|
||||
// return null;
|
||||
product.Units = txtUnits.Text.Trim();
|
||||
|
||||
decimal price;
|
||||
if (!decimal.TryParse(txtPrice.Text, out price))
|
||||
return null;
|
||||
if (string.IsNullOrEmpty(txtPrice.Text.Trim()))
|
||||
{
|
||||
price = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!decimal.TryParse(txtPrice.Text.Trim(), out price))
|
||||
return null;
|
||||
}
|
||||
if (price < 0)
|
||||
return null;
|
||||
product.Price = price;
|
||||
|
||||
if (!decimal.TryParse(txtFullPrice.Text, out price))
|
||||
return null;
|
||||
if (string.IsNullOrEmpty(txtFullPrice.Text.Trim()))
|
||||
{
|
||||
price = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!decimal.TryParse(txtFullPrice.Text.Trim(), out price))
|
||||
return null;
|
||||
}
|
||||
if (price < 0 || price < product.Price)
|
||||
return null;
|
||||
product.FullPrice = price;
|
||||
@ -106,8 +108,16 @@ namespace Tanshu.Accounts.PointOfSale
|
||||
product.ServiceTax = (Tax)cmbServiceTax.SelectedItem;
|
||||
|
||||
decimal serviceCharge;
|
||||
if (!decimal.TryParse(txtServiceCharge.Text, out serviceCharge))
|
||||
return null;
|
||||
if (string.IsNullOrEmpty(txtServiceCharge.Text.Trim()))
|
||||
{
|
||||
serviceCharge = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!decimal.TryParse(txtServiceCharge.Text.Trim(), out serviceCharge))
|
||||
return null;
|
||||
}
|
||||
|
||||
if (serviceCharge < 0 || serviceCharge > 1)
|
||||
return null;
|
||||
product.ServiceCharge = serviceCharge;
|
||||
|
||||
@ -29,25 +29,25 @@
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.components = new System.ComponentModel.Container();
|
||||
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle7 = new System.Windows.Forms.DataGridViewCellStyle();
|
||||
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle8 = 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();
|
||||
this.btnAdd = new System.Windows.Forms.Button();
|
||||
this.btnEdit = new System.Windows.Forms.Button();
|
||||
this.btnExit = new System.Windows.Forms.Button();
|
||||
this.dgvProducts = new System.Windows.Forms.DataGridView();
|
||||
this.bsList = new System.Windows.Forms.BindingSource(this.components);
|
||||
this.btnSave = new System.Windows.Forms.Button();
|
||||
this.chkIsActive = new System.Windows.Forms.CheckBox();
|
||||
this.nameDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.unitsDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.moveUp = new System.Windows.Forms.DataGridViewButtonColumn();
|
||||
this.moveDown = new System.Windows.Forms.DataGridViewButtonColumn();
|
||||
this.Vat = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.ServiceTax = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.Vat = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.Group = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.serviceChargeDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.salePriceDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.isActiveDataGridViewCheckBoxColumn = new System.Windows.Forms.DataGridViewCheckBoxColumn();
|
||||
this.bsList = new System.Windows.Forms.BindingSource(this.components);
|
||||
this.btnSave = new System.Windows.Forms.Button();
|
||||
this.chkIsActive = new System.Windows.Forms.CheckBox();
|
||||
((System.ComponentModel.ISupportInitialize)(this.dgvProducts)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.bsList)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
@ -100,8 +100,8 @@
|
||||
this.unitsDataGridViewTextBoxColumn,
|
||||
this.moveUp,
|
||||
this.moveDown,
|
||||
this.Vat,
|
||||
this.ServiceTax,
|
||||
this.Vat,
|
||||
this.Group,
|
||||
this.serviceChargeDataGridViewTextBoxColumn,
|
||||
this.salePriceDataGridViewTextBoxColumn,
|
||||
@ -120,6 +120,36 @@
|
||||
this.dgvProducts.TabIndex = 74;
|
||||
this.dgvProducts.CellFormatting += new System.Windows.Forms.DataGridViewCellFormattingEventHandler(this.dgvProductTypes_CellFormatting);
|
||||
//
|
||||
// bsList
|
||||
//
|
||||
this.bsList.DataSource = typeof(Tanshu.Accounts.Entities.Product);
|
||||
//
|
||||
// btnSave
|
||||
//
|
||||
this.btnSave.AccessibleName = "Done";
|
||||
this.btnSave.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.btnSave.Location = new System.Drawing.Point(174, 255);
|
||||
this.btnSave.Name = "btnSave";
|
||||
this.btnSave.Size = new System.Drawing.Size(75, 75);
|
||||
this.btnSave.TabIndex = 75;
|
||||
this.btnSave.Text = "&Save";
|
||||
this.btnSave.Click += new System.EventHandler(this.btnSave_Click);
|
||||
//
|
||||
// chkIsActive
|
||||
//
|
||||
this.chkIsActive.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.chkIsActive.AutoSize = true;
|
||||
this.chkIsActive.Checked = true;
|
||||
this.chkIsActive.CheckState = System.Windows.Forms.CheckState.Checked;
|
||||
this.chkIsActive.Location = new System.Drawing.Point(255, 285);
|
||||
this.chkIsActive.Name = "chkIsActive";
|
||||
this.chkIsActive.Size = new System.Drawing.Size(116, 17);
|
||||
this.chkIsActive.TabIndex = 76;
|
||||
this.chkIsActive.Text = "Show Active Only?";
|
||||
this.chkIsActive.ThreeState = true;
|
||||
this.chkIsActive.UseVisualStyleBackColor = true;
|
||||
this.chkIsActive.CheckStateChanged += new System.EventHandler(this.chkIsActive_CheckStateChanged);
|
||||
//
|
||||
// nameDataGridViewTextBoxColumn
|
||||
//
|
||||
this.nameDataGridViewTextBoxColumn.DataPropertyName = "Name";
|
||||
@ -154,14 +184,6 @@
|
||||
this.moveDown.UseColumnTextForButtonValue = true;
|
||||
this.moveDown.Width = 41;
|
||||
//
|
||||
// Vat
|
||||
//
|
||||
this.Vat.DataPropertyName = "Vat";
|
||||
this.Vat.HeaderText = "Vat";
|
||||
this.Vat.Name = "Vat";
|
||||
this.Vat.ReadOnly = true;
|
||||
this.Vat.Width = 48;
|
||||
//
|
||||
// ServiceTax
|
||||
//
|
||||
this.ServiceTax.DataPropertyName = "ServiceTax";
|
||||
@ -170,6 +192,14 @@
|
||||
this.ServiceTax.ReadOnly = true;
|
||||
this.ServiceTax.Width = 86;
|
||||
//
|
||||
// Vat
|
||||
//
|
||||
this.Vat.DataPropertyName = "Vat";
|
||||
this.Vat.HeaderText = "Vat";
|
||||
this.Vat.Name = "Vat";
|
||||
this.Vat.ReadOnly = true;
|
||||
this.Vat.Width = 48;
|
||||
//
|
||||
// Group
|
||||
//
|
||||
this.Group.DataPropertyName = "ProductGroup";
|
||||
@ -181,8 +211,8 @@
|
||||
// serviceChargeDataGridViewTextBoxColumn
|
||||
//
|
||||
this.serviceChargeDataGridViewTextBoxColumn.DataPropertyName = "ServiceCharge";
|
||||
dataGridViewCellStyle7.Format = "P0";
|
||||
this.serviceChargeDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle7;
|
||||
dataGridViewCellStyle1.Format = "P0";
|
||||
this.serviceChargeDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle1;
|
||||
this.serviceChargeDataGridViewTextBoxColumn.HeaderText = "SC";
|
||||
this.serviceChargeDataGridViewTextBoxColumn.Name = "serviceChargeDataGridViewTextBoxColumn";
|
||||
this.serviceChargeDataGridViewTextBoxColumn.ReadOnly = true;
|
||||
@ -191,8 +221,8 @@
|
||||
// salePriceDataGridViewTextBoxColumn
|
||||
//
|
||||
this.salePriceDataGridViewTextBoxColumn.DataPropertyName = "Price";
|
||||
dataGridViewCellStyle8.Format = "N0";
|
||||
this.salePriceDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle8;
|
||||
dataGridViewCellStyle2.Format = "N0";
|
||||
this.salePriceDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle2;
|
||||
this.salePriceDataGridViewTextBoxColumn.HeaderText = "Price";
|
||||
this.salePriceDataGridViewTextBoxColumn.Name = "salePriceDataGridViewTextBoxColumn";
|
||||
this.salePriceDataGridViewTextBoxColumn.ReadOnly = true;
|
||||
@ -206,36 +236,6 @@
|
||||
this.isActiveDataGridViewCheckBoxColumn.ReadOnly = true;
|
||||
this.isActiveDataGridViewCheckBoxColumn.Width = 54;
|
||||
//
|
||||
// bsList
|
||||
//
|
||||
this.bsList.DataSource = typeof(Tanshu.Accounts.Entities.Product);
|
||||
//
|
||||
// btnSave
|
||||
//
|
||||
this.btnSave.AccessibleName = "Done";
|
||||
this.btnSave.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.btnSave.Location = new System.Drawing.Point(174, 255);
|
||||
this.btnSave.Name = "btnSave";
|
||||
this.btnSave.Size = new System.Drawing.Size(75, 75);
|
||||
this.btnSave.TabIndex = 75;
|
||||
this.btnSave.Text = "&Save";
|
||||
this.btnSave.Click += new System.EventHandler(this.btnSave_Click);
|
||||
//
|
||||
// chkIsActive
|
||||
//
|
||||
this.chkIsActive.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.chkIsActive.AutoSize = true;
|
||||
this.chkIsActive.Checked = true;
|
||||
this.chkIsActive.CheckState = System.Windows.Forms.CheckState.Checked;
|
||||
this.chkIsActive.Location = new System.Drawing.Point(255, 285);
|
||||
this.chkIsActive.Name = "chkIsActive";
|
||||
this.chkIsActive.Size = new System.Drawing.Size(116, 17);
|
||||
this.chkIsActive.TabIndex = 76;
|
||||
this.chkIsActive.Text = "Show Active Only?";
|
||||
this.chkIsActive.ThreeState = true;
|
||||
this.chkIsActive.UseVisualStyleBackColor = true;
|
||||
this.chkIsActive.CheckStateChanged += new System.EventHandler(this.chkIsActive_CheckStateChanged);
|
||||
//
|
||||
// ProductListForm
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
@ -268,17 +268,17 @@
|
||||
private System.Windows.Forms.DataGridView dgvProducts;
|
||||
private System.Windows.Forms.BindingSource bsList;
|
||||
internal System.Windows.Forms.Button btnSave;
|
||||
private System.Windows.Forms.CheckBox chkIsActive;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn nameDataGridViewTextBoxColumn;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn unitsDataGridViewTextBoxColumn;
|
||||
private System.Windows.Forms.DataGridViewButtonColumn moveUp;
|
||||
private System.Windows.Forms.DataGridViewButtonColumn moveDown;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn Vat;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn ServiceTax;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn Vat;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn Group;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn serviceChargeDataGridViewTextBoxColumn;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn salePriceDataGridViewTextBoxColumn;
|
||||
private System.Windows.Forms.DataGridViewCheckBoxColumn isActiveDataGridViewCheckBoxColumn;
|
||||
private System.Windows.Forms.CheckBox chkIsActive;
|
||||
//private System.Windows.Forms.DataGridViewTextBoxColumn discountLimitDataGridViewTextBoxColumn;
|
||||
//private System.Windows.Forms.DataGridViewTextBoxColumn groupTypeDataGridViewTextBoxColumn;
|
||||
//private System.Windows.Forms.DataGridViewTextBoxColumn productGroupDataGridViewTextBoxColumn;
|
||||
|
||||
@ -123,30 +123,12 @@
|
||||
<metadata name="moveDown.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="Vat.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="ServiceTax.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="Group.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="bsList.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
<metadata name="moveUp.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="moveDown.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="Vat.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="ServiceTax.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="Group.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
|
||||
Reference in New Issue
Block a user