public C_SKU_VER_MAPPING GetDataObject() { C_SKU_VER_MAPPING DataObject = new C_SKU_VER_MAPPING(); DataObject.EDIT_TIME = this.EDIT_TIME; DataObject.EDIT_EMP = this.EDIT_EMP; DataObject.CUSTOMER_VERSION = this.CUSTOMER_VERSION; DataObject.FOX_VERSION2 = this.FOX_VERSION2; DataObject.FOX_VERSION1 = this.FOX_VERSION1; DataObject.CUSTOMER_SKUNO = this.CUSTOMER_SKUNO; DataObject.FOX_SKUNO = this.FOX_SKUNO; DataObject.ID = this.ID; return(DataObject); }
public C_SKU_VER_MAPPING GetMappingBySkuAndVersion(string sku, string version, OleExec sfcdb) { string sql = $@" select * from C_SKU_VER_MAPPING where fox_skuno='{sku}' and fox_version1='{version}' "; DataTable dataTable = sfcdb.ExecSelect(sql).Tables[0]; C_SKU_VER_MAPPING skuMapping = null; Row_C_SKU_VER_MAPPING rowMapping = null; if (dataTable.Rows.Count > 0) { rowMapping = (Row_C_SKU_VER_MAPPING)this.NewRow(); rowMapping.loadData(dataTable.Rows[0]); skuMapping = rowMapping.GetDataObject(); } return(skuMapping); }