Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Xiaowu Zhang
erp5
Commits
b22aceb8
Commit
b22aceb8
authored
Nov 14, 2012
by
Rafael Monnerat
👻
Committed by
Xiaowu Zhang
Feb 14, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Optimize search by using portal type
parent
6e088d2f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
3 deletions
+5
-3
bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce_widget_library/SaleOrder_getResourceUrl.xml
...erp5_commerce_widget_library/SaleOrder_getResourceUrl.xml
+4
-2
bt5/erp5_commerce/bt/revision
bt5/erp5_commerce/bt/revision
+1
-1
No files found.
bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce_widget_library/SaleOrder_getResourceUrl.xml
View file @
b22aceb8
...
...
@@ -61,10 +61,12 @@ web_site = context.getWebSiteValue()\n
resource = context.getResourceValue()\n
web_site_product_line = web_site.getLayoutProperty(\'ecommerce_base_product_line\')\n
portal_categories = context.getPortalObject().portal_categories\n
\n
base_product_line_object = portal_categories.restrictedTraverse(web_site_product_line)\n
\n
if resource in portal_categories.getRelatedValueList(base_product_line_object):\n
return \'%s/%s\' % (context.getResourceValue().getRelativeUrl(), \'Resource_viewAsShop\') \n
if resource in portal_categories.getRelatedValueList(base_product_line_object, \n
portal_type=resource.getPortalType()):\n
return \'%s/%s\' % (resource.getRelativeUrl(), \'Resource_viewAsShop\')\n
return None\n
</string>
</value>
</item>
...
...
bt5/erp5_commerce/bt/revision
View file @
b22aceb8
301
\ No newline at end of file
302
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment