Different Editor types on the same column
Different Editor types on the same column

Let's say we have a table with 3 rows that contains the following data :
col1 | col2 |
---|---|
A | select |
B | select |
C | select |
"select" is a drop-down that can be easily created like this :
"fields": [
{"name": "col1"},
{"name": "col2","type": "select","options": ["1","2","3"]}
]
My question is : How can i have a drop-down AND a textbox on the same column - so the table will look like this
col1 | col2 |
---|---|
A | select |
B | textbox |
C | select |
please see the pseudocode below :
"fields": [
{"name": "col1"},
{"name": "col2",
...
something like :
if col1 = 'A' or col1 = 'B' then "type": "select","options": ["1","2","3"]
else "type": "text"
...
]
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
Hi @cr1st1 ,
This here is doing what you want, I believe. The field
type
for "Office" is being changed depending on whether the second column is "Accountant".Hope that does the trick,
Cheers,
Colin
Thanks @colin ! That's exactly what i wanted