public DetailDto getTransactionType(String id) { transaction_type transaction_Type = db.transaction_type.Where(s => s.id == id).FirstOrDefault(); DetailDto dto = new DetailDto(transaction_Type.id, transaction_Type.name); return(dto); }
public transaction_type find_transaction_type_By_AppId(string Appid) { try { transaction_type = db.transaction_types.SingleOrDefault(a => a.App_id == Appid); return(transaction_type); } catch (Exception) { return(null); } }
public transaction_type find_transaction_type_By_ID(int id) { try { transaction_type = db.transaction_types.SingleOrDefault(a => a.id == id); return(transaction_type); } catch (Exception) { return(null); } }
public transaction_type delete_transaction_type() { try { transaction_type prev_transaction_type = db.transaction_types.SingleOrDefault(a => a.id == transaction_type.id); db.transaction_types.DeleteOnSubmit(prev_transaction_type); return(transaction_type); } catch (Exception) { return(null); } }
public transaction_type alter_transaction_type() { try { transaction_type prev_transaction_type = db.transaction_types.SingleOrDefault(a => a.id == transaction_type.id); prev_transaction_type.name = transaction_type.name; db.SubmitChanges(); return(transaction_type); } catch (Exception) { return(null); } }
public transaction_type_crud(transaction_type transaction_type_) { this.transaction_type_ = transaction_type_; }