39 lines
618 B
JavaScript
39 lines
618 B
JavaScript
var express = require('express');
|
|
var router = express.Router();
|
|
var util = require('util');
|
|
|
|
var utils = require('../../../src/utils');
|
|
var crossCtl = require('../../../src/crossCtl');
|
|
|
|
var path = require('path');
|
|
|
|
var passport = require('passport');
|
|
|
|
// operation
|
|
/*
|
|
router.use(function (req, res, next) {
|
|
|
|
|
|
next()
|
|
})
|
|
*/
|
|
|
|
/*
|
|
router.use(function (req, res, next) {
|
|
if (req.infos.userInfo.adminFlag === false) {
|
|
res.status(401).render("main/pages/error", {
|
|
infos: req.infos,
|
|
errorCode: 401,
|
|
errorMessage: "Unauthorized",
|
|
});
|
|
} else {
|
|
next();
|
|
}
|
|
});
|
|
*/
|
|
|
|
|
|
|
|
|
|
module.exports = router;
|