mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
FEATURE: add a route to show the password reset dialog: /password-reset
This commit is contained in:
parent
0124187e3a
commit
55f293d062
@ -84,6 +84,7 @@ export default function() {
|
|||||||
|
|
||||||
this.route('signup', {path: '/signup'});
|
this.route('signup', {path: '/signup'});
|
||||||
this.route('login', {path: '/login'});
|
this.route('login', {path: '/login'});
|
||||||
|
this.route('forgot-password', {path: '/password-reset'});
|
||||||
this.route('faq', {path: '/faq'});
|
this.route('faq', {path: '/faq'});
|
||||||
this.route('tos', {path: '/tos'});
|
this.route('tos', {path: '/tos'});
|
||||||
this.route('privacy', {path: '/privacy'});
|
this.route('privacy', {path: '/privacy'});
|
||||||
|
@ -0,0 +1,22 @@
|
|||||||
|
export default Discourse.Route.extend({
|
||||||
|
beforeModel: function() {
|
||||||
|
this.replaceWith('discovery.latest').then(function(e) {
|
||||||
|
Ember.run.next(function() {
|
||||||
|
e.send('showForgotPassword');
|
||||||
|
});
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
model: function() {
|
||||||
|
return Discourse.StaticPage.find('password-reset');
|
||||||
|
},
|
||||||
|
|
||||||
|
renderTemplate: function() {
|
||||||
|
// do nothing
|
||||||
|
this.render('static');
|
||||||
|
},
|
||||||
|
|
||||||
|
setupController: function(controller, model) {
|
||||||
|
this.controllerFor('static').set('model', model);
|
||||||
|
}
|
||||||
|
});
|
0
app/views/static/password_reset.html.erb
Normal file
0
app/views/static/password_reset.html.erb
Normal file
@ -629,7 +629,7 @@ en:
|
|||||||
failed: "Something went wrong, perhaps this email is already registered, try the forgot password link"
|
failed: "Something went wrong, perhaps this email is already registered, try the forgot password link"
|
||||||
|
|
||||||
forgot_password:
|
forgot_password:
|
||||||
title: "Forgot Password"
|
title: "Password Reset"
|
||||||
action: "I forgot my password"
|
action: "I forgot my password"
|
||||||
invite: "Enter your username or email address, and we'll send you a password reset email."
|
invite: "Enter your username or email address, and we'll send you a password reset email."
|
||||||
reset: "Reset Password"
|
reset: "Reset Password"
|
||||||
|
@ -222,6 +222,7 @@ Discourse::Application.routes.draw do
|
|||||||
resources :static
|
resources :static
|
||||||
post "login" => "static#enter"
|
post "login" => "static#enter"
|
||||||
get "login" => "static#show", id: "login"
|
get "login" => "static#show", id: "login"
|
||||||
|
get "password-reset" => "static#show", id: "password_reset"
|
||||||
get "faq" => "static#show", id: "faq"
|
get "faq" => "static#show", id: "faq"
|
||||||
get "guidelines" => "static#show", id: "guidelines"
|
get "guidelines" => "static#show", id: "guidelines"
|
||||||
get "tos" => "static#show", id: "tos"
|
get "tos" => "static#show", id: "tos"
|
||||||
|
Loading…
Reference in New Issue
Block a user