Ejemplo n.º 1
0
        private void tj_mrfz(string str_dwbh)// by zhz
        {
            //read
            if (str_dwbh == "")
            {
                return;                //没有选择节点
            }
            ywszBiz   ywszbiz = new ywszBiz();
            DataTable dt_tjtc = ywszbiz.Get_tj_tc_hd();

            for (int i = 0; i < dt_tjtc.Rows.Count; i++)
            {
                DataRow   dr_tc       = dt_tjtc.Rows[i];              //体检项目
                string    str_bh      = dr_tc["bh"].ToString().Trim();
                DataTable dt_tj_tc_dc = ywszbiz.Get_tj_tc_dt(str_bh); //体检内容

                //add
                txt_fzbh.Text = dr_tc["bh"].ToString().Trim();
                txt_fzmc.Text = dr_tc["mc"].ToString().Trim();
                //cmb_xb.SelectedValue = dr_tc["xb"].ToString().Trim();
                txt_zc.Text = "";
                txt_zw.Text = "";

                str_fzbh = tjglbiz.Get_proc_get_tjdwfzbh(str_dwbh);
                tjdjBiz tjblbiz1 = new tjdjBiz();
                tjblbiz1.str_Delete_TJ_DWFZ_HD(str_fzbh, str_dwbh);
                tjblbiz1.str_Insert_TJ_DWFZ_HD(str_fzbh, str_dwbh, txt_fzmc.Text.Trim(), "1", txt_zw.Text.Trim(), txt_zc.Text.Trim());//1 是男士
                foreach (DataRow dr_dc in dt_tj_tc_dc.Rows)
                {
                    string aa = dr_dc["zhxm"].ToString().Trim();
                    string bb = dr_dc["mc"].ToString().Trim();
                    tjblbiz1.str_Insert_TJ_DWFZ_DT(str_fzbh, str_dwbh, aa);
                }
                tjblbiz1.Exec_ArryList();
            }
        }
Ejemplo n.º 2
0
        private void Form_zhxmlr_Load(object sender, EventArgs e)
        {
            new Common.Common().AddImages(imageList1);
            tv_tjlxb.ImageList = imageList1;

            lv_tc.SmallImageList = imageList1;
            lv_tc.StateImageList = imageList1;
            lv_tc.LargeImageList = imageList1;


            lv_fz.SmallImageList = imageList1;
            lv_fz.StateImageList = imageList1;
            lv_fz.LargeImageList = imageList1;

            lv_uncheckxm.SmallImageList = imageList1;
            lv_uncheckxm.StateImageList = imageList1;
            lv_uncheckxm.LargeImageList = imageList1;

            lv_checkxm.SmallImageList = imageList1;
            lv_checkxm.StateImageList = imageList1;
            lv_checkxm.LargeImageList = imageList1;


            lv_checkxm.Items.Clear();
            lv_checkxm.View = View.SmallIcon;
            foreach (DataRow dr in dt_tj_tc_dt.Rows)
            {
                ListViewItem item = new ListViewItem();
                item.Tag        = dr["zhxm"].ToString().Trim();
                item.Text       = dr["mc"].ToString().Trim();
                item.ImageIndex = 2;
                lv_checkxm.Items.Add(item);
            }

            lv_tc.Items.Clear();
            lv_tc.View = View.Tile;
            DataTable dt_tj_tc_hd = ywszbiz.Get_tj_tc_hd();

            foreach (DataRow dr in dt_tj_tc_hd.Rows)
            {
                ListViewItem item = new ListViewItem();
                item.Tag        = dr["bh"].ToString().Trim();
                item.Text       = dr["mc"].ToString().Trim();
                item.ImageIndex = 5;
                lv_tc.Items.Add(item);
            }
            lv_fz.Items.Clear();
            lv_fz.View = View.SmallIcon;
            DataTable dt_tj_dwfz_hd = tjglbiz.Get_tj_dwfz_hd(str_dwbh);

            foreach (DataRow dr in dt_tj_dwfz_hd.Rows)
            {
                ListViewItem item = new ListViewItem();
                item.Tag        = dr["bh"].ToString().Trim();
                item.Text       = dr["mc"].ToString().Trim();
                item.ImageIndex = 4;
                lv_fz.Items.Add(item);
            }

            tv_tjlxb.Nodes.Clear();
            TreeNode node = new TreeNode("体检科室");

            node.Tag = "00";
            DataTable dt = ywszbiz.Get_tj_tjlxb();

            foreach (DataRow dr in dt.Rows)
            {
                TreeNode node1 = new TreeNode(dr["mc"].ToString());
                node1.Tag = dr["lxbh"].ToString();
                node.Nodes.Add(node1);
            }
            tv_tjlxb.Nodes.Add(node);
            new Common.Common().AddImage(node);
            tv_tjlxb.ExpandAll();

            dt_tj_zhxm_hd = ywszbiz.Get_tj_zhxm_hd();
        }