Remove Live Chat and SMS options tab from Global Settings

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
14 年 前
Hi there,

Sorry have managed to do a LOT of customising and using of nop-commerce. The forums are fantastic btw. However, I cant find out how to remove the tabs for Live Chat and SMS options. We actually have our own of both of these - simple ones but they work, so would like to get rid of these options as they are paid.

Can you point me in the right direction.......or tell me how?

Thanks
Simon
14 年 前
you need to look at    administration-->modules-->globalsettings.ascx

you might be able to delete these options without a problem but i suspect you would first need to change or comment out part of the codebehind

maybe a simpler option is to simply hide the info - something like enclosing the unwanted parts in divs  - eg

<div  style="visibility: hidden;" >     </div>
14 年 前
Thanks for the help. Tried that unfortunately did not work. Tried everything from deleting ajax panels (obvious way) to deleteing every reference I could find for sms and live chat in the solution. But I figure it is something relational. as everything I tried ended up in and expected object error.

I even tried deleting the actual content in the itemtemplate. But that seems to be where the problem is.

In the end it was your suggestion that gave me the idea. I ended up putting style="visibility: hidden;" on the table within the item template. Changing the tab names to something we can use, and putting ome dummy text in about feature soon to be.


So thanks for the help....it aint pretty, but it will do!

Is there any chance of making new feature like this an option rather than a must have? Sorry it may just be becuase I am not a c# coder.....in any way shape or form.

BUT THANKS AGAIN!
14 年 前
hi, i looked further into this and found the following works - anyone, feel free to point out any flaws ....

make a copy of your existing file in case you need to roll back.
===================
in visual studio open :

globalsettings.ascx :
completely delete the tab containers for sms and live chat

delete the following lines at the top of the page:

        toggleSMSAlerts();
        toggleLiveChat();
and

    function toggleLiveChat() {
        if (getE('<%=cbLiveChatEnabled.ClientID %>').checked) {
            $('#pnlLiveChatBtnCode').show();
            $('#pnlLiveChatMonCode').show();
        }
        else {
            $('#pnlLiveChatBtnCode').hide();
            $('#pnlLiveChatMonCode').hide();
        }
    }

    function toggleSMSAlerts() {
        if (getE('<%=cbIsSMSAlertsEnabled.ClientID %>').checked) {
            $('#pnlSMSAlertsPhoneNumber').show();
            $('#pnlSMSAlertsClickatellAPIID').show();
            $('#pnlSMSAlertsClickatellUsername').show();
            $('#pnlSMSAlertsClickatellPassword').show();
        }
        else {
            $('#pnlSMSAlertsPhoneNumber').hide();
            $('#pnlSMSAlertsClickatellAPIID').hide();
            $('#pnlSMSAlertsClickatellUsername').hide();
            $('#pnlSMSAlertsClickatellPassword').hide();
        }
    }

save.
====================
open globalsettings.ascx.cs

you will now find several lines with a red squiggle underneath - comment them out  by putting    //   at the start of the line
eg
//            cbIsSMSAlertsEnabled.Checked = SMSManager.IsSMSAlertsEnabled;

there are about 18 lines like this
save
rebuild

:)
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.