def get_summary_wdg(self): widget = Widget() nav = DivWdg(css="filter_box") search_columns = Shot.get_search_columns() search_filter = SearchFilterWdg(name="shot_search", columns=search_columns) nav.add(search_filter) status_select = FilterSelectWdg("status_select", label='Status:', css='med') status_select.add_empty_option("-- Any Status --") status_select.set_option("setting", "shot_status") status_value = status_select.get_value() nav.add(status_select) filter = SequenceFilterWdg() nav.add(filter) widget.add(nav) search = Search("prod/shot") search_filter.alter_search(search) filter.alter_search(search) if status_value: search.add_filter("status", status_value) table = TableWdg("prod/shot", "summary") table.set_search_limit(10) table.set_search(search) widget.add(table) return widget
def init(my): # my.text = FilterTextWdg("shot_search", label='Search: ', \ # css='med', has_persistence=True) search_columns = Shot.get_search_columns() my.text = SearchFilterWdg("shot_search", columns=search_columns, has_persistence=True) my.add(my.text)
def get_summary_wdg(self): widget = Widget() nav = DivWdg(css="filter_box") search_columns = Shot.get_search_columns() search_filter = SearchFilterWdg(name="shot_search", columns=search_columns) nav.add(search_filter) status_select = FilterSelectWdg("status_select", label='Status:', css='med') status_select.add_empty_option("-- Any Status --") status_select.set_option("setting", "shot_status") status_value = status_select.get_value() nav.add(status_select) filter = SequenceFilterWdg() nav.add(filter) widget.add(nav) search = Search("prod/shot") search_filter.alter_search(search) filter.alter_search(search) if status_value: search.add_filter("status", status_value) table = TableWdg("prod/shot", "summary") table.set_search_limit(10) table.set_search(search) widget.add(table) return widget
def init(my): #my.text = FilterTextWdg("shot_search", label='Search: ', \ # css='med', has_persistence=True) search_columns = Shot.get_search_columns() my.text = SearchFilterWdg("shot_search", columns=search_columns,\ has_persistence=True) my.add(my.text)
def get_shot_list_wdg(self): widget = Widget() help = HelpItemWdg( 'Shot List', 'The Shot List tab allows you to insert new shots, define frame range, amd set differernt statuses for your shot. It also provides a button for media submission.' ) widget.add(help) nav = DivWdg(css='filter_box') search_columns = Shot.get_search_columns() search_filter = SearchFilterWdg(name="shot_search", columns=search_columns) nav.add(search_filter) seq_filter = SequenceFilterWdg() nav.add(seq_filter) status_select = FilterSelectWdg("status_select", label='Status: ') status_select.add_empty_option("-- Any Status --") status_select.set_option("setting", "shot_status") status_value = status_select.get_value() nav.add(status_select) pipeline_filter = PipelineFilterWdg() pipeline_filter.set_search_type('prod/shot') nav.add(pipeline_filter) scan_status_select = FilterSelectWdg("scan_status_select", label='Scan Status: ') scan_status_select.add_empty_option("-- Any Scan Status --") scan_status_select.set_option("setting", "shot_scan_status") scan_status_value = scan_status_select.get_value() nav.add(scan_status_select) widget.add(nav) order = Sequence.get_order() search = Search("prod/shot") search.add_enum_order_by('sequence_code', order) search.add_order_by('code') seq_filter.alter_search(search) pipeline_filter.alter_search(search) if status_value: search.add_filter("status", status_value) if scan_status_value: search.add_filter("scan_status", scan_status_value) widget.set_search(search) table = TableWdg("prod/shot", "manage") widget.add(table) return widget
def get_shot_list_wdg(self): widget = Widget() help = HelpItemWdg('Shot List', 'The Shot List tab allows you to insert new shots, define frame range, amd set differernt statuses for your shot. It also provides a button for media submission.') widget.add(help) nav = DivWdg(css='filter_box') search_columns = Shot.get_search_columns() search_filter = SearchFilterWdg(name="shot_search", columns=search_columns) nav.add(search_filter) seq_filter = SequenceFilterWdg() nav.add(seq_filter) status_select = FilterSelectWdg("status_select", label='Status: ') status_select.add_empty_option("-- Any Status --") status_select.set_option("setting", "shot_status") status_value = status_select.get_value() nav.add(status_select) pipeline_filter = PipelineFilterWdg() pipeline_filter.set_search_type('prod/shot') nav.add(pipeline_filter) scan_status_select = FilterSelectWdg("scan_status_select", label='Scan Status: ') scan_status_select.add_empty_option("-- Any Scan Status --") scan_status_select.set_option("setting", "shot_scan_status") scan_status_value = scan_status_select.get_value() nav.add(scan_status_select) widget.add(nav) order = Sequence.get_order() search = Search("prod/shot") search.add_enum_order_by('sequence_code', order) search.add_order_by('code') seq_filter.alter_search(search) pipeline_filter.alter_search(search) if status_value: search.add_filter("status", status_value) if scan_status_value: search.add_filter("scan_status", scan_status_value) widget.set_search(search) table = TableWdg("prod/shot", "manage") widget.add(table) return widget
def get_task_manager_wdg(self): manager = TaskManagerWdg() manager.set_search_type("prod/shot") manager.set_process_filter_name("shot_process_filter") filter = SpanWdg() filter.add( SequenceFilterWdg() ) search_columns = Shot.get_search_columns() search_filter = SearchFilterWdg(name="shot_search",columns=search_columns) filter.add(search_filter) ''' search_hint = HintWdg('You can enter any of %s of a shot.' % search_columns) filter.add(search_hint) ''' manager.set_sobject_filter( filter ) return manager
def get_task_manager_wdg(self): manager = TaskManagerWdg() manager.set_search_type("prod/shot") manager.set_process_filter_name("shot_process_filter") filter = SpanWdg() filter.add(SequenceFilterWdg()) search_columns = Shot.get_search_columns() search_filter = SearchFilterWdg(name="shot_search", columns=search_columns) filter.add(search_filter) ''' search_hint = HintWdg('You can enter any of %s of a shot.' % search_columns) filter.add(search_hint) ''' manager.set_sobject_filter(filter) return manager