Fixups to portlet webscripts that hardcore the '/service' part of webscript urls to use ${url.serviceContext} and push down into appropriate javascripts

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@5883 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Kevin Roast
2007-06-07 14:29:14 +00:00
parent c53842aa33
commit 9aa5b881c7
5 changed files with 7 additions and 5 deletions

View File

@@ -90,7 +90,7 @@
<div id="spacePanel">
<#-- populated via an AJAX call to 'myspacespanel' webscript -->
<#-- resolved path, filter and home.noderef required as arguments -->
<script>MySpaces.Path="${path?replace("\"","\\\"")}";MySpaces.Filter="${filter}";MySpaces.Home="${home.nodeRef}";</script>
<script>MySpaces.ServiceContext="${url.serviceContext}";MySpaces.Path="${path?replace("\"","\\\"")}";MySpaces.Filter="${filter}";MySpaces.Home="${home.nodeRef}";</script>
</div>
<div class="spaceFooter">
<#-- the count value is retrieved and set dynamically from the AJAX webscript output above -->

View File

@@ -14,7 +14,7 @@
<#if d.isDocument>
<a href="${url.context}${d.url}" target="new" onclick="event.cancelBubble=true"><img class="spaceIconImage" alt="" width="16" height="16" src="${url.context}${d.icon16?replace(".gif",".png")}" border=0></a>
<#else>
<a href="${scripturl("${url.context}/service/myspaces?f=${args.f}&p=${args.p}/${d.name}", false)}"><img class="spaceIconImage" alt="" width="16" height="16" src="${url.context}${d.icon16?replace(".gif",".png")}" border="0" onclick="event.cancelBubble=true;"></a>
<a href="${scripturl("${url.serviceContext}/myspaces?f=${args.f}&p=${args.p}/${d.name}", false)}"><img class="spaceIconImage" alt="" width="16" height="16" src="${url.context}${d.icon16?replace(".gif",".png")}" border="0" onclick="event.cancelBubble=true;"></a>
</#if>
<div style="display:none"><img class="spaceIconImage64" alt="" width="64" height="64" src="${url.context}${d.icon64}"></div>
</div>

View File

@@ -38,7 +38,7 @@
<div id="taskPanel">
<#-- populated via an AJAX call to 'mytaskspanel' webscript -->
<#-- resolved filter required as argument -->
<script>MyTasks.Filter="${filter}";</script>
<script>MyTasks.ServiceContext="${url.serviceContext}";MyTasks.Filter="${filter}";</script>
</div>
</td>
<td width=4 class="paperEdgeRight"><td>

View File

@@ -9,6 +9,7 @@ var MySpaces = {
Path: null,
Filter: null,
Home: null,
ServiceContext: null,
popupPanel: null,
start: function()
@@ -19,7 +20,7 @@ var MySpaces = {
// is responsible for rendering just the contents of the main panel div
YAHOO.util.Connect.asyncRequest(
"GET",
getContextPath() + '/service/myspacespanel?p='+MySpaces.Path+'&f='+MySpaces.Filter+'&h='+MySpaces.Home,
MySpaces.ServiceContext + '/myspacespanel?p='+MySpaces.Path+'&f='+MySpaces.Filter+'&h='+MySpaces.Home,
{
success: function(response)
{

View File

@@ -2,6 +2,7 @@ var MyTasks = {
ANIM_LENGTH: 300,
DETAIL_PANEL_HEIGHT: 132,
Filter: null,
ServiceContext: null,
start: function()
{
@@ -11,7 +12,7 @@ var MyTasks = {
// is responsible for rendering just the contents of the main panel div
YAHOO.util.Connect.asyncRequest(
"GET",
getContextPath() + '/service/mytaskspanel?f='+MyTasks.Filter,
MyTasks.ServiceContext + '/mytaskspanel?f='+MyTasks.Filter,
{
success: function(response)
{