Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Tricky Asset/Product/Invoice question
#1
Hello,
Maybe someone can help me out with this one: I have an asset associated with a product and a invoice(that product's invoice to be more precisely). Since the price of the product on the invoice can be different from the price from the product module is there a way to setup a filter in assets list view(assets module) so that I can see on a column the unit price that is on the invoice NOT the unit price of the product as declared in products module?
Thank you.
Reply
#2
Two ideas come to mind:

1.- create a custom field of type currency, add some code to go to the invoice and fetch the value you need and save it in the field

2.- create a custom field of type relation pointing to the Inventory Details module. That will permit you to select the details of the exact line the product is on. That record has the prices and you will be able to select it on the list view. In this option, you could also add some code to filter the InventoryDetails and show only those related to the invoice, maybe even the product...
Joe
TSolucio
Reply
#3
(06-11-2018, 03:25 PM)joebordes Wrote: Two ideas come to mind:

1.- create a custom field of type currency, add some code to go to the invoice and fetch the value you need and save it in the field

2.- create a custom field of type relation pointing to the Inventory Details module. That will permit you to select the details of the exact line the product is on. That record has the prices and you will be able to select it on the list view. In this option, you could also add some code to filter the InventoryDetails and show only those related to the invoice, maybe even the product...

Thank you again Joe!
The inventory details option crossed my mind but selecting by hand the exact detail is kinda error-prone. Seems like properly solving the issue involves doing some sort of coding. Can you please point me to some resources(documentation or examples) on how to do those kind of 'interventions'?
Reply
#4
Option 1 is an "after-save" event: http://corebos.org/documentation/doku.ph...ebos_hooks

Option 2 is popup filter code: http://corebos.org/documentation/doku.ph...onal_popup
Joe
TSolucio
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)