/** 卸载 */ @RequestMapping(value = "/uninstall", method = RequestMethod.POST) public @ResponseBody Message uninstall() { if (qqLoginPlugin.getIsInstalled()) { pluginConfigService.deleteByPluginId(qqLoginPlugin.getId()); } return SUCCESS_MESSAGE; }
/** 安装 */ @RequestMapping(value = "/install", method = RequestMethod.POST) public @ResponseBody Message install() { if (!qqLoginPlugin.getIsInstalled()) { PluginConfig pluginConfig = new PluginConfig(); pluginConfig.setPluginId(qqLoginPlugin.getId()); pluginConfig.setIsEnabled(false); pluginConfig.setAttributes(null); pluginConfigService.save(pluginConfig); } return SUCCESS_MESSAGE; }