Class s.g.b.l.ModelListSlave(ListSlave):

Part of stoqlib.gui.base.lists View In Hierarchy

Known subclasses: stoqlib.gui.base.lists.ModelListDialog

No class docstring
Method __init__ Create a new ModelListDialog object.
Method _delete_with_transaction Undocumented
Method _delete_model Undocumented
Method _prepare_run_editor Undocumented
Method populate Undocumented
Method add_item Undocumented
Method remove_item Undocumented
Method edit_item Undocumented
Method set_model_type Set the type of the model this slave is containing
Method set_editor_class Set the editor class which will be used to modify
Method set_reuse_transaction Reuse the transaction.
Method run_dialog A special variant of run_dialog which deletes objects
Method run_editor This can be override by a subclass who wants to send in
Method delete_model Deletes the model in a transaction.
def __init__(self, columns=None, conn=None, orientation=gtk.ORIENTATION_VERTICAL):
Create a new ModelListDialog object.
ParametersconnA database connection
def _delete_with_transaction(self, model, trans):
Undocumented
def _delete_model(self, model):
Undocumented
def _prepare_run_editor(self, item):
Undocumented
def populate(self):
Undocumented
def add_item(self):
Undocumented
def remove_item(self, item):
Undocumented
def edit_item(self, item):
Undocumented
def set_model_type(self, model_type):
Set the type of the model this slave is containing
Parametersmodel_typethe model type
def set_editor_class(self, editor_class):
Set the editor class which will be used to modify the mode of this slave
Parameterseditor_classthe editor class
def set_reuse_transaction(self, trans):
Reuse the transaction.
Parametersreuse_transactiona transaction
def run_dialog(self, dialog_class, *args, **kwargs):
A special variant of run_dialog which deletes objects when a transaction is reused, it's safe to use when it's disabled, so always use this in your run_editor hook
def run_editor(self, trans, model):
This can be override by a subclass who wants to send in custom arguments to the editor.
def delete_model(self, model, trans):
Deletes the model in a transaction. This can be overriden by a subclass which is useful when you have foreign keys which depends on this class.
Parametersmodelmodel to delete
transthe transaction to delete the model within
API Documentation for Stoqlib, generated by pydoctor at 2009-07-14 16:00:32.