public void EnablePlugin(Guid pluginId) { PluginViewModel module = _unitOfWork.PluginRepository.GetPlugin(pluginId); _unitOfWork.PluginRepository.SetPluginStatus(pluginId, true); _mvcModuleSetup.EnableModule(module.Name); }
public async Task EnablePlugin(int pluginId) { PluginInfo pluginInfo = await Daos.CurrentDao.Get <PluginInfo>(pluginId); pluginInfo.IsEnable = true; await Daos.CurrentDao.Flush(); _mvcModuleSetup.EnableModule(pluginInfo.Name); }
public void EnablePlugin(Guid pluginId) { var plugin = GetPlugin(pluginId); if (plugin != null) { plugin.IsEnable = true; _myContext.Plugins.Update(plugin); _mvcModuleSetup.EnableModule(plugin.Name); _myContext.SaveChanges(); } }
public JsonResult Enable(string name) { _mvcModuleSetup.EnableModule(name); return(new JsonResult(new { ok = true })); }