/// <summary> /// Update a database row from a class /// </summary> public static void UpdateRowFromReceipttransdetailcriteria(ref DataRow row, Receipttransdetailcriteria entity) { row.SetField("co_num", entity.coNum); row.SetField("wh_num", entity.whNum); row.SetField("po_number", entity.poNumber); row.SetField("po_suffix", entity.poSuffix); row.SetField("vendor_id", entity.vendorId); row.SetField("abs_num", entity.absNum); row.SetField("vend_item", entity.vendItem); row.SetField("row_status", entity.rowStatus); row.SetField("userfield", entity.userfield); }
public static Receipttransdetailcriteria BuildReceipttransdetailcriteriaFromRow(DataRow row) { Receipttransdetailcriteria entity = new Receipttransdetailcriteria(); entity.coNum = row.IsNull("co_num") ? string.Empty : row.Field<string>("co_num"); entity.whNum = row.IsNull("wh_num") ? string.Empty : row.Field<string>("wh_num"); entity.poNumber = row.IsNull("po_number") ? string.Empty : row.Field<string>("po_number"); entity.poSuffix = row.IsNull("po_suffix") ? string.Empty : row.Field<string>("po_suffix"); entity.vendorId = row.IsNull("vendor_id") ? string.Empty : row.Field<string>("vendor_id"); entity.absNum = row.IsNull("abs_num") ? string.Empty : row.Field<string>("abs_num"); entity.vendItem = row.IsNull("vend_item") ? string.Empty : row.Field<string>("vend_item"); entity.rowStatus = row.IsNull("row_status") ? string.Empty : row.Field<string>("row_status"); entity.userfield = row.IsNull("userfield") ? string.Empty : row.Field<string>("userfield"); return entity; }