I have the following table "BillDatVATRates" that looks like this
- Code: Select all
+-------------------+-------------+------+-----+---------+----------------+
| Field | Type | Null | Key | Default | Extra |
+-------------------+-------------+------+-----+---------+----------------+
| BillDataVATRateID | int(11) | NO | PRI | NULL | auto_increment |
| BillDataVATRate | varchar(20) | NO | | NULL | |
| BillDataVATName | varchar(6) | NO | | NULL | |
+-------------------+-------------+------+-----+---------+----------------+
I have these statements in BillData/valuelists.ini
- Code: Select all
[LowBillDataVATRates]
__sql__= "SELECT BillDataVATRate FROM BillDataVATRates ORDER BY BillDataVATRate"
[HighBillDataVATRates]
__sql__= "SELECT BillDataVATRate FROM BillDataVATRates ORDER BY BillDataVATRate"
What I'm after is having a drop down menu say (for example) "17.5%" (BillDataVATName) but still use "0.175" (BillDataVATRate) in the calculation that I'm running. Currently, my drop downs say the same as the "BillDataVATRate". Is there a way I can a function to change what the dropdown says but still maintain the "real" number to be used for the calculations?
NB: The calculations use the field "BillDataVATRate".
Thanks
Paul