daterange & css

Questionsdaterange & css
Massimo Gagliardi asked 8 years ago

It seems that using daterange conflicts with the use of css style
es: $col["editoptions"] = array("style"=>"color: gray;"); doesn't work if you set the daterange anywhere in the script
How can I do?
Thanks in advance
Massimo Gagliardi

5 Answers
Abu Ghufran answered 8 years ago

It looks to be a css priority case. Try using:
color: gray !important;

Refer http://stackoverflow.com/a/1637380/385377

Abu Ghufran answered 8 years ago

You just need to replace "Total" with "total" … as $col["name"] is "total" with small t.
!important is not required.

$f = array();
$f["column"] = "total";
$f["css"] = "'color': 'red'";
$f_conditions[] = $f;
$g->set_conditional_css($f_conditions);

Massimo answered 8 years ago

Hi Abu
I insert this code (indented) in your datarangepicker.php but is not working

$col = array();
$col["title"] = "Total";
$col["name"] = "total";
$col["width"] = "50";
$col["editable"] = true;
$cols[] = $col;

$col = array();
$col["title"] = "Closed";
$col["name"] = "closed";
$col["width"] = "50";
$col["editable"] = true;
$col["edittype"] = "checkbox"; // render as checkbox
$col["editoptions"] = array("value"=>"1:0"); // with these values "checked_value:unchecked_value"
$col["formatter"] = "checkbox";
$cols[] = $col;

$f = array();
$f["column"] = "Total";
$f["css"] = "'color': 'red !important'";
$f_conditions[] = $f;
$g->set_conditional_css($f_conditions);

$grid["rowNum"] = 10; // by default 20
$grid["sortname"] = 'id'; // by default sort grid by this field
$grid["sortorder"] = "desc"; // ASC or DESC
$grid["caption"] = "Invoice Data"; // caption of grid
$grid["autowidth"] = true; // expand grid to screen width
$grid["multiselect"] = false; // allow you to multi-select through checkboxes
$grid["export"] = array("format"=>"pdf", "filename"=>"my-file", "heading"=>"Invoice Details", "orientation"=>"landscape", "paper"=>"a4");

Thanks in advance

Massimo answered 8 years ago

Ok.
It was a my error.
Now all ok.
Tks

Abu Ghufran answered 8 years ago

Thanks for updating.

Your Answer

16 + 5 =

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 0 / 5. Vote count: 0

No votes so far! Be the first to rate it.

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

Let us improve this post!

Tell us how we can improve this post?