mirror of
https://github.com/brain-tec/account_ebics.git
synced 2025-01-23 06:41:44 +00:00
[MIG] account_ebics_batch: Migration to 18.0
This commit is contained in:
parent
c7d20b3bcd
commit
416114793d
@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
{
|
{
|
||||||
"name": "EBICS Files batch import",
|
"name": "EBICS Files batch import",
|
||||||
"version": "17.0.1.0.0",
|
"version": "18.0.1.0.0",
|
||||||
"license": "AGPL-3",
|
"license": "AGPL-3",
|
||||||
"author": "Noviat",
|
"author": "Noviat",
|
||||||
"website": "https://www.noviat.com",
|
"website": "https://www.noviat.com",
|
||||||
|
@ -9,9 +9,7 @@
|
|||||||
<field name="user_id" ref="base.user_root" />
|
<field name="user_id" ref="base.user_root" />
|
||||||
<field name="interval_number">1</field>
|
<field name="interval_number">1</field>
|
||||||
<field name="interval_type">days</field>
|
<field name="interval_type">days</field>
|
||||||
<field name="numbercall">-1</field>
|
|
||||||
<field name="active" eval="False" />
|
<field name="active" eval="False" />
|
||||||
<field name="doall" eval="False" />
|
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
</odoo>
|
</odoo>
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
from sys import exc_info
|
from sys import exc_info
|
||||||
from traceback import format_exception
|
from traceback import format_exception
|
||||||
|
|
||||||
from odoo import _, api, fields, models
|
from odoo import api, fields, models
|
||||||
from odoo.exceptions import UserError
|
from odoo.exceptions import UserError
|
||||||
|
|
||||||
|
|
||||||
@ -49,7 +49,9 @@ class EbicsBatchLog(models.Model):
|
|||||||
def unlink(self):
|
def unlink(self):
|
||||||
for log in self:
|
for log in self:
|
||||||
if log.state != "draft":
|
if log.state != "draft":
|
||||||
raise UserError(_("Only log objects in state 'draft' can be deleted !"))
|
raise UserError(
|
||||||
|
self.env._("Only log objects in state 'draft' can be deleted !")
|
||||||
|
)
|
||||||
return super().unlink()
|
return super().unlink()
|
||||||
|
|
||||||
def button_draft(self):
|
def button_draft(self):
|
||||||
@ -94,12 +96,13 @@ class EbicsBatchLog(models.Model):
|
|||||||
ebics_file_ids = []
|
ebics_file_ids = []
|
||||||
for config in configs:
|
for config in configs:
|
||||||
err_msg = (
|
err_msg = (
|
||||||
_("Error while processing EBICS connection '%s' :\n") % config.name
|
self.env._("Error while processing EBICS connection '%s' :\n")
|
||||||
|
% config.name
|
||||||
)
|
)
|
||||||
if config.state == "draft":
|
if config.state == "draft":
|
||||||
import_dict["errors"].append(
|
import_dict["errors"].append(
|
||||||
err_msg
|
err_msg
|
||||||
+ _(
|
+ self.env._(
|
||||||
"Please set state to 'Confirm' and "
|
"Please set state to 'Confirm' and "
|
||||||
"Reprocess this EBICS Import Log."
|
"Reprocess this EBICS Import Log."
|
||||||
)
|
)
|
||||||
@ -108,7 +111,7 @@ class EbicsBatchLog(models.Model):
|
|||||||
if not any(config.mapped("ebics_userid_ids.ebics_passphrase_store")):
|
if not any(config.mapped("ebics_userid_ids.ebics_passphrase_store")):
|
||||||
import_dict["errors"].append(
|
import_dict["errors"].append(
|
||||||
err_msg
|
err_msg
|
||||||
+ _(
|
+ self.env._(
|
||||||
"No EBICS UserID with stored passphrase found.\n"
|
"No EBICS UserID with stored passphrase found.\n"
|
||||||
"You should configure such a UserID for automated downloads."
|
"You should configure such a UserID for automated downloads."
|
||||||
)
|
)
|
||||||
|
@ -18,15 +18,15 @@
|
|||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
<record id="ebics_batch_log_view_tree" model="ir.ui.view">
|
<record id="ebics_batch_log_view_list" model="ir.ui.view">
|
||||||
<field name="name">ebics.batch.log.tree</field>
|
<field name="name">ebics.batch.log.list</field>
|
||||||
<field name="model">ebics.batch.log</field>
|
<field name="model">ebics.batch.log</field>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<tree create="false">
|
<list create="false">
|
||||||
<field name="create_date" />
|
<field name="create_date" />
|
||||||
<field name="file_count" />
|
<field name="file_count" />
|
||||||
<field name="state" />
|
<field name="state" />
|
||||||
</tree>
|
</list>
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
@ -78,16 +78,15 @@
|
|||||||
<group colspan="4" col="4">
|
<group colspan="4" col="4">
|
||||||
<field name="create_date" />
|
<field name="create_date" />
|
||||||
<field name="ebics_config_ids" widget="many2many_tags" />
|
<field name="ebics_config_ids" widget="many2many_tags" />
|
||||||
<field name="has_draft_files" invisible="1" />
|
|
||||||
</group>
|
</group>
|
||||||
<notebook colspan="4">
|
<notebook colspan="4">
|
||||||
<page string="Batch Import Logs">
|
<page string="Batch Import Logs">
|
||||||
<field name="log_ids" nolabel="1">
|
<field name="log_ids" nolabel="1">
|
||||||
<tree>
|
<list>
|
||||||
<field name="create_date" />
|
<field name="create_date" />
|
||||||
<field name="state" />
|
<field name="state" />
|
||||||
<field name="error_count" />
|
<field name="error_count" />
|
||||||
</tree>
|
</list>
|
||||||
<form string="Batch Import Log">
|
<form string="Batch Import Log">
|
||||||
<group colspan="4" col="6">
|
<group colspan="4" col="6">
|
||||||
<field name="create_date" />
|
<field name="create_date" />
|
||||||
@ -110,8 +109,8 @@
|
|||||||
<field name="name">EBICS Batch Import Logs</field>
|
<field name="name">EBICS Batch Import Logs</field>
|
||||||
<field name="type">ir.actions.act_window</field>
|
<field name="type">ir.actions.act_window</field>
|
||||||
<field name="res_model">ebics.batch.log</field>
|
<field name="res_model">ebics.batch.log</field>
|
||||||
<field name="view_mode">tree,form</field>
|
<field name="view_mode">list,form</field>
|
||||||
<field name="view_id" ref="ebics_batch_log_view_tree" />
|
<field name="view_id" ref="ebics_batch_log_view_list" />
|
||||||
<field name="search_view_id" ref="ebics_batch_log_view_search" />
|
<field name="search_view_id" ref="ebics_batch_log_view_search" />
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user