Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
OpenERP Connect
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
XCG
OpenERP Connect
Commits
aa63f2e7
Commit
aa63f2e7
authored
11 years ago
by
Florent Aide
Browse files
Options
Downloads
Patches
Plain Diff
Now support correctly write operations
parent
8c98ccfa
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
oec/sender.py
+30
-8
30 additions, 8 deletions
oec/sender.py
with
30 additions
and
8 deletions
oec/sender.py
+
30
−
8
View file @
aa63f2e7
...
...
@@ -28,14 +28,36 @@
def
send
(
self
):
for
item
in
self
.
builder
.
build
():
try
:
yield
(
True
,
self
.
sock
.
execute
(
self
.
oedb
,
self
.
uid
,
self
.
oepass
,
self
.
builder
.
itemtype
,
self
.
mode
,
item
))
if
self
.
mode
==
"
create
"
:
yield
(
True
,
self
.
sock
.
execute
(
self
.
oedb
,
self
.
uid
,
self
.
oepass
,
self
.
builder
.
itemtype
,
self
.
mode
,
item
))
elif
self
.
mode
==
"
write
"
:
# if you ask for a write operation you should give us
# a proper db id for your item
item_id
=
item
.
pop
(
'
id
'
)
yield
(
True
,
self
.
sock
.
execute
(
self
.
oedb
,
self
.
uid
,
self
.
oepass
,
self
.
builder
.
itemtype
,
self
.
mode
,
[
item_id
],
item
))
else
:
raise
NotImplementedError
(
'
The method %s is not yet supported.
'
%
self
.
mode
)
except
xmlrpclib
.
Fault
,
e
:
# ATM OpenERP only returns something in the faultCode
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment