Web Script: org/alfresco/components/dashlets/site-profile.get
Generated from /share/service/script/org/alfresco/components/dashlets/site-profile.get on Jun 13, 2026 9:39:04 PM

Script Properties
Id:org/alfresco/components/dashlets/site-profile.get
Short Name:Site Profile
Description:Site profile component used in the collaboration site
Authentication:none
Transaction:none
Method:GET
URL Template:/components/dashlets/site-profile
Format Style:any
Default Format:html
Negotiated Formats:[undefined]
Implementation:class org.alfresco.web.scripts.DeclarativeWebScript
Extensions:[undefined]

Store: classpath:alfresco/site-webscripts

File: org/alfresco/components/dashlets/site-profile.get.desc.xml
<webscript>
   <shortname>Site Profile</shortname>
   <description>Site profile component used in the collaboration site</description>
   <family>site-dashlet</family>
   <url>/components/dashlets/site-profile</url>
</webscript>
File: org/alfresco/components/dashlets/site-profile.get.html.ftl
<div class="dashlet site-profile">
   <div class="title">${msg("header.siteProfile")}</div>
   <div class="body">
      <div class="msg">
         <h3><#if (profile.title != "")>${msg("text.welcome", profile.title)?html}<#else>${msg("text.welcome", profile.shortName)?html}</#if></h3>
<#if (profile.description != "")>
         <p>${profile.description?html}</p>
</#if>
<#if profile.customProperties??>
	<#list profile.customProperties?keys as prop>
	   <#assign customValue=profile.customProperties[prop].value>	
	   <#if customValue?starts_with('alfresco-php://') == true>
			<p>
				<a href="${url.context}/proxy/alfresco-php/${customValue?substring(15)}" target="_blank" class="theme-color-1">${profile.customProperties[prop].title}</a>
			</p>
	   <#else>	
		 <p>
            <span class="label">${profile.customProperties[prop].title}</span>
            <span>${customValue}</span>
         </p>
       </#if>  
	</#list>		
</#if>
<#if (sitemanagers?exists && sitemanagers?size &gt; 0)>
         <p>
            <span class="label">${msg("label.siteAdmin")}</span>
   <#list sitemanagers as sitemanager>
            <a href="${url.context}/page/user/${sitemanager.person.userName?url}/profile" class="theme-color-1">${sitemanager.person.firstName?html}<#if sitemanager.person.lastName != ""> ${sitemanager.person.lastName?html}</#if></a><#if sitemanager_has_next>, </#if>
   </#list>
         </p>
</#if>
         <p><span class="label">${msg("label.visibility")}</span>&nbsp;
<#if profile.isPublic?? && profile.isPublic>
         ${msg("text.public")}
<#else>
         ${msg("text.private")}
</#if>
         </p>
      </div>
      <div class="clear"></div>
   </div>
</div>
File: org/alfresco/components/dashlets/site-profile.get.js
// Call the repo for the sites profile
var profile =
{
   title: "",
   shortName: "",   
   description: ""
}

var json = remote.call("/api/sites/" + page.url.templateArgs.site);
if (json.status == 200)
{
   // Create javascript object from the repo response
   var obj = eval('(' + json + ')');
   if (obj)
   {
      profile = obj;
   }
}

// Find the manager for the site
var sitemanagers = [];

json = remote.call("/api/sites/" + page.url.templateArgs.site + "/memberships?rf=SiteManager");
if (json.status == 200)
{
   var obj = eval('(' + json + ')');
   if (obj)
   {
      // the REST API doesn't yet filter per role, we have to do it here
      var managers = [];
      for (var x=0; x < obj.length; x++)
      {
         if (obj[x].role == "SiteManager")
         {
            managers.push(obj[x]);
         }
      }
       
      sitemanagers = managers;
   }
}

// Prepare the model
model.profile = profile;
model.sitemanagers = sitemanagers;
File: org/alfresco/components/dashlets/site-profile.get.properties
header.siteProfile = Site Profile
text.welcome = Welcome to the {0} site
label.siteAdmin = Site Manager(s):
label.visibility = Visibility:
text.public = Public
text.private = Private

Store: classpath:alfresco/webscripts

[No implementation files]