コード例 #1
0
        public int SaveJkda_zz(TjZybZz zz)
        {
            List <string> sqls = sqls = new List <string>();

            TjZybZzBiz zzBiz = new TjZybZzBiz();

            if (zzBiz.HasExist(zz.tjbh, zz.tjcs))
            {
                zzBiz.Update(zz, sqls);
            }
            else
            {
                zzBiz.Insert(zz, sqls);
            }

            return(base.SqlDBAgent.sqlupdate(sqls));
        }
コード例 #2
0
        /// <summary>
        /// 保存健康档案
        /// </summary>
        /// <param name="ryxx">人员信息</param>
        /// <param name="sqls"></param>
        /// <returns></returns>
        public int SaveJkda(TjZybRyxx ryxx, TjZybZz zz, TjGyzz gyzz, TjZybGqf gqf)
        {
            List <string> sqls = sqls = new List <string>();

            if (HasExist(ryxx.Tjbh, ryxx.Tjcs))
            {
                Update(ryxx, sqls);
            }
            else
            {
                InsertRyxx(ryxx, sqls);
            }
            TjZybZzBiz zzBiz = new TjZybZzBiz();

            if (zzBiz.HasExist(zz.tjbh, zz.tjcs))
            {
                zzBiz.Update(zz, sqls);
            }
            else
            {
                zzBiz.Insert(zz, sqls);
            }
            TjGyzzBiz gyzzBiz = new TjGyzzBiz();

            gyzzBiz.Delete(gyzz.tjbh, gyzz.tjcs, sqls);
            gyzzBiz.Insert(gyzz, sqls);

            TjZybGqfBiz gqfBiz = new TjZybGqfBiz();

            if (gqfBiz.HasExist(gqf.tjbh))
            {
                gqfBiz.Update(gqf, sqls);
            }
            else
            {
                gqfBiz.Insert(gqf, sqls);
            }

            return(base.SqlDBAgent.sqlupdate(sqls));
        }
コード例 #3
0
ファイル: TjZybZzBiz.cs プロジェクト: wangronghua/PEIS_Autoz
        public void Update(TjZybZz zz, List<string> sqls)
        {
            //TJBH,TJCS,JCRQ,jcys,ZZ01
            sql = new StringBuilder("update tj_zyb_zz set tjbh='"+zz.tjbh+"'");
            sql.Append(",tjcs='" + zz.tjcs + "'");
            sql.Append(",JCRQ='" + zz.jcrq + "'");
            sql.Append(",jcys='" + zz.jcys + "'");
            sql.Append(",ZZ01='" + zz.zz01 + "'");
            sql.Append(",ZZ02='" + zz.zz02 + "'");
            sql.Append(",ZZ03='" + zz.zz03 + "'");
            sql.Append(",ZZ04='" + zz.zz04 + "'");
            sql.Append(",ZZ05='" + zz.zz05 + "'");
            sql.Append(",ZZ06='" + zz.zz06 + "'");
            sql.Append(",ZZ07='" + zz.zz07 + "'");
            sql.Append(",ZZ08='" + zz.zz08 + "'");
            sql.Append(",ZZ09='" + zz.zz09 + "'");

            sql.Append(",ZZ10='" + zz.zz10 + "'");
            sql.Append(",ZZ11='" + zz.zz11 + "'");
            sql.Append(",ZZ12='" + zz.zz12 + "'");
            sql.Append(",ZZ13='" + zz.zz13 + "'");
            sql.Append(",ZZ14='" + zz.zz14 + "'");
            sql.Append(",ZZ15='" + zz.zz15 + "'");
            sql.Append(",ZZ16='" + zz.zz16 + "'");
            sql.Append(",ZZ17='" + zz.zz17 + "'");
            sql.Append(",ZZ18='" + zz.zz18 + "'");
            sql.Append(",ZZ19='" + zz.zz19 + "'");

            sql.Append(",ZZ20='" + zz.zz20 + "'");
            sql.Append(",ZZ21='" + zz.zz21 + "'");
            sql.Append(",ZZ22='" + zz.zz22 + "'");
            sql.Append(",ZZ23='" + zz.zz23 + "'");
            sql.Append(",ZZ24='" + zz.zz24 + "'");
            sql.Append(",ZZ25='" + zz.zz25 + "'");
            sql.Append(",ZZ26='" + zz.zz26 + "'");
            sql.Append(",ZZ27='" + zz.zz27 + "'");
            sql.Append(",ZZ28='" + zz.zz28 + "'");
            sql.Append(",ZZ29='" + zz.zz29 + "'");

            sql.Append(",ZZ30='" + zz.zz30 + "'");
            sql.Append(",ZZ31='" + zz.zz31 + "'");
            sql.Append(",ZZ32='" + zz.zz32 + "'");
            sql.Append(",ZZ33='" + zz.zz33 + "'");
            sql.Append(",ZZ34='" + zz.zz34 + "'");
            sql.Append(",ZZ35='" + zz.zz35 + "'");
            sql.Append(",ZZ36='" + zz.zz36 + "'");
            sql.Append(",ZZ37='" + zz.zz37 + "'");
            sql.Append(",ZZ38='" + zz.zz38 + "'");
            sql.Append(",ZZ39='" + zz.zz39 + "'");

            sql.Append(",ZZ40='" + zz.zz40 + "'");
            sql.Append(",ZZ41='" + zz.zz41 + "'");
            sql.Append(",ZZ42='" + zz.zz42 + "'");
            sql.Append(",ZZ43='" + zz.zz43 + "'");
            sql.Append(",ZZ44='" + zz.zz44 + "'");
            sql.Append(",ZZ45='" + zz.zz45 + "'");
            sql.Append(",ZZ46='" + zz.zz46 + "'");
            sql.Append(",ZZ47='" + zz.zz47 + "'");
            sql.Append(",ZZ48='" + zz.zz48 + "'");
            sql.Append(",ZZ49='" + zz.zz49 + "'");

            sql.Append(",ZZ50='" + zz.zz50 + "'");
            sql.Append(",ZZ51='" + zz.zz51 + "'");
            sql.Append(",ZZ52='" + zz.zz52 + "'");
            sql.Append(",ZZ53='" + zz.zz53 + "'");
            sql.Append(",ZZ54='" + zz.zz54 + "'");
            sql.Append(",ZZ55='" + zz.zz55 + "'");
            sql.Append(",ZZ56='" + zz.zz56 + "'");
            sql.Append(",ZZ57='" + zz.zz57 + "'");
            sql.Append(",ZZ58='" + zz.zz58 + "'");
            sql.Append(",ZZ59='" + zz.zz59 + "'");

            sql.Append(",ZZ60='" + zz.zz60 + "'");
            sql.Append(",ZZ61='" + zz.zz61 + "'");
            sql.Append(",ZZ62='" + zz.zz62 + "'");
            sql.Append(",ZZ63='" + zz.zz63 + "'");
            sql.Append(",ZZ64='" + zz.zz64 + "'");

            sql.Append(" where tjbh='"+zz.tjbh+"' and tjcs='"+zz.tjcs+"'");
            sqls.Add(sql.ToString());
            

        }
コード例 #4
0
ファイル: Form_zybwz.cs プロジェクト: wangronghua/PEIS_Autoz
        TjZybZz GetZz(string tjbh, string tjcs)
        {
            TjZybZz zz = new TjZybZz();

            zz.tjbh = tjbh;
            zz.tjcs = tjcs;
            zz.jcrq = dtpJcrq.Value.ToString();
            string jcys = "";

            if (cmbYs.SelectedIndex != -1)
            {
                jcys = cmbYs.SelectedValue.ToString();
            }
            zz.jcys = jcys;

            zz.zz01 = dgvZz.Rows[0].Cells["jg1"].Value.ToString().Trim();
            zz.zz02 = dgvZz.Rows[0].Cells["jg2"].Value.ToString().Trim();
            zz.zz03 = dgvZz.Rows[0].Cells["jg3"].Value.ToString().Trim();

            zz.zz04 = dgvZz.Rows[1].Cells["jg1"].Value.ToString().Trim();
            zz.zz05 = dgvZz.Rows[1].Cells["jg2"].Value.ToString().Trim();
            zz.zz06 = dgvZz.Rows[1].Cells["jg3"].Value.ToString().Trim();

            zz.zz07 = dgvZz.Rows[2].Cells["jg1"].Value.ToString().Trim();
            zz.zz08 = dgvZz.Rows[2].Cells["jg2"].Value.ToString().Trim();
            zz.zz09 = dgvZz.Rows[2].Cells["jg3"].Value.ToString().Trim();

            zz.zz10 = dgvZz.Rows[3].Cells["jg1"].Value.ToString().Trim();
            zz.zz11 = dgvZz.Rows[3].Cells["jg2"].Value.ToString().Trim();
            zz.zz12 = dgvZz.Rows[3].Cells["jg3"].Value.ToString().Trim();

            zz.zz13 = dgvZz.Rows[4].Cells["jg1"].Value.ToString().Trim();
            zz.zz14 = dgvZz.Rows[4].Cells["jg2"].Value.ToString().Trim();
            zz.zz15 = dgvZz.Rows[4].Cells["jg3"].Value.ToString().Trim();

            zz.zz16 = dgvZz.Rows[5].Cells["jg1"].Value.ToString().Trim();
            zz.zz17 = dgvZz.Rows[5].Cells["jg2"].Value.ToString().Trim();
            zz.zz18 = dgvZz.Rows[5].Cells["jg3"].Value.ToString().Trim();

            zz.zz19 = dgvZz.Rows[6].Cells["jg1"].Value.ToString().Trim();
            zz.zz20 = dgvZz.Rows[6].Cells["jg2"].Value.ToString().Trim();
            zz.zz21 = dgvZz.Rows[6].Cells["jg3"].Value.ToString().Trim();

            zz.zz22 = dgvZz.Rows[7].Cells["jg1"].Value.ToString().Trim();
            zz.zz23 = dgvZz.Rows[7].Cells["jg2"].Value.ToString().Trim();
            zz.zz24 = dgvZz.Rows[7].Cells["jg3"].Value.ToString().Trim();

            zz.zz25 = dgvZz.Rows[8].Cells["jg1"].Value.ToString().Trim();
            zz.zz26 = dgvZz.Rows[8].Cells["jg2"].Value.ToString().Trim();
            zz.zz27 = dgvZz.Rows[8].Cells["jg3"].Value.ToString().Trim();

            zz.zz28 = dgvZz.Rows[9].Cells["jg1"].Value.ToString().Trim();
            zz.zz29 = dgvZz.Rows[9].Cells["jg2"].Value.ToString().Trim();
            zz.zz30 = dgvZz.Rows[9].Cells["jg3"].Value.ToString().Trim();

            zz.zz31 = dgvZz.Rows[10].Cells["jg1"].Value.ToString().Trim();
            zz.zz32 = dgvZz.Rows[10].Cells["jg2"].Value.ToString().Trim();
            zz.zz33 = dgvZz.Rows[10].Cells["jg3"].Value.ToString().Trim();

            zz.zz34 = dgvZz.Rows[11].Cells["jg1"].Value.ToString().Trim();
            zz.zz35 = dgvZz.Rows[11].Cells["jg2"].Value.ToString().Trim();
            zz.zz36 = dgvZz.Rows[11].Cells["jg3"].Value.ToString().Trim();

            zz.zz37 = dgvZz.Rows[12].Cells["jg1"].Value.ToString().Trim();
            zz.zz38 = dgvZz.Rows[12].Cells["jg2"].Value.ToString().Trim();
            zz.zz39 = dgvZz.Rows[12].Cells["jg3"].Value.ToString().Trim();

            zz.zz40 = dgvZz.Rows[13].Cells["jg1"].Value.ToString().Trim();
            zz.zz41 = dgvZz.Rows[13].Cells["jg2"].Value.ToString().Trim();
            zz.zz42 = dgvZz.Rows[13].Cells["jg3"].Value.ToString().Trim();

            zz.zz43 = dgvZz.Rows[14].Cells["jg1"].Value.ToString().Trim();
            zz.zz44 = dgvZz.Rows[14].Cells["jg2"].Value.ToString().Trim();
            zz.zz45 = dgvZz.Rows[14].Cells["jg3"].Value.ToString().Trim();

            zz.zz46 = dgvZz.Rows[15].Cells["jg1"].Value.ToString().Trim();
            zz.zz47 = dgvZz.Rows[15].Cells["jg2"].Value.ToString().Trim();
            zz.zz48 = dgvZz.Rows[15].Cells["jg3"].Value.ToString().Trim();

            zz.zz49 = dgvZz.Rows[16].Cells["jg1"].Value.ToString().Trim();
            zz.zz50 = dgvZz.Rows[16].Cells["jg2"].Value.ToString().Trim();
            zz.zz51 = dgvZz.Rows[16].Cells["jg3"].Value.ToString().Trim();

            zz.zz52 = dgvZz.Rows[17].Cells["jg1"].Value.ToString().Trim();
            zz.zz53 = dgvZz.Rows[17].Cells["jg2"].Value.ToString().Trim();
            zz.zz54 = dgvZz.Rows[17].Cells["jg3"].Value.ToString().Trim();

            zz.zz55 = dgvZz.Rows[18].Cells["jg1"].Value.ToString().Trim();
            zz.zz56 = dgvZz.Rows[18].Cells["jg2"].Value.ToString().Trim();
            zz.zz57 = dgvZz.Rows[18].Cells["jg3"].Value.ToString().Trim();

            zz.zz58 = dgvZz.Rows[19].Cells["jg1"].Value.ToString().Trim();
            zz.zz59 = dgvZz.Rows[19].Cells["jg2"].Value.ToString().Trim();
            zz.zz60 = dgvZz.Rows[19].Cells["jg3"].Value.ToString().Trim();

            zz.zz61 = dgvZz.Rows[20].Cells["jg1"].Value.ToString().Trim();
            zz.zz62 = dgvZz.Rows[20].Cells["jg2"].Value.ToString().Trim();
            zz.zz63 = dgvZz.Rows[20].Cells["jg3"].Value.ToString().Trim();

            zz.zz64 = dgvZz.Rows[21].Cells["jg1"].Value.ToString().Trim();

            return(zz);
        }
コード例 #5
0
ファイル: TjZybZzBiz.cs プロジェクト: wangronghua/PEIS_Autoz
        public void Insert(TjZybZz zz, List<string> sqls)
        {
            sql = new StringBuilder("insert into tj_zyb_zz(TJBH,TJCS,JCRQ,jcys,ZZ01 ,ZZ02 ,ZZ03 ,ZZ04 ,ZZ05 ,ZZ06 ,ZZ07 ,ZZ08 ,ZZ09 ,ZZ10 ,ZZ11 ,ZZ12 ,ZZ13 ,ZZ14 ,ZZ15 ,ZZ16 ,ZZ17 ,ZZ18 ,ZZ19 ,ZZ20 ,ZZ21 ,ZZ22 ,ZZ23 ,ZZ24 ,ZZ25 ,ZZ26 ,ZZ27 ,ZZ28 ,ZZ29 ,ZZ30 ,ZZ31 ,ZZ32 ,ZZ33 ,ZZ34 ,ZZ35 ,ZZ36 ,ZZ37 ,ZZ38 ,ZZ39 ,ZZ40 ,Zz41"
                +",zz42,zz43,zz44,zz45,zz46,zz47,zz48,zz49,zz50,zz51,zz52,zz53,zz54,zz55,zz56,zz57,zz58,zz59,zz60,zz61,zz62,zz63,zz64) values('");
            sql.Append(zz.tjbh.Trim() + "','");
            sql.Append(zz.tjcs + "','");
            sql.Append(zz.jcrq + "','");
            sql.Append(zz.jcys + "','");

            sql.Append(zz.zz01 + "','");
            sql.Append(zz.zz02 + "','");
            sql.Append(zz.zz03 + "','");
            sql.Append(zz.zz04 + "','");
            sql.Append(zz.zz05 + "','");
            sql.Append(zz.zz06 + "','");
            sql.Append(zz.zz07 + "','");
            sql.Append(zz.zz08 + "','");
            sql.Append(zz.zz09 + "','");
            sql.Append(zz.zz10 + "','");

            sql.Append(zz.zz11 + "','");
            sql.Append(zz.zz12 + "','");
            sql.Append(zz.zz13 + "','");
            sql.Append(zz.zz14 + "','");
            sql.Append(zz.zz15 + "','");
            sql.Append(zz.zz16 + "','");
            sql.Append(zz.zz17 + "','");
            sql.Append(zz.zz18 + "','");
            sql.Append(zz.zz19 + "','");
            sql.Append(zz.zz20 + "','");

            sql.Append(zz.zz21 + "','");
            sql.Append(zz.zz22 + "','");
            sql.Append(zz.zz23 + "','");
            sql.Append(zz.zz24 + "','");
            sql.Append(zz.zz25 + "','");
            sql.Append(zz.zz26 + "','");
            sql.Append(zz.zz27 + "','");
            sql.Append(zz.zz28 + "','");
            sql.Append(zz.zz29 + "','");
            sql.Append(zz.zz30 + "','");

            sql.Append(zz.zz31 + "','");
            sql.Append(zz.zz32 + "','");
            sql.Append(zz.zz33 + "','");
            sql.Append(zz.zz34 + "','");
            sql.Append(zz.zz35 + "','");
            sql.Append(zz.zz36 + "','");
            sql.Append(zz.zz37 + "','");
            sql.Append(zz.zz38 + "','");
            sql.Append(zz.zz39 + "','");
            sql.Append(zz.zz40 + "','");

            sql.Append(zz.zz41 + "','");
            sql.Append(zz.zz42 + "','");
            sql.Append(zz.zz43 + "','");
            sql.Append(zz.zz44 + "','");
            sql.Append(zz.zz45 + "','");
            sql.Append(zz.zz46 + "','");
            sql.Append(zz.zz47 + "','");
            sql.Append(zz.zz48 + "','");
            sql.Append(zz.zz49 + "','");
            sql.Append(zz.zz50 + "','");

            sql.Append(zz.zz51 + "','");
            sql.Append(zz.zz52 + "','");
            sql.Append(zz.zz53 + "','");
            sql.Append(zz.zz54 + "','");
            sql.Append(zz.zz55 + "','");
            sql.Append(zz.zz56 + "','");
            sql.Append(zz.zz57 + "','");
            sql.Append(zz.zz58 + "','");
            sql.Append(zz.zz59 + "','");
            sql.Append(zz.zz60 + "','");

            sql.Append(zz.zz61 + "','");
            sql.Append(zz.zz62 + "','");
            sql.Append(zz.zz63 + "','");
            sql.Append(zz.zz64 + "')");

            sqls.Add(sql.ToString());
        }