コード例 #1
0
        private void frmYZParameterSet_Load(object sender, EventArgs e)
        {
            commUse.CortrolButtonEnabled(btnADD, this);
            commUse.CortrolButtonEnabled(tsbtnEdit, this);

            getDate(string.Empty, string.Empty);
        }
コード例 #2
0
        private void frmDzpYsTJ_Load(object sender, EventArgs e)
        {//窗体加载
            commUse.CortrolButtonEnabled(btnSelect, this);
            commUse.CortrolButtonEnabled(btnSelMX, this);
            //get con
            if (DB_ID == 4) //修改CZQ 2015-09-16
            {
                ds = db.GetDataSet("SELECT Fdbstr    FROM dbo.YXZTLIST WHERE ID=4", "con");
            }
            else if (DB_ID == 7)
            {
                ds = db.GetDataSet("SELECT Fdbstr    FROM dbo.YXZTLIST WHERE ID=7", "con");
            }
            else if (DB_ID == 17)
            {
                ds = db.GetDataSet("SELECT Fdbstr    FROM dbo.YXZTLIST WHERE ID=17", "con");
            }
            else if (DB_ID == 2)
            {
                ds = db.GetDataSet("SELECT Fdbstr    FROM dbo.YXZTLIST WHERE ID=2", "con");
            }
            string dzpcon = ds.Tables[0].Rows[0]["Fdbstr"].ToString();

            k3db = new DataBase(dzpcon);
            this.txtYear.Text         = DateTime.Now.Year.ToString();
            this.txtMonth.Text        = DateTime.Now.Month.ToString();
            this.radioButton1.Checked = false;
        }
コード例 #3
0
        private void frm_yx_tzjh_Load(object sender, EventArgs e)
        {
            commUse.CortrolButtonEnabled(btnSave, this);
            commUse.CortrolButtonEnabled(btnSel, this);

            commUse.CortrolButtonEnabled(btnEdit, this);


            this.txtA3.Enabled  = false;
            this.txtB3.Enabled  = false;
            this.txtC3.Enabled  = false;
            this.txtD3.Enabled  = false;
            this.txtE3.Enabled  = false;
            this.txtF3.Enabled  = false;
            this.txtG3.Enabled  = false;
            this.txtH3.Enabled  = false;
            this.txtA6.Enabled  = false;
            this.txtB6.Enabled  = false;
            this.dgvMb.ReadOnly = true;
            k3db = new DataBase(conRY);
            if (this.btnSel.Enabled == true)
            {
                btnSel_Click_1(null, null);
            }
        }
コード例 #4
0
 private void frmSpZyd_Load(object sender, EventArgs e)
 {
     commUse.CortrolButtonEnabled(button1, this);
     commUse.CortrolButtonEnabled(button2, this);
     commUse.CortrolButtonEnabled(button4, this);
     commUse.CortrolButtonEnabled(button5, this);
 }
コード例 #5
0
        private void frmWordNote_Load(object sender, EventArgs e)
        {
            commUse.CortrolButtonEnabled(btnBak, this);
            commUse.CortrolButtonEnabled(button1, this);


            //去除委托
            this.comboBox1.SelectedIndexChanged -= new EventHandler(comboBox1_SelectedIndexChanged);
            //绑定数据
            this.comboBox1.DataSource = db.GetDataTable("  SELECT ID,FName FROM dbo.YXZTLIST WHERE ftype='K3'  ORDER BY Forderid  ", "tab");
            comboBox1.DisplayMember   = "FName"; //显示内容
            comboBox1.ValueMember     = "ID";    //选项对应的value

            //添加委托
            this.comboBox1.SelectedIndexChanged += new EventHandler(comboBox1_SelectedIndexChanged);
            this.comboBox1.DisplayMember         = "DisplayColumn";

            //初始为第一个帐套
            ds = db.GetDataSet("SELECT FName,Fdbstr    FROM dbo.YXZTLIST WHERE ID=1", "con");
            DataRow dr = ds.Tables[0].Rows[0];

            this.label1.Text = dr["FName"].ToString() + "-账套日志管理";
            k3constr         = dr["Fdbstr"].ToString();
            ztID             = this.comboBox1.SelectedValue.ToString();
        }
コード例 #6
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");
 }
コード例 #7
0
 private void frm_YX_ICitemSet_Load(object sender, EventArgs e)
 {
     this.ftype = "EDIT";
     commUse.CortrolButtonEnabled(btnSave, this);
     commUse.CortrolButtonEnabled(btnSelect, this);
     commUse.CortrolButtonEnabled(BtnAdd, this);
 }
コード例 #8
0
 private void FormDepartment_Load(object sender, EventArgs e)
 {
     //权限
     commUse.CortrolButtonEnabled(btnAdd, this);
     commUse.CortrolButtonEnabled(btnAmend, this);
     commUse.CortrolButtonEnabled(btnDelete, this);
     commUse.BuildTree(tvDepartment, imageList1, "部门分类", "BSDepartment", "DepartmentCode", "DepartmentName");
 }
コード例 #9
0
        private void FrmRYmdseorder_Load(object sender, EventArgs e)
        {
            commUse.CortrolButtonEnabled(btnSelect, this);
            commUse.CortrolButtonEnabled(btnOutput, this);
            commUse.CortrolButtonEnabled(btnBselect, this);


            // ds = null;
        }
コード例 #10
0
ファイル: FormBSInvenType.cs プロジェクト: ROUSAN-TANG/ERP
 private void FormInvenType_Load(object sender, EventArgs e)
 {
     //权限
     commUse.CortrolButtonEnabled(btnAdd, this);
     commUse.CortrolButtonEnabled(btnAmend, this);
     commUse.CortrolButtonEnabled(btnDelete, this);
     //TreeView绑定到数据源
     commUse.BuildTree(tvInvenType, imageList1, "存货分类", "BSInvenType", "InvenTypeCode", "InvenTypeName");
 }
コード例 #11
0
ファイル: FormBaseType.cs プロジェクト: ROUSAN-TANG/ERP
 private void FormBaseType_Load(object sender, EventArgs e)
 {
     ////权限
     commUse.CortrolButtonEnabled(toolAdd, this);
     commUse.CortrolButtonEnabled(toolAmend, this);
     commUse.CortrolButtonEnabled(toolDelete, this);
     //TreeView绑定到数据源
     commUse.BuildTree(tvBaseType, imageList1, "基础分类", "INBaseType", "Code", "Name");
 }
コード例 #12
0
 private void FormBom_Load(object sender, EventArgs e)
 {
     //设置用户的操作权限
     commUse.CortrolButtonEnabled(toolAdd, this);
     commUse.CortrolButtonEnabled(toolAmend, this);
     commUse.CortrolButtonEnabled(toolDelete, this);
     //TreeView绑定到数据源,显示现有的母件
     commUse.BuildTree(tvInven, imageList1, "母件", "V_BomStruct", "InvenCode", "InvenName");
 }
コード例 #13
0
        private void frm_yx_zydpsmxb_Load(object sender, EventArgs e)
        {
            ds = db.GetDataSet("SELECT Fdbstr    FROM dbo.YXZTLIST WHERE ID=1", "con");
            DataRow dr = ds.Tables[0].Rows[0];

            conSp = dr["Fdbstr"].ToString();
            k3db  = new DataBase(conSp);
            commUse.CortrolButtonEnabled(btnSel, this);
            commUse.CortrolButtonEnabled(btnOut, this);
        }
コード例 #14
0
        private void frm_yx_EmpJS_Load(object sender, EventArgs e)
        {
            commUse.CortrolButtonEnabled(btnSave, this);
            commUse.CortrolButtonEnabled(btnSel, this);
            commUse.CortrolButtonEnabled(btnEdit, this);
            k3db = new DataBase(conSp);

            if (this.btnSel.Enabled == true)
            {
                btnSel_Click(null, null);
            }
        }
コード例 #15
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");
        }
コード例 #16
0
        private void frmOrderList_Load(object sender, EventArgs e)
        {//窗体加载
            //权限控制
            commUse.CortrolButtonEnabled(btnSel, this);
            commUse.CortrolButtonEnabled(tsbtnSel, this);
            commUse.CortrolButtonEnabled(tsbtnOut, this);
            commUse.CortrolButtonEnabled(tsbtnEnter, this);
            commUse.CortrolButtonEnabled(tsbtnFenter, this);
            commUse.CortrolButtonEnabled(tsbtnFcheck, this);
            commUse.CortrolButtonEnabled(tsbtnCheck, this);//
            commUse.CortrolButtonEnabled(tsbtnDel, this);

            if (this.ZtType == "M")
            {
                label3.Text = "门店";
                label7.Text = "区域";

                label9.Visible            = true;
                this.cbmOrderType.Visible = true;


                label10.Text = "门店负责人";
            }



            if (this.btnSel.Enabled == true)
            {
                Selstr = "SELECT TOP 100  * FROM " + this.vwname + " ORDER BY Finterid desc ";
                dgv_addDatabase();
            }
        }
コード例 #17
0
ファイル: FormPRPlan.cs プロジェクト: ROUSAN-TANG/ERP
 private void ControlStatus()
 {
     //工具栏按钮状态切换
     this.toolSave.Enabled   = !this.toolSave.Enabled;
     this.toolCancel.Enabled = !this.toolCancel.Enabled;
     commUse.CortrolButtonEnabled(toolAdd, this);
     commUse.CortrolButtonEnabled(toolAmend, this);
     commUse.CortrolButtonEnabled(toolDelete, this);
     commUse.CortrolButtonEnabled(toolCheck, this);
     commUse.CortrolButtonEnabled(toolUnCheck, this);
     //窗体控件状态切换
     this.btnChoice.Enabled     = !this.btnChoice.Enabled;
     this.cbxInvenCode.Enabled  = !this.cbxInvenCode.Enabled;
     this.txtQuantity.ReadOnly  = !this.txtQuantity.ReadOnly;
     this.dtpFinishDate.Enabled = !this.dtpFinishDate.Enabled;
 }
コード例 #18
0
 private void frm_ry_orderMary_Load(object sender, EventArgs e)
 {
     //ds = db.GetDataSet("SELECT Fdbstr    FROM dbo.YXZTLIST WHERE ID=2", "con");
     //DataRow dr = ds.Tables[0].Rows[0];
     //conRY = dr["Fdbstr"].ToString();
     k3db = new DataBase(DataBase.m_Connstr);
     commUse.CortrolButtonEnabled(btnSel, this);
 }
コード例 #19
0
ファイル: FormSTCheck.cs プロジェクト: randianb/DownLoadDemo
        private void ControlStatus()
        {
            //工具栏按钮状态切换
            this.toolSave.Enabled   = !this.toolSave.Enabled;
            this.toolCancel.Enabled = !this.toolCancel.Enabled;
            commUse.CortrolButtonEnabled(toolAdd, this);
            commUse.CortrolButtonEnabled(toolAmend, this);
            commUse.CortrolButtonEnabled(toolDelete, this);
            commUse.CortrolButtonEnabled(toolCheck, this);
            commUse.CortrolButtonEnabled(toolUnCheck, this);

            //窗体控件状态切换
            this.cbxStoreCode.Enabled      = !this.cbxStoreCode.Enabled;
            this.cbxInvenCode.Enabled      = !this.cbxInvenCode.Enabled;
            this.txtCheckQuantity.ReadOnly = !this.txtCheckQuantity.ReadOnly;
            this.cbxEmployeeCode.Enabled   = !this.cbxEmployeeCode.Enabled;
        }
コード例 #20
0
 private void FormSelProfitReport_Load(object sender, EventArgs e)
 {
     //权限
     commUse.CortrolButtonEnabled(btnQuery, this);
     //ComboBox绑定到数据源
     commUse.BindComboBox(cbxInvenCode, "InvenCode", "InvenName", "select InvenCode,InvenName from BSInven", "BSInven");
     cbxInvenCode.SelectedIndex = -1;
 }
コード例 #21
0
 private void ControlStatus()
 {
     //工具栏按钮状态切换
     this.toolSave.Enabled   = !this.toolSave.Enabled;
     this.toolCancel.Enabled = !this.toolCancel.Enabled;
     commUse.CortrolButtonEnabled(toolAdd, this);
     commUse.CortrolButtonEnabled(toolAmend, this);
     commUse.CortrolButtonEnabled(toolDelete, this);
     commUse.CortrolButtonEnabled(toolCheck, this);
     commUse.CortrolButtonEnabled(toolUnCheck, this);
     //窗体控件状态切换
     this.cbxOutAccCode.Enabled   = !this.cbxOutAccCode.Enabled;
     this.cbxInAccCode.Enabled    = !this.cbxInAccCode.Enabled;
     this.txtFIMoney.ReadOnly     = !this.txtFIMoney.ReadOnly;
     this.cbxEmployeeCode.Enabled = !this.cbxEmployeeCode.Enabled;
     this.txtRemark.ReadOnly      = !this.txtRemark.ReadOnly;
 }
コード例 #22
0
        private void ControlStatus()
        {
            //工具栏按钮状态切换
            toolSave.Enabled   = !toolSave.Enabled;
            toolCancel.Enabled = !toolCancel.Enabled;
            commUse.CortrolButtonEnabled(toolAdd, this);
            commUse.CortrolButtonEnabled(toolAmend, this);
            commUse.CortrolButtonEnabled(toolDelete, this);
            commUse.CortrolButtonEnabled(toolCheck, this);
            commUse.CortrolButtonEnabled(toolUnCheck, this);

            //窗体控件状态切换
            btnChoice.Enabled       = !btnChoice.Enabled;
            cbxStoreCode.Enabled    = !cbxStoreCode.Enabled;
            txtQuantity.ReadOnly    = !txtQuantity.ReadOnly;
            cbxEmployeeCode.Enabled = !cbxEmployeeCode.Enabled;
        }
コード例 #23
0
ファイル: FormPRProduce.cs プロジェクト: eksotama/SmallERP
        private void ControlStatus()
        {
            //工具栏按钮状态切换
            toolSave.Enabled   = !toolSave.Enabled;
            toolCancel.Enabled = !toolCancel.Enabled;
            commUse.CortrolButtonEnabled(toolAdd, this);
            commUse.CortrolButtonEnabled(toolAmend, this);
            commUse.CortrolButtonEnabled(toolDelete, this);
            commUse.CortrolButtonEnabled(toolCheck, this);
            commUse.CortrolButtonEnabled(toolUnCheck, this);

            //窗体控件状态切换
            btnChoice.Enabled         = !btnChoice.Enabled;
            cbxDepartmentCode.Enabled = !cbxDepartmentCode.Enabled;
            txtQuantity.ReadOnly      = !txtQuantity.ReadOnly;
            dtpStartDate.Enabled      = !dtpStartDate.Enabled;
            dtpEndDate.Enabled        = !dtpEndDate.Enabled;
        }
コード例 #24
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");
 }
コード例 #25
0
        private void ControlStatus()
        {
            //工具栏按钮状态切换
            this.toolSave.Enabled   = !this.toolSave.Enabled;
            this.toolCancel.Enabled = !this.toolCancel.Enabled;
            commUse.CortrolButtonEnabled(toolAdd, this);
            commUse.CortrolButtonEnabled(toolAmend, this);
            commUse.CortrolButtonEnabled(toolDelete, this);
            commUse.CortrolButtonEnabled(toolCheck, this);
            commUse.CortrolButtonEnabled(toolUnCheck, this);

            //窗体控件状态切换
            //this.txtPUInCode.ReadOnly = !this.txtPUInCode.ReadOnly;
            this.btnChoice.Enabled       = !this.btnChoice.Enabled;
            this.txtPUMoney.ReadOnly     = !this.txtPUMoney.ReadOnly;
            this.cbxAccountCode.Enabled  = !this.cbxAccountCode.Enabled;
            this.cbxEmployeeCode.Enabled = !this.cbxEmployeeCode.Enabled;
            this.txtRemark.ReadOnly      = !this.txtRemark.ReadOnly;
        }
コード例 #26
0
 bool bSEL = false;         //查询权限
 private void LoadPower()
 {
     commUse.CortrolButtonEnabled(button1, this);
     commUse.CortrolButtonEnabled(btnADD, this);
     commUse.CortrolButtonEnabled(tsbtnEdit, this);
     commUse.CortrolButtonEnabled(btnDelete, this);
     commUse.CortrolButtonEnabled(btnCheck, this);
     commUse.CortrolButtonEnabled(btnHcheck, this);
     commUse.CortrolButtonEnabled(btnExport, this);
     commUse.CortrolButtonEnabled(btnConfirmer, this);
     bSEL = button1.Enabled;
 }
コード例 #27
0
 private void ControlStatus()
 {
     //工具栏按钮状态切换
     toolSave.Enabled   = !toolSave.Enabled;
     toolCancel.Enabled = !toolCancel.Enabled;
     commUse.CortrolButtonEnabled(toolAdd, this);
     commUse.CortrolButtonEnabled(toolAmend, this);
     commUse.CortrolButtonEnabled(toolDelete, this);
     commUse.CortrolButtonEnabled(toolCheck, this);
     commUse.CortrolButtonEnabled(toolUnCheck, this);
     //窗体控件状态切换
     cbxSupplierCode.Enabled = !cbxSupplierCode.Enabled;
     cbxStoreCode.Enabled    = !cbxStoreCode.Enabled;
     cbxInvenCode.Enabled    = !cbxInvenCode.Enabled;
     txtUnitPrice.ReadOnly   = !txtUnitPrice.ReadOnly;
     txtQuantity.ReadOnly    = !txtQuantity.ReadOnly;
     dtpRecInvenDate.Enabled = !dtpRecInvenDate.Enabled;
     cbxEmployeeCode.Enabled = !cbxEmployeeCode.Enabled;
 }
コード例 #28
0
ファイル: FormFISelCost.cs プロジェクト: eksotama/SmallERP
        private void ControlStatus()
        {
            //工具栏按钮状态切换
            toolSave.Enabled   = !toolSave.Enabled;
            toolCancel.Enabled = !toolCancel.Enabled;
            commUse.CortrolButtonEnabled(toolAdd, this);
            commUse.CortrolButtonEnabled(toolAmend, this);
            commUse.CortrolButtonEnabled(toolDelete, this);
            commUse.CortrolButtonEnabled(toolCheck, this);
            commUse.CortrolButtonEnabled(toolUnCheck, this);

            //窗体控件状态切换
            cbxCustomerCode.Enabled = !cbxCustomerCode.Enabled;
            cbxAccountCode.Enabled  = !cbxAccountCode.Enabled;
            cbxEmployeeCode.Enabled = !cbxEmployeeCode.Enabled;
            cbxCostCode.Enabled     = !cbxCostCode.Enabled;
            txtFIMoney.ReadOnly     = !txtFIMoney.ReadOnly;
            txtRemark.ReadOnly      = !txtRemark.ReadOnly;
        }
コード例 #29
0
 private void FormStockQuery_Load(object sender, EventArgs e)
 {
     //权限
     commUse.CortrolButtonEnabled(toolQuery, 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;
 }
コード例 #30
0
        private void frmOrderList_Load(object sender, EventArgs e)
        {
            //窗体加载
            //权限控制
            commUse.CortrolButtonEnabled(btnSel, this);      //查询
            commUse.CortrolButtonEnabled(tsbtnSel, this);    //查看
            commUse.CortrolButtonEnabled(tsbtnCheck, this);  // 审核
            commUse.CortrolButtonEnabled(tsbtnFcheck, this); //反审核
            commUse.CortrolButtonEnabled(tsbtnDel, this);    //删除

            //commUse.CortrolButtonEnabled(tsbtnOut, this);  //导出
            //commUse.CortrolButtonEnabled(tsbtnEnter, this); //确认
            //commUse.CortrolButtonEnabled(tsbtnFenter, this); //反确认

            if (this.btnSel.Enabled == true)
            {
                Selstr = "SELECT TOP 100  * FROM " + this.vwname + " ORDER BY Finterid desc ";
                dgv_addDatabase();
            }
        }