private void fnUILoadStudentRecord(FpStudentObject fso,TempStudentInfo tso)
    {
        if (fso == null) {
            this.lbAlertMsg.Visible = true;
            this.lbAlertMsg.Text = "没有该学员的指纹记录信息";
        }
        else if (tso == null)
        {
            this.lbAlertMsg.Visible = true;
            this.lbAlertMsg.Text = "没有该学员的个人信息";
        }
        else {
            fso.fromTempStudentInfo(tso);
            try {
                this.lbName.Text = fso.NAME;
                this.lbSex.Text = fso.SEX;
                this.lbIdCard.Text = fso.IDCARD;
                this.imgPerson.ImageUrl = string.Format("~/ShowImage.aspx?idcardtype=A&idcard={0}", fso.IDCARD);
                this.lbIDCardType.Text = "第二代身份证";
                this.lbBrithday.Text = DateTimeHelper.fnIsNewDateTime(fso.BRITHDAY) ? "" : fso.BRITHDAY.ToString();
                this.lbPhone.Text = fso.PHONE;
                this.lbAddress.Text = fso.ADDRESS;
                this.lbDrvSchool.Text = fso.DRV_SCHOOL;
                this.lbDocNum.Text = fso.DRV_DOCNUM;
                this.lbDrvType.Text = fso.DRV_TYPE;
                this.lbRemark.Text = fso.REMARK;
                this.lbAlertMsg.Text = "";

            }
            catch (NullReferenceException nre) {

            }

        }
    }
示例#2
0
        public static TempStudentInfo QueryStudent(String glbm, String sfzmhm)
        {
            TempStudentInfo info = null;
            //a.glbm like '{0}%' and
            String sql      = "select distinct '' \"jxmc\",b.jxmc \"jxdm\", 'A' \"idCardType\", a.sfzmhm \"idCard\",a.xm \"name\",b.zkcx \"zkcx\",a.lsh \"lsh\",to_char(b.yxqs,'yyyy-MM-dd') \"yxqs\",to_char(b.yxqz,'yyyy-MM-dd') \"yxqz\",b.jly \"jly\" from fzkyy.st_drv_flow a left join fzkyy.st_drv_examcard b on a.sfzmhm=b.sfzmhm where  a.ywlx in ('A','B') and a.sfzmhm='{1}'";
            String queryStr = string.Format(sql, new string[] { glbm, sfzmhm });

            //IDataAccess access = new OracleDataHelper(System.Configuration.ConfigurationManager.AppSettings["DefaultConnString2"]);
            IDataAccess access = GetInnerDbAccess();
            DataTable   dt     = access.SelectDataTable(queryStr, "tmp");

            if (dt != null && dt.Rows.Count > 0)
            {
                log.Debug("查询到用户!");
                info = new TempStudentInfo();
                DataRow dr = dt.Rows[0];
                info.jxdm       = dr[1] == null ? string.Empty : dr[1].ToString();
                info.idCardType = "A";
                info.idCard     = sfzmhm;
                info.name       = dr[4].ToString();
                info.zkcx       = dr[5].ToString();
                info.lsh        = dr[6].ToString();
                info.yxqs       = dr[7] == null ? string.Empty : dr[7].ToString();
                info.yxqz       = dr[8] == null ? string.Empty : dr[8].ToString();
                info.jly        = dr[9] == null ? string.Empty : dr[9].ToString();

/*
 *              sql = "select distinct decode(xb,1,'男',2,'女') sex,lxdh phone,lxdh mobile,lxzsxxdz address,to_char(csrq,'yyyy-MM-dd') csrq  from fzkyy.st_person a where a.sfzmhm='{1}'";
 *              queryStr = string.Format(sql, new string[] { glbm, sfzmhm });
 *              DataTable dt2 = access.SelectDataTable(queryStr, "tmp");
 *              if (dt2 != null && dt2.Rows.Count > 0)
 *              {
 *                  dr = dt2.Rows[0];
 *                  info.sex=dr[0] == null ? string.Empty : dr[0].ToString();
 *                  info.phone = dr[1] == null ? string.Empty : dr[1].ToString();
 *                  info.mobile = dr[2] == null ? string.Empty : dr[2].ToString();
 *                  info.address = dr[3] == null ? string.Empty : dr[3].ToString();
 *                  info.birthday = dr[4] == null ? string.Empty : dr[4].ToString();
 *              }
 * */
            }
            return(info);
        }
    private void fnUILoadStudentRecord(FpStudentObject fso ,TempStudentInfo tso)
    {
        if (fso == null) {
            this.lbAlertMsg.Visible = true;
            this.lbAlertMsg.Text = "没有该学员的指纹记录信息";
        }
        else if (tso == null)
        {
            this.lbAlertMsg.Visible = true;
            this.lbAlertMsg.Text = "没有该学员的个人信息";
        }
        else {
            //fso.fromTempStudentInfo(tso);
            try {
                this.lbName.Text = fso.NAME;
              //  this.lbSex.Text = fso.SEX;/;
                this.lbIdCard.Text = fso.IDCARD;
              //  this.imgPerson.ImageUrl = string.Format("~/ShowImage.aspx?idcardtype=A&idcard={0}", fso.IDCARD);
               // this.lbIDCardType.Text = "第二代身份证";
              //  this.lbBrithday.Text = DateTimeHelper.fnIsNewDateTime(fso.BRITHDAY) ? "" : fso.BRITHDAY.ToString();
              //  this.lbPhone.Text = fso.PHONE;
              //  this.lbAddress.Text = fso.ADDRESS;
              //  this.lbDrvSchool.Text = fso.DRV_SCHOOL;
              //  this.lbDocNum.Text = fso.DRV_DOCNUM;
             //   this.lbDrvType.Text = fso.DRV_TYPE;
                this.lbRemark.Text = fso.REMARK;
                this.lbAlertMsg.Text = "";
                this.lbLsh.Text = fso.LSH;
                this.lbSchoolName.Text = fso.SCHOOL_NAME;
                this.lbStaute.Text = FpStudentObject.GetDictStatue()[fso.STATUE];
                this.lbFeeStatue.Text = fso.FEE_STATUE == "Y" ? "是" : "否";
                this.lbKm3Verify.Text = fso.KM3_VERIFY == "Y" ? "是" : "否";
                this.lbCarType.Text = fso.CAR_TYPE;
                FpLocalType localType=SimpleOrmOperator.Query<FpLocalType>(fso.LOCALTYPE);
                this.lbLocalType.Text = localType == null ? "" : localType.NAME;
            }
            catch (NullReferenceException nre) {

            }

        }
    }
示例#4
0
 public void fromTempStudentInfo(TempStudentInfo info)
 {
     if (info == null) return;
     this.name = info.name;
     this.sex = info.sex;
     this.phone = info.phone;
     this.address = info.address;
        // this.brithday = DateTime.Parse(info.birthday);
     this.idcard = info.idCard;
 }
示例#5
0
        public static TempStudentInfo QueryStudent(String glbm, String sfzmhm)
        {
            TempStudentInfo info = null;
            //a.glbm like '{0}%' and
            String sql = "select distinct '' \"jxmc\",b.jxmc \"jxdm\", 'A' \"idCardType\", a.sfzmhm \"idCard\",a.xm \"name\",b.zkcx \"zkcx\",a.lsh \"lsh\",to_char(b.yxqs,'yyyy-MM-dd') \"yxqs\",to_char(b.yxqz,'yyyy-MM-dd') \"yxqz\",b.jly \"jly\" from fzkyy.st_drv_flow a left join fzkyy.st_drv_examcard b on a.sfzmhm=b.sfzmhm where  a.ywlx in ('A','B') and a.sfzmhm='{1}'";
            String queryStr = string.Format(sql, new string[] { glbm, sfzmhm });

            //IDataAccess access = new OracleDataHelper(System.Configuration.ConfigurationManager.AppSettings["DefaultConnString2"]);
            IDataAccess access=GetInnerDbAccess();
            DataTable dt = access.SelectDataTable(queryStr, "tmp");
            if (dt != null && dt.Rows.Count > 0)
            {
                log.Debug("查询到用户!");
                info = new TempStudentInfo();
                DataRow dr = dt.Rows[0];
                info.jxdm = dr[1] == null ? string.Empty : dr[1].ToString();
                info.idCardType = "A";
                info.idCard = sfzmhm;
                info.name = dr[4].ToString();
                info.zkcx = dr[5].ToString();
                info.lsh = dr[6].ToString();
                info.yxqs = dr[7] == null ? string.Empty : dr[7].ToString();
                info.yxqz = dr[8] == null ? string.Empty : dr[8].ToString();
                info.jly = dr[9] == null ? string.Empty : dr[9].ToString();
            /*
                sql = "select distinct decode(xb,1,'男',2,'女') sex,lxdh phone,lxdh mobile,lxzsxxdz address,to_char(csrq,'yyyy-MM-dd') csrq  from fzkyy.st_person a where a.sfzmhm='{1}'";
                queryStr = string.Format(sql, new string[] { glbm, sfzmhm });
                DataTable dt2 = access.SelectDataTable(queryStr, "tmp");
                if (dt2 != null && dt2.Rows.Count > 0)
                {
                    dr = dt2.Rows[0];
                    info.sex=dr[0] == null ? string.Empty : dr[0].ToString();
                    info.phone = dr[1] == null ? string.Empty : dr[1].ToString();
                    info.mobile = dr[2] == null ? string.Empty : dr[2].ToString();
                    info.address = dr[3] == null ? string.Empty : dr[3].ToString();
                    info.birthday = dr[4] == null ? string.Empty : dr[4].ToString();
                }
             * */
            }
            return info;
        }