diff --git a/bt5/erp5_base/CategoryTemplateItem/portal_categories/destination_carrier.xml b/bt5/erp5_base/CategoryTemplateItem/portal_categories/destination_carrier.xml index 0df075d11a78e8923b1e6fe2e011962a3c427d6d..47cb95e3171db1986d51727af16cd60025e5222a 100644 --- a/bt5/erp5_base/CategoryTemplateItem/portal_categories/destination_carrier.xml +++ b/bt5/erp5_base/CategoryTemplateItem/portal_categories/destination_carrier.xml @@ -52,7 +52,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>destination_arrow</string> + </tuple> </value> </item> <item> diff --git a/bt5/erp5_base/CategoryTemplateItem/portal_categories/destination_referral.xml b/bt5/erp5_base/CategoryTemplateItem/portal_categories/destination_referral.xml index fc2a6ced2c432694f5affc43c5dcf218fb2cc74b..919de1c1a5c5958a8829866a59192061dcf6a490 100644 --- a/bt5/erp5_base/CategoryTemplateItem/portal_categories/destination_referral.xml +++ b/bt5/erp5_base/CategoryTemplateItem/portal_categories/destination_referral.xml @@ -53,7 +53,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>destination_arrow</string> + </tuple> </value> </item> <item> diff --git a/bt5/erp5_base/CategoryTemplateItem/portal_categories/source_carrier.xml b/bt5/erp5_base/CategoryTemplateItem/portal_categories/source_carrier.xml index 2f226dda7c366ba8213b15a400f17fa8ab535253..74040e55527ad40f66820fd0e89df4576acc2c6b 100644 --- a/bt5/erp5_base/CategoryTemplateItem/portal_categories/source_carrier.xml +++ b/bt5/erp5_base/CategoryTemplateItem/portal_categories/source_carrier.xml @@ -27,6 +27,14 @@ </tuple> </value> </item> + <item> + <key> <string>category_type</string> </key> + <value> + <tuple> + <string>source_arrow</string> + </tuple> + </value> + </item> <item> <key> <string>description</string> </key> <value> diff --git a/bt5/erp5_base/CategoryTemplateItem/portal_categories/source_referral.xml b/bt5/erp5_base/CategoryTemplateItem/portal_categories/source_referral.xml index 3d863d396e0d3e290d957e18a9118ad99c06cfd8..34648cebae206ca6359415ff3e5dbe5798579633 100644 --- a/bt5/erp5_base/CategoryTemplateItem/portal_categories/source_referral.xml +++ b/bt5/erp5_base/CategoryTemplateItem/portal_categories/source_referral.xml @@ -28,6 +28,14 @@ </tuple> </value> </item> + <item> + <key> <string>category_type</string> </key> + <value> + <tuple> + <string>source_arrow</string> + </tuple> + </value> + </item> <item> <key> <string>description</string> </key> <value> diff --git a/bt5/erp5_trade/DocumentTemplateItem/portal_components/document.erp5.TradeModelPath.py b/bt5/erp5_trade/DocumentTemplateItem/portal_components/document.erp5.TradeModelPath.py index 8267327bfba18657eea67c4d1fcc15d744f20c38..96fbe10ca294069cc5834be9d9dcc6ed9d5b7e2b 100644 --- a/bt5/erp5_trade/DocumentTemplateItem/portal_components/document.erp5.TradeModelPath.py +++ b/bt5/erp5_trade/DocumentTemplateItem/portal_components/document.erp5.TradeModelPath.py @@ -114,22 +114,7 @@ class TradeModelPath(Path): Returns all categories which are used to define the source of this Arrow """ - # Naive implementation - we must use category groups instead - XXX - return ('source', - 'source_account', - 'source_administration', - #'source_advice', - 'source_carrier', - 'source_decision', - 'source_function', - 'source_funding', - 'source_payment', - 'source_project', - 'source_referral', - 'source_section', - 'source_trade', - #'source_transport' - ) + return self.getPortalObject().getPortalSourceArrowBaseCategoryList() security.declareProtected(Permissions.AccessContentsInformation, 'getDestinationArrowBaseCategoryList') @@ -138,22 +123,7 @@ class TradeModelPath(Path): Returns all categories which are used to define the destination of this Arrow """ - # Naive implementation - we must use category groups instead - XXX-JPS review this later - return ('destination', - 'destination_account', - 'destination_administration', - #'destination_advice', - #'destination_carrier', - 'destination_decision', - 'destination_function', - 'destination_funding', - 'destination_payment', - 'destination_project', - 'destination_referral', - 'destination_section', - 'destination_trade', - #'destination_transport' - ) + return self.getPortalObject().getPortalDestinationArrowBaseCategoryList() # XXX-JPS UNkonwn ? security.declareProtected(Permissions.AccessContentsInformation, diff --git a/product/ERP5/ERP5Site.py b/product/ERP5/ERP5Site.py index 7a60ecf02a769e5a9b8d998a917c82dfea69cb9f..6155f50629938a187ffa13c7516c07cd19074f74 100644 --- a/product/ERP5/ERP5Site.py +++ b/product/ERP5/ERP5Site.py @@ -938,6 +938,22 @@ class ERP5Site(ResponseHeaderGenerator, FolderMixIn, PortalObjectBase, CacheCook """ return self._getPortalGroupedCategoryList('sub_variation') + security.declareProtected(Permissions.AccessContentsInformation, + 'getPortalSourceArrowBaseCategoryList') + def getPortalSourceArrowBaseCategoryList(self): + """ + Return source arrow base categories. + """ + return self._getPortalGroupedCategoryList('source_arrow') + + security.declareProtected(Permissions.AccessContentsInformation, + 'getPortalDestinationArrowBaseCategoryList') + def getPortalDestinationArrowBaseCategoryList(self): + """ + Return destination arrow base categories. + """ + return self._getPortalGroupedCategoryList('destination_arrow') + security.declareProtected(Permissions.AccessContentsInformation, 'getPortalVariationTypeList') def getPortalVariationTypeList(self): diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination.xml index 43a1e4efcb7e907683f7a8f0f00e96dcf599342e..a7c68eb99cfb3893c90336c4d87e627be5aa6e46 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination.xml @@ -68,7 +68,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>destination_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_account.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_account.xml index d212c18f977f4dcfe588125e1a20f405b8ba5492..1d14a5b1678fd6c421b928692d2aceff25941e02 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_account.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_account.xml @@ -52,7 +52,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>destination_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_administration.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_administration.xml index 7dc46111ebe37e9788747b8e4ca12737e6bc3ae9..87ab99e391c9c0b05e3b442017c8d05095eae167 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_administration.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_administration.xml @@ -50,7 +50,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>destination_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_decision.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_decision.xml index cf7cc441b7a7f537034141af10a679d9dda657b2..43635cfe75b39835a9b72acea555a2ae678a9dd5 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_decision.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_decision.xml @@ -50,7 +50,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>destination_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_function.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_function.xml index a28d0f2e524ddc2d8b7911b3634d4bc23c6a6f86..58f65ddebeac89c254a0ee6a97084d99098b2bea 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_function.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_function.xml @@ -70,7 +70,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>destination_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_funding.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_funding.xml index 180ede846824cb4421b5c7ac917eae6a4cc4c4d3..2bbccd0cb16a572acf1ecedfe5df494210664420 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_funding.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_funding.xml @@ -118,7 +118,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>destination_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_payment.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_payment.xml index b6145a4b9d739445dce7251dffd52b4c04595d6e..9788835125701dc88c394e82062a5e881f6ce809 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_payment.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_payment.xml @@ -50,7 +50,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>destination_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_payment_request.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_payment_request.xml index 1d20edd246e2f9e23ea968c9c48c3490b193c81a..c364056eb8b5d3054fe5fa7c6e68e569f696b4c4 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_payment_request.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_payment_request.xml @@ -119,7 +119,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>destination_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_project.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_project.xml index 690d5a55970d2f41182520d59bd2efd63a75b449..25c168c7bdbacc1c42c491ccc0fa3c8d49f7accb 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_project.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_project.xml @@ -71,7 +71,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>destination_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_section.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_section.xml index 1c2e6828de6199263c1bd3ee54e31360dba95d51..88ead1465b6072fc2b645a019e5258741cb60d77 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_section.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_section.xml @@ -68,7 +68,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>destination_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_trade.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_trade.xml index eac6cdf827a79a764287b6619d7752a5e1879e5f..0cc4278744836e9b5fca92458a956a0352ff2758 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_trade.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/destination_trade.xml @@ -71,7 +71,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>destination_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source.xml index f73069e5ce4e38c699567b838f3bc0f0f5165f53..fbf10af12034b89411566f0a7095ed64648c967c 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source.xml @@ -115,7 +115,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>source_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_account.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_account.xml index 32b0144ba31ec06919d17a2a3a67edf6e9afe3ee..0d53e057980182d4e511353c5e7c0027117d5eb8 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_account.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_account.xml @@ -53,7 +53,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>source_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_administration.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_administration.xml index 911856342961875a888fee68110038d13f36cacd..ae4201198ffa932efd6b5b2b8733018b5af80bbe 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_administration.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_administration.xml @@ -50,7 +50,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>source_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_decision.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_decision.xml index fbb727399bd1f6ec6cde29da2a96d18b4be3a0a7..aaf4e98d562691740864be8b1e7e2c0506e9ee92 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_decision.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_decision.xml @@ -50,7 +50,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>source_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_function.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_function.xml index a006af1d1651dad82732d8bd9edfa470632aef11..ff18821359d3b2c074f62407e7f857fbbd4033b5 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_function.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_function.xml @@ -70,7 +70,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>source_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_funding.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_funding.xml index da2188f263c221b537fe4bdf0de07ffe0e1609fa..b3075995767466f5a0dbcfba67d03ae4b4380944 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_funding.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_funding.xml @@ -118,7 +118,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>source_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_payment.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_payment.xml index 8e0aa127b633b9a05085d074b6456e3f915c0d38..831bb41f21647e904e829c9b7cdbefcbcc89d890 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_payment.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_payment.xml @@ -50,7 +50,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>source_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_payment_request.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_payment_request.xml index 51abc11f0b6bb485f2e484dc0321be8b503c9787..98964050dbf89e95f30687e08708df64a4e10aab 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_payment_request.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_payment_request.xml @@ -119,7 +119,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>source_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_project.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_project.xml index cf11012a5d1dd42777fa843fc57781edf2d168dc..3cdd3c1c324efbee453cdf1c0ac7d9169be779a3 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_project.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_project.xml @@ -118,7 +118,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>source_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_section.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_section.xml index 4857657f2e6f7a81da1872fc5345afa588d04143..eff02b32266676de65f7a0b6d889c428a94d438f 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_section.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_section.xml @@ -68,7 +68,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>source_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_trade.xml b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_trade.xml index 7ae5bc5f1d206089f05337933705800d8831d8ed..c1daadff19c4544f76484a4598c2b3a54aae6c24 100644 --- a/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_trade.xml +++ b/product/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/source_trade.xml @@ -72,7 +72,9 @@ <item> <key> <string>category_type</string> </key> <value> - <tuple/> + <tuple> + <string>source_arrow</string> + </tuple> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/BaseCategory_view/my_category_type_list.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/BaseCategory_view/my_category_type_list.xml index 558c4c43c49adb8cfbc2cd7e46910c1e6de08c35..76a47ad703a7aef4db660e9c0819f7303dc4ffa1 100644 --- a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/BaseCategory_view/my_category_type_list.xml +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/BaseCategory_view/my_category_type_list.xml @@ -10,9 +10,9 @@ <key> <string>delegated_list</string> </key> <value> <list> - <string>title</string> <string>items</string> <string>size</string> + <string>title</string> </list> </value> </item> @@ -113,6 +113,14 @@ <string>sub_variation</string> <string>sub_variation</string> </tuple> + <tuple> + <string>Source Arrow</string> + <string>source_arrow</string> + </tuple> + <tuple> + <string>Destination Arrow</string> + <string>destination_arrow</string> + </tuple> </list> </value> </item>