Hiding Deactivate Page in sidekick | Adobe Higher Education
Skip to main content
Level 2
November 8, 2016
解決済み

Hiding Deactivate Page in sidekick

  • November 8, 2016
  • 6 の返信
  • 1832 ビュー

Hi All,

Can you please help how to hide Deactivate Page option from Side kick? I could able to do it from Site admin but could not able to get rid of this.

Thanks,

Phani

このトピックへの返信は締め切られました。
ベストアンサー kautuk_sahni

phanirajkumarb74317693 wrote...

Hello Kautik, also how the javascript gets invoked in the above provided code? Do we need to call it from any component or?

 

Hi 

You will notice that the client library has category of “cq.widgets”. Using this category means its loaded with all of CQ’s standard widgets. No extra includes needed in the component!!

Reference article :- http://www.adamcancode.com/adobe-cqaem-custom-widgets/

~kautuk

6 の返信

kautuk_sahni
Community Manager
Community Manager
November 8, 2016
Content backfill required
Kautuk Sahni
kautuk_sahni
Community Manager
Community Manager
November 8, 2016

you can skip point 1 also, but then you can do it like.

// 

 if(CQ.User.getCurrentUser().hasPermissionOn("replicate", [CQ.WCM.getSidekick().getPath()])!=true){

            if(sk && sk.panels){
                clearInterval(SK_INTERVAL);


                        var pagePanel = sk.panels["PAGE"];

                        var buttons = pagePanel.findBy(function(comp){
                            return comp["name"] == "PUBLISH" || comp["name"] == "DEACTIVATE";
                        }, pagePanel);

                        CQ.Ext.each(buttons, function(button){
                            button.setDisabled(true);
                        });

                }

Kautuk Sahni
Level 2
November 8, 2016

Thank you Kautuk,

Can't we hide it from Useradmin like a particular usergroup can't see this option(Deactivate Page)? This option was not there in CQ 5.5 but is seen in 6.2

kautuk_sahni
Community Manager
Community Manager
November 9, 2016

phanirajkumarb74317693 wrote...

Thank you Kautuk,

Can't we hide it from Useradmin like a particular usergroup can't see this option(Deactivate Page)? This option was not there in CQ 5.5 but is seen in 6.2

 

I am not sure about it.

Let me ask this with internal people and then get back to you.

~kautuk

Kautuk Sahni
Level 2
November 9, 2016

Hello Kautik, also how the javascript gets invoked in the above provided code? Do we need to call it from any component or?

kautuk_sahni
Community Manager
Community Manager
November 10, 2016

phanirajkumarb74317693 wrote...

Hello Kautik, also how the javascript gets invoked in the above provided code? Do we need to call it from any component or?

 

Hi 

You will notice that the client library has category of “cq.widgets”. Using this category means its loaded with all of CQ’s standard widgets. No extra includes needed in the component!!

Reference article :- http://www.adamcancode.com/adobe-cqaem-custom-widgets/

~kautuk

Kautuk Sahni