diff --git a/docs/api/extjs_links.txt b/docs/api/extjs_links.txt index 46f2d3482e474924fc9a9fd208d69655b76cd427..b44aff9a03eb91ca7ac607316b749186d511c226 100644 --- a/docs/api/extjs_links.txt +++ b/docs/api/extjs_links.txt @@ -82,6 +82,9 @@ .. _Ext.data.Model: http://docs-origin.sencha.com/extjs/4.2.1/#!/api/Ext.data.Model +.. _Ext.toolbar.Paging: + http://docs-origin.sencha.com/extjs/4.2.1/#!/api/Ext.toolbar.Paging + .. _Ext.panel.Panel: http://docs-origin.sencha.com/extjs/4.2.1/#!/api/Ext.panel.Panel diff --git a/modules/plugin_dbui/converter.py b/modules/plugin_dbui/converter.py index b4352055c816d889de3801deb1185296315ad4aa..b980dedd0be7b4733a7dfdff569275e6bffac125 100644 --- a/modules/plugin_dbui/converter.py +++ b/modules/plugin_dbui/converter.py @@ -60,8 +60,8 @@ def _to_field(field, linkedcombo=True, **kwargs): Useful to build grid filter. Keyword Args: - any Ext JS configuration parameters of the - ``Ext.form.Field`` class. They are applied in the following order: + any Ext JS configuration parameters of the class :class:`.Field`. + They are applied in the following order: constructor, modifiers and keyword arguments. Returns: @@ -199,7 +199,7 @@ def to_field(field, composite=True, linkedcombo=True, **kwargs): Keyword Args: **kwargs (dict): any Ext JS configuration parameter of the - ``Ext.form.Field`` widget or derived classes. They are applied + the :class:`.Field` widget or derived classes. They are applied in the following order: constructor, modifiers and keyword arguments. @@ -347,7 +347,7 @@ def to_formPanel(table, **kwargs): Keyword Args: **kwargs (dict): any Ext JS configuration parameter of the - ``Ext.form.Panel`` class. They are applied in the following + class :class:`.FormPanel`. They are applied in the following order: constructor, modifiers and keyword arguments. Returns: @@ -386,7 +386,7 @@ def to_gridColumn(field, **kwargs): Keyword Args: **kwargs (dict): any Ext JS configuration parameter of the - ``Ext.grid.Column`` class. They are applied in the following + class :class:`.GridColumn`. They are applied in the following order: constructor, modifiers and keyword arguments. Returns: @@ -500,8 +500,8 @@ def to_gridFilter(table, **kwargs): Keyword Args: **kwargs (dict): any of the Ext JS configuration parameters of the - ``App.grid.Filter`` class. They are applied in the following order: - constructor, modifiers, keyword arguments. + the :class:`.GridFilter`` class. They are applied in the following + order: constructor, modifiers, keyword arguments. Returns: * GridFilter @@ -607,9 +607,9 @@ def to_gridPanel(table, **kwargs): table (gluon.dal.Table): database table Keyword Args: - **kwargs (dict): any of the Ext JS configuration parameters of the - ``App.grid.Panel`` class. They are applied in the following order: - constructor, modifiers, keyword arguments. + **kwargs (dict): any of the Ext JS configuration parameters of + the :class:`.GridPanel` class. They are applied in the following + order: constructor, modifiers, keyword arguments. Returns: GridPanel @@ -656,8 +656,8 @@ def to_jsonstore(table, **kwargs): table (gluon.dal.Table): database table Keyword Args: - **kwargs (dict): any of the Ext JS configuration parameters of the - ``App.data.DirectStore`` class. They are applied in the + **kwargs (dict): any of the Ext JS configuration parameters of + the :class:`.DirectStore` class. They are applied in the following order: constructor, modifiers, keyword arguments. Returns: @@ -804,8 +804,8 @@ def to_panelWithUrlSelector(table, selectorTitle='Select', **kwargs): It is mandatory to specified the baseUrl. Keyword Args: - **kwargs (dict): any of the Ext JS configuration parameters of the - ``App.panel.WithUrlSelector`` class. + **kwargs (dict): any of the Ext JS configuration parameters of + the :class:`.PanelWithUrlSelector`` class. Returns: PanelWithUrlSelector @@ -861,8 +861,8 @@ def to_viewport(**kwargs): instructions. Keyword Args: - **kwargs (dict): any of the Ext JS configuration parameters of the - ``App.viewport.Viewport`` class. + **kwargs (dict): any of the Ext JS configuration parameters of + the :class:`.Viewport`` class. Returns: dict diff --git a/modules/plugin_dbui/dbsvc.py b/modules/plugin_dbui/dbsvc.py index efffc46e360c466651cba14b73b57a051e797283..f7362e36e2e880640fe4f4bab9f5de3805e6b901 100644 --- a/modules/plugin_dbui/dbsvc.py +++ b/modules/plugin_dbui/dbsvc.py @@ -527,7 +527,7 @@ class DbSvc(BaseSvc): The third argument is equal to ``"ASC"`` or ``"DESC"``. * The transaction dictionary can also contains parameters useful - for paging. For more details, see the ``Ext.toolbar.Paging`` + for paging. For more details, see the `Ext.toolbar.Paging`_ configuration parameters: ``page``, ``start``, ``limit``, ``sort`` and ``dir``. @@ -538,6 +538,8 @@ class DbSvc(BaseSvc): * The keyword ``records`` is a list of dictionary containing all key value pairs for the record found in the database. + .. include:: ../../../../docs/api/extjs_links.txt + """ self.dbg("Start DbSvc.read") diff --git a/modules/plugin_dbui/fieldsmodifier.py b/modules/plugin_dbui/fieldsmodifier.py index 595e19a17e1326f3f4ef0889207a6d120bc0d930..f99a8972b8b4d7d0b12b953b6d787fb96bd4f124 100644 --- a/modules/plugin_dbui/fieldsmodifier.py +++ b/modules/plugin_dbui/fieldsmodifier.py @@ -117,7 +117,7 @@ class FieldsModifier(Modifier): Keyword Args: **kwargs: any configuration parameter of the - ``Ext.form.FieldContainer``. + the :class:`.FieldContainer`. """ # configuration of the FieldContainer diff --git a/modules/plugin_dbui/formmodifier.py b/modules/plugin_dbui/formmodifier.py index c7e1952953c6b468a4338381cb44c4ad8409354d..7caf0216230e21a248ecc00597acb30e678bb522 100644 --- a/modules/plugin_dbui/formmodifier.py +++ b/modules/plugin_dbui/formmodifier.py @@ -26,7 +26,8 @@ def configure_forms(db, **extjs): associated database table name. Keyword Args: - **extjs: any configuration parameter of the ``Ext.form.Panel`` widget. + **extjs: any configuration parameter of the :class:`.FormPanel` + widget. """ if isinstance(db, DAL): @@ -54,7 +55,7 @@ class FormModifier(Modifier): four keys/attributes: * **extjs** (dict): Ext JS configuration options - for ``Ext.form.Panel`` widget. + for :class:`.FormPanel` widget. * **field_sets** (list): list of ``gluon.storage.Storage`` defining the :class:`.FieldSet` configurations. It has two @@ -122,7 +123,7 @@ class FormModifier(Modifier): masterHasSlaveData='anotherTable') * This method modify deeply the field configuration transforming - the ``Ext.form.comboBox`` into ``App.form.LinkedComboBox``. + the :class:`.ComboBox` into ``App.form.LinkedComboBox``. Keyword Args: master (gluon.dal.Field): the database field used as master. @@ -137,11 +138,11 @@ class FormModifier(Modifier): between master and slave. It should contains fields with the name of the master and slave ones. - masterExtJS (dict): configuration options dictionary for the - ``Ext.form.field.Combobox`` associated to the master reference field. + masterExtJS (dict): configuration options dictionary for + the :class:`.ComboBox` associated to the master reference field. - slaveExtJS (dict): configuration option dictionary for the - ``Ext.form.field.Combobox`` associated to the slave reference field. + slaveExtJS (dict): configuration option dictionary for + the :class:`.ComboBox` associated to the slave reference field. """ # short cuts @@ -212,7 +213,7 @@ class FormModifier(Modifier): *fields: variable list of database field identified by their name. Keyword Args: - **kwargs: any configuration options of the ``Ext.form.FieldSet`` + **kwargs: any configuration options of the :class:`.FieldSet` widget. """ @@ -234,7 +235,7 @@ class FormModifier(Modifier): vertically, by columns or table. This approach does not allow to map field/fieldset in panels - contains in the form, like an ``Ext.tab.Panel``. The mapper tool + contains in the form, like an :class:`.TabPanel`. The mapper tool handles this case. It is a function with one arguments, the list of field/fieldset. The function return a dictionary with the structure of panels embedded in the form an the fields they contained. diff --git a/modules/plugin_dbui/gridmodifier.py b/modules/plugin_dbui/gridmodifier.py index 4856fcfc6835967d71aceba881b1ee2d9809c8be..e7228403fe90270c6109c1db5fecedf8a0bdf9ff 100644 --- a/modules/plugin_dbui/gridmodifier.py +++ b/modules/plugin_dbui/gridmodifier.py @@ -28,7 +28,7 @@ def configure_grids(db, **extjs): associated database table name. Keyword Args: - **extjs: any configuration parameter of the ``Ext.grid.Panel`` widget. + **extjs: any configuration parameter of the :class:`.GridPanel` widget. """ if isinstance(db, DAL): @@ -59,10 +59,10 @@ class GridModifier(Modifier): seven keys/attributes: * **extjs** (dict): Ext JS configuration options - for ``Ext.grid.Panel`` widget. + for :class:`.GridPanel` widget. * **configure_columns** (dict): the Ext JS configuration options for - each ``Ext.grid.Column`` object. The grid has one column per + each :class:`.GridColumn` object. The grid has one column per per database field of the table. Therefore, the key is the database field name @@ -73,8 +73,8 @@ class GridModifier(Modifier): * **grid_filters** (gluon.storage.Storage): list of filter rules (see :meth:`append_filter`) - * **grid_with_filter** (dict): configuration options of the - ``App.grid.GridWithFilter`` widget. + * **grid_with_filter** (dict): configuration options of + the :class:`.GridWithFilter` widget. * **hidden_columns** (list): list of database fields which are hidden in the grid widget. @@ -115,7 +115,7 @@ class GridModifier(Modifier): column will be insert. The first column is at 0. The keyword argument ExtJS is a dictionary containing - configuration options of the underlying Ext.grid.Column. + configuration options of the underlying :class:`.GridColumn`. """ @@ -144,7 +144,7 @@ class GridModifier(Modifier): or ``('table2.field3', 'operator', 'comment')`` Keyword Args: - **kwargs: any configuration options of the``Ext.form.Field``. + **kwargs: any configuration options of the :class:`.Field`. """ self.data.grid_filters.filters.append(filter) @@ -161,41 +161,41 @@ class GridModifier(Modifier): in the constructor. Keyword Args: - **kwargs: any configuration option of the - ``Ext.grid.Column`` object. + **kwargs: any configuration option of the :class:`.GridColumn` + object. """ self.data.configure_columns[fieldname] = kwargs def configure_filters(self, **kwargs): - """Configure the ``Ext.form.FieldSet`` embedded in the GridFilter. + """Configure the :class:`.FieldSet` embedded in the :class:`.GridFilter`. The latter is created automatically as soon as a filter is defined. Filter are defined and tuned individually using the method :meth:`append_filter`. Keyword Args: - **kwargs: any configuration options of the - ``Ext.form.FieldSet`` widget. + **kwargs: any configuration options of the :class:`.FieldSet` + widget. """ self.data.grid_filters.extjs = kwargs def configure_gridWithFilter(self, **kwargs): - """Configure the ``App.grid.GridwithFilter`` widget. + """Configure the :class:`.GridWithFilter` widget. Keyword Args: **kwargs: any configuration option of - the ``App.grid.GridwithFilter`` widget + the :class:`.GridwithFilter` widget """ self.data.grid_with_filter.extjs = kwargs def delete_columns(self, *fields): - """Delete the columns in the ``Ext.grid.Panel`` widget. + """Delete the columns in the :class:`.GridPanel` widget. The grid has one column per database field of the table. This method defined the database fields not displayed in the grid. @@ -211,7 +211,7 @@ class GridModifier(Modifier): def hide_columns(self, *fields): - """Hide the columns in the ``Ext.grid.Panel`` widget. + """Hide the columns in the :class:`.GridPanel` widget. The grid has one column per database field of the table. This method defined the database fields hidden in the grid. diff --git a/modules/plugin_dbui/mapper.py b/modules/plugin_dbui/mapper.py index b2a9e50ca10cbdd24c67f6c47d75506ca61e400c..228d3b6eaff61596d12f958a67c158a15e778556 100644 --- a/modules/plugin_dbui/mapper.py +++ b/modules/plugin_dbui/mapper.py @@ -5,7 +5,7 @@ from extjs import TabPanel def map_default(fields): - """Map a list of field in the ``Ext.form.formPanel``. + """Map a list of field in the :class:`.FormPanel`. Args: fields (list): database field names @@ -19,7 +19,7 @@ def map_default(fields): def map_tabpanel(fieldsets): - """Map a list of ``FieldSets`` in the ``Ext.TabPanel``. + """Map a list of :class:`.FieldSet` in the :class:`.TabPanel`. * A tab is associated to each fieldset. * the name of the tab is the name of the fieldset. diff --git a/modules/plugin_dbui/storemodifier.py b/modules/plugin_dbui/storemodifier.py index 750af59440a916eb8040df9026b6f8cb86f02238..e1320b4dc017b3cf1bd465e8fec974cf353c9bb0 100644 --- a/modules/plugin_dbui/storemodifier.py +++ b/modules/plugin_dbui/storemodifier.py @@ -21,7 +21,7 @@ class AddStore(object): the ``plugin_dbui/dbui_conf`` action. From time to time, it is useful to defined static store, - like ``Ext.data.ArrayStore``. This tool allows to defined them + like :class:`.ArrayStore`. This tool allows to defined them and to add their configuration to the persistent dictionary. Thus they can be retrieve by the client in the standard way. @@ -33,9 +33,9 @@ class AddStore(object): Keyword Args: **kwargs: any configuration options for the target store. - For example the ``Ext.data.ArrayStore`` requires the + For example the :class:`.ArrayStore` requires the keyword ``fields`` and ``data``. For more details see - the ExtJS documentation. + the Ext JS documentation. Note: The key associated to this store in the persistent dictionary @@ -66,7 +66,7 @@ class StoreModifier(Modifier): two keys/attributes: * **extjs** (dict): Ext JS configuration options - for ``Ext.data.Store`` object. + for :class:`.Store` object. * **order_by** (list): database fields to order the content of the store @@ -106,7 +106,7 @@ class StoreModifier(Modifier): Keyword Args: kwargs (dict): the configuration parameter of - the ``Ext.data.Store`` related to the buffering, namely: + the :class:`.Store` related to the buffering, namely: ``buffered``, ``clearOnPaqgeLoad``, ``leadingBufferZone``, ``pageSize``, ``purgePageCount`` and ``trailingBufferZone``. diff --git a/modules/plugin_dbui/viewportmodifier.py b/modules/plugin_dbui/viewportmodifier.py index b9d93902e2e392deaf9af43cf3143228cbb9a2c8..4460f3d3e723279fe6d96f645ac4ba763ef08acd 100644 --- a/modules/plugin_dbui/viewportmodifier.py +++ b/modules/plugin_dbui/viewportmodifier.py @@ -21,7 +21,7 @@ class ViewportModifier(Modifier): three keys/attributes: * **extjs** (dict): Ext JS configuration options - for ``Ext.container.Viewport`` widget. + for :class:`.Viewport` widget. * **default** (list): list of string defining the path of the node which will be opened at start up. Each node is identify its