public ActionResult AppearlDept()
 {
     ApprealInfoEntity iAPP = new ApprealInfoEntity();
     ViewData["DeptName"] = GetAllDepatementListItem();
     iAPP.StartDate = DateTime.Today.Date.ToString("dd/MM/yyyy");
     iAPP.EndDate = DateTime.Today.Date.ToString("dd/MM/yyyy");
     return View("AppearlDept", iAPP);
 }
 public JsonResult AppearlDeptList(string startDate = "", string endDate = "", string DeptName = "", int jtStartIndex = 0, int jtPageSize = 0, string jtSorting = null)
 {
     try
     {
         try
         {
             ApprealInfoEntity _Model = new ApprealInfoEntity();
             _Model.DeptName = DeptName;
             _Model.StartDate = startDate;
             _Model.EndDate = endDate;
             DataTable dt = (DataTable)ExecuteDB(ERPTask.AG_GetAPPDeptRecord, _Model);
             List<ApprealInfoEntity> ItemList = null;
             ItemList = new List<ApprealInfoEntity>();
             int iCount = 0;
             int offset = 0;
             offset = jtStartIndex / jtPageSize;
             foreach (DataRow dr in dt.Rows)
             {
                 if (iCount >= jtStartIndex && iCount < (jtPageSize * (offset + 1)))
                 {
                     ItemList.Add(new ApprealInfoEntity()
                     {
                         PDate = dr["PDate"].ToString(),
                         EMPID = dr["EMPID"].ToString(),
                         EName = dr["EName"].ToString(),
                         Designation = dr["Designation"].ToString(),
                         DeptName = dr["DeptName"].ToString(),
                         Intime = dr["Intime"].ToString(),
                         Outtime = dr["Outtime"].ToString(),
                         Status = dr["Status"].ToString(),
                     });
                 }
                 iCount += 1;
             }
             var RecordCount = dt.Rows.Count;
             var Record = ItemList;
             Session["APPDept"] = ItemList;
             return Json(new { Result = "OK", Records = Record, TotalRecordCount = RecordCount });
         }
         catch (Exception ex)
         {
             return Json(new { Result = "ERROR", Message = ex.Message });
         }
     }
     catch (Exception ex)
     {
         return Json(new { Result = "ERROR", Message = ex.Message });
     }
 }
 public ActionResult APPEMPExcelReport(string EX1 = "", string EX2 = "", string EX3 = "")
 {
     ApprealInfoEntity _Model = new ApprealInfoEntity();
     _Model.StartDate = EX1;
     _Model.EndDate = EX2;
     _Model.EMPID = EX3;
     DataTable dt = (DataTable)ExecuteDB(ERPTask.AG_GetApprealEMPWiseRecord, _Model);
     ERP.Utility.Excelimport.ExcelFileResult actionResult = new ERP.Utility.Excelimport.ExcelFileResult(dt) { FileDownloadName = "NTEmployeeWise.xls" };
     return actionResult;
 }
 public ActionResult ApprealWise()
 {
     ApprealInfoEntity _Model = new ApprealInfoEntity();
     ViewData["EMPID"] = GetAllAppearlListItem();
     _Model.StartDate = DateTime.Today.ToString("dd/MM/yyyy");
     _Model.EndDate = DateTime.Today.Date.ToString("dd/MM/yyyy");
     return View(_Model);
 }
 public ActionResult ApprealInfo()
 {
     ApprealInfoEntity Model = new ApprealInfoEntity();
     Model.StartDate = DateTime.Today.Date.ToString("dd/MM/yyyy");
     Model.EndDate = DateTime.Today.Date.ToString("dd/MM/yyyy");
     return View(Model);
 }