src/Topxia/AdminBundle/Resources/public/js/controller/default/index.js

(开头部分) 1KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

define(function (require, exports, module) {

    var Notify = require('common/bootstrap-notify');
    var Validator = require('bootstrap.validator');
    require('common/validator-rules').inject(Validator);
    require('echarts');
    var Cookie = require('cookie');

    exports.run = function () {
        popover();
        //图表
        courseExplore();
        studyCountStatistic();
        payOrderStatistic();
        studyTaskCountStatistic()
        //事件
        registerSwitchEvent();
        //提醒教师
        remindTeachersEvent();
        //热门搜索
        cloudHotSearch();
        //ajax 获取数据
        loadAjaxData();
        //云广告
        showCloudAd();
    };

    var loadAjaxData = function () {
        systemStatusData()
            .then(siteOverviewData)
            //.then(usersStatistic);
    }

    var registerSwitchEvent = function () {

        DataSwitchEvent('.js-user-switch-button', usersStatistic);

        DataSwitchEvent('.js-study-switch-button', studyCountStatistic);

        DataSwitchEvent('.js-order-switch-button', payOrderStatistic);

        DataSwitchEvent('.js-task-switch-button', studyTaskCountStatistic);

        DataSwitchEvent('.js-course-switch-button', courseExplore);

    }

    //热门搜索
    var cloudHotSearch = function () {
        var totalWidth = $(".js-cloud-search").parent().width();
        var $countDom = $(".js-cloud-search");
        var totalCount = 0;

        $countDom.each(function () {
            totalCount += $(this).data('count');
        })

        $countDom.each(function () {
            var width = ($(this).data('count') / totalCount * totalWidth * 3 + 2).toFixed(2);
            $(this).width(width);

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。