diff options
| author | Thibault Delavallée <tde@openerp.com> | 2012-09-03 11:18:18 +0200 |
|---|---|---|
| committer | Thibault Delavallée <tde@openerp.com> | 2012-09-03 11:18:18 +0200 |
| commit | 6fa349a4ebf63fc54d633beedd32d07f335f3d8e (patch) | |
| tree | 569e9dc3ffac29afa07e864ee62c52bfe1d1d7a3 /addons/document_webdav | |
| parent | a97ac7649f997edd0a67820edc82c26da58c10c1 (diff) | |
| parent | e3f1c26e6afcf7c3df9bd98166614778e27645ea (diff) | |
[MERGE] Merged with addons/trunk.
bzr revid: tde@openerp.com-20120903091818-0qnjl3e5tss54bbj
Diffstat (limited to 'addons/document_webdav')
| -rw-r--r-- | addons/document_webdav/nodes.py | 4 | ||||
| -rwxr-xr-x | addons/document_webdav/test_davclient.py | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/addons/document_webdav/nodes.py b/addons/document_webdav/nodes.py index d6ceca458cd..a8fedee4fe3 100644 --- a/addons/document_webdav/nodes.py +++ b/addons/document_webdav/nodes.py @@ -25,6 +25,8 @@ from tools.safe_eval import safe_eval as eval import time import urllib import uuid +from openerp import SUPERUSER_ID + try: from tools.dict_tools import dict_filter except ImportError: @@ -233,7 +235,7 @@ class node_acl_mixin(object): if props_to_delete: # explicitly delete, as admin, any of the ids we have identified. - propobj.unlink(cr, 1, props_to_delete) + propobj.unlink(cr, SUPERUSER_ID, props_to_delete) if lock_data.get('unlock_mode', False): return lock_found and True diff --git a/addons/document_webdav/test_davclient.py b/addons/document_webdav/test_davclient.py index f1f2e58c835..0f66363c553 100755 --- a/addons/document_webdav/test_davclient.py +++ b/addons/document_webdav/test_davclient.py @@ -42,6 +42,7 @@ from tools import config from xmlrpclib import Transport, ProtocolError import StringIO import base64 +from openerp import SUPERUSER_ID _logger = logging.getLogger(__name__) @@ -361,7 +362,7 @@ class DAVClient(object): to break if "base_crypt" is used. """ ruob = obj.pool.get('res.users') - res = ruob.read(cr, 1, [uid,], ['login', 'password']) + res = ruob.read(cr, SUPERUSER_ID, [uid,], ['login', 'password']) assert res, "uid %s not found" % uid self.user = res[0]['login'] self.passwd = res[0]['password'] |
