Beispiel #1
0
 def on_click(self, event, params, vars=None):
     if params[0] == 'update':
         self._mgr.update_list()
         self.put_message('info', 'Plugin list updated')
     if params[0] == 'remove':
         self._mgr.remove(params[1])
         self.put_message('info', 'Plugin removed. Refresh page for changes to take effect.')
     if params[0] == 'reload':
         try:
             PluginLoader.unload(params[1])
         except:
             pass
         try:
             PluginLoader.load(params[1])
         except:
             pass
         self.put_message('info', 'Plugin reloaded. Refresh page for changes to take effect.')
     if params[0] == 'restart':
         self.app.restart()
     if params[0] == 'install':
         self._mgr.install(params[1], load=True)
         self.put_message('info', 'Plugin installed. Refresh page for changes to take effect.')
         ComponentManager.get().rescan()
         ConfManager.get().rescan();
Beispiel #2
0
 def on_click(self, event, params, vars=None):
     if params[0] == 'update':
         self._mgr.update_list()
         self.put_message('info', 'Plugin list updated')
     if params[0] == 'remove':
         self._mgr.remove(params[1])
         self.put_message('info', 'Plugin removed. Refresh page for changes to take effect.')
     if params[0] == 'reload':
         try:
             PluginLoader.unload(params[1])
         except:
             pass
         try:
             PluginLoader.load(params[1])
         except:
             pass
         self.put_message('info', 'Plugin reloaded. Refresh page for changes to take effect.')
     if params[0] == 'restart':
         self.app.restart()
     if params[0] == 'install':
         self._mgr.install(params[1], load=True)
         self.put_message('info', 'Plugin installed. Refresh page for changes to take effect.')
         ComponentManager.get().rescan()
         ConfManager.get().rescan();
Beispiel #3
0
     except Exception, e:
         self.put_message('err', str(e))
         self.app.log.error(str(e))
     else:
         self.put_message('info', 'Plugin list updated')
 if params[0] == 'remove':
     try:
         self._mgr.check_conflict(params[1], 'remove')
         lr = LiveRemove(self._mgr, params[1], self)
         lr.start()
         self._nc.remove(params[1])
     except ImSorryDave, e:
         self.put_message('err', str(e))
 if params[0] == 'reload':
     try:
         PluginLoader.unload(params[1])
     except:
         pass
     try:
         PluginLoader.load(params[1])
     except:
         pass
     self.put_message(
         'info',
         'Plugin reloaded. Refresh page for changes to take effect.')
 if params[0] == 'restart':
     self.app.restart()
 if params[0] == 'install':
     try:
         self._mgr.check_conflict(params[1], 'install')
         li = LiveInstall(self._mgr, params[1], True, self)
Beispiel #4
0
     except Exception, e:
         self.put_message('err', str(e))
         self.app.log.error(str(e))
     else:
         self.put_message('info', 'Plugin list updated')
 if params[0] == 'remove':
     try:
         self._mgr.check_conflict(params[1], 'remove')
         lr = LiveRemove(self._mgr, params[1], self)
         lr.start()
         self._nc.remove(params[1])
     except ImSorryDave, e:
         self.put_message('err', str(e))
 if params[0] == 'reload':
     try:
         PluginLoader.unload(params[1])
     except:
         pass
     try:
         PluginLoader.load(params[1])
     except:
         pass
     self.put_message('info', 'Plugin reloaded. Refresh page for changes to take effect.')
 if params[0] == 'restart':
     self.app.restart()
 if params[0] == 'install':
     try:
         self._mgr.check_conflict(params[1], 'install')
         li = LiveInstall(self._mgr, params[1], 
             True, self)
         li.start()