Skip to content

Commit 58be587

Browse files
Merge pull request #64 from tosccolors/16.0-132-account_edi_simple_pdf
[ADD] #132 integrate account_edi_simple_pdf
2 parents 0c507dd + 57300c5 commit 58be587

File tree

4 files changed

+12
-2
lines changed

4 files changed

+12
-2
lines changed

ps_account/__manifest__.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,7 @@
1616
"ps_timesheet_invoicing",
1717
"report_qweb_pdf_watermark",
1818
"ps_calendar",
19-
# TODO: probably replace with yet-to-be-migrated account_edi_simple_pdf
20-
"account_edi",
19+
"account_edi_simple_pdf",
2120
"account_move_tier_validation",
2221
"account_invoice_merge",
2322
],

ps_account/models/account_move.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,3 +173,11 @@ def _get_name_invoice_report(self):
173173
if not self.company_id.use_standard_layout and ps_invoice:
174174
return "ps_account.report_invoice_document_ps_account"
175175
return super()._get_name_invoice_report()
176+
177+
def _simple_pdf_create_invoice_from_attachment(self, attachment):
178+
"""Fill supplier_invoice_number from ref"""
179+
self = self.with_context(default_supplier_invoice_number="dummy")
180+
result = super()._simple_pdf_create_invoice_from_attachment(attachment)
181+
result.supplier_invoice_number = result.ref
182+
result.ref = False
183+
return result

repos.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ edi:
4545
oca: https://github.com/OCA/edi
4646
merges:
4747
- oca 16.0
48+
- oca refs/pull/1091/head
4849
hr:
4950
remotes:
5051
oca: https://github.com/OCA/hr

requirements.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
astor
2+
dateparser
23
phonenumbers
34
pypdf<5.0
5+
regex

0 commit comments

Comments
 (0)