|
|
# Description
|
|
|
Contains applications based on Node.js and AngularJS
|
|
|
|
|
|
> *Requirements*
|
|
|
* [git](https://git-scm.com)
|
|
|
* [Node.js](https://nodejs.org)
|
|
|
|
|
|
# Checkout process
|
|
|
```
|
|
|
> git clone git@gitlab.beuth-hochschule.de:smart-learning/applications.git
|
|
|
> git checkout dashboard-application-release
|
|
|
> npm install
|
|
|
> npm run bower install
|
|
|
```
|
|
|
|
|
|
# Check if tools are available
|
|
|
```
|
|
|
> npm -v
|
|
|
> npm run bower -- -v
|
|
|
> npm run grunt -- --version
|
|
|
```
|
|
|
|
|
|
# Configuration
|
|
|
In order to configure the dashboard-application open and edit the
|
|
|
*ENV.js* file in the root directory.
|
|
|
|
|
|
* `window.__env.app.roles` - list of all enumerated roles
|
|
|
* `window.__env.app.window.__env.app.minRole ` - minimal role to use the dashboard-application
|
|
|
* `window.__env.app.authentication.prot` - protocol of the API endpoint authentication-manager
|
|
|
* `window.__env.app.authentication.host` - host of the API endpoint authentication-manager
|
|
|
* `window.__env.app.authentication.port` - port of the API endpoint authentication-manager
|
|
|
* `window.__env.app.authentication.base` - base url of the API endpoint authentication-manager
|
|
|
* `window.__env.app.asset.prot` - protocol of the API endpoint asset-manager
|
|
|
* `window.__env.app.asset.host` - host of the API endpoint asset-manager
|
|
|
* `window.__env.app.asset.port` - port of the API endpoint asset-manager
|
|
|
* `window.__env.app.asset.base` - base url of the API endpoint asset-manager
|
|
|
* `window.__env.app.configuration.prot` - protocol of the API endpoint configuration-manager
|
|
|
* `window.__env.app.configuration.host` - host of the API endpoint configuration-manager
|
|
|
* `window.__env.app.configuration.port` - port of the API endpoint configuration-manager
|
|
|
* `window.__env.app.configuration.base` - base url of the API endpoint configuration-manager
|
|
|
* `window.__env.app.credentials.prot` - protocol of the API endpoint credentials-manager
|
|
|
* `window.__env.app.credentials.host` - host of the API endpoint credentials-manager
|
|
|
* `window.__env.app.credentials.port` - port of the API endpoint credentials-manager
|
|
|
* `window.__env.app.credentials.base` - base url of the API endpoint credentials-manager
|
|
|
* `window.__env.app.presentation.prot` - protocol of the APP url to presentation-application
|
|
|
* `window.__env.app.presentation.host` - host of the APP url to presentation-application
|
|
|
* `window.__env.app.presentation.port` - port of the APP url to presentation-application
|
|
|
* `window.__env.app.presentation.base` - base url of the APP url to presentation-application
|
|
|
* `window.__env.app.help.prot` - protocol of the url to help html file
|
|
|
* `window.__env.app.help.host` - host of the url to help html file
|
|
|
* `window.__env.app.help.port` - port of the url to help html file
|
|
|
* `window.__env.app.help.base` - base url of the url to help html file
|
|
|
* `window.__env.app.imprint.prot` - protocol of the url to imprint html file
|
|
|
* `window.__env.app.imprint.host` - host of the url to imprint html file
|
|
|
* `window.__env.app.imprint.port` - port of the url to imprint html file
|
|
|
* `window.__env.app.imprint.base` - base url of the url to imprint html file
|
|
|
|
|
|
```
|
|
|
// APP variables
|
|
|
window.__env.app = {};
|
|
|
window.__env.app.roles = [
|
|
|
'Public',
|
|
|
'Editor',
|
|
|
'Manager',
|
|
|
'Administrator'
|
|
|
];
|
|
|
window.__env.app.minRole = 'Manager';
|
|
|
|
|
|
// API endpoint: authentication-manager
|
|
|
window.__env.authentication = {};
|
|
|
window.__env.authentication.prot = 'http';
|
|
|
window.__env.authentication.host = 'localhost';
|
|
|
window.__env.authentication.port = '3131';
|
|
|
window.__env.authentication.base = '';
|
|
|
|
|
|
// API endpoint: asset-manager
|
|
|
window.__env.asset = {};
|
|
|
window.__env.asset.prot = 'http';
|
|
|
window.__env.asset.host = 'localhost';
|
|
|
window.__env.asset.port = '3132';
|
|
|
window.__env.asset.base = '';
|
|
|
|
|
|
// API endpoint: configuration-manager
|
|
|
window.__env.configuration = {};
|
|
|
window.__env.configuration.prot = 'http';
|
|
|
window.__env.configuration.host = 'localhost';
|
|
|
window.__env.configuration.port = '3134';
|
|
|
window.__env.configuration.base = '';
|
|
|
|
|
|
// API endpoint: credentials-manager
|
|
|
window.__env.credentials = {};
|
|
|
window.__env.credentials.prot = 'http';
|
|
|
window.__env.credentials.host = 'localhost';
|
|
|
window.__env.credentials.port = '3135';
|
|
|
window.__env.credentials.base = '';
|
|
|
|
|
|
// APP endpoint: presentation-application
|
|
|
window.__env.presentation = {};
|
|
|
window.__env.presentation.prot = 'http';
|
|
|
window.__env.presentation.host = 'localhost';
|
|
|
window.__env.presentation.port = '3015';
|
|
|
window.__env.presentation.base = '';
|
|
|
|
|
|
// Link endpoint: Help
|
|
|
window.__env.help = {};
|
|
|
window.__env.help.prot = 'http';
|
|
|
window.__env.help.host = 'localhost';
|
|
|
window.__env.help.port = '9001';
|
|
|
window.__env.help.base = '/help.html';
|
|
|
|
|
|
// Link endpoint: Imprint
|
|
|
window.__env.imprint = {};
|
|
|
window.__env.imprint.prot = 'http';
|
|
|
window.__env.imprint.host = 'localhost';
|
|
|
window.__env.imprint.port = '9001';
|
|
|
window.__env.imprint.base = '/imprint.html';
|
|
|
```
|
|
|
|
|
|
# Prepare assets such as minimize images or create missing minified vendor libs
|
|
|
```
|
|
|
> npm run grunt -- prepareArtifacts
|
|
|
```
|
|
|
|
|
|
# Build development
|
|
|
```
|
|
|
> npm run grunt -- buildDevelopment
|
|
|
> npm run grunt -- serveDevelopment
|
|
|
```
|
|
|
|
|
|
# Build production
|
|
|
```
|
|
|
> npm run grunt -- buildProduction
|
|
|
> npm run grunt -- serveProduction
|
|
|
```
|
|
|
*Production build creates a deployment archive in subfolder: deployBundle*
|
|
|
|
|
|
# See also:
|
|
|
* [Documentation](https://gitlab.beuth-hochschule.de/smart-learning/applications/blob/dashboard-application-release/docs/index.html) [JSDoc] or within unarchived folder in directory *docs*
|
|
|
|
|
|
# Licence:
|
|
|
<a rel="license" href="http://creativecommons.org/licenses/by-sa/4.0/"><img alt="Creative Commons License" style="border-width:0" src="https://i.creativecommons.org/l/by-sa/4.0/88x31.png" /></a><br />This work is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by-sa/4.0/">Creative Commons Attribution-ShareAlike 4.0 International License</a>. |