public ActionResult Edit([FromQuery] uint Market_id) { MarketdescInfo item = Marketdesc.GetItem(Market_id); if (item == null) { return(APIReturn.记录不存在_或者没有权限); } ViewBag.item = item; return(View()); }
public APIReturn _Edit([FromQuery] uint Market_id, [FromForm] string Content, [FromForm] string Url) { MarketdescInfo item = Marketdesc.GetItem(Market_id); if (item == null) { return(APIReturn.记录不存在_或者没有权限); } item.Content = Content; item.Url = Url; int affrows = Marketdesc.Update(item); if (affrows > 0) { return(APIReturn.成功.SetMessage($"更新成功,影响行数:{affrows}")); } return(APIReturn.失败); }