mirror of
https://github.com/documize/community.git
synced 2025-07-25 08:09:43 +02:00
include auth.scss file and redirect once on logout
This commit is contained in:
parent
7188324714
commit
e8785f5420
9 changed files with 19 additions and 18 deletions
|
@ -12,23 +12,23 @@
|
|||
import { inject as service } from '@ember/service';
|
||||
|
||||
import Route from '@ember/routing/route';
|
||||
import config from 'documize/config/environment';
|
||||
// import config from 'documize/config/environment';
|
||||
|
||||
export default Route.extend({
|
||||
session: service(),
|
||||
appMeta: service(),
|
||||
|
||||
activate: function () {
|
||||
this.get('session').invalidate().then(() => {
|
||||
if (config.environment === 'test') {
|
||||
this.transitionTo('auth.login');
|
||||
} else {
|
||||
if (this.get("appMeta.allowAnonymousAccess")) {
|
||||
this.transitionTo('folders');
|
||||
} else {
|
||||
this.transitionTo('auth.login');
|
||||
}
|
||||
}
|
||||
this.get('session').invalidate().then(() => {
|
||||
// if (config.environment === 'test') {
|
||||
// this.transitionTo('auth.login');
|
||||
// } else {
|
||||
// if (this.get("appMeta.allowAnonymousAccess")) {
|
||||
// this.transitionTo('folders');
|
||||
// } else {
|
||||
// this.transitionTo('auth.login');
|
||||
// }
|
||||
// }
|
||||
});
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue