ADD to config 'document_path' to set ftp root path

bzr revid: greg-apieum-20100224093210-mpitlp5ckckxjvm5
This commit is contained in:
greg-apieum
2010-02-24 10:32:10 +01:00
parent e7a22755e5
commit 0adc588146
2 changed files with 5 additions and 3 deletions
+2 -1
View File
@@ -36,12 +36,13 @@ import tools
from tools.translate import _
import nodes
DMS_ROOT_PATH = tools.config.get('document_path', os.path.join(tools.config['root_path'], 'filestore'))
class document_file(osv.osv):
_inherit = 'ir.attachment'
_rec_name = 'datas_fname'
def _get_filestore(self, cr):
return os.path.join(tools.config['root_path'], 'filestore', cr.dbname)
return os.path.join(DMS_ROOT_PATH, cr.dbname)
def _data_get(self, cr, uid, ids, name, arg, context):
fbrl = self.browse(cr, uid, ids, context=context)