/// <summary> /// Lấy tất cả dữ liệu trong table /// </summary> /// <param name="request"></param> /// <returns></returns> public ActionResult GetAll([DataSourceRequest] DataSourceRequest request) { var service = new RestServiceClient<IEnumerable<Cat_TAMScanReasonMissModel>>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Cat_TAMScanReasonMissForAtt/"); return Json(result.ToDataSourceResult(request)); }
// <summary> /// Lấy tất cả dữ liệu trong table Sys_Resource /// </summary> /// <param name="request"></param> /// <returns></returns> public ActionResult GetAll([DataSourceRequest] DataSourceRequest request) { var service = new RestServiceClient<IEnumerable<Sys_ResourceModel>>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Sys_Service); var result = service.Get(_hrm_Sys_Service, "api/SysResource/"); return Json(result.ToDataSourceResult(request)); }
/// <summary> /// Lấy tất cả dữ liệu Ca Làm Việc /// </summary> /// <param name="request"></param> /// <returns></returns> public ActionResult GetAll([DataSourceRequest] DataSourceRequest request) { var service = new RestServiceClient<List<Att_ReportDetailForgetCardModel>>(UserLogin); service.SetCookies(Request.Cookies, _Hrm_Hre_Service); var result = service.Get(_Hrm_Hre_Service, "api/Att_ReportDetailForgetCard/"); return Json(result.ToDataSourceResult(request)); }
public ActionResult Edit(Guid id) { var service = new RestServiceClient<Att_WorkdayModel>(UserLogin); service.SetCookies(this.Request.Cookies, _Hrm_Hre_Service); var result = service.Get(_Hrm_Hre_Service, "api/Att_WorkDay/",id); return View(result); }
public void Export(Att_ReportDetailForgetCardModel model) { var service = new RestServiceClient<List<Att_ReportDetailForgetCardModel>>(UserLogin); service.SetCookies(Request.Cookies, _Hrm_Hre_Service); var result = service.PostAll(_Hrm_Hre_Service, "api/Att_ReportDetailForgetCard/", model); }
/// <summary> /// Tạo mời một Can_Canteen /// </summary> /// <param name="model"></param> /// <returns></returns> public ActionResult Add([Bind] Can_CanteenModel model) { var service = new RestServiceClient<Can_CanteenModel>(UserLogin); service.SetCookies(this.Request.Cookies, _hrm_Can_Service); var result = service.Put(_hrm_Can_Service, "api/Can_Canteen/", model); return Json(result); }
/// <summary> /// Tạo mời một AttWorkDay /// </summary> /// <param name="model"></param> /// <returns></returns> public ActionResult Add([Bind] Att_WorkdayModel model) { var service = new RestServiceClient<Att_WorkdayModel>(UserLogin); service.SetCookies(this.Request.Cookies, _Hrm_Hre_Service); var result = service.Put(_Hrm_Hre_Service, "api/Att_WorkDay/", model); return Json(result); }
public ActionResult Edit(string id) { var service = new RestServiceClient<Rec_RecruitmentHistoryModel>(UserLogin); service.SetCookies(this.Request.Cookies, _Hrm_Hre_Service); var result = service.Get(_Hrm_Hre_Service, "api/Rec_RecruitmentHistory/", id); return View(result); }
public ActionResult Remove(Guid id) { var service = new RestServiceClient<Att_WorkdayModel>(UserLogin); service.SetCookies(this.Request.Cookies, _Hrm_Hre_Service); var result = service.Delete(_Hrm_Hre_Service, "api/Att_WorkDay/", id); return Json(result); }
public ActionResult SalCostCentreInfo(string id) { //bool isAccess; //if (!string.IsNullOrEmpty(id)) //{ // isAccess = CheckPermission(UserId, PrivilegeType.Modify, ConstantPermission.Sal_CostCentre); //} //else //{ // isAccess = CheckPermission(UserId, PrivilegeType.Create, ConstantPermission.Sal_CostCentre); //} //if (!isAccess) //{ // return PartialView("AccessDenied"); //} if (!string.IsNullOrEmpty(id)) { var id1 = Common.ConvertToGuid(id); var service = new RestServiceClient<SalCostCentreModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var modelResult = service.Get(_hrm_Hr_Service, "api/Sal_CostCentre/", id1); return View(modelResult); } else { return View(); } }
/// <summary> /// Lấy tất cả dữ liệu trong table AttWorkDay /// </summary> /// <param name="request"></param> /// <returns></returns> public ActionResult GetAll([DataSourceRequest] DataSourceRequest request) { var service = new RestServiceClient<IEnumerable<Att_WorkdayModel>>(UserLogin); service.SetCookies(Request.Cookies, _Hrm_Hre_Service); var result = service.Get(_Hrm_Hre_Service, "api/Att_WorkDay/"); return Json(result.ToDataSourceResult(request)); }
public ActionResult EvaluationContractInfo(string id) { //bool isAccess; //if (!string.IsNullOrEmpty(id)) //{ // isAccess = CheckPermission(UserId, PrivilegeType.Modify, ConstantPermission.Hre_Qualification); //} //else //{ // isAccess = CheckPermission(UserId, PrivilegeType.Create, ConstantPermission.Hre_Qualification); //} //if (!isAccess) //{ // return PartialView("AccessDenied"); //} if (!string.IsNullOrEmpty(id)) { var service = new RestServiceClient<Hre_ContractModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Hre_Contract/", id); return View(result); } else { return View(); } }
public ActionResult CreateOrUpdate(string id) { //bool isAccess; //if (!string.IsNullOrEmpty(id)) //{ // isAccess = CheckPermission(UserId, PrivilegeType.Modify, ConstantPermission.Cat_OrgStructure); //} //else //{ // isAccess = CheckPermission(UserId, PrivilegeType.Create, ConstantPermission.Cat_OrgStructure); //} //if (!isAccess) //{ // return PartialView("AccessDenied"); //} if (!string.IsNullOrEmpty(id)) { var idModel = Common.ConvertToGuid(id); var service = new RestServiceClient<CatOrgStructureModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/CatOrgStructure/", idModel); return View(result); } else { return View(); } }
public ActionResult Remove(string id) { var service = new RestServiceClient<CatElementModel>(UserLogin); service.SetCookies(this.Request.Cookies, _hrm_Hr_Service); var result = service.Delete(_hrm_Hr_Service, "api/CatElement/", id); return Json(result); }
/// <summary> /// Lấy tất cả dữ liệu trong table Cat_Brand /// </summary> /// <param name="request"></param> /// <returns></returns> public ActionResult Get([DataSourceRequest] DataSourceRequest request) { var service = new RestServiceClient<IEnumerable<Cat_SupplierModel>>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Cat_Brand/"); return Json(result.ToDataSourceResult(request)); }
/// <summary> /// Lấy tất cả dữ liệu cho control multiselect /// </summary> /// <param name="request"></param> /// <returns></returns> public JsonResult GetMultiselect() { var service = new RestServiceClient<IEnumerable<CatDistrictModel>>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hre_Service); var result = service.Get(_hrm_Hre_Service, "api/CatDistrict/"); return Json(result, JsonRequestBehavior.AllowGet); }
public ActionResult Edit(Guid id) { var service = new RestServiceClient<Rep_MasterModel>(UserLogin); service.SetCookies(this.Request.Cookies, _hrm_Sys_Service); var result = service.Get(_hrm_Sys_Service, "api/Rep_Master/", id); return View(result); }
/// <summary> /// Lấy tất cả dữ liệu trong table Sys_DelegateApprove /// </summary> /// <param name="request"></param> /// <returns></returns> public ActionResult Get([DataSourceRequest] DataSourceRequest request) { var service = new RestServiceClient<IEnumerable<Sys_DelegateApproveModel>>(); service.SetCookies(Request.Cookies, _hrm_Sys_Service); var result = service.Get(_hrm_Sys_Service, "api/Sys_DelegateApprove/"); return Json(result.ToDataSourceResult(request)); }
/// <summary> /// Lấy tất cả dữ liệu trong table CatDistrict /// </summary> /// <returns></returns> public IEnumerable<CatProvinceModel> GetAllCatProvince() { var service = new RestServiceClient<IEnumerable<CatProvinceModel>>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hre_Service); var result = service.Get(_hrm_Hre_Service, "api/CatProvince/"); return result; }
public ActionResult Add([Bind] Sys_GroupUserModel model) { var service = new RestServiceClient<Sys_GroupUserModel>(); service.SetCookies(this.Request.Cookies, _hrm_Sys_Service); var result = service.Put(_hrm_Sys_Service, "api/Sys_GroupUser/", model); return Json(result); }
public ActionResult ReportTotalAnnualTaxableInComeConfigElementIfno(string id) { //bool isAccess; //if (!string.IsNullOrEmpty(id)) //{ // isAccess = CheckPermission(UserId, PrivilegeType.Modify, ConstantPermission.Sal_ItemForShop); //} //else //{ // isAccess = CheckPermission(UserId, PrivilegeType.Create, ConstantPermission.Sal_ItemForShop); //} //if (!isAccess) //{ // return PartialView("AccessDenied"); //} if (!string.IsNullOrEmpty(id)) { var id1 = Common.ConvertToGuid(id); var service = new RestServiceClient<Sys_AllSettingModel>(UserLogin); service.SetCookies(Request.Cookies, _Hrm_Sys_Service); var modelResult = service.Get(_Hrm_Sys_Service, "api/Sal_ItemForShop/", id1); return View(modelResult); } else { return View(); } }
public ActionResult ReadGrid([DataSourceRequest] DataSourceRequest request, int id) { var service = new RestServiceClient<IEnumerable<Sys_GroupUserModel>>(); service.SetCookies(Request.Cookies, _hrm_Sys_Service); var result = service.Put(_hrm_Sys_Service, "api/Sys_GroupUser/", id).ToList(); return Json(result.ToDataSourceResult(request)); }
public ActionResult PerformanceExtendInfo(string id, Guid? PerformanceID) { //bool isAccess; //if (!string.IsNullOrEmpty(id)) //{ // isAccess = CheckPermission(UserId, PrivilegeType.Modify, ConstantPermission.Eva_PerformanceExtend); //} //else //{ // isAccess = CheckPermission(UserId, PrivilegeType.Create, ConstantPermission.Eva_PerformanceExtend); //} //if (!isAccess) //{ // return PartialView("AccessDenied"); //} ViewData["PerformanceID"] = PerformanceID; if (!string.IsNullOrEmpty(id)) { var service = new RestServiceClient<Eva_PerformanceExtendModel>(UserLogin); service.SetCookies(Request.Cookies, _Hrm_Hr_Service); var result = service.Get(_Hrm_Hr_Service, "api/Eva_PerformanceExtend/", id); return View(result); } else { return View(); } }
public ActionResult Remove(Guid id) { var service = new RestServiceClient<Can_CanteenModel>(UserLogin); service.SetCookies(this.Request.Cookies, _hrm_Can_Service); var result = service.Delete(_hrm_Can_Service, "api/Can_Canteen/", id); return Json(result); }
public Test() { restClient = new RestServiceClient(); restClient.Proxy.Credentials = CredentialCache.DefaultCredentials; //!!! Please provide your application id and password here // To create an application and obtain a password, // register at http://cloud.ocrsdk.com/Account/Register // More info on getting your application id and password at // http://ocrsdk.com/documentation/faq/#faq3 /* // Name of application you created restClient.ApplicationId = "<your application id>"; // Password should be sent to your e-mail after application was created restClient.Password = "******"; */ // Display hint to provide credentials if (String.IsNullOrEmpty(restClient.ApplicationId) || String.IsNullOrEmpty(restClient.Password)) { throw new Exception("Please provide access credentials to Cloud OCR SDK service! See Test.cs file for details!"); } Console.WriteLine(String.Format("Application id: {0}\n", restClient.ApplicationId)); }
public ActionResult HreHDTJobInfo(Guid id) { //bool isAccess; //if (id != null && id != Guid.Empty) //{ // isAccess = CheckPermission(UserId, PrivilegeType.Modify, ConstantPermission.Hre_HDTJob); //} //else //{ // isAccess = CheckPermission(UserId, PrivilegeType.Create, ConstantPermission.Hre_HDTJob); //} //if (!isAccess) //{ // return PartialView("AccessDenied"); //} if (id != null && id != Guid.Empty) { // var id1 = Common.ConvertToGuid(id); var service = new RestServiceClient<Hre_HDTJobModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Hre_HDTJob/", id); return View(result); } else { return View(); } }
public Window1() { InitializeComponent(); restClient = new RestServiceClient(); restClient.Proxy.Credentials = CredentialCache.DefaultCredentials; restClient.ServerUrl = Properties.Settings.Default.ServerAddress; if (String.IsNullOrEmpty(Properties.Settings.Default.ApplicationId) || String.IsNullOrEmpty(Properties.Settings.Default.Password) ) { changeAppIdAndPwd(); } restClient.ApplicationId = Properties.Settings.Default.ApplicationId; restClient.Password = Properties.Settings.Default.Password; restClientAsync = new RestServiceClientAsync(restClient); restClientAsync.UploadFileCompleted += UploadCompleted; restClientAsync.TaskProcessingCompleted += ProcessingCompleted; restClientAsync.DownloadFileCompleted += DownloadCompleted; restClientAsync.ListTasksCompleted += TaskListObtained; fieldLevelImage.RegionSelected += fieldSelected; }
/// <summary> /// Chuyển trạng thái IsDelete = true /// </summary> /// <param name="id"></param> /// <returns></returns> public ActionResult Remove(Guid id) { var service = new RestServiceClient<Lau_MarkerModel>(UserLogin); service.SetCookies(this.Request.Cookies, _hrm_Hre_Service); var result = service.Remove(_hrm_Hre_Service, "api/Lau_Marker/", id); return Json(result); }
public ActionResult CreateOrUpdate(string id) { if (!string.IsNullOrEmpty(id)) { var service = new RestServiceClient<Hre_ProfilePartyUnionModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Hre_ProfilePartyUnion/", id); return View(result); } else { if (Request["profileID"] != null) { string aaa = Request["profileID"].ToString(); if (!string.IsNullOrEmpty(aaa)) { ViewBag.profileID = aaa; } } return View(); } }
public ActionResult CreateList(List <Sys_AutoBackupModel> TotalCat_ElementModel, [Bind(Prefix = "models")] List <Sys_AutoBackupModel> updatedCat_ElementModel) { var service = new RestServiceClient <Sys_AutoBackupModel>(); service.SetCookies(this.Request.Cookies, _hrm_Sys_Service); if (updatedCat_ElementModel != null) { for (int i = 0; i < updatedCat_ElementModel.Count; i++) { service.Post(_hrm_Sys_Service, "api/Sys_AutoBackup/", updatedCat_ElementModel[i]); } } return(Json(updatedCat_ElementModel)); }
/// <summary> /// Xử lí thay doi trang thai cua roster group /// </summary> /// <param name="contract"></param> /// <returns></returns> public ActionResult SetStatusSelected(List <Guid> selectedIds, string status) { var rosterGroup = new Att_RosterGroupModel(); if (selectedIds != null || selectedIds.Count > 0) { var service = new RestServiceClient <Att_RosterGroupModel>(UserLogin); service.SetCookies(this.Request.Cookies, _Hrm_Hre_Service); rosterGroup.ProfileIds = Common.DotNetToOracle(String.Join(",", selectedIds)); rosterGroup.Status = status; service.Put(_Hrm_Hre_Service, "api/Att_RosterGroup/", rosterGroup); } return(Json("")); }
public Rec_InterviewModel GetById(Guid?id) { if (id == null || id == Guid.Empty) { return(null); } else { var service = new RestServiceClient <Rec_InterviewModel>(UserLogin); service.SetCookies(Request.Cookies, _Hrm_Hre_Service); var result = service.Get(_Hrm_Hre_Service, "api/Rec_Candidate/", (Guid)id); return(result); } }
public ActionResult Remove(Guid id) { //var isAccess = CheckPermission(UserId, PrivilegeType.Delete, ConstantPermission.Hre_CandidateHistory); //if (!isAccess) //{ // return PartialView("AccessDenied"); //} var service = new RestServiceClient <Hre_CandidateHistoryModel>(UserLogin); service.SetCookies(this.Request.Cookies, _hrm_Hr_Service); var result = service.Remove(_hrm_Hr_Service, "api/CandidateHistory/", id); return(Json(result)); }
/// <summary> /// Tab Người Thân /// </summary> /// <param name="id"></param> /// <returns></returns> public ActionResult Hre_RelativesDetail([DataSourceRequest] DataSourceRequest request, Guid id) { if (id != Guid.Empty) { var service = new RestServiceClient <IEnumerable <Hre_RelativesModel> >(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Hre_RelativesCustom/", id); return(Json(result.ToDataSourceResult(request))); } else { return(View()); } }
public ActionResult Create([Bind] Hre_ProfileModel model) { //var isAccess = CheckPermission(UserId, PrivilegeType.Create, ConstantPermission.GeneralProfile); //if (!isAccess) //{ // return PartialView("AccessDenied"); //} var service = new RestServiceClient <Hre_ProfileModel>(UserLogin); service.SetCookies(this.Request.Cookies, _hrm_Hr_Service); var result = service.Put(_hrm_Hr_Service, "api/Hre_Profile/", model); return(Json(result)); }
public ActionResult Tab_Hre(Guid id) { //var isAccess = CheckPermission(UserId, PrivilegeType.View, ConstantPermission.GeneralProfile); //if (!isAccess) //{ // return PartialView("AccessDenied"); //} var service = new RestServiceClient <Hre_ProfileModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Hre_Profile/", id); return(View(result)); }
public ActionResult Edit(Guid id) { var service = new RestServiceClient <Att_LeaveDayModel>(UserLogin); service.SetCookies(this.Request.Cookies, _Hrm_Hre_Service); var result = service.Get(_Hrm_Hre_Service, "api/Att_Leaveday/", id); if (result != null) { result.HoursFrom = result.DateStart; result.HoursTo = result.DateEnd; } return(View(result)); }
public ActionResult InsurancePayBackInfo(string id) { if (!string.IsNullOrEmpty(id)) { var service = new RestServiceClient <Ins_InsuranceSalaryPaybackModel>(UserLogin); service.SetCookies(Request.Cookies, _Hrm_Hr_Service); var result = service.Get(_Hrm_Hr_Service, "api/Ins_InsuranceSalaryPayback/", id); return(View(result)); } else { return(View()); } }
public ActionResult SetMethodPaymentSelected(List <Guid> selectedIds, string status) { var model = new Att_OvertimeModel(); if (selectedIds != null || selectedIds.Count > 0) { var service = new RestServiceClient <Att_OvertimeModel>(UserLogin); service.SetCookies(this.Request.Cookies, _Hrm_Hre_Service); model.ProfileIds = String.Join(",", selectedIds); model.MethodPayment = status; model = service.Put(_Hrm_Hre_Service, "api/Att_Overtime/", model); } return(Json(model)); }
public ActionResult Edit(Guid id) { //var isAccess = CheckPermission(UserId, PrivilegeType.Modify, ConstantPermission.Sal_SalaryInformation); //if (!isAccess) //{ // return PartialView("AccessDenied"); //} var service = new RestServiceClient <Sal_SalaryInformationModel>(UserLogin); service.SetCookies(this.Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Sal_SalaryInformation/", id); return(View(result)); }
public ActionResult GetByProfileIdGrid([DataSourceRequest] DataSourceRequest request, Guid id) { //var isAccess = CheckPermission(UserId, PrivilegeType.Modify, ConstantPermission.Hre_Discipline); //if (!isAccess) //{ // return PartialView("AccessDenied"); //} var service = new RestServiceClient <IEnumerable <Hre_DisciplineModel> >(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Hre_DisciplineCustom/", id); return(Json(result.ToDataSourceResult(request))); }
public Att_AttendanceTableModel GetById(Guid id, Guid cutoffId) { var model = new ProfileIdAndCutOffIdModel() { ProfileId = id, CutOffId = cutoffId }; var service = new RestServiceClient <Att_AttendanceTableModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Put(_hrm_Hr_Service, "api/Att_AttendanceTable/", model); return(result); }
public ActionResult Edit(Guid id) { //var isAccess = CheckPermission(UserId, PrivilegeType.Modify, ConstantPermission.Hre_Qualification); //if (!isAccess) //{ // return PartialView("AccessDenied"); //} var service = new RestServiceClient <Hre_ProfileLanguageLevelModel>(UserLogin); service.SetCookies(this.Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Hre_ProfileLanguage/", id); return(View(result)); }
public ActionResult MultiCreate([DataSourceRequest] DataSourceRequest request, [Bind(Prefix = "models")] IEnumerable <Att_OvertimeModel> attOvertime) { var service = new RestServiceClient <Att_OvertimeModel>(UserLogin); service.SetCookies(this.Request.Cookies, _Hrm_Hre_Service); if (attOvertime != null) { foreach (var item in attOvertime) { service.Put(_Hrm_Hre_Service, "api/Att_Overtime/", item); } } return(Json(attOvertime)); }
/// <summary> /// Xử lí thay doi trang thai cua ngày công /// </summary> /// <param name="contract"></param> /// <returns></returns> public ActionResult SetStatusSelected(string selectedIds, string status) { var model = new Lau_LaundryRecordModel(); if (selectedIds != null) { var service = new RestServiceClient <Lau_LaundryRecordModel>(UserLogin); service.SetCookies(this.Request.Cookies, _hrm_Lau_Service); model.ProfileIDs = selectedIds; model.Status = status; service.Put(_hrm_Lau_Service, "api/LaundryRecord/", model); } return(Json("")); }
public ActionResult LocationInfo(Guid id) { if (id != Guid.Empty) { var service = new RestServiceClient <LMS_LocationLMSModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Lau_Service); var modelResult = service.Get(_hrm_Lau_Service, "api/Lau_LocationLMS/", id); return(View(modelResult)); } else { return(View()); } }
public ActionResult TabEva_KPIBuilding360(string id) { if (!string.IsNullOrEmpty(id)) { var service = new RestServiceClient <Eva_KPIBuildingModel>(UserLogin); service.SetCookies(Request.Cookies, _Hrm_Hr_Service); var result = service.Get(_Hrm_Hr_Service, "api/Eva_KPIBuilding/", id); return(View(result)); } else { return(View()); } }
public ActionResult RegisterOutInfo(string id) { if (!string.IsNullOrEmpty(id)) { var service = new RestServiceClient <Hre_HDTJobModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Hre_HDTJob/", id); return(View(result)); } else { return(View()); } }
public ActionResult Edit([DataSourceRequest] DataSourceRequest request, Sys_GroupUserModel model) { //if (ModelState.IsValid) //{ var service = new RestServiceClient <Sys_GroupUserModel>(UserLogin); service.SetCookies(this.Request.Cookies, _hrm_Sys_Service); var result = service.Put(_hrm_Sys_Service, "api/Sys_GroupUser/", model); //return Json(result); //ViewBag.MsgUpdate = "Update success"; //} return(Json(result)); }
public ActionResult Create([Bind(Prefix = "performanceModel")] Eva_PerformanceModel model, [Bind(Prefix = "models")] List <Eva_KPIModel> kpiModels) { if (kpiModels != null && kpiModels.Count != 0) { model.KPIs = kpiModels; } var service = new RestServiceClient <Eva_PerformanceModel>(UserLogin); service.SetCookies(this.Request.Cookies, _Hrm_Hr_Service); var result = service.Post(_Hrm_Hr_Service, "api/Eva_Performance360/", model); ViewBag.MsgInsert = "Insert success"; return(Json(result, JsonRequestBehavior.AllowGet)); }
public Hre_ContractModel GetById(Guid?id) { if (id == null || id == Guid.Empty) { return(null); } else { var service = new RestServiceClient <Hre_ContractModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Hre_Contract/", (Guid)id); return(result); } }
/// <summary> /// Lấy card history theo profile Id /// </summary> /// <param name="request"></param> /// <returns></returns> /// public ActionResult GetByProfileId(Guid id) { //var isAccess = CheckPermission(UserId, PrivilegeType.Modify, ConstantPermission.Hre_CardHistory); //if (!isAccess) //{ // return PartialView("AccessDenied"); //} var service = new RestServiceClient <Hre_CardHistoryModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Hre_CardHistoryCustom/", id); return(View(result)); }
public ActionResult Sys_CodeObjectInfo(string id) { if (!string.IsNullOrEmpty(id)) { var guidId = Common.ConvertToGuid(id); var service = new RestServiceClient <Sys_CodeObjectModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Sys_Service); var modelResult = service.Get(_hrm_Sys_Service, "api/Sys_CodeObject/", guidId); return(View(modelResult)); } else { return(View()); } }
public ActionResult HreStopWorkingInfo(Guid id) { if (id != null && id != Guid.Empty) { //var id1 = Common.ConvertToGuid(id); var service = new RestServiceClient <Hre_StopWorkingModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Hre_StopWorking/", id); return(View(result)); } else { return(View()); } }
public ActionResult TravelRequestRejectInfo(string id) { if (!string.IsNullOrEmpty(id)) { var id1 = Common.ConvertToGuid(id); var service = new RestServiceClient <FIN_TravelRequestModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var modelResult = service.Get(_hrm_Hr_Service, "api/Fin_TravelRequest/", id1); return(View(modelResult)); } else { return(View()); } }
public ActionResult Cat_TAMScanReasonMissInfo(string id) { if (!string.IsNullOrEmpty(id)) { var id1 = Common.ConvertToGuid(id); var service = new RestServiceClient <Cat_TAMScanReasonMissModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Cat_TAMScanReasonMiss/", id1); return(View(result)); } else { return(View()); } }
public ActionResult CatAppendixContractTypeInfo(string id) { if (!string.IsNullOrEmpty(id)) { var id1 = Common.ConvertToGuid(id); var service = new RestServiceClient <Cat_AppendixContractTypeModel>(UserLogin); service.SetCookies(Request.Cookies, _hrm_Hr_Service); var modelResult = service.Get(_hrm_Hr_Service, "api/Cat_AppendixContractType/", id1); return(View(modelResult)); } else { return(View()); } }
public ActionResult CreateAdvancePaymentList(List <CatElementModel> TotalCat_ElementModel, [Bind(Prefix = "models")] List <CatElementModel> updatedCat_ElementModel) { var service = new RestServiceClient <CatElementModel>(UserLogin); service.SetCookies(this.Request.Cookies, _hrm_Hr_Service); if (updatedCat_ElementModel != null) { for (int i = 0; i < updatedCat_ElementModel.Count; i++) { updatedCat_ElementModel[i].MethodPayroll = MethodPayroll.E_ADNVANCE_PAYMENT.ToString(); service.Post(_hrm_Hr_Service, "api/CatElement/", updatedCat_ElementModel[i]); } } return(Json(updatedCat_ElementModel)); }
public ActionResult RemoveSelecteds(List <Guid> selectedIds) { var user = new List <Rec_SourceAdsModel>(); if (selectedIds != null) { var service = new RestServiceClient <Rec_CandidateModel>(UserLogin); service.SetCookies(this.Request.Cookies, _Hrm_Hre_Service); foreach (var id in selectedIds) { service.Delete(_Hrm_Hre_Service, "api/Rec_Candidate/", id); } } return(Json("")); }
public ActionResult Edit(Guid id) { var service = new RestServiceClient<Cat_SkillModel>(UserLogin); service.SetCookies(this.Request.Cookies, _hrm_Hr_Service); var result = service.Get(_hrm_Hr_Service, "api/Cat_Skill/", id); return View(result); }