public ComHirViewModel GetComHirById(int id) { var result = new ComHirViewModel { id = 10, WHTaxCorporation = 1.10, WHTaxIndividual = 2.20, MaximumCommission = 3.00, DeductionRate = 4.00, EntCodeShow = "00001", EntNameShow = "สายใจ สุดใจ", HiringChargeIncludeVAT = 3.00, PayCommissionTo = "สายหยุด", AmountVAT = 4.00, AbsorbTax = "01", AmountIncludeVAT = 5.00, CommissionRate = 6.00, MaxRate = 7.00, WithHoldTaxAmount = 8.00, CommissionTerm = 9.00, MaxTerm = 5, NetPaid = 10.00, CommissionVATNo = 11.00, InterestRate = 12.00, CommissionVATDate = Convert.ToDateTime("07-06-2015"), //Low LowInterestRate = 13.00, CampaignName = "ชื่อ Campaing" }; return result; }
public Boolean Insert(ComHirViewModel obj) { if (obj.id != null) { //Update } else { //Insert } return true; }