HEX
Server: Microsoft-IIS/8.5
System: Windows NT YDAWBH120 6.3 build 9600 (Windows Server 2012 R2 Standard Edition) AMD64
User: tentjecom_web (0)
PHP: 7.4.14
Disabled: NONE
Upload Files
File: D:/HostingSpaces/RMourik/bassol.nl/CMS/CMSScripts/CMSModules/CMSSharePoint/ConnectionTest.js
cmsdefine(['CMS/Core', 'jQuery'], function (Core, $) {
    'use strict';

    var Module = function (opt) {
        var core = new Core(opt, null),
            ctx = core.ctx,
            data = ctx.data,
            // The data has to contain the following
            $testButton = $("#" + data.testButtonId),
            $statusLabel = $("#" + data.statusLabelId),
            reportProgressMessage = data.inprogressMessage,
            
            // Report progress to user when $testButton is clicked
            reportProgress = function () {
                $statusLabel.text(reportProgressMessage);
            },
            
            // Hook onclick event on $testButton
            init = function () {
                $testButton.click(
                    function () {
                        reportProgress();
                    }
                );
            };

        init();
    };

    return Module;
});