diff options
| author | eco-odoo <eco@odoo.com> | 2018-08-13 11:55:54 +0200 |
|---|---|---|
| committer | Yannick Tivisse <yti@odoo.com> | 2018-08-13 17:14:05 +0200 |
| commit | f28369fd26313148d23a8b0a48d3b0e6f84656d9 (patch) | |
| tree | 1d9c99581bf3590dd7e6bd87b95c8e1900b9446a /addons/payment | |
| parent | 9030781a518e4c3bbf3b567ecc0ac95a4a98d78d (diff) | |
[IMP] sale,account: Fix/improve miscellaneous points on the onboarding bars
Purpose
=======
Clean some stuff on the onboarding bars:
- Payment setting should be activated in sales settings if a payment acquirer is
activated from the sales bar, otherwise the customer can't pay with the acquirer
- No email is sent with sample documents -> sending to yourself using the chatter doesn't work...
- Select "sign online" by default
- Improve payment instructions
- Improve the default thank you message on payment acquirer accordingly (when no bank defined)
- Choose a custom payment method -> mark the step as done
- Improve buttons wording:
- Put a pointer cursor when hovering on done steps
- Fix typo : instructions -> Instructions
- Fix layout issue on tax screen
Diffstat (limited to 'addons/payment')
| -rw-r--r-- | addons/payment/views/payment_acquirer_onboarding_templates.xml | 6 | ||||
| -rw-r--r-- | addons/payment/wizards/payment_acquirer_onboarding_wizard.py | 10 |
2 files changed, 11 insertions, 5 deletions
diff --git a/addons/payment/views/payment_acquirer_onboarding_templates.xml b/addons/payment/views/payment_acquirer_onboarding_templates.xml index b200dac5f27..45b67e57329 100644 --- a/addons/payment/views/payment_acquirer_onboarding_templates.xml +++ b/addons/payment/views/payment_acquirer_onboarding_templates.xml @@ -5,7 +5,7 @@ <t t-call="base.onboarding_step"> <t t-set="title">Payment Method</t> <t t-set="description">Configure your payment methods.</t> - <t t-set="btn_text">Set Payments</t> + <t t-set="btn_text">Set payments</t> <t t-set="done_text">Payment method set!</t> <t t-set="method" t-value="'action_open_payment_onboarding_payment_acquirer'" /> <t t-set="model" t-value="'res.company'" /> @@ -61,9 +61,9 @@ </div> <div attrs="{'invisible': [('payment_method', '!=', 'other')]}"> - <a type="action" role="button" name="payment.action_payment_acquirer"> + <button type="object" name="action_onboarding_other_payment_acquirer"> Check here - </a> + </button> to choose another payment method. </div> <div attrs="{'invisible': [('payment_method', '!=', 'manual')]}"> diff --git a/addons/payment/wizards/payment_acquirer_onboarding_wizard.py b/addons/payment/wizards/payment_acquirer_onboarding_wizard.py index 80cb9e21799..e3ea6ffead7 100644 --- a/addons/payment/wizards/payment_acquirer_onboarding_wizard.py +++ b/addons/payment/wizards/payment_acquirer_onboarding_wizard.py @@ -25,11 +25,12 @@ class PaymentWizard(models.TransientModel): manual_name = fields.Char("Method", default=lambda self: self._get_default_payment_acquirer_onboarding_value('manual_name')) journal_name = fields.Char("Bank Name", default=lambda self: self._get_default_payment_acquirer_onboarding_value('journal_name')) acc_number = fields.Char("Account Number", default=lambda self: self._get_default_payment_acquirer_onboarding_value('acc_number')) - manual_post_msg = fields.Html("Payment instructions") + manual_post_msg = fields.Html("Payment Instructions") @api.onchange('journal_name', 'acc_number') def _set_manual_post_msg_value(self): - self.manual_post_msg = _('Please make a payment to %s %s') % (self.journal_name or _("Bank") , self.acc_number or _("Account")) + self.manual_post_msg = _('Please make a payment to <ul><li>Bank: %s</li><li>Account Number: %s</li><li>Account Holder: %s</li></ul>') %\ + (self.journal_name or _("Bank") , self.acc_number or _("Account"), self.env.user.company_id.name) _payment_acquirer_onboarding_cache = {} _data_fetched = False @@ -137,3 +138,8 @@ class PaymentWizard(models.TransientModel): def _set_payment_acquirer_onboarding_step_done(self): self.env.user.company_id.set_onboarding_step_done('payment_acquirer_onboarding_state') + + def action_onboarding_other_payment_acquirer(self): + self._set_payment_acquirer_onboarding_step_done() + action = self.env.ref('payment.action_payment_acquirer').read()[0] + return action |
