Esempio n. 1
0
        public M_Plat_CompDoc GetModelFromReader(DbDataReader rdr)
        {
            M_Plat_CompDoc model = new M_Plat_CompDoc();

            model.ID         = Convert.ToInt32(rdr["ID"]);
            model.Name       = rdr["Name"].ToString();
            model.FileSize   = rdr["FileSize"].ToString();
            model.VPath      = rdr["VPath"].ToString();
            model.DocType    = Convert.ToInt32(rdr["DocType"]);
            model.UserID     = Convert.ToInt32(rdr["UserID"]);
            model.CreateTime = Convert.ToDateTime(rdr["CreateTime"]);
            rdr.Close();
            return(model);
        }
Esempio n. 2
0
        public override SqlParameter[] GetParameters()
        {
            M_Plat_CompDoc model = this;

            EmptyDeal();
            SqlParameter[] sp = GetSP();
            sp[0].Value = model.ID;
            sp[1].Value = model.Name;
            sp[2].Value = model.FileSize;
            sp[3].Value = model.VPath;
            sp[4].Value = model.DocType;
            sp[5].Value = model.UserID;
            sp[6].Value = model.CreateTime;
            return(sp);
        }