public static ChequeReq FromModel(ChequeIN.Models.ChequeReq model) { ChequeReq c = new ChequeReq() { ChequeReqID = model.ChequeReqID, FreeFood = model.FreeFood, OnlinePurchases = model.OnlinePurchases, ToBeMailed = model.ToBeMailed, LedgerAccountID = model.LedgerAccountID, PreTax = model.PreTax, GST = model.GST, PST = model.PST, HST = model.HST, MailingAddress = model.MailingAddress, //TODO alias here StatusHistory = model.StatusHistory, PayeeName = model.PayeeName, Description = model.Description, ApprovedBy = model.ApprovedBy }; return(c); }
public static ChequeIN.Models.ChequeReq ToModel(ChequeReq cheque, int userProfileID, ICollection <SupportingDocument> docs, ICollection <Status> status) { ChequeIN.Models.ChequeReq c = new ChequeIN.Models.ChequeReq() { UserProfileID = userProfileID, SupportingDocuments = docs, StatusHistory = status, ChequeReqID = cheque.ChequeReqID, FreeFood = cheque.FreeFood, OnlinePurchases = cheque.OnlinePurchases, ToBeMailed = cheque.ToBeMailed, LedgerAccountID = cheque.LedgerAccountID, PreTax = cheque.PreTax, GST = cheque.GST, PST = cheque.PST, HST = cheque.HST, MailingAddress = cheque.MailingAddress, //TODO PayeeName = cheque.PayeeName, Description = cheque.Description, ApprovedBy = cheque.ApprovedBy }; return(c); }