Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
1 Odpowiedz
7590 Widoki

Hi,

In the accounting section in invoicing under the customers if i generate a invoice the invoice number is being generated as INV/YEAR/SEQUENCE but i want the invoice number to be of other format let's say IN-SEQUENCE. I can acheive this via changing sequences in UI but can anyone  tell me how to achieve this via changing the code.

Thanks

Awatar
Odrzuć
Najlepsza odpowiedź

Sequence can be added in Code usually in XML, refer for any sample Odoo's standard

For Ex, Refer PurchaseOrder's Sequence: seq_purchase_order.

In case of Accounting, Sequence will usually be related to its associated Journal.
Any addition of Journal added by user, in-turn will create a sequence automatically, unless creation of journal is handled technically, then possible of handling the creation of Seq from source code itself.


Awatar
Odrzuć
Autor

Under the account.py file in the _create_sequence def, I have located the sequence and for the sample test i have modified it a bit but the changes doesn't get reflected in the invoice numbering format even when i restarted the server and upgraded the app. Do you have any idea as to why is this happening or like am i missing anything?

Powiązane posty Odpowiedzi Widoki Czynność
3
lut 25
2675
1
lis 24
2419
1
gru 23
2332
6
sty 24
15253
1
lip 16
3979