public string GetHolidayCount(FormCollection collection) { try { string result = string.Empty; BLRegion objRegion = new BLRegion(); JSONConverter objJson = new JSONConverter(); string fromDate = collection["fromDate"].ToString(); string toDate = collection["toDate"].ToString(); string companyCode = _objCurr.GetCompanyCode(); _objData.OpenConnection(companyCode); { result = Convert.ToString(_objData.ExecuteScalar("exec SP_hdGetHolidayCount '" + companyCode + "','" + _objCurr.GetUserCode() + "','" + fromDate + "','" + toDate + "','" + _objCurr.GetRegionCode() + "'")); } #region WeekendDays List <MVCModels.HiDoctor_Master.WeekendDaysForARegion> lstWeekend = new List <MVCModels.HiDoctor_Master.WeekendDaysForARegion>(); lstWeekend = objRegion.GetWeekendDaysForARegion(companyCode, _objCurr.GetRegionCode(), fromDate, toDate); #endregion WeekendDays return(result + "$" + objJson.Serialize(lstWeekend)); } finally { _objData.CloseConnection(); } }
// get weekend group definr report public JsonResult GetWeekendGroupDefinerReport(FormCollection coll) { BLRegion objWeekend = new BLRegion(); List <MVCModels.HiDoctor_Master.WeekendGroupModel> lstWeek = new List <MVCModels.HiDoctor_Master.WeekendGroupModel>(); lstWeek = objWeekend.GetWeekendGroupDefinerReport(_objcurrentInfo.GetCompanyCode(), Convert.ToInt32(coll["weekEndGroupCode"])); return(Json(lstWeek, JsonRequestBehavior.AllowGet)); }
// get all defined weekend groups public JsonResult GetAllWeekendGroups() { BLRegion objWeekend = new BLRegion(); List <MVCModels.HiDoctor_Master.WeekendGroupModel> lstWeek = new List <MVCModels.HiDoctor_Master.WeekendGroupModel>(); lstWeek = objWeekend.GetAllWeekendGroups(_objcurrentInfo.GetCompanyCode()); return(Json(lstWeek, JsonRequestBehavior.AllowGet)); }
// Inert or update Sales order(applied or drafted status) public string InsertWeekendGroup(string weekendGroupName, string selectedDays, string holidayMethodDetails) { BLRegion objWeekend = new BLRegion(); return(objWeekend.InsertWeekendGroup(_objcurrentInfo.GetCompanyCode(), weekendGroupName, selectedDays, holidayMethodDetails)); }
private List <MVCModels.HiDoctor_Master.WeekendGroupModel> WeekendOffHolidayMethods(string companyCode) { BLRegion objWeekend = new BLRegion(); return(objWeekend.WeekendOffHolidayMethods(companyCode)); }