AnsweredAssumed Answered

Remove 'New List' button

Question asked by nancygaillard on Mar 18, 2015
Latest reply on Mar 19, 2015 by s.palyukh
Hi,
I am on Windows 7x64bits with Alfresco Community 4.2.e
java version 1.8.0_31

I would like to remove the button "New List" in the toolbar of the datalist template.

I found it here :
- <Alfresco_home>\tomcat\webapps\share\WEB-INF\classes\alfresco\site-webscripts\org\alfresco\components\data-lists\list.get.html.ftl
- <Alfresco_home>\tomcat\webapps\share\WEB-INF\classes\alfresco\site-webscripts\org\alfresco\components\data-lists\datalists.get.html.ftl

Modifying the first file (and restart Tomcat of course ^^) doens't change anything…
However, the second file seems to be the one I have to set, but I don't understand how it doesn't give me the expected result!

There is my issue :
in the following section :
<blockcode>
<@markup id="html">
   <@uniqueIdDiv>
      <#assign id = args.htmlid>
      <div id="${id}-body" class="datalists">
         <div id="${id}-headerBar" class="header-bar toolbar flat-button theme-bg-2">
            <div class="left">
               <span id="${id}-newListButton" class="yui-button yui-push-button new-list">
                   <span class="first-child">
                       <button type="button">${msg('button.new-list')}</button>
                   </span>
               </span>
            </div>
         </div>
         <h2>${msg("header.lists")}</h2>
         <div id="${id}-lists" class="filter"></div>
         <div class="horiz-rule"> </div>
      </div>
   </@>
</@>
</blockcode>
if I simply have removed for test one of the following parts every times :
the whole tag and its contents :
<div class="left">…</div>
,
<span id="…" class="yui-button yui-push-button new-list">…</span>
,
<span class="first-child">…</span>
,
<buton type="button">…</button>

Every times, the result was remaining identical… all of the left part (including the button, the filters, the list of datalists) disappears.

What is the problem?

******
It is a simple test to finally granulate permissions :)

Thank you for reading and answering!

Outcomes