You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by "youssef khaye (Created) (JIRA)" <ji...@apache.org> on 2011/10/16 21:12:11 UTC

[jira] [Created] (OFBIZ-4487) enable definition for position on sortfield

enable definition for position on sortfield
-------------------------------------------

                 Key: OFBIZ-4487
                 URL: https://issues.apache.org/jira/browse/OFBIZ-4487
             Project: OFBiz
          Issue Type: Improvement
          Components: framework
    Affects Versions: SVN trunk
            Reporter: youssef khaye


in some cases, form extending another one, it may be convenient to be able to define field position on the sort field element.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Closed] (OFBIZ-4487) enable definition for position on sortfield

Posted by "Erwan de FERRIERES (Closed) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-4487?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Erwan de FERRIERES closed OFBIZ-4487.
-------------------------------------

       Resolution: Fixed
    Fix Version/s: SVN trunk
    
> enable definition for position on sortfield
> -------------------------------------------
>
>                 Key: OFBIZ-4487
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4487
>             Project: OFBiz
>          Issue Type: Improvement
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: youssef khaye
>            Assignee: Erwan de FERRIERES
>             Fix For: SVN trunk
>
>         Attachments: OFBIZ-4487-1.png, OFBIZ-4487-2.png, sortFieldPosition-exampleForms.patch, sortFieldPosition.patch, sortFieldPosition2.patch
>
>
> in some cases, form extending another one, it may be convenient to be able to define field position on the sort field element.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (OFBIZ-4487) enable definition for position on sortfield

Posted by "Erwan de FERRIERES (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-4487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13136301#comment-13136301 ] 

Erwan de FERRIERES commented on OFBIZ-4487:
-------------------------------------------

Youssef,
I'm having a strange behaviour with your patch using 
{code}
            <field-group>
                <sort-field name="statusId"  position="2"/>
                <sort-field name="exampleTypeId"/>
            </field-group>
{code}

or using 

{code}
            <field-group>
                <sort-field name="exampleTypeId"/>
                <sort-field name="statusId"  position="2"/>
            </field-group>
{code}

this is not the same output generated. Could you review your code ?

Thanks
                
> enable definition for position on sortfield
> -------------------------------------------
>
>                 Key: OFBIZ-4487
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4487
>             Project: OFBiz
>          Issue Type: Improvement
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: youssef khaye
>         Attachments: sortFieldPosition-exampleForms.patch, sortFieldPosition.patch
>
>
> in some cases, form extending another one, it may be convenient to be able to define field position on the sort field element.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (OFBIZ-4487) enable definition for position on sortfield

Posted by "youssef khaye (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-4487?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

youssef khaye updated OFBIZ-4487:
---------------------------------

    Attachment: sortFieldPosition.patch

this patch makes necessary modifications to enable defining postion for srot-field.
                
> enable definition for position on sortfield
> -------------------------------------------
>
>                 Key: OFBIZ-4487
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4487
>             Project: OFBiz
>          Issue Type: Improvement
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: youssef khaye
>         Attachments: sortFieldPosition.patch
>
>
> in some cases, form extending another one, it may be convenient to be able to define field position on the sort field element.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (OFBIZ-4487) enable definition for position on sortfield

Posted by "Erwan de FERRIERES (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-4487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13172575#comment-13172575 ] 

Erwan de FERRIERES commented on OFBIZ-4487:
-------------------------------------------

Done at r1220927
Thanks Youssef and Olivier
                
> enable definition for position on sortfield
> -------------------------------------------
>
>                 Key: OFBIZ-4487
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4487
>             Project: OFBiz
>          Issue Type: Improvement
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: youssef khaye
>            Assignee: Erwan de FERRIERES
>             Fix For: SVN trunk
>
>         Attachments: OFBIZ-4487-1.png, OFBIZ-4487-2.png, sortFieldPosition-exampleForms.patch, sortFieldPosition.patch, sortFieldPosition2.patch
>
>
> in some cases, form extending another one, it may be convenient to be able to define field position on the sort field element.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Issue Comment Edited] (OFBIZ-4487) enable definition for position on sortfield

Posted by "Olivier Heintz (Issue Comment Edited) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-4487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13145825#comment-13145825 ] 

Olivier Heintz edited comment on OFBIZ-4487 at 12/13/11 5:33 PM:
-----------------------------------------------------------------

Erwan,

It's correct that it's not the same ouput.
in case one there is no field with position="1" so it's put in first column

It's exactly the same without the patch without extend
if you test with
    <form name="FindExamples" type="single" target="FindExample" default-entity-name="Example">
        <field name="noConditionFind"><hidden value="Y"/><!-- if this isn't there then with all fields empty no query will be done --></field>
        <field name="exampleId" title="${uiLabelMap.ExampleExampleId}"><text-find/></field>
        <field name="exampleName" title="${uiLabelMap.CommonName}"><text-find/></field>
        <field name="exampleTypeId" title="${uiLabelMap.CommonType}">
            <drop-down allow-empty="true" current-description="">
                <entity-options description="${description}" key-field-name="exampleTypeId" entity-name="ExampleType">
                    <entity-order-by field-name="description"/>
                </entity-options>
            </drop-down>
        </field>
        <field name="statusId" title="${uiLabelMap.CommonStatus}" position="2">
            <drop-down allow-empty="true" current-description="">
                <entity-options description="${description}" key-field-name="statusId" entity-name="ExampleStatusItem"/>
            </drop-down>
        </field>
        <field name="searchButton" title="${uiLabelMap.CommonFind}" widget-style="smallSubmit"><submit button-type="button" image-location="/images/icons/magnifier.png"/></field>
        <sort-order>
            <field-group>
                <sort-field name="exampleId"/>
                <sort-field name="exampleName"/>
            </field-group>
            <field-group>
                <sort-field name="exampleTypeId"/>
                <sort-field name="statusId"/>
            </field-group>
            <sort-field name="searchButton"/>
        </sort-order>
    </form>

you will see.

But there is still a other problem with the proposed patch
the defaut position in sort field (if there is nothing, it's 1) override the position which is given in field.
It's not correct, it should override only if value is given for position in sortfield.

I have corrected this problem and created a new patch sortFieldPosition2.patch.
so, now, with this new patch 
all seem correct for me.

                
      was (Author: holivier):
    Erwan,

It's correct that it's not the same ouput.
in case one there is no field with position="1" so it's put in first column

It's exactly the same without the patch without extend
if you test with
    <form name="FindExamples" type="single" target="FindExample" default-entity-name="Example">
        <field name="noConditionFind"><hidden value="Y"/><!-- if this isn't there then with all fields empty no query will be done --></field>
        <field name="exampleId" title="${uiLabelMap.ExampleExampleId}"><text-find/></field>
        <field name="exampleName" title="${uiLabelMap.CommonName}"><text-find/></field>
        <field name="exampleTypeId" title="${uiLabelMap.CommonType}">
            <drop-down allow-empty="true" current-description="">
                <entity-options description="${description}" key-field-name="exampleTypeId" entity-name="ExampleType">
                    <entity-order-by field-name="description"/>
                </entity-options>
            </drop-down>
        </field>
        <field name="statusId" title="${uiLabelMap.CommonStatus}" position="2">
            <drop-down allow-empty="true" current-description="">
                <entity-options description="${description}" key-field-name="statusId" entity-name="ExampleStatusItem"/>
            </drop-down>
        </field>
        <field name="searchButton" title="${uiLabelMap.CommonFind}" widget-style="smallSubmit"><submit button-type="button" image-location="/images/icons/magnifier.png"/></field>
        <sort-order>
            <field-group>
                <sort-field name="exampleId"/>
                <sort-field name="exampleName"/>
            </field-group>
            <field-group>
                <sort-field name="exampleTypeId"/>
                <sort-field name="statusId"/>
            </field-group>
            <sort-field name="searchButton"/>
        </sort-order>
    </form>

you will see.

But there is still a other problem with the proposed patch
the defaut position in sort field (if there is nothing, it's 1) override the position which is given in field.
It's not correct, it should override only if value is given for position in sortfield.

so, with the new patch all seem correct for me.
                  
> enable definition for position on sortfield
> -------------------------------------------
>
>                 Key: OFBIZ-4487
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4487
>             Project: OFBiz
>          Issue Type: Improvement
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: youssef khaye
>         Attachments: OFBIZ-4487-1.png, OFBIZ-4487-2.png, sortFieldPosition-exampleForms.patch, sortFieldPosition.patch, sortFieldPosition2.patch
>
>
> in some cases, form extending another one, it may be convenient to be able to define field position on the sort field element.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (OFBIZ-4487) enable definition for position on sortfield

Posted by "Erwan de FERRIERES (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-4487?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Erwan de FERRIERES updated OFBIZ-4487:
--------------------------------------

    Assignee: Erwan de FERRIERES
    
> enable definition for position on sortfield
> -------------------------------------------
>
>                 Key: OFBIZ-4487
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4487
>             Project: OFBiz
>          Issue Type: Improvement
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: youssef khaye
>            Assignee: Erwan de FERRIERES
>         Attachments: OFBIZ-4487-1.png, OFBIZ-4487-2.png, sortFieldPosition-exampleForms.patch, sortFieldPosition.patch, sortFieldPosition2.patch
>
>
> in some cases, form extending another one, it may be convenient to be able to define field position on the sort field element.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (OFBIZ-4487) enable definition for position on sortfield

Posted by "Olivier Heintz (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-4487?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Olivier Heintz updated OFBIZ-4487:
----------------------------------

    Attachment: sortFieldPosition2.patch

Erwan,

It's correct that it's not the same ouput.
in case one there is no field with position="1" so it's put in first column

It's exactly the same without the patch without extend
if you test with
    <form name="FindExamples" type="single" target="FindExample" default-entity-name="Example">
        <field name="noConditionFind"><hidden value="Y"/><!-- if this isn't there then with all fields empty no query will be done --></field>
        <field name="exampleId" title="${uiLabelMap.ExampleExampleId}"><text-find/></field>
        <field name="exampleName" title="${uiLabelMap.CommonName}"><text-find/></field>
        <field name="exampleTypeId" title="${uiLabelMap.CommonType}">
            <drop-down allow-empty="true" current-description="">
                <entity-options description="${description}" key-field-name="exampleTypeId" entity-name="ExampleType">
                    <entity-order-by field-name="description"/>
                </entity-options>
            </drop-down>
        </field>
        <field name="statusId" title="${uiLabelMap.CommonStatus}" position="2">
            <drop-down allow-empty="true" current-description="">
                <entity-options description="${description}" key-field-name="statusId" entity-name="ExampleStatusItem"/>
            </drop-down>
        </field>
        <field name="searchButton" title="${uiLabelMap.CommonFind}" widget-style="smallSubmit"><submit button-type="button" image-location="/images/icons/magnifier.png"/></field>
        <sort-order>
            <field-group>
                <sort-field name="exampleId"/>
                <sort-field name="exampleName"/>
            </field-group>
            <field-group>
                <sort-field name="exampleTypeId"/>
                <sort-field name="statusId"/>
            </field-group>
            <sort-field name="searchButton"/>
        </sort-order>
    </form>

you will see.

But there is still a other problem with the proposed patch
the defaut position in sort field (if there is nothing, it's 1) override the position which is given in field.
It's not correct, it should override only if value is given for position in sortfield.

so, with the new patch all seem correct for me.
                
> enable definition for position on sortfield
> -------------------------------------------
>
>                 Key: OFBIZ-4487
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4487
>             Project: OFBiz
>          Issue Type: Improvement
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: youssef khaye
>         Attachments: OFBIZ-4487-1.png, OFBIZ-4487-2.png, sortFieldPosition-exampleForms.patch, sortFieldPosition.patch, sortFieldPosition2.patch
>
>
> in some cases, form extending another one, it may be convenient to be able to define field position on the sort field element.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (OFBIZ-4487) enable definition for position on sortfield

Posted by "Erwan de FERRIERES (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-4487?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Erwan de FERRIERES updated OFBIZ-4487:
--------------------------------------

    Attachment: OFBIZ-4487-2.png
                OFBIZ-4487-1.png
    
> enable definition for position on sortfield
> -------------------------------------------
>
>                 Key: OFBIZ-4487
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4487
>             Project: OFBiz
>          Issue Type: Improvement
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: youssef khaye
>         Attachments: OFBIZ-4487-1.png, OFBIZ-4487-2.png, sortFieldPosition-exampleForms.patch, sortFieldPosition.patch
>
>
> in some cases, form extending another one, it may be convenient to be able to define field position on the sort field element.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (OFBIZ-4487) enable definition for position on sortfield

Posted by "youssef khaye (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-4487?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

youssef khaye updated OFBIZ-4487:
---------------------------------

    Attachment: sortFieldPosition-exampleForms.patch

this patch illustrates this functionality, i think it may be interresting to includ it in ofbiz.
                
> enable definition for position on sortfield
> -------------------------------------------
>
>                 Key: OFBIZ-4487
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4487
>             Project: OFBiz
>          Issue Type: Improvement
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: youssef khaye
>         Attachments: sortFieldPosition-exampleForms.patch, sortFieldPosition.patch
>
>
> in some cases, form extending another one, it may be convenient to be able to define field position on the sort field element.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira