Exemple #1
0
 public ResultInfo UpdateFriendsLink(WordLink wordLink)
 {
     if (wordLink.Id <= 0)
         return new ResultInfo(0, "未找到相应的友情链接!");
     var config = _utils.Get();
     var item = config.FriendsLink.FirstOrDefault(t => t.Id == wordLink.Id);
     if (item == null)
         return new ResultInfo(0, "未找到相应的分类!");
     var index = config.FriendsLink.IndexOf(item);
     config.FriendsLink[index] = wordLink;
     _utils.Set(config);
     return new ResultInfo(1);
 }
Exemple #2
0
 public JsonResult UpdateFriendsLink(WordLink info)
 {
     return Json(_busi.UpdateFriendsLink(info));
 }