Ejemplo n.º 1
0
        public async Task <ActionResult <string> > PostAsync([FromBody] PlanEntity Entity)
        {
            ExcuteResult actResult = new ExcuteResult();

            if (await _PlanRepository.AddAsync(Entity).ConfigureAwait(false) > 0)
            {
                actResult.SetValues(p_state: 0, p_msg: "保存成功", p_tag: Entity?.Id);
            }
            else
            {
                actResult.SetValues(1, "保存失败");
            }
            return(JsonConvert.SerializeObject(actResult));
        }