equate column display

Questionsequate column display
Lynn Lollar asked 6 years ago

I have a status field in my database and it is a 1-no status, 2-invited and 3-accepted.
I want the column to be the meaning and not the number. How can I achieve this?


1 Answers
Amir answered 6 years ago

you should be able to do something like this:

$col["title"] = "status"; // caption of column
$col["name"] = "status"; // grid column name, same as db field or alias from sql
$col["viewable"] = true;
$col["hidden"] = false;
$col["editable"] = true;
$col["edittype"] = "select"; // render as select
$col["editoptions"] = array("value"=>'1:No;2:Invited;3:Accepted');
$cols[] = $col;

Good luck

Your Answer

17 + 14 =

Login with your Social Id:

OR, enter

Attach code here and paste link in question.
Attach screenshot here and paste link in question.

How useful was this discussion?

Click on a star to rate it!

Average rating / 5. Vote count:

We are sorry that this post was not useful for you!

Let us improve this post!