def on_save(self): self.binder.update() try: CronManager.get().save_tab(self.current_user, self.config) self.refresh() except Exception, e: self.context.notify('error', e.message)
def on_save(self): self.binder.update() logging.info('[cron] edited tasks') try: CronManager.get().save_tab(self.current_user, self.config) self.refresh() except Exception as e: self.context.notify('error', e.message)
def refresh(self): users_select = self.find('users') users_select.value = self.current_user users = [x.name for x in PasswdConfig(path='/etc/passwd').load().tree.users] users_select.values = users_select.labels = users self.config = CronManager.get().load_tab(self.current_user) self.binder.setup(self.config.tree).populate()
def refresh(self): users_select = self.find('users') users_select.value = self.current_user users = [x.name for x in PasswdConfig(path='/etc/passwd').load().tree.users if int(x.uid) >= 500 or x.name == 'root'] users_select.values = users_select.labels = users self.config = CronManager.get().load_tab(self.current_user) self.binder.setup(self.config.tree).populate()
def refresh(self): users_select = self.find('users') users_select.value = self.current_user users = [x.name for x in PasswdConfig(path='/etc/passwd').load().tree.users if int(x.uid) >= 500 or x.name == 'root'] users_select.values = users_select.labels = users self.config = CronManager.get().load_tab(self.current_user) self.binder.reset(self.config.tree).autodiscover().populate()
def refresh(self): users_select = self.find("users") users_select.value = self.current_user users = [ x.name for x in PasswdConfig(path="/etc/passwd").load().tree.users if int(x.uid) >= 500 or x.name == "root" ] users_select.values = users_select.labels = users self.config = CronManager.get().load_tab(self.current_user) self.binder.setup(self.config.tree).populate()
def refresh(self): users_select = self.find('users') users_select.value = self.current_user users = [ x.name for x in PasswdConfig(path='/etc/passwd').load().tree.users ] users_select.values = users_select.labels = users self.config = CronManager.get().load_tab(self.current_user) self.binder.reset(self.config.tree).autodiscover().populate()