Initial work for upgrade feature

This commit is contained in:
NGPixel
2017-02-13 00:59:52 -05:00
parent 5223368e37
commit 391afc4d7a
4 changed files with 56 additions and 2 deletions

View File

@@ -6,7 +6,7 @@ const Promise = require('bluebird')
const validator = require('validator')
const _ = require('lodash')
const axios = require('axios')
const moment = require('moment')
const path = require('path')
/**
* Admin
@@ -234,4 +234,14 @@ router.get('/settings', (req, res) => {
})
})
router.get('/settings/install', (req, res) => {
if (!res.locals.rights.manage) {
return res.render('error-forbidden')
}
let sysLib = require(path.join(ROOTPATH, 'libs/system.js'))
sysLib.install('v1.0-beta.5')
res.status(200).end()
})
module.exports = router