diff options
| author | Jules Laplace <julescarbon@gmail.com> | 2018-08-15 12:58:05 +0200 |
|---|---|---|
| committer | Jules Laplace <julescarbon@gmail.com> | 2018-08-15 12:58:05 +0200 |
| commit | 590a9772063bd0774c6ad4c099447472294deecd (patch) | |
| tree | 3039838ea3edde5f4516ec9286072967c5c9d36a /StoneIsland/www/js/lib/account/ConsentModal.js | |
| parent | 28553fe863564b44f810eacc0ce3f45608346297 (diff) | |
consent modal stuff
Diffstat (limited to 'StoneIsland/www/js/lib/account/ConsentModal.js')
| -rw-r--r-- | StoneIsland/www/js/lib/account/ConsentModal.js | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/StoneIsland/www/js/lib/account/ConsentModal.js b/StoneIsland/www/js/lib/account/ConsentModal.js index c4fe0b53..22f63c53 100644 --- a/StoneIsland/www/js/lib/account/ConsentModal.js +++ b/StoneIsland/www/js/lib/account/ConsentModal.js @@ -19,12 +19,16 @@ var ConsentModal = View.extend({ var status = localStorage.getItem('account_terms.consent') if (status !== 'true') { this.show() + return true } else { this.hide() + app.demand_consent = false + return false } }, show: function(){ + app.demand_consent = true this.$el.show() setTimeout(function(){ this.$el.addClass('visible') @@ -63,11 +67,13 @@ var ConsentModal = View.extend({ if (!state) { return } + app.demand_consent = false this.hide() localStorage.setItem('account_terms.consent', 'true') }, logout: function(){ + app.demand_consent = false this.hide() localStorage.setItem('account_terms.consent', 'false') app.router.go("account/logout") |
