示例#1
0
        private void FormBomInput_Load(object sender, EventArgs e)
        {
            formBom      = (FormBSBom)this.Owner;
            intNodeIndex = formBom.tvInven.SelectedNode.Index;
            propInvens   = LoadInven();
            propBoms     = LoadBom();
            commUse.BindComboBox(cbxProInvenCode, "InvenCode", "InvenName", "select InvenCode,InvenName ,SpecsModel from BSInven", "BSInven");
            commUse.BindComboBox(cbxMatInvenCode, "InvenCode", "InvenName", "select InvenCode,InvenName ,SpecsModel from BSInven", "BSInven");

            //在添加操作下打开FormBomInput窗体
            if (this.Tag.ToString() == "Add")
            {
                if (formBom.tvInven.SelectedNode.Tag == null)
                {
                    cbxProInvenCode.SelectedIndex = -1;
                    cbxMatInvenCode.SelectedIndex = -1;
                }
                else
                {
                    cbxProInvenCode.SelectedValue = formBom.tvInven.SelectedNode.Tag;
                    cbxMatInvenCode.SelectedIndex = -1;
                }
            }

            //在修改操作下打开FormBomInput窗体
            if (this.Tag.ToString() == "Edit")
            {
                cbxProInvenCode.SelectedValue = formBom.tvInven.SelectedNode.Tag;
                cbxProInvenCode.Enabled       = false;
                cbxMatInvenCode.SelectedValue = formBom.dgvStructInfo[0, formBom.dgvStructInfo.CurrentRow.Index].Value;
                txtSpecsModel2.Text           = formBom.dgvStructInfo[2, formBom.dgvStructInfo.CurrentRow.Index].Value.ToString();
                txtQuantity.Text = formBom.dgvStructInfo[4, formBom.dgvStructInfo.CurrentRow.Index].Value.ToString();
            }
        }
示例#2
0
        private void FormCURelRecord_Load(object sender, EventArgs e)
        {
            formCustomerCourse = (FormCustomerCourse)this.Owner;
            commUse.BindComboBox(cbxCustomerCode, "CustomerCode", "CustomerName", "select CustomerCode,CustomerName from BSCustomer", "BSCustomer");
            commUse.BindComboBox(cbxRelManner, "Code", "Name", "select Code,Name from INRelManner", "INRelManner");
            cbxCustomerCode.SelectedValue = formCustomerCourse.tvCustomer.SelectedNode.Tag;

            //添加操作
            if (this.Tag.ToString() == "Add")
            {
                cbxRelManner.SelectedIndex = -1;
                dtpRelDate.Value           = DateTime.Today;
                dtpNextDate.Value          = DateTime.Today;
            }

            //修改操作
            if (this.Tag.ToString() == "Edit")
            {
                dtpRelDate.Value           = Convert.ToDateTime(formCustomerCourse.dgvRel["RelDate", formCustomerCourse.dgvRel.CurrentRow.Index].Value);
                cbxRelManner.SelectedValue = formCustomerCourse.dgvRel["RelManner", formCustomerCourse.dgvRel.CurrentRow.Index].Value;
                txtLinkman.Text            = formCustomerCourse.dgvRel["Linkman_Rel", formCustomerCourse.dgvRel.CurrentRow.Index].Value.ToString();
                txtTelephoneCode.Text      = formCustomerCourse.dgvRel["TelephoneCode_Rel", formCustomerCourse.dgvRel.CurrentRow.Index].Value.ToString();
                dtpNextDate.Value          = Convert.ToDateTime(formCustomerCourse.dgvRel["NextDate", formCustomerCourse.dgvRel.CurrentRow.Index].Value);
                rtbRelContent.Text         = formCustomerCourse.dgvRel["RelContent", formCustomerCourse.dgvRel.CurrentRow.Index].Value.ToString();
                rtbFeeInfo.Text            = formCustomerCourse.dgvRel["FeeInfo", formCustomerCourse.dgvRel.CurrentRow.Index].Value.ToString();
            }
        }
示例#3
0
        private void FormCustomer_Load(object sender, EventArgs e)
        {
            //权限
            commUse.CortrolButtonEnabled(toolAdd, this);
            commUse.CortrolButtonEnabled(toolAmend, this);
            commUse.CortrolButtonEnabled(toolDelete, this);
            //ComboBox绑定到数据源
            commUse.BindComboBox(cbxEmployeeCode, "EmployeeCode", "EmployeeName", "select EmployeeCode, EmployeeName from BSEmployee", "BSEmployee");
            commUse.BindComboBox(cbxGradeCode, "GradeCode", "GradeName", "select GradeCode, GradeName from CUGrade", "CUGrade");
            commUse.BindComboBox(cbxStateCode, "StateCode", "StateName", "select StateCode, StateName from CUState", "CUState");
            commUse.BindComboBox(cbxCreditCode, "CreditCode", "CreditName", "select CreditCode, CreditName from CUCredit", "CUCredit");
            commUse.BindComboBox(cbxTradeCode, "TradeCode", "TradeName", "select TradeCode, TradeName from CUTrade", "CUTrade");

            //DataGridViewComboBoxColumn绑定到数据源
            commUse.BindComboBox(this.dgvCustomerInfo.Columns[2], "EmployeeCode", "EmployeeName", "select EmployeeCode, EmployeeName from BSEmployee", "BSEmployee");
            commUse.BindComboBox(this.dgvCustomerInfo.Columns[11], "GradeCode", "GradeName", "select GradeCode, GradeName from CUGrade", "CUGrade");
            commUse.BindComboBox(this.dgvCustomerInfo.Columns[12], "StateCode", "StateName", "select StateCode, StateName from CUState", "CUState");
            commUse.BindComboBox(this.dgvCustomerInfo.Columns[13], "CreditCode", "CreditName", "select CreditCode, CreditName from CUCredit", "CUCredit");
            commUse.BindComboBox(this.dgvCustomerInfo.Columns[14], "TradeCode", "TradeName", "select TradeCode, TradeName from CUTrade", "CUTrade");
            //
            BindDataGridView("");
            this.BindToolStripComboBox();
            this.cbxCondition.SelectedIndex = 0;
            toolStrip1.Tag = "";
        }
示例#4
0
        private void FormCUSellChance_Load(object sender, EventArgs e)
        {
            formCustomerCourse = (FormCustomerCourse)this.Owner;
            commUse.BindComboBox(cbxCustomerCode, "CustomerCode", "CustomerName", "select CustomerCode,CustomerName from BSCustomer", "BSCustomer");
            commUse.BindComboBox(cbxChanceCode, "ChanceCode", "ChanceName", "select ChanceCode,ChanceName from CUChance", "CUChance");
            commUse.BindComboBox(cbxInvenCode, "InvenCode", "InvenName", "select InvenCode,InvenName from BSInven", "BSInven");
            cbxCustomerCode.SelectedValue = formCustomerCourse.tvCustomer.SelectedNode.Tag;

            if (this.Tag.ToString() == "Add") //添加操作
            {
                cbxChanceCode.SelectedIndex = -1;
                cbxInvenCode.SelectedIndex  = -1;
                dtpRegDate.Value            = DateTime.Today;
                dtpForeDate.Value           = DateTime.Today;
            }

            if (this.Tag.ToString() == "Edit") //编辑操作
            {
                txtTheme.Text               = formCustomerCourse.dgvSell["Theme", formCustomerCourse.dgvSell.CurrentRow.Index].Value.ToString();
                dtpRegDate.Value            = Convert.ToDateTime(formCustomerCourse.dgvSell["RegDate", formCustomerCourse.dgvSell.CurrentRow.Index].Value);
                cbxChanceCode.SelectedValue = formCustomerCourse.dgvSell["ChanceCode", formCustomerCourse.dgvSell.CurrentRow.Index].Value;
                dtpForeDate.Value           = Convert.ToDateTime(formCustomerCourse.dgvSell["ForeDate", formCustomerCourse.dgvSell.CurrentRow.Index].Value);
                cbxInvenCode.SelectedValue  = formCustomerCourse.dgvSell["InvenCode", formCustomerCourse.dgvSell.CurrentRow.Index].Value;
                txtUnitPrice.Text           = formCustomerCourse.dgvSell["UnitPrice", formCustomerCourse.dgvSell.CurrentRow.Index].Value.ToString();
                txtQuantity.Text            = formCustomerCourse.dgvSell["Quantity", formCustomerCourse.dgvSell.CurrentRow.Index].Value.ToString();
                txtCUMoney.Text             = formCustomerCourse.dgvSell["CUMoney", formCustomerCourse.dgvSell.CurrentRow.Index].Value.ToString();
                rtbRemark.Text              = formCustomerCourse.dgvSell["Remark", formCustomerCourse.dgvSell.CurrentRow.Index].Value.ToString();
            }
        }
示例#5
0
        private void FormSTLoss_Load(object sender, EventArgs e)
        {
            //权限
            commUse.CortrolButtonEnabled(toolAdd, this);
            commUse.CortrolButtonEnabled(toolAmend, this);
            commUse.CortrolButtonEnabled(toolDelete, this);
            commUse.CortrolButtonEnabled(toolCheck, this);
            commUse.CortrolButtonEnabled(toolUnCheck, this);

            //ComboBox绑定到数据源
            commUse.BindComboBox(cbxOperatorCode, "OperatorCode", "OperatorName",
                                 "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(cbxStoreCode, "StoreCode", "StoreName", "select StoreCode,StoreName from BSStore",
                                 "BSStore");
            commUse.BindComboBox(cbxEmployeeCode, "EmployeeCode", "EmployeeName",
                                 "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
            commUse.BindComboBox(cbxIsFlag, "Code", "Name", "select * from INCheckFlag", "INCheckFlag");

            //DataGridViewComboBoxColumn绑定到数据源
            commUse.BindComboBox(dgvSTLossInfo.Columns["OperatorCode"], "OperatorCode", "OperatorName",
                                 "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(dgvSTLossInfo.Columns["StoreCode"], "StoreCode", "StoreName",
                                 "select StoreCode,StoreName from BSStore", "BSStore");
            commUse.BindComboBox(dgvSTLossInfo.Columns["InvenCode"], "InvenCode", "InvenName",
                                 "select InvenCode,InvenName from BSInven", "BSInven");
            commUse.BindComboBox(dgvSTLossInfo.Columns["EmployeeCode"], "EmployeeCode", "EmployeeName",
                                 "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
            commUse.BindComboBox(dgvSTLossInfo.Columns["IsFlag"], "Code", "Name", "select * from INCheckFlag",
                                 "INCheckFlag");
            //
            BindDataGridView("");
            BindToolStripComboBox();
            cbxCondition.SelectedIndex = 0;
            toolStrip1.Tag             = "";
        }
示例#6
0
        private void FormFIDeposit_Load(object sender, EventArgs e)
        {
            //权限
            commUse.CortrolButtonEnabled(toolAdd, this);
            commUse.CortrolButtonEnabled(toolAmend, this);
            commUse.CortrolButtonEnabled(toolDelete, this);
            commUse.CortrolButtonEnabled(toolCheck, this);
            commUse.CortrolButtonEnabled(toolUnCheck, this);

            //ComboBox绑定到数据源
            commUse.BindComboBox(cbxOperatorCode, "OperatorCode", "OperatorName", "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(cbxOutAccCode, "AccountCode", "AccountName", "select AccountCode,AccountName from BSAccount", "BSAccount");
            commUse.BindComboBox(cbxInAccCode, "AccountCode", "AccountName", "select AccountCode,AccountName from BSAccount", "BSAccount");
            commUse.BindComboBox(cbxEmployeeCode, "EmployeeCode", "EmployeeName", "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
            commUse.BindComboBox(cbxIsFlag, "Code", "Name", "select * from INCheckFlag", "INCheckFlag");

            //DataGridViewComboBoxColumn绑定到数据源
            commUse.BindComboBox(this.dgvFIDepositInfo.Columns["OperatorCode"], "OperatorCode", "OperatorName", "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(this.dgvFIDepositInfo.Columns["OutAccCode"], "AccountCode", "AccountName", "select AccountCode,AccountName from BSAccount", "BSAccount");
            commUse.BindComboBox(this.dgvFIDepositInfo.Columns["InAccCode"], "AccountCode", "AccountName", "select AccountCode,AccountName from BSAccount", "BSAccount");
            commUse.BindComboBox(this.dgvFIDepositInfo.Columns["EmployeeCode"], "EmployeeCode", "EmployeeName", "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
            commUse.BindComboBox(this.dgvFIDepositInfo.Columns["IsFlag"], "Code", "Name", "select * from INCheckFlag", "INCheckFlag");
            //
            BindDataGridView("");
            this.BindToolStripComboBox();
            this.cbxCondition.SelectedIndex = 0;
            toolStrip1.Tag = "";
        }
示例#7
0
 private void FormPurReport_Load(object sender, EventArgs e)
 {
     //权限
     commUse.CortrolButtonEnabled(btnQuery, this);
     //ComboBox绑定到数据源
     commUse.BindComboBox(cbxSupplierCode, "SupplierCode", "SupplierName", "select SupplierCode,SupplierName from BSSupplier", "BSSupplier");
     commUse.BindComboBox(cbxInvenCode, "InvenCode", "InvenName", "select InvenCode,InvenName from BSInven", "BSInven");
     cbxSupplierCode.SelectedIndex = -1;
     cbxInvenCode.SelectedIndex    = -1;
 }
示例#8
0
 private void FormStockWarnReport_Load(object sender, EventArgs e)
 {
     //权限
     commUse.CortrolButtonEnabled(btnQuery, this);
     //ComboBox绑定到数据源
     commUse.BindComboBox(cbxStoreCode, "StoreCode", "StoreName", "select StoreCode,StoreName from BSStore", "BSStore");
     commUse.BindComboBox(cbxInvenCode, "InvenCode", "InvenName", "select InvenCode,InvenName from BSInven", "BSInven");
     //
     cbxStoreCode.SelectedIndex = -1;
     cbxInvenCode.SelectedIndex = -1;
 }
示例#9
0
        private void FormProduceComplete_Load(object sender, EventArgs e)
        {
            //授权
            commUse.CortrolButtonEnabled(toolCheck, this);
            commUse.CortrolButtonEnabled(toolUnCheck, this);

            //ComboBox控件绑定到数据源
            commUse.BindComboBox(cbxOperatorCode, "OperatorCode", "OperatorName", "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(cbxDepartmentCode, "DepartmentCode", "DepartmentName", "select DepartmentCode,DepartmentName from BSDepartment", "BSDepartment");
            commUse.BindComboBox(cbxInvenCode, "InvenCode", "InvenName", "select InvenCode,InvenName from BSInven", "BSInven");
            commUse.BindComboBox(cbxIsComplete, "Code", "Name", "select * from INCheckFlag", "INCheckFlag");
        }
示例#10
0
 private void FormSelReport_Load(object sender, EventArgs e)
 {
     //权限
     commUse.CortrolButtonEnabled(btnQuery, this);
     //ComboBox绑定到数据源
     commUse.BindComboBox(cbxCustomerCode, "CustomerCode", "CustomerName",
                          "select CustomerCode,CustomerName from BSCustomer", "BSCustomer");
     commUse.BindComboBox(cbxInvenCode, "InvenCode", "InvenName", "select InvenCode,InvenName from BSInven",
                          "BSInven");
     //
     cbxCustomerCode.SelectedIndex = -1;
     cbxInvenCode.SelectedIndex    = -1;
     //this.reportViewer1.RefreshReport();
 }
示例#11
0
        private void FormPRProduce_Load(object sender, EventArgs e)
        {
            //权限
            commUse.CortrolButtonEnabled(toolAdd, this);
            commUse.CortrolButtonEnabled(toolAmend, this);
            commUse.CortrolButtonEnabled(toolDelete, this);
            commUse.CortrolButtonEnabled(toolCheck, this);
            commUse.CortrolButtonEnabled(toolUnCheck, this);

            //ComboBox绑定到数据源
            commUse.BindComboBox(cbxOperatorCode, "OperatorCode", "OperatorName",
                                 "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(cbxDepartmentCode, "DepartmentCode", "DepartmentName",
                                 "select DepartmentCode,DepartmentName from BSDepartment", "BSDepartment");
            commUse.BindComboBox(cbxInvenCode, "InvenCode", "InvenName", "select InvenCode,InvenName from BSInven",
                                 "BSInven");
            commUse.BindComboBox(cbxIsFlag, "Code", "Name", "select * from INCheckFlag", "INCheckFlag");

            //DataGridViewComboBoxColumn绑定到数据源
            commUse.BindComboBox(dgvPRProduceInfo.Columns["OperatorCode"], "OperatorCode", "OperatorName",
                                 "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(dgvPRProduceInfo.Columns["DepartmentCode"], "DepartmentCode", "DepartmentName",
                                 "select DepartmentCode,DepartmentName from BSDepartment", "BSDepartment");
            commUse.BindComboBox(dgvPRProduceInfo.Columns["InvenCode"], "InvenCode", "InvenName",
                                 "select InvenCode,InvenName from BSInven", "BSInven");
            commUse.BindComboBox(dgvPRProduceInfo.Columns["IsFlag"], "Code", "Name", "select * from INCheckFlag",
                                 "INCheckFlag");
            //
            BindDataGridView("");
            BindToolStripComboBox();
            cbxCondition.SelectedIndex = 0;
            toolStrip1.Tag             = "";
        }
示例#12
0
 private void FormCost_Load(object sender, EventArgs e)
 {
     //权限
     commUse.CortrolButtonEnabled(toolAdd, this);
     commUse.CortrolButtonEnabled(toolAmend, this);
     commUse.CortrolButtonEnabled(toolDelete, this);
     //ComboBox绑定到数据源
     commUse.BindComboBox(cbxCostTypeCode, "CostTypeCode", "CostTypeName", "select * from BSCostType", "BSCostType");
     //DataGridViewComboBoxColumn绑定到数据源
     commUse.BindComboBox(this.dgvCostInfo.Columns[2], "CostTypeCode", "CostTypeName", "select * from BSCostType", "BSCostType");
     BindDataGridView("");
     this.BindToolStripComboBox();
     this.cbxCondition.SelectedIndex = 0;
     toolStrip1.Tag = "";
 }
示例#13
0
        private void FormBrowsePRPlan_Load(object sender, EventArgs e)
        {
            formPRProduce = (FormPRProduce)this.Owner;
            //DataGridViewComboBoxColumn绑定到数据源
            commUse.BindComboBox(this.dgvPRPlanInfo.Columns["OperatorCode"], "OperatorCode", "OperatorName", "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(this.dgvPRPlanInfo.Columns["InvenCode"], "InvenCode", "InvenName", "select InvenCode,InvenName from BSInven", "BSInven");
            commUse.BindComboBox(this.dgvPRPlanInfo.Columns["IsFlag"], "Code", "Name", "select * from INCheckFlag", "INCheckFlag");

            this.BindDataGridView(" WHERE IsFlag = '1'");

            if (dgvPRPlanInfo.RowCount <= 0)
            {
                gbInfo.Text = "无已审核订单";
            }
        }
示例#14
0
 private void FormInitStock_Load(object sender, EventArgs e)
 {
     //权限
     commUse.CortrolButtonEnabled(toolAdd, this);
     commUse.CortrolButtonEnabled(toolAmend, this);
     commUse.CortrolButtonEnabled(toolDelete, this);
     //ComboBox绑定到数据源
     commUse.BindComboBox(cbxStoreCode, "StoreCode", "StoreName", "select StoreCode,StoreName from BSStore", "BSStore");
     commUse.BindComboBox(cbxInvenCode, "InvenCode", "InvenName", "select InvenCode,InvenName from BSInven", "BSInven");
     //DataGridViewComboBoxColumn绑定到数据源
     commUse.BindComboBox(this.dgvStockInfo.Columns[0], "StoreCode", "StoreName", "select StoreCode,StoreName from BSStore", "BSStore");
     commUse.BindComboBox(this.dgvStockInfo.Columns[1], "InvenCode", "InvenName", "select InvenCode,InvenName from BSInven", "BSInven");
     BindDataGridView("");
     toolStrip1.Tag = "";
 }
示例#15
0
 private void FormStore_Load(object sender, EventArgs e)
 {
     //权限
     commUse.CortrolButtonEnabled(toolAdd, this);
     commUse.CortrolButtonEnabled(toolAmend, this);
     commUse.CortrolButtonEnabled(toolDelete, this);
     //ComboBox绑定到数据源
     commUse.BindComboBox(cbxEmployeeCode, "EmployeeCode", "EmployeeName", "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
     //DataGridViewComboBoxColumn绑定到数据源
     commUse.BindComboBox(this.dgvStoreInfo.Columns[3], "EmployeeCode", "EmployeeName", "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
     //
     BindDataGridView("");
     this.BindToolStripComboBox();
     this.cbxCondition.SelectedIndex = 0;
     toolStrip1.Tag = "";
 }
        private void FormSTReturnBrowseProduce_Load(object sender, EventArgs e)
        {
            formSTReturnMaterial = (FormSTReturnMaterial)Owner;
            //DataGridViewComboBoxColumn绑定到数据源
            commUse.BindComboBox(dgvPRProduceInfo.Columns["OperatorCode"], "OperatorCode", "OperatorName",
                                 "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(dgvPRProduceInfo.Columns["DepartmentCode"], "DepartmentCode", "DepartmentName",
                                 "select DepartmentCode,DepartmentName from BSDepartment", "BSDepartment");
            commUse.BindComboBox(dgvPRProduceInfo.Columns["InvenCode"], "InvenCode", "InvenName",
                                 "select InvenCode,InvenName from BSInven", "BSInven");
            commUse.BindComboBox(dgvPRProduceInfo.Columns["EmployeeCode"], "EmployeeCode", "EmployeeName",
                                 "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
            commUse.BindComboBox(dgvPRProduceInfo.Columns["IsFlag"], "Code", "Name", "select * from INCheckFlag",
                                 "INCheckFlag");
            commUse.BindComboBox(dgvPRProduceInfo.Columns["IsComplete"], "Code", "Name", "select * from INCheckFlag",
                                 "INCheckFlag");
            commUse.BindComboBox(dgvPRProduceItemInfo.Columns["InvenCode_Item"], "InvenCode", "InvenName",
                                 "select InvenCode,InvenName from BSInven", "BSInven");
            //
            BindDataGridView(" WHERE IsFlag = '1'", "PRProduce", dgvPRProduceInfo);

            if (dgvPRProduceInfo.RowCount > 0)
            {
                string strPRProduceCode = dgvPRProduceInfo["PRProduceCode", 0].Value.ToString();
                BindDataGridView(" WHERE PRProduceCode =  '" + strPRProduceCode + "'", "PRProduceItem",
                                 dgvPRProduceItemInfo);
            }
        }
示例#17
0
 private void FormCustomerCourse_Load(object sender, EventArgs e)
 {
     //权限
     commUse.CortrolButtonEnabled(toolAdd, this);
     commUse.CortrolButtonEnabled(toolAmend, this);
     commUse.CortrolButtonEnabled(toolDelete, this);
     //dgvSell的DataGridViewComboBoxColumn绑定到数据源
     commUse.BindComboBox(dgvSell.Columns["CustomerCode_Sell"], "CustomerCode", "CustomerName",
                          "Select CustomerCode,CustomerName From BSCustomer", "BSCustomer");
     commUse.BindComboBox(dgvSell.Columns["ChanceCode"], "ChanceCode", "ChanceName",
                          "Select ChanceCode,ChanceName From CUChance", "CUChance");
     commUse.BindComboBox(dgvSell.Columns["InvenCode"], "InvenCode", "InvenName",
                          "Select InvenCode,InvenName From BSInven", "BSInven");
     //dgvRel的DataGridViewComboBoxColumn绑定到数据源
     commUse.BindComboBox(dgvRel.Columns["CustomerCode_Rel"], "CustomerCode", "CustomerName",
                          "Select CustomerCode,CustomerName From BSCustomer", "BSCustomer");
     commUse.BindComboBox(dgvRel.Columns["RelManner"], "Code", "Name", "select Code,Name from INRelManner",
                          "INRelManner");
     //dgvAfter的DataGridViewComboBoxColumn绑定到数据源
     commUse.BindComboBox(dgvAfter.Columns["CustomerCode_After"], "CustomerCode", "CustomerName",
                          "Select CustomerCode,CustomerName From BSCustomer", "BSCustomer");
     commUse.BindComboBox(dgvAfter.Columns["EmployeeCode"], "EmployeeCode", "EmployeeName",
                          "Select EmployeeCode,EmployeeName From BSEmployee", "BSEmployee");
     //tvCustomer绑定到数据源
     commUse.BuildTree(tvCustomer, imageList1, "客户信息", "BSCustomer", "CustomerCode", "CustomerName");
 }
 private void FormSelProfitCollectReport_Load(object sender, EventArgs e)
 {
     //设置用户的操作权限
     commUse.CortrolButtonEnabled(btnQuery, this);
     //ComboBox绑定到数据源
     commUse.BindComboBox(cbxInvenCode, "InvenCode", "InvenName", "select InvenCode,InvenName from BSInven", "BSInven");
     //设置产品默认不选择任何项
     cbxInvenCode.SelectedIndex = -1;
 }
示例#19
0
        private void FormAccount_Load(object sender, EventArgs e)
        {
            //权限
            commUse.CortrolButtonEnabled(toolAdd, this);
            commUse.CortrolButtonEnabled(toolAmend, this);
            commUse.CortrolButtonEnabled(toolDelete, this);

            //ComboBox绑定到数据源
            commUse.BindComboBox(cbxAccSubject, "Code", "Name", "select * from INAccSubject", "INAccSubject");

            //DataGridViewComboBoxColumn绑定到数据源
            commUse.BindComboBox(dgvAccountInfo.Columns[3], "Code", "Name", "select * from INAccSubject", "INAccSubject");
            //
            BindDataGridView("");
            BindToolStripComboBox();
            cbxCondition.SelectedIndex = 0;
            toolStrip1.Tag             = "";
        }
示例#20
0
 private void FormAssignRight_Load(object sender, EventArgs e)
 {
     //权限控制
     commUse.CortrolButtonEnabled(toolSave, this);
     //绑定到数据源
     commUse.BuildTree(tvOperator, imageList1, "操作员", "SYOperator Where IsAdmin <> '1'", "OperatorCode", "OperatorName");
     commUse.BuildTree(tvModule, imageList1, "功能模块", "INModule", "ModuleTag", "ModuleName");
     commUse.BindComboBox(dgvINRightInfo.Columns["RightTag"], "RightTag", "RightName", "Select RightTag,RightName From INRight", "INRight");
 }
示例#21
0
        private void FormBrowseSEOrder_Load(object sender, EventArgs e)
        {
            if (Owner.GetType() == typeof(FormSEOutStore))
            {
                formSEOutStore = (FormSEOutStore)Owner;
            }

            if (Owner.GetType() == typeof(FormPRPlan))
            {
                formPRPlan = (FormPRPlan)Owner;
            }

            commUse.BindComboBox(dgvSEOrderInfo.Columns["OperatorCode"], "OperatorCode", "OperatorName",
                                 "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(dgvSEOrderInfo.Columns["CustomerCode"], "CustomerCode", "CustomerName",
                                 "select CustomerCode,CustomerName from BSCustomer", "BSCustomer");
            commUse.BindComboBox(dgvSEOrderInfo.Columns["StoreCode"], "StoreCode", "StoreName",
                                 "select StoreCode,StoreName from BSStore", "BSStore");
            commUse.BindComboBox(dgvSEOrderInfo.Columns["InvenCode"], "InvenCode", "InvenName",
                                 "select InvenCode,InvenName from BSInven", "BSInven");
            commUse.BindComboBox(dgvSEOrderInfo.Columns["EmployeeCode"], "EmployeeCode", "EmployeeName",
                                 "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
            commUse.BindComboBox(dgvSEOrderInfo.Columns["IsFlag"], "Code", "Name", "select * from INCheckFlag",
                                 "INCheckFlag");

            BindDataGridView(" WHERE IsFlag = '1'");

            if (dgvSEOrderInfo.RowCount <= 0)
            {
                gbInfo.Text = "无已审核订单";
            }
        }
示例#22
0
        private void FormBrowsePRProduce_Load(object sender, EventArgs e)
        {
            string strSql = null;

            if (Owner.GetType() == typeof(FormProduceComplete))
            {
                formProduceComplete = (FormProduceComplete)Owner;
                strSql = "Select * From PRProduce Where IsFlag = '1'";
                Text   = "浏览已审核生产单";
            }

            if (Owner.GetType() == typeof(FormPRInStore))
            {
                formPRInStore = (FormPRInStore)Owner;
                strSql        = "Select * From PRProduce Where IsComplete = '1'"; //完工的,一定是审核的
                Text          = "浏览完工生产单";
            }

            //DataGridViewComboBoxColumn绑定到数据源
            commUse.BindComboBox(dgvPRProduceInfo.Columns["OperatorCode"], "OperatorCode", "OperatorName",
                                 "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(dgvPRProduceInfo.Columns["DepartmentCode"], "DepartmentCode", "DepartmentName",
                                 "select DepartmentCode,DepartmentName from BSDepartment", "BSDepartment");
            commUse.BindComboBox(dgvPRProduceInfo.Columns["InvenCode"], "InvenCode", "InvenName",
                                 "select InvenCode,InvenName from BSInven", "BSInven");
            commUse.BindComboBox(dgvPRProduceInfo.Columns["EmployeeCode"], "EmployeeCode", "EmployeeName",
                                 "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
            commUse.BindComboBox(dgvPRProduceInfo.Columns["IsFlag"], "Code", "Name", "select * from INCheckFlag",
                                 "INCheckFlag");
            commUse.BindComboBox(dgvPRProduceInfo.Columns["IsComplete"], "Code", "Name", "select * from INCheckFlag",
                                 "INCheckFlag");

            BindDataGridView(strSql, "PRProduce", dgvPRProduceInfo);
        }
示例#23
0
 private void FormSYOperator_Load(object sender, EventArgs e)
 {
     //设置权限
     commUse.CortrolButtonEnabled(toolAdd, this);
     commUse.CortrolButtonEnabled(toolAmend, this);
     commUse.CortrolButtonEnabled(toolDelete, this);
     //绑定到数据源
     commUse.BindComboBox(this.dgvSYOperatorInfo.Columns["IsAdmin"], "Code", "Name", "select * from INCheckFlag", "INCheckFlag");
     BindDataGridView("");
     this.BindToolStripComboBox();
     this.cbxCondition.SelectedIndex = 0;
     toolStrip1.Tag = "";
 }
示例#24
0
        private void FormCUAfterService_Load(object sender, EventArgs e)
        {
            formCustomerCourse = (FormCustomerCourse)Owner;
            commUse.BindComboBox(cbxCustomerCode, "CustomerCode", "CustomerName",
                                 "select CustomerCode,CustomerName from BSCustomer", "BSCustomer");
            commUse.BindComboBox(cbxEmployeeCode, "EmployeeCode", "EmployeeName",
                                 "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
            cbxCustomerCode.SelectedValue = formCustomerCourse.tvCustomer.SelectedNode.Tag;

            if (Tag.ToString() == "Add") //添加操作
            {
                cbxEmployeeCode.SelectedIndex = -1;
                dtpSerDate.Value = DateTime.Today;
            }

            if (Tag.ToString() == "Edit") //修改操作
            {
                dtpSerDate.Value =
                    Convert.ToDateTime(
                        formCustomerCourse.dgvAfter["SerDate", formCustomerCourse.dgvAfter.CurrentRow.Index].Value);
                cbxEmployeeCode.SelectedValue =
                    formCustomerCourse.dgvAfter["EmployeeCode", formCustomerCourse.dgvAfter.CurrentRow.Index].Value;
                txtLinkman.Text =
                    formCustomerCourse.dgvAfter["Linkman_After", formCustomerCourse.dgvAfter.CurrentRow.Index].Value.
                    ToString();
                txtTelephoneCode.Text =
                    formCustomerCourse.dgvAfter["TelephoneCode_After", formCustomerCourse.dgvAfter.CurrentRow.Index].
                    Value.ToString();
                txtSerDays.Text =
                    formCustomerCourse.dgvAfter["SerDays", formCustomerCourse.dgvAfter.CurrentRow.Index].Value.ToString();
                rtbSerContent.Text =
                    formCustomerCourse.dgvAfter["SerContent", formCustomerCourse.dgvAfter.CurrentRow.Index].Value.
                    ToString();
                rtbResolvent.Text =
                    formCustomerCourse.dgvAfter["Resolvent", formCustomerCourse.dgvAfter.CurrentRow.Index].Value.
                    ToString();
            }
        }
示例#25
0
        private void FormBrowsePUOrder_Load(object sender, EventArgs e)
        {
            formPUInStore = (FormPUInStore)this.Owner;

            commUse.BindComboBox(this.dgvPUOrderInfo.Columns[2], "OperatorCode", "OperatorName", "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(this.dgvPUOrderInfo.Columns[3], "SupplierCode", "SupplierName", "select SupplierCode,SupplierName from BSSupplier", "BSSupplier");
            commUse.BindComboBox(this.dgvPUOrderInfo.Columns[4], "StoreCode", "StoreName", "select StoreCode,StoreName from BSStore", "BSStore");
            commUse.BindComboBox(this.dgvPUOrderInfo.Columns[5], "InvenCode", "InvenName", "select InvenCode,InvenName from BSInven", "BSInven");
            commUse.BindComboBox(this.dgvPUOrderInfo.Columns[10], "EmployeeCode", "EmployeeName", "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
            commUse.BindComboBox(this.dgvPUOrderInfo.Columns[11], "Code", "Name", "select * from INCheckFlag", "INCheckFlag");

            this.BindDataGridView(" WHERE IsFlag = '1'");

            if (dgvPUOrderInfo.RowCount <= 0)
            {
                gbInfo.Text = "无已审核订单";
            }
        }
        private void FormBrowseSEOutStore_Load(object sender, EventArgs e)
        {
            formSEGather = (FormSEGather)this.Owner;

            commUse.BindComboBox(this.dgvSEOutStoreInfo.Columns["OperatorCode"], "OperatorCode", "OperatorName", "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(this.dgvSEOutStoreInfo.Columns["CustomerCode"], "CustomerCode", "CustomerName", "select CustomerCode,CustomerName from BSCustomer", "BSCustomer");
            commUse.BindComboBox(this.dgvSEOutStoreInfo.Columns["StoreCode"], "StoreCode", "StoreName", "select StoreCode,StoreName from BSStore", "BSStore");
            commUse.BindComboBox(this.dgvSEOutStoreInfo.Columns["InvenCode"], "InvenCode", "InvenName", "select InvenCode,InvenName from BSInven", "BSInven");
            commUse.BindComboBox(this.dgvSEOutStoreInfo.Columns["EmployeeCode"], "EmployeeCode", "EmployeeName", "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
            commUse.BindComboBox(this.dgvSEOutStoreInfo.Columns["IsFlag"], "Code", "Name", "select * from INCheckFlag", "INCheckFlag");

            this.BindDataGridView(" WHERE IsFlag = '1'");

            if (dgvSEOutStoreInfo.RowCount <= 0)
            {
                gbInfo.Text = "无已审核销售出库单";
            }
        }
示例#27
0
        private void FormBrowseSEOutStore_Load(object sender, EventArgs e)
        {
            //获取拥有已审核的销售出库单窗体的窗体,即销售收款单窗体
            formSEGather = (FormSEGather)this.Owner;
            //DataGridView控件的相关列绑定到数据源(包括操作员、客户名称、物料名称、仓库、员工名称、审核标记)
            commUse.BindComboBox(this.dgvSEOutStoreInfo.Columns["OperatorCode"], "OperatorCode", "OperatorName", "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(this.dgvSEOutStoreInfo.Columns["CustomerCode"], "CustomerCode", "CustomerName", "select CustomerCode,CustomerName from BSCustomer", "BSCustomer");
            commUse.BindComboBox(this.dgvSEOutStoreInfo.Columns["StoreCode"], "StoreCode", "StoreName", "select StoreCode,StoreName from BSStore", "BSStore");
            commUse.BindComboBox(this.dgvSEOutStoreInfo.Columns["InvenCode"], "InvenCode", "InvenName", "select InvenCode,InvenName from BSInven", "BSInven");
            commUse.BindComboBox(this.dgvSEOutStoreInfo.Columns["EmployeeCode"], "EmployeeCode", "EmployeeName", "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
            commUse.BindComboBox(this.dgvSEOutStoreInfo.Columns["IsFlag"], "Code", "Name", "select * from INCheckFlag", "INCheckFlag");

            this.BindDataGridView(" WHERE IsFlag = '1'"); //检索已审核的销售出库单

            if (dgvSEOutStoreInfo.RowCount <= 0)          //若无数据行,则系统给与提示信息
            {
                gbInfo.Text = "无已审核销售出库单";
            }
        }
示例#28
0
 private void FormEmployee_Load(object sender, EventArgs e)
 {
     //权限
     commUse.CortrolButtonEnabled(toolAdd, this);
     commUse.CortrolButtonEnabled(toolAmend, this);
     commUse.CortrolButtonEnabled(toolDelete, this);
     //ComboBox绑定到数据源
     commUse.BindComboBox(cbxDepartmentCode, "DepartmentCode", "DepartmentName", "select DepartmentCode,DepartmentName from BSDepartment", "BSDepartment");
     commUse.BindComboBox(cbxSex, "Code", "Name", "select * from INSex", "INSex");
     commUse.BindComboBox(cbxEduLevel, "Code", "Name", "select * from INEduLevel", "INEduLevel");
     //DataGridViewComboBoxColumn绑定到数据源
     commUse.BindComboBox(this.dgvEmployeeInfo.Columns[2], "DepartmentCode", "DepartmentName", "select DepartmentCode,DepartmentName from BSDepartment", "BSDepartment");
     commUse.BindComboBox(this.dgvEmployeeInfo.Columns[4], "Code", "Name", "select * from INSex", "INSex");
     commUse.BindComboBox(this.dgvEmployeeInfo.Columns[5], "Code", "Name", "select * from INEduLevel", "INEduLevel");
     //DataGridView绑定到数据源
     BindDataGridView("");
     this.BindToolStripComboBox();
     this.cbxCondition.SelectedIndex = 0;
     toolStrip1.Tag = "";
 }
示例#29
0
        private void FormFISelCost_Load(object sender, EventArgs e)
        {
            //权限
            commUse.CortrolButtonEnabled(toolAdd, this);
            commUse.CortrolButtonEnabled(toolAmend, this);
            commUse.CortrolButtonEnabled(toolDelete, this);
            commUse.CortrolButtonEnabled(toolCheck, this);
            commUse.CortrolButtonEnabled(toolUnCheck, this);

            //ComboBox绑定到数据源
            commUse.BindComboBox(cbxOperatorCode, "OperatorCode", "OperatorName", "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(cbxCustomerCode, "CustomerCode", "CustomerName", "select CustomerCode,CustomerName from BSCustomer", "BSCustomer");
            commUse.BindComboBox(cbxAccountCode, "AccountCode", "AccountName", "select AccountCode,AccountName from BSAccount", "BSAccount");
            commUse.BindComboBox(cbxEmployeeCode, "EmployeeCode", "EmployeeName", "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
            commUse.BindComboBox(cbxCostCode, "CostCode", "CostName", "select CostCode,CostName from BSCost Where CostTypeCode = '02'", "BSCost");
            commUse.BindComboBox(cbxIsFlag, "Code", "Name", "select * from INCheckFlag", "INCheckFlag");

            //DataGridViewComboBoxColumn绑定到数据源
            commUse.BindComboBox(this.dgvFISelCostInfo.Columns["OperatorCode"], "OperatorCode", "OperatorName", "select OperatorCode,OperatorName from SYOperator", "SYOperator");
            commUse.BindComboBox(this.dgvFISelCostInfo.Columns["CustomerCode"], "CustomerCode", "CustomerName", "select CustomerCode,CustomerName from BSCustomer", "BSCustomer");
            commUse.BindComboBox(this.dgvFISelCostInfo.Columns["AccountCode"], "AccountCode", "AccountName", "select AccountCode,AccountName from BSAccount", "BSAccount");
            commUse.BindComboBox(this.dgvFISelCostInfo.Columns["EmployeeCode"], "EmployeeCode", "EmployeeName", "select EmployeeCode,EmployeeName from BSEmployee", "BSEmployee");
            commUse.BindComboBox(this.dgvFISelCostInfo.Columns["CostCode"], "CostCode", "CostName", "select CostCode,CostName from BSCost Where CostTypeCode = '02'", "BSCost");
            commUse.BindComboBox(this.dgvFISelCostInfo.Columns["IsFlag"], "Code", "Name", "select * from INCheckFlag", "INCheckFlag");

            //DataGridView绑定到数据源
            DataGridViewBindSource("");
            this.BindToolStripComboBox();
            this.cbxCondition.SelectedIndex = 0;
            toolStrip1.Tag = "";
        }