コード例 #1
0
 def __init__(self):
     controller = MainController()
     Menu.create('Manage', ActionCollection(
         ('Companies', controller.company_action),
         ('Clients', controller.client_action),
         ('Staff', controller.staff_action),
         ('Statuses', controller.status_action),
         ('Projects', controller.project_action),
         ('Jobs', controller.job_action),
         ('Invoices', controller.invoice_action),
         exit_action=Action('q', 'Quit', False)
     ))
コード例 #2
0
 def show_item_menu(self, id):
     Menu.create(self.table_name + ' Menu', ActionCollection())
コード例 #3
0
 def show_item_menu(self, id):
     Menu.create(
         self.table_name + ' Menu',
         ActionCollection(('Update Status', lambda: self.update_status(id)),
                          ('Log Time', lambda: self.log_time(id))))
コード例 #4
0
 def menu(self):
     Menu.create('Manage ' + self.table_name, self.menu_actions)
コード例 #5
0
ファイル: staff_crud.py プロジェクト: jscottgray/Invoicing
 def show_item_menu(self, id):
     Menu.create(
         self.table_name + 'Menu',
         ActionCollection(
             ('Show Assigned Jobs',
              lambda: JobCrud().show_jobs_by_assigned_to(id)), ))