Want to evaluate the date format value with current using options attribute
<field name="last_date" position="attributes">
<attribute name="options"> {
"bg_color": "red: last_date <= datetime.datetime.now().strftime('%Y-%m-%d 00:00:00')",
"fg_color": "black"
}</attribute>
</field>
Also I tired "& l e;" instead and both caused raised an error of none define entity
Any one knows how to solve it?
Use the variable current_date instead of using it with another date. you will get the result.
{ "bg_color": "red: last_date <=; current_date", "fg_color": "black" }
Thanks