Contributors mailing list archives
contributors@odoo-community.org
Browse archives
Encrypt personal data in French/European Medical legislations (GPDR++)
field extraction rule for funny date format
Re: field extraction rule for funny date format
byHi,
reading the source there probably isn't but I haven't tested it. Looking at it I see 2 ways going forward:
1) Extending the options for date formats with this specific one - may be a bit tricky
2) Adding an option for usage of dateparser library and possible mask
Regarding dateparser it's quite easy:
>>> dateparser.parse('02.April 2024', date_formats=['%d.%B %Y'])
datetime.datetime(2024, 4, 2, 0, 0)
I would even suggest reworking the date handling using the library...
Best regards
Radovan
On štvrtok 23. mája 2024 14:32:10 CEST Jan Suhr | Nitrokey wrote:
> Hi!
> The module account_invoice_import_simple_pdf allows to define field
> extraction rules. UPS sends invoices with date in format "02.April 2024"
> so the first separator is a dot and the second a space. Is it possible
> to define a field extraction rule for such format?
> Best regards
> Jan
>
> _______________________________________________
> Mailing-List: https://odoo-community.org/groups/contributors-15 [1]
> Post to: mailto:contributors@odoo-community.org
> Unsubscribe: https://odoo-community.org/groups?unsubscribe [2]
>
>
>
> [1] https://odoo-community.org/groups/contributors-15
> [2] https://odoo-community.org/groups?unsubscribe
Reference
-
field extraction rule for funny date format
byNitrokey GmbH, Jan Suhr-
Re: field extraction rule for funny date format
byData Dance s.r.o., Radovan Skolnik
-