예제 #1
0
 private void LoadCabinet()
 {
     try {
         if (Clsxtpz.myHouseID == 0)
         {
             return;
         }
         DataTable dt = T_Sysset.GetHouseGui(Clsxtpz.myHouseID);
         if (dt == null || dt.Rows.Count <= 0)
         {
             return;
         }
         this.lsvCabinet.Items.Clear();
         int i = 1;
         foreach (DataRow dr in dt.Rows)
         {
             ListViewItem lvi = new ListViewItem();
             lvi.Text = dr["HouseGui"].ToString();
             lvi.SubItems.AddRange(new string[] { dr["HouseCol"].ToString(), dr["HouseRow"].ToString(), dr["HoseBoxCount"].ToString(), dr["HouseJuan"].ToString(), dr["ID"].ToString() });
             this.lsvCabinet.Items.Add(lvi);
             i++;
         }
     } catch (Exception ee) {
         MessageBox.Show(ee.ToString());
     }
 }
예제 #2
0
 private void lsvCabinet_Click(object sender, EventArgs e)
 {
     try {
         int imgboxq = 1;
         if (lsvCabinet.SelectedItems != null && lsvCabinet.SelectedItems.Count > 0)
         {
             txtGuiHao.Text      = lsvCabinet.SelectedItems[0].Text;
             txtLie.Text         = lsvCabinet.SelectedItems[0].SubItems[1].Text;
             txtCeng.Text        = lsvCabinet.SelectedItems[0].SubItems[2].Text;
             txtboxsn.Text       = lsvCabinet.SelectedItems[0].SubItems[3].Text;
             txtJuan.Text        = lsvCabinet.SelectedItems[0].SubItems[4].Text;
             Clsxtpz.myCabinetID = Convert.ToInt32(lsvCabinet.SelectedItems[0].SubItems[5].Text);
             V_HouseSetCs.Id     = Clsxtpz.myCabinetID;
         }
         txt_kfsz_rongliang.Text = Convert.ToString(SnValid(txtGuiHao.Text) * SnValid(txtLie.Text) * SnValid(txtCeng.Text) * SnValid(txtboxsn.Text) * SnValid(txtJuan.Text) * 2);
         if (txtGuiHao.Text == "1")
         {
             imgboxq = 1;
         }
         else
         {
             imgboxq = SnValid(txtLie.Text) * SnValid(txtCeng.Text) * SnValid(txtboxsn.Text) * 2;
         }
         int imgboxz = SnValid(txtGuiHao.Text) * SnValid(txtLie.Text) * SnValid(txtCeng.Text) * SnValid(txtboxsn.Text) * 2;
         Clsxtpz.imagecount = T_Sysset.Getboxsnimage(imgboxq, imgboxz);
     } catch (Exception ee) {
         MessageBox.Show(ee.ToString());
     }
 }
예제 #3
0
        private void AddHouseSet()
        {
            V_HouseSetCs.Houseid   = Clsxtpz.myHouseID;
            V_HouseSetCs.HouseGui  = Convert.ToInt32(txtGuiHao.Text);
            V_HouseSetCs.HouseCol  = Convert.ToInt32(txtLie.Text);
            V_HouseSetCs.HouseRow  = Convert.ToInt32(txtCeng.Text);
            V_HouseSetCs.Housebox  = Convert.ToInt32(txtboxsn.Text);
            V_HouseSetCs.Housejuan = Convert.ToInt16(txtJuan.Text);
            int id = 0;

            if (radio_kfsz_box.Checked)
            {
                foreach (ListViewItem item in lsvCabinet.Items)
                {
                    int CabinetNum = Convert.ToInt32(item.Text.ToString());
                    if (V_HouseSetCs.HouseGui == CabinetNum)
                    {
                        txtGuiHao.Focus();
                        MessageBox.Show("柜号已存在");
                        return;
                    }
                }
                id = 0;
            }
            else
            {
                id = 1;
            }
            T_Sysset.HouseSetAdd(id);
        }
예제 #4
0
파일: UcInfoGet.cs 프로젝트: Ghcsm/Wh_Fzg
        void Init()
        {
            combZd.Items.Clear();
            lsName.Clear();
            lsdata.Clear();
            DataTable dt = T_Sysset.GetInfoenterSql();

            if (dt == null || dt.Rows.Count <= 0)
            {
                return;
            }
            DataRow dr = dt.Rows[0];

            table = dr["InfoTable"].ToString();
            strzd = dr["InfoCol"].ToString();
            if (strzd.Length > 0)
            {
                string[] a = strzd.Split(';');
                for (int i = 0; i < a.Length; i++)
                {
                    string b = a[i];
                    if (b.Trim().Length > 0)
                    {
                        combZd.Items.Add(b);
                    }
                }
                if (combZd.Items.Count > 0)
                {
                    combZd.SelectedIndex = 0;
                }
            }
            combtj.SelectedIndex = 0;
        }
예제 #5
0
        private void GetinfoSql()
        {
            Lsinfo.Clear();
            DataTable dt = T_Sysset.GetInfoenterSql();

            if (dt == null || dt.Rows.Count <= 0)
            {
                return;
            }
            string str = dt.Rows[0][2].ToString();

            if (str.Trim().Length <= 0)
            {
                return;
            }
            string[] str1 = str.Split(';');
            for (int i = 0; i < str1.Length; i++)
            {
                str = str1[i];
                if (str.Trim().Length <= 0)
                {
                    continue;
                }
                Lsinfo.Add(str);
            }
        }
예제 #6
0
        private void butMenuSave_Click(object sender, EventArgs e)
        {
            string txtname = txtMenuname.Text.Trim();
            string txtxh   = txtMenuxh.Text.Trim();
            int    id      = -1;

            if (txtname.Length <= 0 || txtxh.Length <= 0)
            {
                MessageBox.Show("请输入菜单名称或顺序号!");
                txtMenuname.Focus();
                return;
            }
            if (chkMenuName.SelectedItems.Count >= 0)
            {
                id = Getmenuid();
            }
            if (ClsSetInfopar.lsname.IndexOf(txtname) >= 0)
            {
                MessageBox.Show("菜单名称已存在请更改!");
                txtMenuname.Focus();
                return;
            }
            if (ClsSetInfopar.lsxh.IndexOf(txtxh) >= 0 && id < 0)
            {
                MessageBox.Show("菜单顺序号已存在!");
                txtMenuxh.Focus();
                return;
            }
            try {
                T_Sysset.SaveMenuset(id.ToString(), txtname, txtxh);
            } catch { } finally {
                Getmenuset();
            }
        }
예제 #7
0
 private void btnSave_Click(object sender, EventArgs e)
 {
     try {
         if (!isFwqTxt())
         {
             MessageBox.Show("请完善相关信息!");
             return;
         }
         T_ConFigure.FtpIP         = txtFtpIP.Text.Trim();
         T_ConFigure.FtpPort       = Convert.ToInt32(txtFtpPort.Text.Trim());
         T_ConFigure.FtpUser       = txtFtpUser.Text.Trim();
         T_ConFigure.FtpPwd        = txtFtpPwd.Text.Trim();
         T_ConFigure.FtpArchScan   = txtFtpArchScan.Text.Trim();
         T_ConFigure.FtpArchIndex  = txtFtpArchIndex.Text.Trim();
         T_ConFigure.FtpArchSave   = txtFtpArchSave.Text.Trim();
         T_ConFigure.FtpArchUpdate = txtFtpArchUpdate.Text.Trim();
         T_ConFigure.FtpTmp        = txtFtpArchScanTmp.Text.Trim();
         T_ConFigure.FtpTmpPath    = txtFwqYsPath.Text.Trim();
         T_ConFigure.FtpBakimgFwq  = Convert.ToInt32(chkFtpSever.Checked);
         T_ConFigure.FtpBakimgBd   = Convert.ToInt32(chkFtpBd.Checked);
         T_ConFigure.FtpStyle      = Convert.ToInt32(chkFtpStyle.Checked);
         T_ConFigure.FtpFwqPath    = txtFwqPath.Text.Trim();
         if (T_Sysset.SetFtpInfo() > 0)
         {
             MessageBox.Show("更新成功!");
         }
         else
         {
             MessageBox.Show("更新失败!");
         }
     } catch (Exception ex) {
         MessageBox.Show("更新失败!" + ex.ToString());
     }
 }
예제 #8
0
        private void btnOk_Click(object sender, EventArgs e)
        {
            if (this.txtUser.Text.Trim().Length <= 0 || this.txtPwd.Text.Trim().Length <= 0)
            {
                MessageBox.Show("用户或密码不正确!");
                this.txtUser.Focus();
                return;
            }
            if (!T_Sysset.IsCheckUser(this.txtUser.Text.Trim(), this.txtPwd.Text.Trim()))
            {
                MessageBox.Show("用户或密码不正确!");
                this.txtUser.Focus();
                return;
            }
            if (!Setusersys())
            {
                txtUser.Focus();
                return;
            }

            try {
                FrmMain fmMain = new FrmMain();
                this.Hide();
                Wirteini();
                fmMain.ShowDialog();
            } catch {
                Application.Exit();
            }
        }
예제 #9
0
 private void InitHouse()
 {
     try {
         List <V_HouseSet> HouseEc = new List <V_HouseSet>();
         DataTable         dt      = T_Sysset.GetHouseInfo();
         if (dt == null || dt.Rows.Count <= 0)
         {
             return;
         }
         cboHouse.Items.Clear();
         foreach (DataRow dr in dt.Rows)
         {
             V_HouseSet House = new V_HouseSet();
             House.HouseName = dr["HOUSENAME"].ToString();
             House.HouseID   = Convert.ToInt32(dr["id"].ToString());
             House.HouseBox  = Convert.ToInt32(dr["MaxBoxNum"].ToString());
             HouseEc.Add(House);
         }
         cboHouse.BeginUpdate();
         cboHouse.Items.Clear();
         cboHouse.Items.AddRange(HouseEc.ToArray());
         cboHouse.EndUpdate();
         cboHouse.SelectedItem = HouseEc;
     } catch (Exception ee) {
         MessageBox.Show(ee.ToString());
     }
 }
예제 #10
0
파일: FrmBorrLog.cs 프로젝트: Ghcsm/Wh_Fzg
        void InIcol()
        {
            combCol.DataSource = null;
            DataTable dt = null;

            lvQuer.Columns.Clear();
            lvQuer.Items.Clear();
            lvQuer.Columns.Add("序号");
            int id = combTable.SelectedIndex;

            if (id == 0)
            {
                table = "V_borrTable";
            }
            else
            {
                table = "V_BorrLog";
            }
            if (lscol.Count <= 0 || lscollog.Count <= 0)
            {
                dt = T_Sysset.GetTableName(table);
            }
            else
            {
                List <string> coltmp = null;
                if (combTable.SelectedIndex == 0)
                {
                    coltmp = lscol.ToList();
                }
                else
                {
                    coltmp = lscollog.ToList();
                }
                for (int i = 0; i < coltmp.Count; i++)
                {
                    combCol.Items.Add(coltmp[i]);
                    lvQuer.Columns.Add(coltmp[i]);
                }
                return;
            }
            if (dt == null || dt.Rows.Count <= 0)
            {
                return;
            }
            for (int i = 0; i < dt.Rows.Count; i++)
            {
                string str = dt.Rows[i][0].ToString();
                lvQuer.Columns.Add(str);
                if (id == 0)
                {
                    lscol.Add(str);
                }
                else
                {
                    lscollog.Add(str);
                }
            }
            combCol.DataSource    = dt;
            combCol.DisplayMember = "Name";
        }
예제 #11
0
 Task <bool> IniMenu()
 {
     return(Task.Run(() =>
     {
         DataTable dt = T_Sysset.GetMenuSet();
         if (dt == null || dt.Rows.Count <= 0)
         {
             return false;
         }
         for (int i = 0; i < dt.Rows.Count; i++)
         {
             string strname = dt.Rows[i][0].ToString();
             if (strname.Trim().Length <= 0)
             {
                 continue;
             }
             if (T_User.UserMenu.IndexOf(DESEncrypt.DesEncrypt(strname)) < 0)
             {
                 continue;
             }
             SideBarPanelItem item = new SideBarPanelItem();
             item.Name = strname;
             item.Text = strname;
             item.FontBold = true;
             sideBarManger.Invoke(new Action(() =>
             {
                 sideBarManger.Panels.Add(item);
                 sideBarManger.Refresh();
             }));
         }
         return true;
     }));
 }
예제 #12
0
        public void GetContenInfo()
        {
            //if (ClsContenInfo.ContenTable ==null && ClsContenInfo.ContenTable.Length<=0)
            //    return;
            DataTable dt = T_Sysset.GetConten(UcContents.Modulename);

            if (dt == null || dt.Rows.Count <= 0)
            {
                return;
            }
            DataRow dr = dt.Rows[0];

            ContenCoList.Clear();
            ContenTable   = dr["ContenTable"].ToString();
            ContenLie     = dr["ContenLie"].ToString();
            ContenWith    = dr["ContenWith"].ToString();
            ContenTxtwith = dr["ContentxtWith"].ToString();
            ContenTitle   = dr["ContenTitle"].ToString();
            ContenPages   = dr["ContenPages"].ToString();
            ContenCol     = dr["ContenCol"].ToString();
            if (ContenCol.Length > 0)
            {
                string[] col = ContenCol.Split(';');
                for (int i = 0; i < col.Length; i++)
                {
                    ContenCoList.Add(col[i]);
                }
            }
            PagesWz = ContenCoList.IndexOf(ContenPages);
            TitleWz = ContenCoList.IndexOf(ContenTitle);
            LoadModulels();
        }
예제 #13
0
 private void butModuleSet_Click(object sender, EventArgs e)
 {
     if (T_ConFigure.Bgsoft)
     {
         MessageBox.Show("警告:软件未授权无法进行操作!");
         return;
     }
     if (txtModuleChName.Text.Trim().Length <= 0 ||
         txtModuleChName.Text.Trim().Length <= 0 ||
         txtModuleFileName.Text.Trim().Length <= 0 ||
         comModuleFz.Text.Trim().Length <= 0 ||
         comModuleImg.Text.Trim().Length <= 0)
     {
         MessageBox.Show("请输入相关信息!");
         txtModuleChName.Focus();
         return;
     }
     T_addModule.T_moduleChName   = this.txtModuleChName.Text.Trim();
     T_addModule.T_moduleName     = this.txtModuleName.Text.Trim();
     T_addModule.T_moduleFileName = this.txtModuleFileName.Text.Trim();
     T_addModule.T_moduleInt      = ClsSetInfopar.lsxh[comModuleFz.SelectedIndex].ToString();
     T_addModule.T_moduleImgIdx   = this.comModuleImg.SelectedIndex;
     T_Sysset.SaveModule();
     MessageBox.Show("保存成功!");
     this.txtModuleChName.Text   = "";
     this.txtModuleFileName.Text = "";
     this.txtModuleName.Text     = "";
     this.comModuleImg.Text      = "";
     this.comModuleFz.Text       = "";
 }
예제 #14
0
파일: FrmPwd.cs 프로젝트: Ghcsm/Wh_Fzg
        private bool istxt()
        {
            if (txtOldpwd.Text.Trim().Length <= 0)
            {
                MessageBox.Show("请输入旧密码!");
                txtOldpwd.Focus();
                return(false);
            }

            if (txtNewPwd.Text.Trim().Length <= 0 || txtNewPwd2.Text.Trim().Length <= 0)
            {
                MessageBox.Show("请输入新密码或重复新密码!");
                txtNewPwd.Focus();
                return(false);
            }
            else
            {
                if (txtNewPwd.Text.Trim() != txtNewPwd2.Text.Trim())
                {
                    MessageBox.Show("两次密码不一致!");
                    txtNewPwd.Focus();
                    return(false);
                }
            }

            if (!T_Sysset.IsCheckUser(T_User.LoginName, txtOldpwd.Text.Trim()))
            {
                MessageBox.Show("旧密码不正确!");
                txtOldpwd.Focus();
                return(false);
            }
            return(true);
        }
예제 #15
0
파일: BorrMethod.cs 프로젝트: Ghcsm/Wh_Fzg
        public static void Getinfo(ListView lv, ComboBoxEx box)
        {
            lscol.Clear();
            box.Items.Clear();
            Timecol = "";
            DataTable dt = T_Sysset.GetborrTable();

            if (dt == null || dt.Rows.Count <= 0)
            {
                return;
            }
            string str = dt.Rows[0][2].ToString();

            Timecol = dt.Rows[0][3].ToString();
            if (str.Trim().Length <= 0)
            {
                return;
            }
            if (str.IndexOf(";") < 0)
            {
                return;
            }
            string[] s = str.Split(';');
            for (int i = 0; i < s.Length; i++)
            {
                lscol.Add(s[i].Trim());
                box.Items.Add(s[i].Trim());
                lv.Columns.Add(s[i].Trim());
            }
            lv.Columns.Add("Archid");
            Getsys();
        }
예제 #16
0
        private void LoadHouse()
        {
            try {
                cboHouseType.Text    = "";
                txtHoseName.Text     = "";
                txtHouseBoxjuan.Text = "";
                DataTable dt = T_Sysset.GetHouseInfo();
                if (dt != null && dt.Rows.Count > 0)
                {
                    this.lsvHouse.Items.Clear();
                    int    i            = 1;
                    string tmpHouseType = string.Empty;
                    string tmpHouse     = string.Empty;
                    string tmpMaxBox    = string.Empty;
                    string tmpHouseID   = string.Empty;

                    foreach (DataRow dr in dt.Rows)
                    {
                        ListViewItem lvi = new ListViewItem();
                        lvi.Text     = i.ToString();
                        tmpHouseType = dr["HouseType"].ToString();
                        tmpHouse     = dr["HouseName"].ToString();
                        tmpMaxBox    = dr["MaxBoxNum"].ToString();
                        tmpHouseID   = dr["id"].ToString();
                        lvi.SubItems.AddRange(new string[] { tmpHouseType, tmpHouse, tmpMaxBox, tmpHouseID });
                        this.lsvHouse.Items.Add(lvi);
                        i++;
                    }
                }
            } catch (Exception ee) {
                MessageBox.Show(ee.ToString());
            }
        }
예제 #17
0
        private void butOk_Click(object sender, EventArgs e)
        {
            if (!chkUpdateTime.Checked)
            {
                if (txtId.Text.Trim().Length <= 0 ||
                    txtSn.Text.Trim().Length <= 0 ||
                    txtTime.Text.Trim().Length <= 0)
                {
                    MessageBox.Show("请输入相关信息!");
                    this.txtId.Focus();
                    return;
                }

                if (txtSn.Text.Trim().Length > 38 ||
                    txtSn.Text.Trim().Length < 30)
                {
                    MessageBox.Show("SN字段不正确!");
                    txtSn.Focus();
                    return;
                }
            }
            if (txtTime.Text.Trim().Length > 65 ||
                txtTime.Text.Trim().Length < 45)
            {
                MessageBox.Show("时间字段不正确!");
                this.txtTime.Focus();
                return;
            }
            T_addModule.T_id     = txtId.Text.Trim();
            T_addModule.T_sn     = txtSn.Text.Trim();
            T_addModule.T_time   = txtTime.Text.Trim();
            T_addModule.T_timecs = DateTime.Now.ToString();
            T_Sysset.SaveModuleSofte(chkUpdateTime.Checked);
            MessageBox.Show("保存成功!");
        }
예제 #18
0
        private void Getmodule()
        {
            DataTable dt = T_Sysset.IsGetModule(0);

            if (dt == null || dt.Rows.Count <= 0)
            {
                return;
            }
            DataRow[] drt = dt.Select("ModuleSys is null");
            chkMouduleCol.Items.Clear();
            chkMouduleColSet.Items.Clear();
            T_addModule.ModuleColSet.Clear();
            foreach (DataRow dr in drt)
            {
                string str = dr[1].ToString();
                chkMouduleCol.Items.Add(str);
            }
            DataRow[] drj = dt.Select("ModuleSys='1'");
            foreach (DataRow dr in drj)
            {
                string str = dr[1].ToString();
                chkMouduleColSet.Items.Add(str);
                T_addModule.ModuleColSet.Add(str);
            }
        }
예제 #19
0
 private void ChangeHouseSet()
 {
     V_HouseSetCs.Houseid   = Clsxtpz.myHouseID;
     V_HouseSetCs.HouseGui  = Convert.ToInt32(txtGuiHao.Text);
     V_HouseSetCs.HouseCol  = Convert.ToInt32(txtLie.Text);
     V_HouseSetCs.HouseRow  = Convert.ToInt32(txtCeng.Text);
     V_HouseSetCs.Housebox  = Convert.ToInt32(txtboxsn.Text);
     V_HouseSetCs.Housejuan = Convert.ToInt16(txtJuan.Text);
     T_Sysset.HouseSetChanger();
 }
예제 #20
0
        private void Loaduser()
        {
            Cletxt();
            DataTable dt = T_Sysset.GetuserSys();

            dgvData.DataSource = null;
            if (dt != null && dt.Rows.Count > 0)
            {
                dgvData.DataSource = dt;
            }
        }
예제 #21
0
        private void ModuleSys()
        {
            DataTable dt = T_Sysset.GetOtherModule();

            if (dt == null || dt.Rows.Count <= 0)
            {
                return;
            }
            lvOtherModule.DataSource    = dt;
            lvOtherModule.DisplayMember = "OtherModule";
        }
예제 #22
0
 private void txtId_Leave(object sender, EventArgs e)
 {
     if (txtSn.Text.Trim().Length <= 0)
     {
         return;
     }
     T_addModule.T_id = txtId.Text.Trim();
     T_Sysset.SeleModuleSofte();
     txtSn.Text   = T_addModule.T_sn;
     txtTime.Text = T_addModule.T_time;
 }
예제 #23
0
 private void butDel_Click(object sender, EventArgs e)
 {
     try {
         if (!isuser(1))
         {
             return;
         }
         T_Sysset.Deluser(txtUser.Text.Trim());
         Loaduser();
     } catch (Exception exception) {
         MessageBox.Show("删除用户失败!" + exception);
     }
 }
예제 #24
0
파일: FrmPwd.cs 프로젝트: Ghcsm/Wh_Fzg
 private void butPwd_Click(object sender, EventArgs e)
 {
     try {
         if (!istxt())
         {
             return;
         }
         T_Sysset.UpUserPwd(txtNewPwd.Text.Trim());
         MessageBox.Show("修改密码完成!");
     } catch (Exception exception) {
         MessageBox.Show("修改密码失败!" + exception);
     }
 }
예제 #25
0
        private bool isuser(int user)
        {
            bool tf = true;

            if (txtUser.Text.Trim().Length <= 0)
            {
                MessageBox.Show("请输入用户名!");
                txtUser.Focus();
                tf = false;
            }
            if (user == 0)
            {
                if (txtPwd.Text.Trim().Length <= 0 || txtPwd2.Text.Trim().Length <= 0)
                {
                    MessageBox.Show("请输入密码!");
                    txtPwd.Focus();
                    tf = false;
                }
                else
                {
                    if (txtPwd.Text.Trim() != txtPwd2.Text.Trim())
                    {
                        MessageBox.Show("两次密码不一致!");
                        tf = false;
                    }
                }
                if (T_Sysset.IsCheckUser(txtUser.Text.Trim()))
                {
                    MessageBox.Show("用户已存在!");
                    txtUser.Focus();
                    tf = false;
                }
            }
            else
            {
                if (!T_Sysset.IsCheckUser(txtUser.Text.Trim()))
                {
                    MessageBox.Show("用户不存在!");
                    txtUser.Focus();
                    tf = false;
                }
            }
            if (txtTime.Text.Trim().Length <= 0)
            {
                MessageBox.Show("请输入入职时间!");
                txtTime.Focus();
                tf = false;
            }
            return(tf);
        }
예제 #26
0
 private void butUpdate_Click(object sender, EventArgs e)
 {
     try {
         if (!isuser(1))
         {
             return;
         }
         string usermenu = Usermenu();
         string usersys  = Usersysstr();
         string othersys = OthersysStr();
         T_Sysset.UpUserSys(txtUser.Text.Trim(), txtPhone.Text.Trim(), txtTime.Text.Trim(), txtBz.Text.Trim(), usersys, othersys, userid, usermenu);
         Loaduser();
     } catch (Exception exception) {
         MessageBox.Show("修改权限失败!" + exception);
     }
 }
예제 #27
0
 private void SetModulesys(bool bl)
 {
     if (bl)
     {
         if (chkMouduleCol.Items.Count <= 0 || chkMouduleCol.SelectedItems.Count <= 0)
         {
             return;
         }
         for (int i = 0; i < chkMouduleCol.Items.Count; i++)
         {
             if (chkMouduleCol.GetItemChecked(i))
             {
                 string str = chkMouduleCol.Items[i].ToString();
                 if (T_addModule.ModuleColSet.IndexOf(str) < 0)
                 {
                     Thread.Sleep(300);
                     T_Sysset.UpdateModuelSys(str, bl);
                     chkMouduleColSet.Items.Add(str);
                     T_addModule.ModuleColSet.Add(str);
                     i--;
                 }
             }
         }
     }
     else
     {
         if (chkMouduleColSet.Items.Count <= 0 || chkMouduleColSet.SelectedItems.Count <= 0)
         {
             return;
         }
         for (int i = 0; i < chkMouduleColSet.Items.Count; i++)
         {
             if (chkMouduleColSet.GetItemChecked(i))
             {
                 string str = chkMouduleColSet.Items[i].ToString();
                 if (T_addModule.ModuleColSet.IndexOf(str) >= 0)
                 {
                     Thread.Sleep(300);
                     T_Sysset.UpdateModuelSys(str, bl);
                     chkMouduleColSet.Items.Remove(str);
                     T_addModule.ModuleColSet.Remove(str);
                     i--;
                 }
             }
         }
     }
 }
예제 #28
0
 private void txtModuleChName_Leave(object sender, EventArgs e)
 {
     if (txtModuleChName.Text.Trim().Length <= 0)
     {
         return;
     }
     try
     {
         T_addModule.T_moduleChName = txtModuleChName.Text.Trim();
         T_Sysset.SeleModule();
         txtModuleName.Text        = T_addModule.T_moduleName;
         txtModuleFileName.Text    = T_addModule.T_moduleFileName;
         comModuleFz.SelectedIndex = Convert.ToInt32(T_addModule.T_moduleInt.ToString()) - 1;
         comModuleImg.Text         = T_addModule.T_moduleImgIdx.ToString();
     }
     catch
     {}
 }
예제 #29
0
        private static void GetExportTable()
        {
            ClsDataSplitPar.ClsExportTable.Clear();
            ClsDataSplitPar.ClsExportxlsid.Clear();
            ClsDataSplitPar.ClsExportCol.Clear();
            ClsDataSplitPar.ClsExportColLeg.Clear();
            DataTable dt = T_Sysset.GetDataSplitExporTable();

            if (dt == null || dt.Rows.Count <= 0)
            {
                return;
            }
            foreach (DataRow dr in dt.Rows)
            {
                string table = dr["ImportTable"].ToString();
                string col   = dr["ImportCol"].ToString();
                string xlsid = dr["BindId"].ToString();
                ClsDataSplitPar.ClsExportTable.Add(table);
                ClsDataSplitPar.ClsExportxlsid.Add(xlsid);
                string str = "";
                string leg = "";
                if (col.IndexOf(';') >= 0)
                {
                    string[] strleg = col.Split(';');
                    for (int i = 0; i < strleg.Length; i++)
                    {
                        string[] leg1 = strleg[i].Split(':');
                        if (str.Trim().Length <= 0)
                        {
                            str += leg1[0];
                            leg += leg1[1];
                        }
                        else
                        {
                            str += "," + leg1[0];
                            leg += "," + leg1[1];
                        }
                    }
                    ClsDataSplitPar.ClsExportCol.Add(str);
                    ClsDataSplitPar.ClsExportColLeg.Add(leg);
                }
            }
        }
예제 #30
0
 private void but_gui_Click(object sender, EventArgs e)
 {
     try
     {
         DevComponents.DotNetBar.ButtonX bt = (DevComponents.DotNetBar.ButtonX)sender;
         int g = Convert.ToInt32(bt.Name.Substring(3));
         V_HouseSetCs.HouseGui = g;
         T_Sysset.GetHouseGuiCs();
         StoreView st = new StoreView
         {
             ShowInTaskbar = true
         };
         st.Show();
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.ToString());
     }
 }