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
Labels
Merge Requests
138
Merge Requests
138
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
Jobs
Commits
Open sidebar
nexedi
erp5
Commits
d81abd3d
Commit
d81abd3d
authored
Apr 07, 2020
by
Arnaud Fontaine
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
newTemp*() deprecation (
1bce8563
,
04b49859
): Cosmetic: Fix docstring.
parent
7bea7bb2
Pipeline
#8770
failed with stage
in 0 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
2 deletions
+3
-2
product/ERP5Type/Tool/SessionTool.py
product/ERP5Type/Tool/SessionTool.py
+3
-2
No files found.
product/ERP5Type/Tool/SessionTool.py
View file @
d81abd3d
...
...
@@ -164,8 +164,9 @@ class SessionTool(BaseTool):
session_id = '1234567'
session = context.portal_sessions[session_id]
session['shopping_cart'] = newTempOrder(context, '987654321') # will work only for local RAM sessions
(you can also use 'session.edit(shopping_cart= newTempOrder(context, '987654321'))' )
# will work only for local RAM sessions
session['shopping_cart'] = context.newContent(portal_type='Order', temp_object=True, id='987654321')
(you can also use 'session.edit(shopping_cart=context.newContent(context.newContent(portal_type='Order', temp_object=True, id='987654321'))' )
(later in another script you can acquire shopping_cart):
...
...
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