Пример #1
0
        public static Etccdetdata849ihdr BuildEtccdetdata849ihdrFromRow(DataRow row)
        {
            Etccdetdata849ihdr entity = new Etccdetdata849ihdr();

            entity.sxxmldocRowid = row.Field <byte[]>("sxxmldoc-rowid").ToStringEncoded();
            entity.section       = row.IsNull("section") ? string.Empty : row.Field <string>("section");
            entity.approvty      = row.IsNull("approvty") ? string.Empty : row.Field <string>("approvty");
            entity.datasource    = row.IsNull("datasource") ? string.Empty : row.Field <string>("datasource");
            entity.sectionD      = row.IsNull("section-d") ? string.Empty : row.Field <string>("section-d");
            entity.secseq        = row.IsNull("secseq") ? 0 : row.Field <int>("secseq");
            entity.errcnt        = row.IsNull("errcnt") ? 0 : row.Field <int>("errcnt");
            entity.exccnt        = row.IsNull("exccnt") ? 0 : row.Field <int>("exccnt");
            entity.infocnt       = row.IsNull("infocnt") ? 0 : row.Field <int>("infocnt");
            entity.stageword     = row.IsNull("stageword") ? string.Empty : row.Field <string>("stageword");
            entity.stagecd       = row.IsNull("stagecd") ? 0 : row.Field <int>("stagecd");
            entity.processedfl   = row.Field <bool>("processedfl");
            entity.partner       = row.IsNull("partner") ? string.Empty : row.Field <string>("partner");
            entity.headdt        = row.Field <DateTime?>("headdt");
            entity.purpose       = row.IsNull("purpose") ? string.Empty : row.Field <string>("purpose");
            entity.vendno        = row.IsNull("vendno") ? decimal.Zero : row.Field <decimal>("vendno");
            entity.conoerpsysid  = row.IsNull("conoerpsysid") ? string.Empty : row.Field <string>("conoerpsysid");
            entity.venderpsysid  = row.IsNull("venderpsysid") ? string.Empty : row.Field <string>("venderpsysid");
            entity.venddunsno    = row.IsNull("venddunsno") ? string.Empty : row.Field <string>("venddunsno");
            entity.contractno    = row.IsNull("contractno") ? string.Empty : row.Field <string>("contractno");
            entity.contstatcd    = row.IsNull("contstatcd") ? string.Empty : row.Field <string>("contstatcd");
            entity.contmsg       = row.IsNull("contmsg") ? string.Empty : row.Field <string>("contmsg");
            entity.validcd       = row.IsNull("validcd") ? string.Empty : row.Field <string>("validcd");
            entity.rejectcd      = row.IsNull("rejectcd") ? string.Empty : row.Field <string>("rejectcd");
            entity.rejectmsg     = row.IsNull("rejectmsg") ? string.Empty : row.Field <string>("rejectmsg");
            entity.follupcd      = row.IsNull("follupcd") ? string.Empty : row.Field <string>("follupcd");
            entity.follupmsg     = row.IsNull("follupmsg") ? string.Empty : row.Field <string>("follupmsg");
            entity.refer         = row.IsNull("refer") ? string.Empty : row.Field <string>("refer");
            entity.linecnt       = row.IsNull("linecnt") ? 0 : row.Field <int>("linecnt");
            entity.createdt      = row.Field <DateTime?>("createdt");
            entity.createtm      = row.IsNull("createtm") ? string.Empty : row.Field <string>("createtm");
            entity.transdt       = row.Field <DateTime?>("transdt");
            entity.transtm       = row.IsNull("transtm") ? string.Empty : row.Field <string>("transtm");
            entity.transproc     = row.IsNull("transproc") ? string.Empty : row.Field <string>("transproc");
            entity.operinit      = row.IsNull("operinit") ? string.Empty : row.Field <string>("operinit");
            entity.docid         = row.IsNull("docid") ? 0 : row.Field <int>("docid");
            entity.origdata      = row.IsNull("origdata") ? string.Empty : row.Field <string>("origdata");
            entity.ovrddata      = row.IsNull("ovrddata") ? string.Empty : row.Field <string>("ovrddata");
            entity.transdata     = row.IsNull("transdata") ? string.Empty : row.Field <string>("transdata");
            entity.sortseq       = row.IsNull("sortseq") ? 0 : row.Field <int>("sortseq");
            entity.docidD        = row.IsNull("docid-d") ? string.Empty : row.Field <string>("docid-d");
            entity.userfield     = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield");
            return(entity);
        }
Пример #2
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromEtccdetdata849ihdr(ref DataRow row, Etccdetdata849ihdr entity)
 {
     row.SetField("sxxmldoc-rowid", entity.sxxmldocRowid.ToByteArray());
     row.SetField("section", entity.section);
     row.SetField("approvty", entity.approvty);
     row.SetField("datasource", entity.datasource);
     row.SetField("section-d", entity.sectionD);
     row.SetField("secseq", entity.secseq);
     row.SetField("errcnt", entity.errcnt);
     row.SetField("exccnt", entity.exccnt);
     row.SetField("infocnt", entity.infocnt);
     row.SetField("stageword", entity.stageword);
     row.SetField("stagecd", entity.stagecd);
     row.SetField("processedfl", entity.processedfl);
     row.SetField("partner", entity.partner);
     row.SetField("headdt", entity.headdt);
     row.SetField("purpose", entity.purpose);
     row.SetField("vendno", entity.vendno);
     row.SetField("conoerpsysid", entity.conoerpsysid);
     row.SetField("venderpsysid", entity.venderpsysid);
     row.SetField("venddunsno", entity.venddunsno);
     row.SetField("contractno", entity.contractno);
     row.SetField("contstatcd", entity.contstatcd);
     row.SetField("contmsg", entity.contmsg);
     row.SetField("validcd", entity.validcd);
     row.SetField("rejectcd", entity.rejectcd);
     row.SetField("rejectmsg", entity.rejectmsg);
     row.SetField("follupcd", entity.follupcd);
     row.SetField("follupmsg", entity.follupmsg);
     row.SetField("refer", entity.refer);
     row.SetField("linecnt", entity.linecnt);
     row.SetField("createdt", entity.createdt);
     row.SetField("createtm", entity.createtm);
     row.SetField("transdt", entity.transdt);
     row.SetField("transtm", entity.transtm);
     row.SetField("transproc", entity.transproc);
     row.SetField("operinit", entity.operinit);
     row.SetField("docid", entity.docid);
     row.SetField("origdata", entity.origdata);
     row.SetField("ovrddata", entity.ovrddata);
     row.SetField("transdata", entity.transdata);
     row.SetField("sortseq", entity.sortseq);
     row.SetField("docid-d", entity.docidD);
     row.SetField("userfield", entity.userfield);
 }