public List <Models.Data> Retrieve(string dataId = "") { //Return data from DB using (DataAccessComponent dac = new DataAccessComponent()) { DataTable dtResult = dac.RetrieveContent(dataId); return(DataTableToList <Models.Data>(dtResult)); } }
public bool Delete(string dataId) { if (!string.IsNullOrEmpty(dataId)) { //Delete from DB using (DataAccessComponent dac = new DataAccessComponent()) { return(dac.DeleteContent(dataId)); } } else { return(false); } }
public bool Update(Models.Data data) { if (data != null) { //Update data to DB using (DataAccessComponent dac = new DataAccessComponent()) { return(dac.UpdateContent(data)); } } else { return(false); } }