예제 #1
0
        public DailyReportProxy GetPersonDailyReport(decimal personId, string miladiDate)
        {
            try
            {
                DateTime dayDate = Utility.ToMildiDateTime(miladiDate);
                BPersonMonthlyWorkedTime monthlyReport = new BPersonMonthlyWorkedTime(personId);
                PersonalMonthlyReportRow row           = monthlyReport.GetPersonDailyReport(dayDate);

                DailyReportProxy proxy = new DailyReportProxy();
                proxy.AllowableOverTime        = row.AllowableOverTime;
                proxy.DailyAbsence             = row.DailyAbsence;
                proxy.DailyMission             = row.DailyMission;
                proxy.HourlyMeritoriouslyLeave = row.HourlyMeritoriouslyLeave;
                proxy.HourlyMission            = row.HourlyMission;
                proxy.HourlyPureOperation      = row.HourlyPureOperation;
                proxy.HourlySickLeave          = row.HourlySickLeave;
                proxy.HourlyUnallowableAbsence = row.HourlyUnallowableAbsence;
                proxy.HourlyWithoutPayLeave    = row.HourlyWithoutPayLeave;
                proxy.ShiftPairs = row.ShiftPairs;

                return(proxy);
            }
            catch (Exception ex)
            {
                LogException(ex, "BTraffic", "GetPersonDailyReport");
                throw ex;
            }
        }
        public void GetReport_PersonalDailyReportTest()
        {
            try
            {
                PersianDateTime          dt = new PersianDateTime(DateTime.Now);
                BPersonMonthlyWorkedTime pb = new BPersonMonthlyWorkedTime(32688);
                ClearSession();
                PersonalMonthlyReportRow row = pb.GetPersonDailyReport(Utility.ToMildiDate("1390/06/03"));

                string value = row.PeriodicDailyPureOperation;
            }
            catch (Exception ex) { Assert.Fail(ex.Message); }
        }