/// <summary> /// Check suspend, authority and resume of MAS120 /// </summary> /// <param name="screenParam"></param> /// <returns></returns> public ActionResult MAS120_Authority(MAS120_ScreenParameter screenParam) { ObjectResultData res = new ObjectResultData(); try { ICommonHandler commonHandler = ServiceContainer.GetService <ICommonHandler>() as ICommonHandler; if (commonHandler.IsSystemSuspending()) { res.AddErrorMessage(MessageUtil.MODULE_COMMON, MessageUtil.MessageList.MSG0049); return(Json(res)); } if (!(CheckUserPermission(ScreenID.C_SCREEN_ID_MAINTAIN_SHELF_INFO, FunctionID.C_FUNC_ID_VIEW) == true || CheckUserPermission(ScreenID.C_SCREEN_ID_MAINTAIN_SHELF_INFO, FunctionID.C_FUNC_ID_ADD) == true || CheckUserPermission(ScreenID.C_SCREEN_ID_MAINTAIN_SHELF_INFO, FunctionID.C_FUNC_ID_EDIT) == true || CheckUserPermission(ScreenID.C_SCREEN_ID_MAINTAIN_SHELF_INFO, FunctionID.C_FUNC_ID_DEL) == true )) { res.AddErrorMessage(MessageUtil.MODULE_COMMON, MessageUtil.MessageList.MSG0053); return(Json(res)); } return(InitialScreenEnvironment <MAS120_ScreenParameter>("MAS120", screenParam, res)); } catch (Exception ex) { res.AddErrorMessage(ex); return(Json(res)); } }
/// <summary> /// Get shelf detail data /// </summary> /// <param name="ShelfNo"></param> /// <returns></returns> public ActionResult MAS120_GetShelfDetail(string ShelfNo) { ObjectResultData res = new ObjectResultData(); try { IShelfMasterHandler hand = ServiceContainer.GetService <IShelfMasterHandler>() as IShelfMasterHandler; ICommonHandler comHandler = ServiceContainer.GetService <ICommonHandler>() as ICommonHandler; doShelf detail = null; List <doShelf> list = hand.GetShelf(ShelfNo, null, null, null); if (list.Count > 0) { detail = list[0]; MAS120_ScreenParameter MAS120Param = GetScreenObject <MAS120_ScreenParameter>(); if (detail.UpdateDate.HasValue) { MAS120Param.updateDate = detail.UpdateDate.Value; } detail.AreaCodeName = comHandler.GetMiscDisplayValue(MiscType.C_INV_AREA, detail.AreaCode); } res.ResultData = detail; return(Json(res)); } catch (Exception ex) { res.AddErrorMessage(ex); return(null); } }