示例#1
0
        /// <summary>
        /// Build a class from a database row
        /// </summary>
        public static Icsep BuildIcsepFromRow(DataRow row)
        {
            var entity = BuildIcsepBaseFromRow <Icsep>(row);

            if (entity != null)
            {
                var childRowP_ttblicsp = row.GetChildRows("P_ttblicsp").FirstOrDefault();
                if (childRowP_ttblicsp != null)
                {
                    entity.icspes = (Icsp)SetKeyFields(entity, Icsp.BuildIcspFromRow(childRowP_ttblicsp), "cono,prod", "cono,prod");
                }
                var childRowP_ttblicsw = row.GetChildRows("P_ttblicsw").FirstOrDefault();
                if (childRowP_ttblicsw != null)
                {
                    entity.icswes = (Icsw)SetKeyFields(entity, Icsw.BuildIcswFromRow(childRowP_ttblicsw), "cono,whse,prod", "cono,whse,prod");
                }
            }
            return(entity);
        }
示例#2
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromIcsw(ref DataRow row, Icsw entity)
 {
     UpdateRowFromIcswBase(ref row, entity);
 }
示例#3
0
 /// <summary>
 /// Build a minimal row from a class (key fields only)
 /// </summary>
 public static void BuildMinimalRow(ref DataRow row, Icsw entity)
 {
     IcswBase.BuildMinimalRow(ref row, entity);
 }