/**
 * 工具页面控制器
 *
 * @author CaiAoLin
 * @date 2017/7/21
 * @version
 */
import BaseController from "../../common/base/base_controller";
let config = require("../../../config/config.js");

class ToolController extends BaseController {

    /**
     *  工具首页
     *
     * @param {object} request
     * @param {object} response
     * @return {void}
     */
    async index(request, response) {
        let toolMenuData = request.session.managerData.toolMenuData;
        console.log(toolMenuData);
        let renderData = {
            layout: 'users/views/layout/layout',
            toolMenu: toolMenuData,
            LicenseKey:config.getLicenseKey(process.env.NODE_ENV)
        };
        response.render('users/views/tool/index', renderData);
    }

}
export default ToolController;
