This question has been flagged


I'm creating a new view for a personalized POS module for my restaurant. It's a specific view for kitchen, already filtered to show just kitchen's related items of a POS order.

Now I would like to show a particular series of product with the name starting with "#" as a unique in a column populated by a new field side by side with the "standard" products. In fact I'm speaking of a set of instructions coded as products to be available on POS and since I was unable to edit the js and css of the pos for suit my needs I decided to create kitchen instructions as a product (service). In my POS there are 3 categories that are not products but instructions (ADD, SUBTRACT, ADDITIONAL NOTE).

What I would like to archive is a view like:

Product 
Note
Quantity
[1007] Pom. Secchi
# + Búfala # - Mussarela
1
[2002] Nutella banana
# + Mussarela
1
[3002] Fanta Uva 350ml

1

The original view is: 

Product
Category
Quantity
[1007] Pom. Secchi
Piadine
1
# + Búfala
Extra-Rid
1
# - Mussarela
Extra-Rid
1
[2002] Nutella banana
Piadine Dolci
1
# + Mussarela
Extra-Rid
1
[3002] Fanta Uva 350ml
Bebida
1

I know I can group field values in a unique, new field with fields.function(_get_concatenate_values) but my problem is how to filter the products before write them respecting the id sequence for the new view. Other than this I need to select just the "#" product between two internal code starting with "[code]" and this is the hard thing to do.

Someone could gently drive me to the right direction?


EDIT:

I can see added pictures on my post during creation/edit but not when I save the post. Is because I don't have enough Karma? 

Avatar
Discard
Author Best Answer

Solved creating a new module and using directly python and psycopg2. Was complicated but works!

Avatar
Discard

Why don't you open source this somewhere on Github for others to learn from Federico? :D I think quite some people would like that.

Author

Nah Yenthe, it's not a "quality job" for now. Is just a bunch of .py and sql query mixed with xml. And all need to be optimized. There are so many things still not working as I would. Beside, the module is incomplete and needs some manual works to have it done for example I was unable to build the server actions I need on my templates.xml. Lack of documentation, again. But I'll think on it when I'll have it completely working on V9. Probably I'll need some help from the outside and Git could be a good solution for a alpha/beta test.