public decimal GetDaySalary(WorkDay day) { if (day != null) { if (day.Revenue < 6000) return 300; else if (day.Revenue <= 10000) return (decimal)(day.Revenue * 0.05); else if (day.Revenue >= 100000) return (decimal)((day.Revenue - 10000) * 0.1 + 500 + 0.15 * day.Revenue); else return (decimal)((day.Revenue - 10000) * 0.1 + 500); } else return 0; }
public decimal GetDaySalary(WorkDay day) { return day.Hours * HourPay; }