<#-- Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. --> <#if !rootForumId?has_content> <#assign rootForumId=requestParameters.rootForumId!/> <#if !rootForumId?has_content> <#assign rootForumId=defaultSiteId!/> <@checkPermission entityOperation="_ADMIN" targetOperation="CONTENT_ADMIN" >
<#if requestParameters.moderatedSiteId?has_content> <#if requestParameters.permRoleSiteId?has_content>
  Root Site ID  
Refresh
<#assign rowCount = 0 /> <@showSites forumId=rootForumId />
Add Top Level Forum
<@moderateSite rootForumId=rootForumId forumId=requestParameters.moderatedSiteId />

Unapproved entries for forum Id:${requestParameters.moderatedSiteId}


<@grantSiteRoles rootForumId=rootForumId forumId=requestParameters.permRoleSiteId/>

Associated roles for forum Id:${requestParameters.permRoleSiteId}


<#macro showSites forumId formAction="/enableSites" indentIndex=0 catTrail=[]> <#local thisContentId=catTrail[indentIndex]!/> <#local indent = ""> <#if 0 < indentIndex > <#list 0..(indentIndex - 1) as idx> <#local indent = indent + "    "> <@loopSubContent contentId=forumId viewIndex=0 viewSize=9999 contentAssocTypeId="SUBSITE" returnAfterPickWhen="1==1";> ${indent} <#local plusMinus="-"/> ${plusMinus} ${content.contentName!} Moderate    |    User Roles    |    Add Child Forum    |    RemoveSite <#assign rowCount = rowCount + 1 /> <@showSites forumId=subContentId indentIndex=(indentIndex + 1)/> <#macro moderateSite forumId rootForumId > <#assign row=0/> <#list mostRecentList as content> <@checkPermission entityOperation="_ADMIN" targetOperation="CONTENT_PUBLISH" subContentId=forumId > <@injectNodeTrailCsv subContentId=content.contentId redo="true" contentAssocTypeId="PUBLISH_LINK"> <#assign row = row + 1/> <#if 0 < mostRecentList?size >
id:${content.contentId} name:${content.contentName} View
content:
<@renderSubContentCache subContentId=content.contentId/>

<#macro grantSiteRoles forumId rootForumId >
<#list blogRoleIdList as roleTypeId> <#assign rowCount=0/> <#list siteList as siteRoleMap> <#list blogRoleIdList as roleTypeId> <#assign cappedSiteRole= Static["org.apache.ofbiz.entity.model.ModelUtil"].dbNameToVarName(roleTypeId) /> <#assign rowCount=rowCount + 1/> <#list blogRoleIdList as roleTypeId> <#assign cappedSiteRole= Static["org.apache.ofbiz.entity.model.ModelUtil"].dbNameToVarName(roleTypeId) /> <#assign rowCount=rowCount + 1/>
User${roleTypeId}
${siteRoleMap.partyId} checked="checked"/>
<@htmlTemplate.lookupField formName="siteRoleForm" name="partyId_o_${rowCount}" id="partyId_o_${rowCount}" fieldFormName="LookupPerson"/><#-- FIXME check if should be changed -->