Ejemplo n.º 1
0
 public static CheckItemRecord SetValue(CheckItemRecord cir, DataRow dr)
 {
     if (dr != null)
     {
         cir.strID       = dr["strID"].ToString();
         cir.dtCheckTime = PageBase.static_ext_date(dr["dtCheckTime"]);
         cir.nAcceptID   = PageBase.static_ext_int(dr["nAcceptID"]);
         cir.nUserID     = PageBase.static_ext_int(dr["nUserID"]);
         cir.JiHuaID     = PageBase.static_ext_int(dr["JiHuaID"]);
     }
     return(cir);
 }
Ejemplo n.º 2
0
        /// <summary>
        /// 返回list对象
        /// </summary>
        /// <param name="dt"></param>
        /// <returns></returns>
        public static List <CheckItemRecord> ListValue(DataTable dt)
        {
            List <CheckItemRecord> CheckItemRecordList = new List <CheckItemRecord>();
            CheckItemRecord        checkitemrecord;

            if (dt.Rows.Count > 0)
            {
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    checkitemrecord = new CheckItemRecord();
                    CheckItemRecordList.Add(SetValue(checkitemrecord, dt.Rows[i]));
                }
            }
            return(CheckItemRecordList);
        }