示例#1
0
        public static Safetyallowanceresults BuildSafetyallowanceresultsFromRow(DataRow row)
        {
            Safetyallowanceresults entity = new Safetyallowanceresults();

            entity.safeallamt  = row.IsNull("safeallamt") ? decimal.Zero : row.Field <decimal>("safeallamt");
            entity.safeallamt2 = row.IsNull("safeallamt2") ? decimal.Zero : row.Field <decimal>("safeallamt2");
            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 UpdateRowFromSafetyallowanceresults(ref DataRow row, Safetyallowanceresults entity)
 {
     row.SetField("safeallamt", entity.safeallamt);
     row.SetField("safeallamt2", entity.safeallamt2);
     row.SetField("userfield", entity.userfield);
 }