Exemplo n.º 1
0
 /// <summary>删除模块 
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public ActionResult DelModule(int id)
 {
     var entity = _PluginBll.GetPlugin(id);
     if (entity.Status == 1)
     {
         _PluginBll.DisablePlugin(id);
     }
     int result = _PluginBll.DelPlugin(id);
     if (entity.MenuShow == 1)
     {
         RightBll rightBll = new RightBll();
         List<RightEntity> rightEntities = rightBll.GetRights(id);
         rightBll.DeleteRightRel(rightEntities.Select(m => m.Id).ToList());
     }
     return Json(result);
 }