rename package to walnut@daplie.com/init
This commit is contained in:
parent
2ecfbc1e98
commit
4b477f562e
|
@ -162,15 +162,17 @@ module.exports.create = function (app, xconfx, models) {
|
||||||
// TODO How can we help apps handle this? token?
|
// TODO How can we help apps handle this? token?
|
||||||
// TODO allow apps to configure trustedDomains, auth, etc
|
// TODO allow apps to configure trustedDomains, auth, etc
|
||||||
app.use('/api', cors);
|
app.use('/api', cors);
|
||||||
app.get('/api/com.daplie.walnut.init', getConfig);
|
app.get('/api/walnut@daplie.com/init', getConfig);
|
||||||
app.post('/api/com.daplie.walnut.init', setConfig);
|
app.get('/api/com.daplie.walnut.init', getConfig); // deprecated
|
||||||
|
app.post('/api/walnut@daplie.com/init', setConfig);
|
||||||
|
app.post('/api/com.daplie.walnut.init', setConfig); // deprecated
|
||||||
|
|
||||||
// TODO use package loader
|
// TODO use package loader
|
||||||
//app.use('/', express.static(path.join(__dirname, '..', '..', 'packages', 'pages', 'com.daplie.walnut.init')));
|
//app.use('/', express.static(path.join(__dirname, '..', '..', 'packages', 'pages', 'walnut@daplie.com', 'init')));
|
||||||
app.use('/', express.static(path.join(__dirname, 'com.daplie.walnut.init')));
|
app.use('/', express.static(path.join(__dirname, 'walnut@daplie.com', 'init')));
|
||||||
app.use('/', function (req, res, next) {
|
app.use('/', function (req, res, next) {
|
||||||
res.statusCode = 404;
|
res.statusCode = 404;
|
||||||
res.end('Walnut Bootstrap Not Found. Mising com.daplie.walnut.init');
|
res.end('Walnut Bootstrap Not Found. Mising walnut@daplie.com/init');
|
||||||
});
|
});
|
||||||
|
|
||||||
return new PromiseA(function (_resolve) {
|
return new PromiseA(function (_resolve) {
|
||||||
|
|
|
@ -22,7 +22,7 @@ $(function () {
|
||||||
|
|
||||||
return $.http({
|
return $.http({
|
||||||
method: 'GET'
|
method: 'GET'
|
||||||
, url: baseUrl + '/api/com.daplie.walnut.init'
|
, url: baseUrl + '/api/walnut@daplie.com/init'
|
||||||
, headers: {
|
, headers: {
|
||||||
"Accept" : "application/json; charset=utf-8"
|
"Accept" : "application/json; charset=utf-8"
|
||||||
}
|
}
|
||||||
|
@ -83,7 +83,7 @@ $(function () {
|
||||||
|
|
||||||
$.http({
|
$.http({
|
||||||
method: 'POST'
|
method: 'POST'
|
||||||
, url: baseUrl + '/api/com.daplie.walnut.init'
|
, url: baseUrl + '/api/walnut@daplie.com/init'
|
||||||
, headers: {
|
, headers: {
|
||||||
"Accept" : "application/json; charset=utf-8"
|
"Accept" : "application/json; charset=utf-8"
|
||||||
, "Content-Type": "application/json; charset=utf-8"
|
, "Content-Type": "application/json; charset=utf-8"
|
Loading…
Reference in New Issue