Commit Graph
79 Commits
Author SHA1 Message Date
Christophe Simonis 3fc2577c01 [MERGE] forward port branch saas-12.2 up to be3c981423 2019-04-11 19:27:36 +02:00
Christophe Simonis 5313cea8e6 [FIX] snailmail: add missing model entry in test declaration
This allow enterprise tests to pass.
2019-04-10 15:38:09 +02:00
Odoo Translation Bot 1b932b339a [I18N] Update translation terms from Transifex 2019-03-24 06:23:04 +01:00
Martin Trigaux 04370bff18 [I18N] export saas-12.2 source terms
closes odoo/odoo#31985

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-03-20 14:59:50 +00:00
Christophe Simonis 5df4746c9a [MERGE] forward port branch saas-12.2 up to 230ad8c381
closes odoo/odoo#32088

Signed-off-by: Christophe Simonis <chs@odoo.com>
2019-03-25 11:13:41 +00:00
de9006f112 [REF] snailmail: adapt code after jQuery update
Part of task 1896658

Co-authored-by: Aaron Bohy <aab@odoo.com>
Co-authored-by: Christophe Matthieu <chm@odoo.com>
Co-authored-by: Mathieu Duckerts-Antoine <dam@odoo.com>
Co-authored-by: David Monjoie <dmo@odoo.com>
Co-authored-by: Martin Geubelle <mge@odoo.com>
Co-authored-by: svs-odoo <svs@odoo.com>
Co-authored-by: Vincent Schippefilt <vsc@odoo.com>
2019-03-06 20:07:17 +01:00
Christophe Simonis cf52a04979 [MERGE] forward port branch saas-12.1 up to d3b8422c9c
closes odoo/odoo#30614
2019-01-28 13:58:11 +00:00
Antoine Prieels (ANP) 8f486db52d [IMP] mail, snailmail, snailmail_account: improve error management
When a letter is sent through snailmail and encounter an error, it used
to create an activity to the user to notify him that there was an error
with its letter.

When a user had this activity, he didn't have any clues of what was the
error and how to manage it. So we decided to better handle snailmail
errors and give the possibility to the user to easily fix the source of
the snailmail errors.

First to give a better feedback on the letters in errors, we've made
features similar to ones existing for emails:
 - We add a mail message on the document that sent the letter, and put a
   small paper plane icon, which is red when an error occurs (like the
   envelope for email)
 - As letters can be sent in batch, we've also added an entry in the
   systray to easily manage the different documents having snailmail
   errors like for emails.

Then we identified, the most common errors encountered with the
snailmail letters and give proper way to let the user fix them:
 - Missing Required Field:
    - The address is not complete, some of the fields are empty.
    - We open a wizard allowing the user to modify the partner address
      and we try to resend all letters having this error on the modified
      partner.
    - We also try to avoid this error, by opening the wizard before
      sending the letter, but it only works for single documents, not
      for batch.
 - Trial/Credit Error:
    - The user has not enough credits to send letters anymore.
    - We open a wizard that give a redirection lnk to add credits on its
      iap account.
 - No Price Available:
    - The destination country is not supported by any of our providers,
      and we cannot do anything to send this letter.
 - Format Error:
    - The format of the pdf report send by the user is refused by our
      providers, because some visual stuffs are not respected, for
      example blank zone to print barcode or margins.
    - We show a wizard to the user letting him check a setting option
      that add a cover page in the envelope and the documents will be
      send with this extra page containing the address.
 - Unknown Error:
    - This is not one of the listed error above.
    - A wizard suggesting the user to contact support is displayed.

The cron that try to resend letters on error, has been addapted to only
try to send the error of type Trial/No Credit, because the account might
have been reloaded, and other errors, won't change if they have not been
fixed locally.

closes odoo/odoo#29685
2019-01-24 13:36:51 +00:00
Christophe Simonis a337b9ec92 [MERGE] forward port branch 12.0 up to f854e01a98 2019-01-18 14:26:33 +01:00
Martin Trigaux bfe1e20d6b [I18N] export saas-12.1 source terms
To reflect fixes at ec2263080a and cd4080839f

closes odoo/odoo#30253
2019-01-16 10:35:49 +00:00
Pierre Masereel 27cc1fb3af [FIX] snailmail: background layout footer
In the background layout footer, it happens that the content is over a
zone that must stay blank. That's why w've added a left-padding to the
footer.

OPW-1928366

closes odoo/odoo#30296
2019-01-16 15:17:14 +00:00
Christophe Simonis 8aa8548d8a [MERGE] forward port branch 12.0 up to 3e4138deaa
closes odoo/odoo#30045
2019-01-09 15:56:53 +00:00
Antoine Prieels 2299d2563b [FIX] snailmail: Remove class on recipient's address
Layouts were not accepted by Pingen due to the fact that the class that we added to the recipient's address was not present in stable versions.
The format was therefore not adapted to Pingen.
We then remove this class to fix layouts in stable versions.

closes odoo/odoo#29976
2019-01-07 09:25:51 +00:00
Odoo Translation Bot 652cecffde [I18N] Update translation terms from Transifex 2019-01-06 01:32:05 +01:00
Martin Trigaux 1e224d244c [I18N] export 12.0 source terms
Mostly following changes at 7f8631a913

closes odoo/odoo#30072
2019-01-15 15:15:34 +00:00
Antoine Prieels 62221bc3f9 [FIX] snailmail: Object of type bytes is not JSON serializable
Sending a letter resulted systematically in an error due to the insertion of the binary of the PDF in the JSON sent to IAP-services.

closes odoo/odoo#29880
2019-01-03 12:56:52 +00:00
Odoo Translation Bot 91382f691d [I18N] Update translation terms from Transifex 2018-12-30 01:30:16 +01:00
Antoine Prieels (ANP) c50f5da416 [FIX] snailmail: Avoid format errors when sending with Pingen
Pingen validates the format of documents before sending them. These are the elements that it checks and how when ensure that the constrains are validated:
    - The recipient's address should appear in a predefined area
	--> Move the address to this area and reduce the font-size if the address is too long
    - The destination country should be the last line of the address
	--> Sometimes, the Tax ID was in this zone, so we add a margin after the address
    - Above the Address Area, there should be a Postage Area that should be completely empty
	--> Make the background white to avoid having a background image in this area
	--> Crop the header if it takes too much space
    - There are margins of 5mm all around the document
	--> Crop the footer 5mm above the bottom of the page if it takes too much space
    - There is a square in the bottom left of the document that should be empty
	--> Add a margin on the left of the footer

closes odoo/odoo#29522
2018-12-26 10:11:05 +00:00
Christophe Simonis f351dd8cab [MERGE] forward port branch 12.0 up to 047e2b28de 2018-12-12 11:38:25 +01:00
Odoo Translation Bot 47aae6faba [I18N] Update translation terms from Transifex 2018-12-23 01:29:13 +01:00
Odoo Translation Bot ec4ee14c89 [I18N] Update translation terms from Transifex 2018-12-09 01:16:26 +01:00
Martin Trigaux fa98749154 [I18N] export 12.0 source terms
Update to reflect the recent code changes

closes odoo/odoo#29636
2018-12-19 08:50:10 +00:00
Odoo Translation Bot 1208ac6ce3 [I18N] Update translation terms from Transifex 2018-12-02 01:25:05 +01:00
Antoine Prieels (ANP) e81ef3a603 [FIX] snailmail: Do not resend letters in state 'error' in cron
closes odoo/odoo#29456
2018-12-12 09:36:36 +00:00
Christophe Simonis e1f9499d26 [MERGE] forward port branch 12.0 up to 053bb45706 2018-12-05 18:46:15 +01:00
Christophe Simonis d7c5bc02cc [MERGE] forward port branch saas-12.1 up to 8aa8548d8a 2019-01-09 19:59:27 +01:00
Pierre Rousseau c37a79925b [IMP] snailmail, snailmail_account: settings
closes odoo/odoo#29320
2019-01-07 08:13:21 +00:00
Christophe Simonis ce4cc24621 [MERGE] forward port branch 12.0 up to 82a1e1dcc3 2018-11-29 20:06:16 +01:00
Christophe Simonis 7a0243ec15 [MERGE] forward port branch 12.0 up to b3052b690f 2018-11-23 12:11:32 +01:00
Antoine Prieels (ANP) a08cb50e7e [I18N] snailmail,snailmail_account: Update translation files 2018-11-22 15:38:42 +00:00
Antoine Prieels (ANP) f68df47ddf [IMP] snailmail: Show the price in terms of stamps
- The price of sending a letter was displayed in the currency of the company, now we express the price in terms of stamps
- Show a different message in the modal depending on the validity of the address
2018-11-22 15:38:42 +00:00
Antoine Prieels (ANP) d5ca268438 [IMP] snailmail: Change order of settings and default values
Task #1892473
2018-11-22 15:38:42 +00:00
Antoine Prieels (ANP) 2dfa7cd597 [IMP] snailmail: Add form and tree views for snailmail.letter
Add new form and tree views for snailmail.letter available in Accounting > Configuration > Management > Snailmail Letters
Add a many2one field to snailmail.letter to link to a mail.activity in case of an error with snailmail

Task #1892473
2018-11-22 15:38:42 +00:00
Odoo Translation Bot b60f9bb739 [I18N] Update translation terms from Transifex 2018-11-18 01:28:38 +01:00
Odoo Translation Bot dcc077afc5 [I18N] Update translation terms from Transifex 2018-11-11 01:26:46 +01:00
Rémi Rahir 235811d468 [FIX] snailmail: avoid spam on user mailbox
the fix merged in cb8bd299fc
was only tackling half the problem. When you assign a user to an
activity, the said user will be notified by email. This also occur if
you change the assignee to the next activity even if you change it to
the same user.

This commit ensures that we only write on the user_id field when we
create the next activity and not during the update.
2018-11-05 09:32:33 +00:00
Rémi Rahir 9988ce3f3b [IMP] snailmail: add new error message to help the user 2018-11-05 09:31:52 +00:00
Odoo Translation Bot 790bd62f14 [I18N] Update translation terms from Transifex 2018-11-04 01:27:12 +01:00
Odoo Translation Bot 29dc21ae4b [I18N] Update translation terms from Transifex 2018-10-28 01:25:21 +02:00
Rémi Rahir 5032828d5a [FIX] snailmail: instable behaviour on print
Since commit b6a981405e we require a
certain key in the context to apply the custom snailmail report layout.
This was badly managed and would eventually confilt inside the modal
that links snailmail and the mail composer.

This fix stabilises the biehaviour by properly propagating the context
key.
2018-10-19 08:36:16 +00:00
Antoine Prieels (ANP) 218fbaf90b [IMP] snailmail: Change formatting of address in snailmail
The previos format displayed the fields 'street' and 'street2' on two different line, making the address too big for the address area allowed by Pingen.
2018-10-19 08:36:16 +00:00
Odoo Translation Bot de265ce63e [I18N] Update translation terms from Transifex 2018-10-21 01:25:56 +02:00
Odoo Translation Bot e774b2cb1c [I18N] Update translation terms from Transifex 2018-10-14 01:23:43 +02:00
Odoo Translation Bot 07f6b8ef57 [I18N] Update translation terms from Transifex 2018-11-25 01:26:32 +01:00
Antoine Prieels (ANP) a5b3246dcd [FIX] Convert the estimated price for snailmail server-side
Currency rates were not updated client-side so we moved to make the convertion happen server-side, where rates are updated daily

closes odoo/odoo#27688
2018-10-11 14:48:25 +00:00
Rémi Rahir cb8bd299fc [FIX] snailmail: avoid next activity spamming
closes odoo/odoo#27665
2018-10-11 11:11:42 +00:00
Odoo Translation Bot b6c8919444 [I18N] Update translation terms from Transifex 2018-10-07 02:27:57 +02:00
Martin Trigaux d77000aef3 [I18N] export saas-11.5 source terms
Reflect module moved to enterprise and remove fields after c9837ac5d
2018-10-02 13:15:40 +02:00
Odoo Translation Bot a01c1bf5bf [I18N] Update translation terms from Transifex 2018-09-30 02:25:45 +02:00
Rémi Rahir e12ac2b91b [IMP] snailmail(_account): smoothe the etimation of price
Up until now, when we wanted to post a single document, it's base64 blob
was uploaded to the snailmail server to estimate the cost of the
transaction.  We now use the 'batch' apporach that will estimate the
price based on 1 page per document.
2018-09-29 11:12:39 +02:00