4077-login_recover-password & account_verifyEmail #1063
|
@ -12,9 +12,10 @@ export default class Component extends EventEmitter {
|
|||
* @param {HTMLElement} $element The main component element
|
||||
* @param {$rootScope.Scope} $scope The element scope
|
||||
* @param {Function} $transclude The transclusion function
|
||||
* @param {Function} $location The location function
|
||||
*/
|
||||
constructor($element, $scope, $transclude) {
|
||||
super();
|
||||
constructor($element, $scope, $transclude, $location) {
|
||||
super($element, $scope, $transclude, $location);
|
||||
this.$ = $scope;
|
||||
|
||||
if (!$element) return;
|
||||
|
@ -164,7 +165,7 @@ export default class Component extends EventEmitter {
|
|||
$transclude.$$boundTransclude.$$slots[slot];
|
||||
}
|
||||
}
|
||||
Component.$inject = ['$element', '$scope'];
|
||||
Component.$inject = ['$element', '$scope', '$location', '$state'];
|
||||
|
||||
/*
|
||||
* Automatically adds the most used services to the prototype, so they are
|
||||
|
|
|
@ -9,12 +9,18 @@ import Component from 'core/lib/component';
|
|||
* @property {SideMenu} rightMenu The left menu, if it's present
|
||||
*/
|
||||
export default class App extends Component {
|
||||
constructor($element, $, $location, $state) {
|
||||
super($element, $, $location, $state);
|
||||
this.$location = $location;
|
||||
this.$state = $state;
|
||||
}
|
||||
|
||||
$postLink() {
|
||||
alexm marked this conversation as resolved
Outdated
|
||||
this.vnApp.logger = this;
|
||||
}
|
||||
|
||||
get showLayout() {
|
||||
const state = this.$state.current.name;
|
||||
const state = this.$state.current.name || this.$location.$$path.substring(1).replace('/', '.');
|
||||
const outLayout = ['login', 'recoverPassword', 'resetPassword'];
|
||||
return state && !outLayout.some(ol => ol == state);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Açò funciona en tots els casos? Que passa si un estat conte login?