mirror of
https://github.com/ZwareBear/awx.git
synced 2026-04-15 20:41:49 -05:00
Promise-ify the call to /config and reduce number
of calls to 1 per session. We'll also pull the config/license info from memory instead of local storage
This commit is contained in:
@@ -11,10 +11,17 @@ export default function($stateProvider) {
|
||||
resolve.features = ['FeaturesService', function(FeaturesService) {
|
||||
return FeaturesService.get();
|
||||
}];
|
||||
// resolve.features = ['CheckLicense', 'Store', '$state',
|
||||
// function(CheckLicense, Store, $state) {
|
||||
// var license = Store('license');
|
||||
// if(CheckLicense.valid(license)=== false){
|
||||
// $state.go('license');
|
||||
// }
|
||||
// }];
|
||||
return resolve;
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
addState: function(state) {
|
||||
var route = state.route || state.url,
|
||||
resolve = this.getResolves(state);
|
||||
|
||||
Reference in New Issue
Block a user