Exemplo n.º 1
0
        public HtmlDataOperRetDto EditConst(CreateConstDto input, int inputId)
        {
            var constItem = this._constRep.Single(x => x.Id == inputId);

            constItem.intro          = input.intro;
            constItem.operatorId     = AbpSession.UserId ?? 0;
            constItem.constVal       = input.constVal;
            constItem.elementId      = input.elementId;
            constItem.lastModifyTime = DateTime.Now;

            this._constRep.Update(constItem);
            return(new HtmlDataOperRetDto()
            {
                Code = 1,
                Message = "操作成功!"
            });
        }
Exemplo n.º 2
0
        public HtmlDataOperRetDto AddConst(CreateConstDto input)
        {
            AssayConst item = new AssayConst();

            item.constVal       = input.constVal;
            item.elementId      = input.elementId;
            item.intro          = input.intro;
            item.operatorId     = AbpSession.UserId ?? 0;
            item.lastModifyTime = DateTime.Now;

            this._constRep.Insert(item);
            return(new HtmlDataOperRetDto()
            {
                Code = 1,
                Message = "操作成功!"
            });
        }