I'd like to know what is the location of JS file where define the implementation of Print/Reprint Receipt from POS Screen. I already changed the template of the Receipt. I want to make a RPC request to load some fields and add them to a Receipt but i can't find the appropriate function to override this functionality.
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Contabilidad
- Inventario
- PoS
- Project
- MRP
Se marcó esta pregunta
Hey there. So, diving into the POS Odoo 14 code can be a bit of a maze, but I feel your thoughts. When it comes to the JS file for Print/Reprint Receipt, you're probably looking for it in the point_of_sale module.
Here's a breadcrumb trail: Check out the 'static/src/js' folder, specifically the 'screens' or 'widgets' subfolders. You might find what you're after in there. Look for something related to receipt printing.
For your RPC request, you might want to peek into 'models.js'. Sometimes the magic happens there. If you're adding fields, maybe extending the 'Receipt' model could be the way to go.
Good luck, and may the code be ever in your favor :)
Now, about my experience – this kind of thing always requires some trial and error. Don't forget to back up before you go on a code adventure. Messing with core files can be tricky, but hey, that's how we learn, right? In my work, I'm often helped by resources like this one: https://andersenlab.com/services/custom-software-development
in OrderReceipt component willStart function
here is the docs:
https://github.com/odoo/owl/blob/master/doc/reference/component.md#willstart
¿Le interesa esta conversación? ¡Participe en ella!
Cree una cuenta para poder utilizar funciones exclusivas e interactuar con la comunidad.
InscribirsePublicaciones relacionadas | Respuestas | Vistas | Actividad | |
---|---|---|---|---|
|
1
nov 24
|
2103 | ||
|
0
jun 24
|
987 | ||
|
1
dic 21
|
5989 | ||
|
0
sept 20
|
3222 | ||
|
1
abr 19
|
10961 |