[jira] Created: (OFBIZ-1622) Added support for "anonymous" url parameters

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

[jira] Created: (OFBIZ-1622) Added support for "anonymous" url parameters

Nicolas Malin (Jira)
Added support for "anonymous" url parameters
--------------------------------------------

                 Key: OFBIZ-1622
                 URL: https://issues.apache.org/jira/browse/OFBIZ-1622
             Project: OFBiz
          Issue Type: New Feature
          Components: framework
            Reporter: Jacopo Cappellato
            Priority: Minor
         Attachments: anon-param.patch

The attached patch will add support for "anonymous"/"positional" url parameters: the values of the parameters can be passed in a certain order without specifying the name of them.
For example:

instead of:
categoryId=PROMOTIONS&productId=WG-1111

you can set:
/~PROMOTIONS/~WG-1111

The framework will automatically assign the following names to the parameters:
pathInfo1 (= PROMOTIONS)
pathInfo2 (= WG-1111)

The goal is to provide a way to have cleaner URL

Please review the patch; if you think it is a good idea I will commit it.


--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (OFBIZ-1622) Added support for "anonymous" url parameters

Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-1622?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jacopo Cappellato updated OFBIZ-1622:
-------------------------------------

    Attachment: anon-param.patch

> Added support for "anonymous" url parameters
> --------------------------------------------
>
>                 Key: OFBIZ-1622
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1622
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Jacopo Cappellato
>            Priority: Minor
>         Attachments: anon-param.patch
>
>
> The attached patch will add support for "anonymous"/"positional" url parameters: the values of the parameters can be passed in a certain order without specifying the name of them.
> For example:
> instead of:
> categoryId=PROMOTIONS&productId=WG-1111
> you can set:
> /~PROMOTIONS/~WG-1111
> The framework will automatically assign the following names to the parameters:
> pathInfo1 (= PROMOTIONS)
> pathInfo2 (= WG-1111)
> The goal is to provide a way to have cleaner URL
> Please review the patch; if you think it is a good idea I will commit it.

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-1622) Added support for "anonymous" url parameters

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-1622?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12566457#action_12566457 ]

Jacques Le Roux commented on OFBIZ-1622:
----------------------------------------

I like the idea : +1

> Added support for "anonymous" url parameters
> --------------------------------------------
>
>                 Key: OFBIZ-1622
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1622
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Jacopo Cappellato
>            Priority: Minor
>         Attachments: anon-param.patch
>
>
> The attached patch will add support for "anonymous"/"positional" url parameters: the values of the parameters can be passed in a certain order without specifying the name of them.
> For example:
> instead of:
> categoryId=PROMOTIONS&productId=WG-1111
> you can set:
> /~PROMOTIONS/~WG-1111
> The framework will automatically assign the following names to the parameters:
> pathInfo1 (= PROMOTIONS)
> pathInfo2 (= WG-1111)
> The goal is to provide a way to have cleaner URL
> Please review the patch; if you think it is a good idea I will commit it.

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-1622) Added support for "anonymous" url parameters

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-1622?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12566704#action_12566704 ]

David E. Jones commented on OFBIZ-1622:
---------------------------------------

Yeah, this would be cool.

It might even be possible to do this without the "~" (tilde) in front of each, and just look at all of them after the request-uri, or the request-uri/view-uri if the one after the request matches a view name (if not then consider it a parameter).

> Added support for "anonymous" url parameters
> --------------------------------------------
>
>                 Key: OFBIZ-1622
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1622
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Jacopo Cappellato
>            Priority: Minor
>         Attachments: anon-param.patch
>
>
> The attached patch will add support for "anonymous"/"positional" url parameters: the values of the parameters can be passed in a certain order without specifying the name of them.
> For example:
> instead of:
> categoryId=PROMOTIONS&productId=WG-1111
> you can set:
> /~PROMOTIONS/~WG-1111
> The framework will automatically assign the following names to the parameters:
> pathInfo1 (= PROMOTIONS)
> pathInfo2 (= WG-1111)
> The goal is to provide a way to have cleaner URL
> Please review the patch; if you think it is a good idea I will commit it.

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-1622) Added support for "anonymous" url parameters

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-1622?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12566718#action_12566718 ]

Jacques Le Roux commented on OFBIZ-1622:
----------------------------------------

David's proposition even cooler :o)

> Added support for "anonymous" url parameters
> --------------------------------------------
>
>                 Key: OFBIZ-1622
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1622
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Jacopo Cappellato
>            Priority: Minor
>         Attachments: anon-param.patch
>
>
> The attached patch will add support for "anonymous"/"positional" url parameters: the values of the parameters can be passed in a certain order without specifying the name of them.
> For example:
> instead of:
> categoryId=PROMOTIONS&productId=WG-1111
> you can set:
> /~PROMOTIONS/~WG-1111
> The framework will automatically assign the following names to the parameters:
> pathInfo1 (= PROMOTIONS)
> pathInfo2 (= WG-1111)
> The goal is to provide a way to have cleaner URL
> Please review the patch; if you think it is a good idea I will commit it.

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-1622) Added support for "anonymous" url parameters

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-1622?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12567281#action_12567281 ]

Jacopo Cappellato commented on OFBIZ-1622:
------------------------------------------

David,

what you suggest is really very interesting.
The format of the uri will be:

request-uri/view-uri/parameterValue1/parameterValue2/parameterValue3...

where view-uri is optional.
This would help to get very clean url such as:

addToCart/showProductDetails/PROMOTIONS/WG-1111

or

showProductDetails/PROMOTIONS/WG-1111

In my free time I'll have a look at the code to see if it is easy to implement... I 've worked on this a lot of time ago and I don't remember.




> Added support for "anonymous" url parameters
> --------------------------------------------
>
>                 Key: OFBIZ-1622
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1622
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Jacopo Cappellato
>            Priority: Minor
>         Attachments: anon-param.patch
>
>
> The attached patch will add support for "anonymous"/"positional" url parameters: the values of the parameters can be passed in a certain order without specifying the name of them.
> For example:
> instead of:
> categoryId=PROMOTIONS&productId=WG-1111
> you can set:
> /~PROMOTIONS/~WG-1111
> The framework will automatically assign the following names to the parameters:
> pathInfo1 (= PROMOTIONS)
> pathInfo2 (= WG-1111)
> The goal is to provide a way to have cleaner URL
> Please review the patch; if you think it is a good idea I will commit it.

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.