Пример #1
0
        public ActionResult SetDefaultGodown()
        {
            DefualtGodownModel model = new DefualtGodownModel();
            model.Code = Request.QueryString["CODE"];

            //ParameterResultLong result = BusinessPortal.Load<ParameterResultLong>(new GetDefaultGodownByWH()
            //{
            //    WH_CODE = model.Code
            //});
            long? val=QuickInvoke.GetDefultGodown(model.Code );
            if(val.HasValue)
            {
                model.GodownID = val.Value;  //result.Result.Value;
             }

            if (model.GodownID == -1)
                model.GodownID = null;

            return View(model);
        }
Пример #2
0
        public ActionResult SetDefaultGodown(DefualtGodownModel model)
        {
            try
            {
                if (!ModelState.IsValid)
                {
                    return View(model);
                }

                BusinessResult result = BusinessPortal.Save(model);

                if (result.ResultType == 0)
                {
                    SessionCache.Instance.Remove("SalesReturnList");
                    this.ShowMessageEx(BusinessResultMessage.INF_SAVE_SUCCEED, isSucessed: true);
                }
                else if (result.ResultType == -9999)
                {
                    this.ShowMessageEx(BusinessResultMessage.INF_SAVE_FAILED, isSucessed: false);
                }
                else
                {
                    this.ShowMessageEx(result.GetMessage(), isSucessed: false);
                }

                return View(model);
            }
            catch (Exception ex)
            {
                this.ShowMessage(ex.Message, isSucessed: false);
                return View(model);
            }
        }
Пример #3
0
 public SaveDefaultGodown(DefualtGodownModel mobj)
 {
     m_Parent=mobj;
 }