[jira] [Created] (OFBIZ-11212) Default option for ModelFormField.DateFindField doesn't work

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[jira] [Created] (OFBIZ-11212) Default option for ModelFormField.DateFindField doesn't work

Nicolas Malin (Jira)
Nicolas Malin created OFBIZ-11212:
-------------------------------------

             Summary: Default option for ModelFormField.DateFindField doesn't work
                 Key: OFBIZ-11212
                 URL: https://issues.apache.org/jira/browse/OFBIZ-11212
             Project: OFBiz
          Issue Type: Bug
          Components: framework
    Affects Versions: Trunk
            Reporter: Nicolas Malin


When you use a  date-find element on form, the defaut option are in code like to greater_than and less _than
{code:java}
        public DateFindField(int fieldSource, String type) {
            super(fieldSource, type);
            this.defaultOptionFrom = "greaterThanEqualTo";
            this.defaultOptionThru = "lessThanEqualTo";
        }
{code}
but on macro
{code}
<#macro renderDateFindField ...
      <option value="greaterThan"<#if defaultOptionFrom=="greaterThan"> selected="selected"</#if>>${opGreaterThan}</option><#rt/>
...
      <option value="opLessThan"<#if defaultOptionThru=="opLessThan"> selected="selected"</#if>>${opLessThan}</option><#rt/>
...
{code}

So the value java isn't correct why ftl values and default value never used.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)