AnsweredAssumed Answered

Hide comment link in document details

Question asked by netfisher777 on Nov 17, 2015
Latest reply on Nov 19, 2015 by netfisher777
Hi all!

I'm writing an amp module for hiding some content in alfresco share and now need to hide all links in document details node-header component (likes, favourite, share, comment)
I was successfully remove likes, favourite and share links, but not comment.

Here is what i'm trying to do:

src/main/amp/config/alfresco/web-extension/site-data/extensions/interface-cut-plugin-extension-modules.xml:



<extension>
<modules>
    <module>
        <id>Remove Likes, Favourite and Share links from document details</id>
        <auto-deploy>true</auto-deploy>
        <customizations>
            <customization>
                <targetPackageRoot>org.alfresco.components.node-details</targetPackageRoot>
                <sourcePackageRoot>com.somepackage</sourcePackageRoot>
            </customization>
        </customizations>
    </module>
</modules>
</extension>



src/main/amp/config/alfresco/web-extension/site-webscripts/com/somepackage/node-header.get.js:


for (var i=0; i<model.widgets.length; i++)  {
    if (model.widgets.id == "NodeHeader") {
        model.widgets.options.showFavourite = false;
        model.widgets.options.showLikes = false;
        model.widgets.options.showQuickShare = false;
        model.widgets.options.showComments = false;
    }
}



Any suggestions?

Alfresco SDK version - 2.1.1 (Community)

Outcomes