php-reports icon indicating copy to clipboard operation
php-reports copied to clipboard

Key Value options

Open ghost opened this issue 10 years ago • 2 comments

Hi @jdorn

In my database table, I have a few columns that have non-descript names (e.g "fname", "lname"). My report will ideally allow a user to choose which column to query against. I want them to have labels like "First Name" and "Last Name" but still be able to run my query against their actual column name. I was thinking I could do a select variable header and have my options by an array like [{"key":"fname","value":"First Name"}] but this didn't work (the dropdown appeared blank). Any ideas on how to make this work?

ghost avatar Sep 16 '14 01:09 ghost

options: [{display:"ok", value:"1"},{display:"anulowany", value:"3"}]

jbienko1 avatar Jun 17 '15 20:06 jbienko1

This example should be added to project documentation because project documentation is useless regarding this issue (options with key value pairs).

schtritoff avatar May 15 '16 02:05 schtritoff