ez projects / ez_category_selection__ezp4...
| UNIX name | Owner | Status | Version | Compatible with |
|---|---|---|---|---|
| ez_category_selection__ezp4.3+_ | Michael Lee | stable | 1.7 | 4.3+ |
Category selection data type for eZ publish
This is a branch for eZ publish 4.3+
By default, eZ publish only supports selection data type. But selection
data type doesn't relate to each other, which means your selection of
one "selection" field won't affect other "selection" fields.
Sometimes, you need define dependencies between "selection" fields.
For example, you might need define three fields (country, city and
area) in a content class and define the dependencies between them.
The city field depends on country and area field depends on city
field.
ezcategoryselection extension was developed to fulfill such requirements. It introduced
a new data type - ezcategoryselection which allows you to bind one or
more categories to options of an ezcategoryselection attribute.
The categories may come from:
- selection attributes defined in same content class
- ezcategoryselection attributes defined in same content class
- selection attributes defined in other content class
- ezcategoryselection attributes defined in other content class
You can also bind a combination of categories (category and its
values) to a group of options. For example, you may bind color [
'red' | 'black' ] and size ['large' | 'medium' | 'small' ] to option
1 to option 10 of the 'product' attribute (which is
ezcategoryselection data type).
The following illustration and description explains how to use
ezcategoryselection data type:
1. threshold - this field holds an integer which can be used as a
threshold for different purposes
2. description - this field holds the description for current
ezcategoryselection attribute.
3. cross class - specifying if current ezcategoryselection attribute
may be binded to external categories or not. 'No' by default, which
means you can only bind categories defined in current content class
to this attribute. If you set it to 'Yes', a 'class drop down' list
will show up to allow you specify external categories.
Note:
When editing content object or submitting information collection form,
external category binds will be ignored and won't affect the
visibilities of ezcategoryselection options.
4. attribute drop down list - lists attributes with 'selection' or
'ezcategoryselection' data type
5. category drop down list - lists option values of the selected
category attribute in the attribute drop down list.
6. remove selected category - select categories with the check boxes
and click on remove selected
button to remove the selected categories.
7. refresh category - click the refresh
category button to re-load attribute list and
category list.
8. bind category
* select options with its check boxes. (please refer to item 11.)
* select categories with category check boxes.
* select category values with category drop down list. (please refer
to item 5)
* click bind category to bind
selected categories and values to selected options.
9. new category - click the new
category button to add a new category. After the
category is added, you need click refresh
category (item 7) to re-load attribute drop down
list and category drop down list.
10. option label - display information of the binded categories and
values
11. option id - display the system id of each option. Each option has an
unique id, the id does not change with the order of each option. So
please note option id is different with option index.
12. moving options up/down - click on 'down' or 'up' button to move
option down or up in same group.
13. remove selected option - select options with check boxes and click
remove selected button to remove
selected options.
14. new option - click this button to add a new option.
Changelog
Sunday 04 July 2010 18:13
Michael Lee