Part of stoqlib.gui.base.search View In Hierarchy
Known subclasses: stoqlib.gui.base.search.SearchEditor, stoqlib.gui.dialogs.tillhistory.TillHistoryDialog, stoqlib.gui.search.commissionsearch.CommissionSearch, stoqlib.gui.search.paymentsearch._BaseBillCheckSearch, stoqlib.gui.search.productsearch.ProductSearchQuantity, stoqlib.gui.search.receivingsearch.PurchaseReceivingSearch, stoqlib.gui.search.salesearch.DeliverySearch, stoqlib.gui.search.salesearch.SaleSearch, stoqlib.gui.search.tillsearch.TillFiscalOperationsSearch, stoqlib.gui.search.transfersearch.TransferOrderSearch
Base class for *all* the search dialogs, responsible for the list construction and "Filter" and "Clear" buttons management.
This class must be subclassed and its subclass *must* implement the methods 'get_columns' and 'get_query_and_args' (if desired, 'get_query_and_args' can be implemented in the user's slave class, so SearchDialog will get its slave instance and call the method directly). Its subclass also must implement a setup_slaves method and call its equivalent base class method as in:
>>> def setup_slave(self): ... SearchDialog.setup_slaves(self)
or then, call it in its constructor, like:
>>> def __init__(self, *args): ... SearchDialog.__init__(self)
Class Variables | table | the table type which we will query on to get the objects. |
searchbar_labels | labels for SearchBar entry and date fields | |
searchbar_result_strings | a tuple where each item has a singular and a plural form for searchbar results label | |
advanced_search | If the advanced search is enabled or disabled |
Method | __init__ | A base class for search dialog inheritance |
Method | _setup_search_table | Undocumented |
Method | _setup_selection_mode | Undocumented |
Method | _setup_search | Undocumented |
Method | _setup_details_slave | Undocumented |
Method | set_details_button_sensitive | Undocumented |
Method | set_print_button_sensitive | Undocumented |
Method | get_selection | Undocumented |
Method | confirm | Undocumented |
Method | cancel | Undocumented |
Method | set_table | Undocumented |
Method | set_searchbar_labels | Undocumented |
Method | set_searchbar_search_string | Undocumented |
Method | set_result_strings | Undocumented |
Method | set_text_field_columns | See SearchSlaveDelegate.set_text_field_columns |
Method | disable_search_entry | See SearchSlaveDelegate.disable_search_entry |
Method | add_filter | See SearchSlaveDelegate.add_filter |
Method | row_activate | This is called when an item in the results list is double clicked. |
Method | create_branch_filter | Undocumented |
Method | _on_results__cell_edited | Override this method on child when it's needed to perform some |
Method | _on_results__selection_changed | Undocumented |
Method | _on_results__row_activated | Undocumented |
Method | _has_rows | Undocumented |
Method | create_filters | Undocumented |
Method | setup_widgets | Undocumented |
Method | get_columns | Undocumented |
Method | update_widgets | Subclass can have an 'update_widgets', and this method will be |
Inherited from BasicDialog:
Method | _initialize | Undocumented |
Method | setup_keyactions | Undocumented |
Method | hide_footer | Undocumented |
Method | enable_ok | Undocumented |
Method | disable_ok | Undocumented |
Method | set_ok_label | Undocumented |
Method | set_cancel_label | Undocumented |
Method | justify_label | Undocumented |
Method | set_confirm_widget | Enables widget as a confirm widget, the dialog will be closed as |
Method | set_cancel_widget | Enables widget as a cancel widget, the dialog will be closed as |
Method | add | Undocumented |
Method | action_area | Undocumented |
Method | on_ok_button__clicked | Undocumented |
Method | on_cancel_button__clicked | Undocumented |
Inherited from RunnableView (via BasicDialog, AbstractDialog):
Method | close | Handles action to be performed when window is closed. |
Method | destroy | Undocumented |
Method | run | Handles action to be performed when window is opened. Defaults to |
Parameters | conn | |
table | ||
editor_class | ||
search_table | ||
hide_footer | ||
title | ||
selection_mode | ||
double_click_confirm | If double click a item in the list should automatically confirm |
SearchSlaveDelegate.add_filter
Parameters | obj | the item that was double clicked. |