コード例 #1
0
ファイル: AddSupplierView.xaml.cs プロジェクト: qq5013/TMS-1
        private void btnAddCustomer_Click(object sender, RoutedEventArgs e)
        {
            SUPPLIER supplier = new SUPPLIER();

            if (txtFullName.Text != string.Empty && txtAddress.Text != string.Empty && cboSupplierStatus.Text != string.Empty)
            {
                supplier.SUPPLIER_NAME = txtFullName.Text;
                supplier.SUPPLIER_ADDRESS = txtAddress.Text;
                supplier.SUPPLIER_CONTACT_NO = Convert.ToInt64(txtContactNo1.Text);
                supplier.SUPPLIER_TYPE = Convert.ToInt32(cmbSupplierType.SelectedValue);
                supplier.SUPPLIER_STATUS = Convert.ToInt32(cboSupplierStatus.SelectedValue);

                data.Insert<SUPPLIER>(supplier);

                BindSuppliers();

            }
            else
            {
                MessageBox.Show("Please Fill All the mandatory fields");
                return;
            }

            Common.ClearAllControls<TextBox>(addSupplier, 1);
            Common.ClearAllControls<ComboBox>(addSupplier);

            MessageBox.Show("Supplier Added Succesfully");
        }
コード例 #2
0
 partial void DeleteSUPPLIER(SUPPLIER instance);
コード例 #3
0
 partial void UpdateSUPPLIER(SUPPLIER instance);
コード例 #4
0
 partial void InsertSUPPLIER(SUPPLIER instance);
コード例 #5
0
		private void detach_SUPPLIERs1(SUPPLIER entity)
		{
			this.SendPropertyChanging();
			entity.MASTER1 = null;
		}
コード例 #6
0
		private void attach_SUPPLIERs(SUPPLIER entity)
		{
			this.SendPropertyChanging();
			entity.MASTER = this;
		}