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

ASF subversion and git services commented on OFBIZ-13154:
---------------------------------------------------------

Commit f7bfe0c6ad7aac9e1273b7bba35194f1b179360a in ofbiz-site's branch 
refs/heads/master from Jacques Le Roux
[ https://gitbox.apache.org/repos/asf?p=ofbiz-site.git;h=f7bfe0c ]

Improved: updates DTDs for OFBIZ-13154


> Add uri shortener function
> --------------------------
>
>                 Key: OFBIZ-13154
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-13154
>             Project: OFBiz
>          Issue Type: Improvement
>          Components: framework
>            Reporter: Nicolas Malin
>            Assignee: Nicolas Malin
>            Priority: Major
>              Labels: freemarker, link, shortener
>
> This improvement offer the possibility to use a shortener url to call ofbiz 
> when it render a url.
> The origin requirement is to send by email a url to contact OFBiz without any 
> information on technical or functionnal context like JWToken, userLogin, 
> orderId, partyId and so on. OFBiz forward only a short reference that match 
> the actual uri wanted.
> Example : 
>   * ecommerce/myaccount/order/ORD10034 -> s/tiozerzaze
>   * 
> ecommerce/myaccount?token=JWT[more..than..100]axdr&userLoginId=m...@ofbiz.org 
> -> s/epsserlner
>  
> When a request arrive in OFBiz with the pattern
> {noformat}
>  s/{shortener}
> {noformat}
> , the request handler forward to matched uri.
> To generate a shortener on freemarker template just use it like it :
> {code}
>    <@ofbizUrl pathShortener="true">${MyBigUriToSecure}</@ofbizUrl>
> {code}
> For email template it's ugly recommand to use *webSiteId* and *fullPath*
> {code}
>    <@ofbizUrl webSiteId="MyWebSite" fullPath="true" 
> pathShortener="true">${MyBigUriToSecure}</@ofbizUrl>
> {code}
> With this you can have a url like this : 
> https://mywebsite.mydomain/s/rytedqzdfd
>  
> At this time only *<@ofbizUrl *macro freemarker support it.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to