Merge pull request #9 from Noviat/16.0

Syncing from upstream Noviat/account_ebics (16.0)
This commit is contained in:
braintec 2023-09-01 13:18:25 +02:00 committed by GitHub
commit 2e8c6cae36
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 7 deletions

View File

@ -3,7 +3,7 @@
{ {
"name": "EBICS banking protocol", "name": "EBICS banking protocol",
"version": "16.0.1.4.0", "version": "16.0.1.5.0",
"license": "LGPL-3", "license": "LGPL-3",
"author": "Noviat", "author": "Noviat",
"website": "https://www.noviat.com/", "website": "https://www.noviat.com/",

View File

@ -148,10 +148,6 @@ class EbicsConfig(models.Model):
help="Companies sharing this EBICS contract.", help="Companies sharing this EBICS contract.",
) )
@api.model
def _default_ebics_files(self):
return "/".join(["/home/odoo/ebics_files", self._cr.dbname])
@api.model @api.model
def _default_ebics_keys(self): def _default_ebics_keys(self):
return "/".join(["/etc/odoo/ebics_keys", self._cr.dbname]) return "/".join(["/etc/odoo/ebics_keys", self._cr.dbname])

View File

@ -403,7 +403,7 @@ class EbicsUserID(models.Model):
else: else:
lang = self.env.user.lang or self.env["res.lang"].search([])[0].code lang = self.env.user.lang or self.env["res.lang"].search([])[0].code
lang = lang[:2] lang = lang[:2]
tmp_dir = os.path.normpath(self.ebics_config_id.ebics_files + "/tmp") tmp_dir = os.path.normpath(self.ebics_config_id.ebics_host + "/tmp")
if not os.path.isdir(tmp_dir): if not os.path.isdir(tmp_dir):
os.makedirs(tmp_dir, mode=0o700) os.makedirs(tmp_dir, mode=0o700)
fn_date = fields.Date.today().isoformat() fn_date = fields.Date.today().isoformat()
@ -479,7 +479,7 @@ class EbicsUserID(models.Model):
raise UserError(error) from err raise UserError(error) from err
public_bank_keys = public_bank_keys.encode() public_bank_keys = public_bank_keys.encode()
tmp_dir = os.path.normpath(self.ebics_config_id.ebics_files + "/tmp") tmp_dir = os.path.normpath(self.ebics_config_id.ebics_host + "/tmp")
if not os.path.isdir(tmp_dir): if not os.path.isdir(tmp_dir):
os.makedirs(tmp_dir, mode=0o700) os.makedirs(tmp_dir, mode=0o700)
fn_date = fields.Date.today().isoformat() fn_date = fields.Date.today().isoformat()