Ejemplo n.º 1
0
        public ActionResult UpdateSn()
        {
            SequenceEntity entity = WebUtil.GetFormObject <SequenceEntity>("entity");

            if (entity != null)
            {
                SequenceProvider provider = new SequenceProvider();
                int line = provider.Update(entity);
            }
            return(Content(this.ReturnJson.ToString()));
        }
Ejemplo n.º 2
0
        /// <summary>
        /// 编辑标识符规则
        /// </summary>
        /// <returns></returns>
        public ActionResult Edit()
        {
            string           CompanyID = WebUtil.GetFormValue <string>("CompanyID", string.Empty);
            SequenceEntity   entity    = WebUtil.GetFormObject <SequenceEntity>("Entity");
            SequenceProvider provider  = new SequenceProvider(CompanyID);
            int line = provider.Update(entity);

            DataResult dataResult = new DataResult();

            if (line > 0)
            {
                dataResult.Code    = (int)EResponseCode.Success;
                dataResult.Message = "保存成功";
            }
            else
            {
                dataResult.Code    = (int)EResponseCode.Exception;
                dataResult.Message = "保存失败";
            }
            return(Content(JsonHelper.SerializeObject(dataResult)));
        }