[FIX]quality_integration_server: fixed problem in make link

bzr revid: hmo@tinyerp.com-20091208051546-3zx1zfe4327smng2
This commit is contained in:
Harry (Open ERP) 2009-12-08 10:45:46 +05:30
parent b8513df777
commit 9b783a6547
1 changed files with 13 additions and 14 deletions

View File

@ -208,8 +208,8 @@ def drop_db(uri, dbname):
def make_links(uri, uid, dbname, source, destination, module, user, pwd):
if module in ('base','quality_integration_server'):
return True
if not os.path.islink(destination + '/' + module):
if not os.path.isdir(destination + '/' + module):
if os.path.islink(destination + '/' + module):
os.unlink(destination + '/' + module)
for path in source:
if os.path.isdir(path + '/' + module):
os.symlink(path + '/' + module, destination + '/' + module)
@ -221,7 +221,6 @@ def make_links(uri, uid, dbname, source, destination, module, user, pwd):
dep_datas = execute(obj_conn, 'execute', dbname, uid, pwd, 'ir.module.module.dependency', 'read', data['dependencies_id'],['name'])
for dep_data in dep_datas:
make_links(uri, uid, dbname, source, destination, dep_data['name'], user, pwd)
return True
return False
def install_module(uri, dbname, modules, addons='', extra_addons='', user='admin', pwd='admin'):