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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Thomas Gambier
erp5
Commits
e8bf1284
Commit
e8bf1284
authored
Jul 18, 2019
by
Yusei Tahara
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[erp5_core] Add getVariationCategoryValueListDict to InventoryListBrain.
To use variation is still too complex.
parent
44a716cb
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
1 deletion
+17
-1
product/ERP5/bootstrap/erp5_core/ExtensionTemplateItem/portal_components/extension.erp5.InventoryBrain.py
...teItem/portal_components/extension.erp5.InventoryBrain.py
+14
-0
product/ERP5/bootstrap/erp5_core/ExtensionTemplateItem/portal_components/extension.erp5.InventoryBrain.xml
...eItem/portal_components/extension.erp5.InventoryBrain.xml
+3
-1
No files found.
product/ERP5/bootstrap/erp5_core/ExtensionTemplateItem/portal_components/extension.erp5.InventoryBrain.py
View file @
e8bf1284
...
@@ -309,6 +309,20 @@ class InventoryListBrain(ComputedAttributeGetItemCompatibleMixin):
...
@@ -309,6 +309,20 @@ class InventoryListBrain(ComputedAttributeGetItemCompatibleMixin):
mapping
=
mapping
)
mapping
=
mapping
)
return
translateString
(
'Unknown'
)
return
translateString
(
'Unknown'
)
def
getVariationCategoryValueListDict
(
self
):
result
=
{}
if
not
self
.
variation_text
:
return
result
category_tool
=
self
.
portal_categories
for
category_path
in
self
.
variation_text
.
split
(
'
\
n
'
):
category_value
=
category_tool
.
getCategoryValue
(
category_path
)
base_category_id
=
category_tool
.
getBaseCategoryId
(
category_path
)
if
not
base_category_id
in
result
:
result
[
base_category_id
]
=
[]
result
[
base_category_id
].
append
(
category_value
)
return
result
class
TrackingListBrain
(
InventoryListBrain
):
class
TrackingListBrain
(
InventoryListBrain
):
"""
"""
List of aggregated movements
List of aggregated movements
...
...
product/ERP5/bootstrap/erp5_core/ExtensionTemplateItem/portal_components/extension.erp5.InventoryBrain.xml
View file @
e8bf1284
...
@@ -45,7 +45,9 @@
...
@@ -45,7 +45,9 @@
<item>
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<value>
<tuple/>
<tuple>
<string>
W: 17, 0: Unused getToolByName imported from Products.CMFCore.utils (unused-import)
</string>
</tuple>
</value>
</value>
</item>
</item>
<item>
<item>
...
...
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