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

CJ Horton commented on OFBIZ-2260:
----------------------------------

Hi Ashish,

I apologize if I was unclear.  The issue I am having is that when I code the 
EditCustomTimePeriod.ftl by replacing the following:

<a 
href='<@ofbizUrl>deleteCustomTimePeriod?customTimePeriodId=${customTimePeriod.customTimePeriodId?if_exists}&currentCustomTimePeriodId=${currentCustomTimePeriodId?if_exists}&findOrganizationPartyId=${findOrganizationPartyId?if_exists}</@ofbizUrl>'>
${uiLabelMap.CommonDelete}</a

with:

<form name="DeleteCustomTimePeriod" method="post" 
action="<@ofbizUrl>deleteCustomTimePeriod</@ofbizUrl>">
<input type="hidden" name="customTimePeriodId" 
value="${customTimePeriod.customTimePeriodId?if_exists}">
<input type="hidden" name="currentCustomTimePeriodId" 
value="${currentCustomTimePeriodId?if_exists}">
<input type="hidden" name="findOrganizationPartyId" 
value="${findOrganizationPartyId?if_exists}">
<a href="javascript:document.DeleteCustomTimePeriod.submit()" 
>${uiLabelMap.CommonDelete}</a>
</form>

When I visit: https://localhost:8443/accounting/control/EditCustomTimePeriod 
and click on the Delete link, absolutely nothing happens. It is like I am just 
clicking on plain text. Same thing happens when I add the ; as in your post.

Now, when I code the .ftl file with:

<form name="DeleteCustomTimePeriod" method="post" 
action="<@ofbizUrl>deleteCustomTimePeriod</@ofbizUrl>">
<input type="hidden" name="customTimePeriodId" 
value="${customTimePeriod.customTimePeriodId?if_exists}">
<input type="hidden" name="currentCustomTimePeriodId" 
value="${currentCustomTimePeriodId?if_exists}">
<input type="hidden" name="findOrganizationPartyId" 
value="${findOrganizationPartyId?if_exists}">
<input type="submit" value='${uiLabelMap.CommonDelete}'>
</form>

and I visit the page in my browser, the Delete button behaves as 
expected(request->service->etc.)

I guess I am wondering why it doesn't work using <a 
href="javascript:document.DeleteCustomTimePeriod.submit()" 
>${uiLabelMap.CommonDelete}</a>?




> Secure URLs in Freemarker templates files
> -----------------------------------------
>
>                 Key: OFBIZ-2260
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-2260
>             Project: OFBiz
>          Issue Type: Improvement
>          Components: ALL COMPONENTS
>    Affects Versions: Release Branch 4.0, Release Branch 9.3
>            Reporter: Jacques Le Roux
>            Assignee: Jacques Le Roux
>             Fix For: Release Branch 4.0, Release Branch 9.3
>
>         Attachments: listPortalPortlets.patch, OFBIZ-2256.patch, 
> OFBIZ-2260.patch, OFBIZ-2260.patch, orderitems.patch, UpdateLabelsFiles.patch
>
>
> Follow OFBIZ-2256 but for FTL files only

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

Reply via email to