mirror of https://gitee.com/bigwinds/arangodb
Merge pull request #1148 from triAGENS/correct-horse-battery-staple
Dev app baseUrls should be db-relative too
This commit is contained in:
commit
8af441da56
|
@ -547,7 +547,7 @@ function executeAppScript (app, name, mount, prefix) {
|
||||||
appContext.options = app._options;
|
appContext.options = app._options;
|
||||||
appContext.configuration = app._options.configuration;
|
appContext.configuration = app._options.configuration;
|
||||||
appContext.basePath = fs.join(root, app._path);
|
appContext.basePath = fs.join(root, app._path);
|
||||||
appContext.baseUrl = devel ? mount : '/_db/' + encodeURIComponent(arangodb.db._name()) + mount;
|
appContext.baseUrl = '/_db/' + encodeURIComponent(arangodb.db._name()) + mount;
|
||||||
|
|
||||||
appContext.isDevelopment = devel;
|
appContext.isDevelopment = devel;
|
||||||
appContext.isProduction = ! devel;
|
appContext.isProduction = ! devel;
|
||||||
|
@ -776,7 +776,7 @@ function routingAalApp (app, mount, options) {
|
||||||
appContextTempl.configuration = app._options.configuration;
|
appContextTempl.configuration = app._options.configuration;
|
||||||
appContextTempl.collectionPrefix = prefix; // collection prefix
|
appContextTempl.collectionPrefix = prefix; // collection prefix
|
||||||
appContextTempl.basePath = fs.join(root, app._path);
|
appContextTempl.basePath = fs.join(root, app._path);
|
||||||
appContextTempl.baseUrl = devel ? mount : '/_db/' + encodeURIComponent(arangodb.db._name()) + mount;
|
appContextTempl.baseUrl = '/_db/' + encodeURIComponent(arangodb.db._name()) + mount;
|
||||||
|
|
||||||
appContextTempl.isDevelopment = devel;
|
appContextTempl.isDevelopment = devel;
|
||||||
appContextTempl.isProduction = ! devel;
|
appContextTempl.isProduction = ! devel;
|
||||||
|
|
Loading…
Reference in New Issue