Authored by ccbikai(👎🏻🍜)

修改静态资源时间

Showing 1 changed file with 2 additions and 1 deletions
@@ -21,6 +21,7 @@ const compression = require('compression'); @@ -21,6 +21,7 @@ const compression = require('compression');
21 const bodyParser = require('body-parser'); 21 const bodyParser = require('body-parser');
22 const cookieParser = require('cookie-parser'); 22 const cookieParser = require('cookie-parser');
23 const uuid = require('uuid'); 23 const uuid = require('uuid');
  24 +const moment = require('moment');
24 25
25 const pkg = require('./package.json'); 26 const pkg = require('./package.json');
26 const cookieSession = require('client-sessions'); 27 const cookieSession = require('client-sessions');
@@ -34,7 +35,7 @@ const app = express(); @@ -34,7 +35,7 @@ const app = express();
34 // 向模板注入变量 35 // 向模板注入变量
35 app.locals.devEnv = app.get('env') === 'development'; 36 app.locals.devEnv = app.get('env') === 'development';
36 app.locals.version = pkg.version; 37 app.locals.version = pkg.version;
37 -app.locals.startTime = Date.now(); 38 +app.locals.startTime = moment().format('YYYYMMDDHH');
38 39
39 // 全局注册library 40 // 全局注册library
40 yohoLib.global(config); 41 yohoLib.global(config);