示例#1
0
        public async Task <IHttpActionResult> Update(params CommOpcUaServerInputDto[] inputDto)
        {
            //修改人员、时间
            inputDto?.ToList().ForEach((a) =>
            {
                a.LastUpdatedTime   = DateTime.Now;
                a.LastUpdatorUserId = User.Identity.Name;
            });
            var result = await CommOpcUaServerConract.EditCommOpcUaServers(inputDto);

            return(Json(result));
        }
示例#2
0
        public async Task <IHttpActionResult> Add(params CommOpcUaServerInputDto[] commOpcUaServer)
        {
            //创建和修改的人员、时间
            commOpcUaServer?.ToList().ForEach((a) =>
            {
                a.Id                = CombHelper.NewComb();
                a.CreatorUserId     = User.Identity.Name;
                a.CreatedTime       = DateTime.Now;
                a.LastUpdatedTime   = a.CreatedTime;
                a.LastUpdatorUserId = a.CreatorUserId;
            });
            var result = await CommOpcUaServerConract.AddCommOpcUaServers(commOpcUaServer);

            return(Json(result));
        }
示例#3
0
        public async Task <IHttpActionResult> Remove(params Guid[] ids)
        {
            var result = await CommOpcUaServerConract.DeleteCommOpcUaServers(ids);

            return(Json(result));
        }