Exemple #1
0
        private List <P10TaxRecord> GetEmployeeMonthlyTaxRecords()
        {
            try
            {
                System.Globalization.DateTimeFormatInfo mfi = new System.Globalization.DateTimeFormatInfo();
                List <P10TaxRecord>          TaxRec         = new List <P10TaxRecord>();
                List <psuedovwPayrollMaster> taxrec         = GetPayrollMasterList();

                foreach (psuedovwPayrollMaster pm in taxrec)
                {
                    P10TaxRecord tr = new P10TaxRecord();
                    //populate
                    tr.MonthInt = pm.Period; // all periods = month
                    tr.Month    = mfi.GetAbbreviatedMonthName(tr.MonthInt);
                    tr.PAYETax  = pm.PayeTax;

                    TaxRec.Add(tr);
                }
                return(TaxRec);
            }
            catch (Exception ex)
            {
                Utils.ShowError(ex);
                return(null);
            }
        }
Exemple #2
0
        private List <P10TaxRecord> GetMonthlyTax()
        {
            try
            {
                System.Globalization.DateTimeFormatInfo mfi = new System.Globalization.DateTimeFormatInfo();

                List <P10TaxRecord> TaxRec = new List <P10TaxRecord>();

                var _employeesquery = from emp in db.Employees
                                      where emp.EmployerId == _employer.Id
                                      select emp;
                List <Employee> _Employees = _employeesquery.ToList();
                foreach (var employee in _Employees)
                {
                    List <EmployersMonthlyTaxRecord> taxrecordlist = rep.GetEmployerTaxRecord(_current, employee.Id, employee.EmpNo, _year);

                    foreach (EmployersMonthlyTaxRecord pm in taxrecordlist)
                    {
                        P10TaxRecord tr = new P10TaxRecord();
                        //populate
                        tr.MonthInt = pm.MonthInt; // all periods = month
                        tr.Month    = mfi.GetAbbreviatedMonthName(tr.MonthInt);
                        tr.PAYETax  = pm.J;

                        TaxRec.Add(tr);
                    }
                }
                return(TaxRec);
            }
            catch (Exception ex)
            {
                Utils.ShowError(ex);
                return(null);
            }
        }
        private List <P10TaxRecord> GetEmployeeMonthlyTaxRecords()
        {
            System.Globalization.DateTimeFormatInfo mfi = new

                                                          System.Globalization.DateTimeFormatInfo();

            List <P10TaxRecord> TaxRec = new List <P10TaxRecord>();

            List <psuedovwPayrollMaster> taxrec = rep.GetEmployeeTaxRecord(_current, _EmpNo, _year);

            foreach (psuedovwPayrollMaster pm in taxrec)
            {
                P10TaxRecord tr = new P10TaxRecord();
                //populate
                tr.MonthInt = pm.Period; // all periods = month
                tr.Month    = mfi.GetAbbreviatedMonthName(tr.MonthInt);
                tr.PAYETax  = pm.PayeTax;
                //tr.AuditTax = this.GetAuditTax;
                //tr.FringeBenefitTax = this.GetFringeTax;

                TaxRec.Add(tr);
            }

            return(TaxRec);
        }