diff --git a/bt5/erp5_apparel/ActionTemplateItem/portal_types/Apparel%20Model/view_composition.xml b/bt5/erp5_apparel/ActionTemplateItem/portal_types/Apparel%20Model/view_composition.xml new file mode 100644 index 0000000000000000000000000000000000000000..5022689e65f4189a69aa6159de86aad8cf0c8a66 --- /dev/null +++ b/bt5/erp5_apparel/ActionTemplateItem/portal_types/Apparel%20Model/view_composition.xml @@ -0,0 +1,77 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <global name="ActionInformation" module="Products.CMFCore.ActionInformation"/> + <tuple/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>action</string> </key> + <value> + <persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent> + </value> + </item> + <item> + <key> <string>category</string> </key> + <value> <string>object_view</string> </value> + </item> + <item> + <key> <string>condition</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>description</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>icon</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>view_composition</string> </value> + </item> + <item> + <key> <string>permissions</string> </key> + <value> + <tuple> + <string>View</string> + </tuple> + </value> + </item> + <item> + <key> <string>priority</string> </key> + <value> <float>3.0</float> </value> + </item> + <item> + <key> <string>title</string> </key> + <value> <string>Composition</string> </value> + </item> + <item> + <key> <string>visible</string> </key> + <value> <int>1</int> </value> + </item> + </dictionary> + </pickle> + </record> + <record id="2" aka="AAAAAAAAAAI="> + <pickle> + <tuple> + <global name="Expression" module="Products.CMFCore.Expression"/> + <tuple/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>text</string> </key> + <value> <string>string:${object_url}/ApparelFabric_viewComposition</string> </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/bt5/erp5_apparel/PortalTypeAllowedContentTypeTemplateItem/allowed_content_types.xml b/bt5/erp5_apparel/PortalTypeAllowedContentTypeTemplateItem/allowed_content_types.xml index ffe5f68ffa399b5fb53b5b248dac66df1f2e597d..be58abea7d5160e187128d1d0425b126efd63783 100644 --- a/bt5/erp5_apparel/PortalTypeAllowedContentTypeTemplateItem/allowed_content_types.xml +++ b/bt5/erp5_apparel/PortalTypeAllowedContentTypeTemplateItem/allowed_content_types.xml @@ -55,6 +55,7 @@ <item>Apparel Measurement</item> </portal_type> <portal_type id="Apparel Model"> + <item>Mapped Value</item> <item>Supply Line</item> <item>Apparel Model Colour Variation</item> <item>Apparel Model Morphology Variation</item> diff --git a/bt5/erp5_apparel/PortalTypeHiddenContentTypeTemplateItem/hidden_content_type_list.xml b/bt5/erp5_apparel/PortalTypeHiddenContentTypeTemplateItem/hidden_content_type_list.xml index 3f7e364dda7765a5d44461e859fbb63177272d77..6808357b5d01e83bf12b88f5f31fe294ed195d7b 100644 --- a/bt5/erp5_apparel/PortalTypeHiddenContentTypeTemplateItem/hidden_content_type_list.xml +++ b/bt5/erp5_apparel/PortalTypeHiddenContentTypeTemplateItem/hidden_content_type_list.xml @@ -12,6 +12,7 @@ </portal_type> <portal_type id="Apparel Model"> <item>Supply Line</item> + <item>Mapped Value</item> </portal_type> <portal_type id="Apparel Transformation Transformed Resource"> <item>Mapped Value</item> diff --git a/bt5/erp5_apparel/PortalTypeTemplateItem/portal_types/Apparel%20Model.xml b/bt5/erp5_apparel/PortalTypeTemplateItem/portal_types/Apparel%20Model.xml index 7da7972dcbb876d5ea12cad741ef7cace9872855..13a14653d10e10314d7627c0084b263c0d523ae1 100644 --- a/bt5/erp5_apparel/PortalTypeTemplateItem/portal_types/Apparel%20Model.xml +++ b/bt5/erp5_apparel/PortalTypeTemplateItem/portal_types/Apparel%20Model.xml @@ -21,6 +21,25 @@ <dictionary/> </value> </item> + <item> + <key> <string>_property_domain_dict</string> </key> + <value> + <dictionary> + <item> + <key> <string>short_title</string> </key> + <value> + <persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent> + </value> + </item> + <item> + <key> <string>title</string> </key> + <value> + <persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent> + </value> + </item> + </dictionary> + </value> + </item> <item> <key> <string>_roles</string> </key> <value> @@ -114,4 +133,44 @@ </dictionary> </pickle> </record> + <record id="2" aka="AAAAAAAAAAI="> + <pickle> + <tuple> + <global name="TranslationInformation" module="Products.ERP5Type.TranslationProviderBase"/> + <tuple/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>domain_name</string> </key> + <value> <string>erp5_content</string> </value> + </item> + <item> + <key> <string>property_name</string> </key> + <value> <string>short_title</string> </value> + </item> + </dictionary> + </pickle> + </record> + <record id="3" aka="AAAAAAAAAAM="> + <pickle> + <tuple> + <global name="TranslationInformation" module="Products.ERP5Type.TranslationProviderBase"/> + <tuple/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>domain_name</string> </key> + <value> <string>erp5_content</string> </value> + </item> + <item> + <key> <string>property_name</string> </key> + <value> <string>title</string> </value> + </item> + </dictionary> + </pickle> + </record> </ZopeData> diff --git a/bt5/erp5_apparel/PropertySheetTemplateItem/ApparelModel.py b/bt5/erp5_apparel/PropertySheetTemplateItem/ApparelModel.py index a064db63b630502dfd619af9f36aa3b87a266f3f..6270c73356eea5b328190bc2a4d159011df423c5 100644 --- a/bt5/erp5_apparel/PropertySheetTemplateItem/ApparelModel.py +++ b/bt5/erp5_apparel/PropertySheetTemplateItem/ApparelModel.py @@ -67,10 +67,6 @@ class ApparelModel: 'acquisition_accessor_id' : 'getTitle', 'acquisition_depends' : None, 'mode' : 'w' }, - { 'id' : 'composition', - 'description' : 'Apparel Model composition', - 'type' : 'text', - 'mode' : 'w' }, { 'id' : 'margin_ratio', ### XXX 'description' : 'Margin coefficient', 'type' : 'float', @@ -143,7 +139,7 @@ class ApparelModel: 'mode' : 'w' }, ) - _categories = ( 'transformation_state', 'pricing', 'origin', 'brand', 'tariff_nomenclature' ) + _categories = ( 'composition', 'transformation_state', 'pricing', 'origin', 'brand', 'tariff_nomenclature' ) #_categories = ( 'transformation_state', 'apparel_pricing', 'apparel_creation_type', 'brand', 'tariff_nomenclature' ) # XXXXXXX XXXX XXXX apparel_model_creation_type (As in Brussels Tariff Nomenclature) diff --git a/bt5/erp5_apparel/SkinTemplateItem/portal_skins/erp5_apparel/ApparelModel_view.xml b/bt5/erp5_apparel/SkinTemplateItem/portal_skins/erp5_apparel/ApparelModel_view.xml index bada2e64acd41daecf1ffaf3f6d70c4049de965c..121dee4a2d073dea48ce943d114ef267e9d0b9eb 100644 --- a/bt5/erp5_apparel/SkinTemplateItem/portal_skins/erp5_apparel/ApparelModel_view.xml +++ b/bt5/erp5_apparel/SkinTemplateItem/portal_skins/erp5_apparel/ApparelModel_view.xml @@ -98,7 +98,7 @@ <string>my_origin</string> <string>my_apparel_model_template_title</string> <string>my_apparel_cloth_title_list</string> - <string>my_composition</string> + <string>my_composition_list</string> <string>my_ean13_code</string> <string>my_tariff_nomenclature</string> <string>my_transformation_state_list</string> diff --git a/bt5/erp5_apparel/SkinTemplateItem/portal_skins/erp5_apparel/ApparelModel_view/my_composition.xml b/bt5/erp5_apparel/SkinTemplateItem/portal_skins/erp5_apparel/ApparelModel_view/my_composition_list.xml similarity index 75% rename from bt5/erp5_apparel/SkinTemplateItem/portal_skins/erp5_apparel/ApparelModel_view/my_composition.xml rename to bt5/erp5_apparel/SkinTemplateItem/portal_skins/erp5_apparel/ApparelModel_view/my_composition_list.xml index 2f6b885fe0fd97b70319659a94b634b9a6206aa7..fdafe9bc821c215c995409c55ecd625bead498ba 100644 --- a/bt5/erp5_apparel/SkinTemplateItem/portal_skins/erp5_apparel/ApparelModel_view/my_composition.xml +++ b/bt5/erp5_apparel/SkinTemplateItem/portal_skins/erp5_apparel/ApparelModel_view/my_composition_list.xml @@ -3,18 +3,15 @@ <record id="1" aka="AAAAAAAAAAE="> <pickle> <tuple> - <tuple> - <string>Products.Formulator.StandardFields</string> - <string>TextAreaField</string> - </tuple> - <none/> + <global name="MultiListField" module="Products.Formulator.StandardFields"/> + <tuple/> </tuple> </pickle> <pickle> <dictionary> <item> <key> <string>id</string> </key> - <value> <string>my_composition</string> </value> + <value> <string>my_composition_list</string> </value> </item> <item> <key> <string>message_values</string> </key> @@ -24,21 +21,13 @@ <key> <string>external_validator_failed</string> </key> <value> <string>The input failed the external validator.</string> </value> </item> - <item> - <key> <string>line_too_long</string> </key> - <value> <string>A line was too long.</string> </value> - </item> <item> <key> <string>required_not_found</string> </key> <value> <string>Input is required but no input given.</string> </value> </item> <item> - <key> <string>too_long</string> </key> - <value> <string>You entered too many characters.</string> </value> - </item> - <item> - <key> <string>too_many_lines</string> </key> - <value> <string>You entered too many lines.</string> </value> + <key> <string>unknown_selection</string> </key> + <value> <string>You selected an item that was not in the list.</string> </value> </item> </dictionary> </value> @@ -80,7 +69,7 @@ <value> <string></string> </value> </item> <item> - <key> <string>height</string> </key> + <key> <string>extra_item</string> </key> <value> <string></string> </value> </item> <item> @@ -88,19 +77,15 @@ <value> <string></string> </value> </item> <item> - <key> <string>max_length</string> </key> + <key> <string>items</string> </key> <value> <string></string> </value> </item> <item> - <key> <string>max_linelength</string> </key> - <value> <string></string> </value> - </item> - <item> - <key> <string>max_lines</string> </key> + <key> <string>required</string> </key> <value> <string></string> </value> </item> <item> - <key> <string>required</string> </key> + <key> <string>size</string> </key> <value> <string></string> </value> </item> <item> @@ -112,11 +97,7 @@ <value> <string></string> </value> </item> <item> - <key> <string>whitespace_preserve</string> </key> - <value> <string></string> </value> - </item> - <item> - <key> <string>width</string> </key> + <key> <string>view_separator</string> </key> <value> <string></string> </value> </item> </dictionary> @@ -136,7 +117,9 @@ </item> <item> <key> <string>default</string> </key> - <value> <string></string> </value> + <value> + <persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent> + </value> </item> <item> <key> <string>description</string> </key> @@ -159,7 +142,7 @@ <value> <string></string> </value> </item> <item> - <key> <string>height</string> </key> + <key> <string>extra_item</string> </key> <value> <string></string> </value> </item> <item> @@ -167,19 +150,17 @@ <value> <string></string> </value> </item> <item> - <key> <string>max_length</string> </key> - <value> <string></string> </value> - </item> - <item> - <key> <string>max_linelength</string> </key> - <value> <string></string> </value> + <key> <string>items</string> </key> + <value> + <persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent> + </value> </item> <item> - <key> <string>max_lines</string> </key> + <key> <string>required</string> </key> <value> <string></string> </value> </item> <item> - <key> <string>required</string> </key> + <key> <string>size</string> </key> <value> <string></string> </value> </item> <item> @@ -191,11 +172,7 @@ <value> <string></string> </value> </item> <item> - <key> <string>whitespace_preserve</string> </key> - <value> <string></string> </value> - </item> - <item> - <key> <string>width</string> </key> + <key> <string>view_separator</string> </key> <value> <string></string> </value> </item> </dictionary> @@ -215,7 +192,9 @@ </item> <item> <key> <string>default</string> </key> - <value> <string></string> </value> + <value> + <list/> + </value> </item> <item> <key> <string>description</string> </key> @@ -238,29 +217,27 @@ <value> <string></string> </value> </item> <item> - <key> <string>height</string> </key> - <value> <int>1</int> </value> + <key> <string>extra_item</string> </key> + <value> <string></string> </value> </item> <item> <key> <string>hidden</string> </key> <value> <int>0</int> </value> </item> <item> - <key> <string>max_length</string> </key> - <value> <string></string> </value> - </item> - <item> - <key> <string>max_linelength</string> </key> - <value> <string></string> </value> - </item> - <item> - <key> <string>max_lines</string> </key> - <value> <string></string> </value> + <key> <string>items</string> </key> + <value> + <list/> + </value> </item> <item> <key> <string>required</string> </key> <value> <int>0</int> </value> </item> + <item> + <key> <string>size</string> </key> + <value> <int>5</int> </value> + </item> <item> <key> <string>title</string> </key> <value> <string>Composition</string> </value> @@ -270,12 +247,13 @@ <value> <int>0</int> </value> </item> <item> - <key> <string>whitespace_preserve</string> </key> - <value> <int>0</int> </value> - </item> - <item> - <key> <string>width</string> </key> - <value> <int>40</int> </value> + <key> <string>view_separator</string> </key> + <value> <string encoding="cdata"><![CDATA[ + +<br />\n + + +]]></string> </value> </item> </dictionary> </value> @@ -283,4 +261,42 @@ </dictionary> </pickle> </record> + <record id="2" aka="AAAAAAAAAAI="> + <pickle> + <tuple> + <tuple> + <string>Products.Formulator.TALESField</string> + <string>TALESMethod</string> + </tuple> + <none/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>_text</string> </key> + <value> <string>here/getCompositionList</string> </value> + </item> + </dictionary> + </pickle> + </record> + <record id="3" aka="AAAAAAAAAAM="> + <pickle> + <tuple> + <tuple> + <string>Products.Formulator.TALESField</string> + <string>TALESMethod</string> + </tuple> + <none/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>_text</string> </key> + <value> <string>here/portal_categories/composition/getCategoryChildLogicalPathItemList</string> </value> + </item> + </dictionary> + </pickle> + </record> </ZopeData> diff --git a/bt5/erp5_apparel/bt/revision b/bt5/erp5_apparel/bt/revision index 8fdd954df9831dfd29ceec0d74829b02f3f5d8c3..410b14d2ce6f958c13adcb30807e8673074c49d9 100644 --- a/bt5/erp5_apparel/bt/revision +++ b/bt5/erp5_apparel/bt/revision @@ -1 +1 @@ -22 \ No newline at end of file +25 \ No newline at end of file diff --git a/bt5/erp5_apparel/bt/template_action_path_list b/bt5/erp5_apparel/bt/template_action_path_list index a912332b4599bd6611f8a7355bfbf4389f2b126a..2aacb6ae0e470c20c21e480967a6adcba591e01f 100644 --- a/bt5/erp5_apparel/bt/template_action_path_list +++ b/bt5/erp5_apparel/bt/template_action_path_list @@ -115,6 +115,7 @@ Apparel Model | jump_to_related_apparel_transformation Apparel Model | morphology_variation Apparel Model | references Apparel Model | view +Apparel Model | view_composition Apparel Model | view_price Apparel Model | view_variated_reference_list Apparel Shape Module | csv_export diff --git a/bt5/erp5_apparel/bt/template_portal_type_allowed_content_type_list b/bt5/erp5_apparel/bt/template_portal_type_allowed_content_type_list index 1e82de4c88019113f5d7be1546f949b24cd2b40d..2cfb5176f082acd8298a55859eb65c4d9eef8788 100644 --- a/bt5/erp5_apparel/bt/template_portal_type_allowed_content_type_list +++ b/bt5/erp5_apparel/bt/template_portal_type_allowed_content_type_list @@ -22,6 +22,7 @@ Apparel Measurement | Mapped Value Apparel Model Module | Apparel Model Apparel Model | Apparel Model Colour Variation Apparel Model | Apparel Model Morphology Variation +Apparel Model | Mapped Value Apparel Model | Supply Line Apparel Shape Module | Apparel Shape Apparel Shape | Apparel Technical Drawing diff --git a/bt5/erp5_apparel/bt/template_portal_type_hidden_content_type_list b/bt5/erp5_apparel/bt/template_portal_type_hidden_content_type_list index b0842b6615f52e1d8c0ddeb67cf5205ef34d131a..a4654ce49f04281e4f3507e36c8f0da1bb2d8efd 100644 --- a/bt5/erp5_apparel/bt/template_portal_type_hidden_content_type_list +++ b/bt5/erp5_apparel/bt/template_portal_type_hidden_content_type_list @@ -3,5 +3,6 @@ Apparel Component | Supply Line Apparel Consumption | Mapped Value Apparel Fabric | Mapped Value Apparel Fabric | Supply Line +Apparel Model | Mapped Value Apparel Model | Supply Line Apparel Transformation Transformed Resource | Mapped Value \ No newline at end of file