Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
V
venjob
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
3
Merge Requests
3
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Xuan Trung Le
venjob
Commits
10e57825
Commit
10e57825
authored
Oct 25, 2017
by
Xuan Trung Le
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix bugs
parent
89805be5
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
6 deletions
+6
-6
app/controllers/registrations_controller.rb
+1
-1
app/mailers/user_mailer.rb
+2
-2
app/views/users/registrations/new.html.erb
+3
-3
No files found.
app/controllers/registrations_controller.rb
View file @
10e57825
class
RegistrationsController
<
Devise
::
RegistrationsController
class
RegistrationsController
<
Devise
::
RegistrationsController
def
new
def
new
@step
=
params
[
:step
]
@step
=
params
[
:step
]
.
to_i
if
params
[
:code
]
if
params
[
:code
]
@user
=
User
.
find_by
(
confirmation_token:
params
[
:code
])
@user
=
User
.
find_by
(
confirmation_token:
params
[
:code
])
else
else
...
...
app/mailers/user_mailer.rb
View file @
10e57825
class
UserMailer
<
ApplicationMailer
class
UserMailer
<
ApplicationMailer
default
from:
'
from@example
.com'
default
from:
'
notify@venjob
.com'
def
registration_confirmation
(
user
)
def
registration_confirmation
(
user
)
@user
=
user
@user
=
user
mail
(
to:
@user
.
email
,
:subject
=>
"Welcome To VeNJOB! Confirm Your Email"
)
mail
(
to:
@user
.
email
,
subject:
'Welcome To VeNJOB! Confirm Your Email'
)
end
end
end
end
app/views/users/registrations/new.html.erb
View file @
10e57825
<div
class=
"row"
>
<div
class=
"row"
>
<div
class=
"container"
>
<div
class=
"container"
>
<h2>
Register
</h2>
<h2>
Register
</h2>
<%-
if
@step
.
to_i
==
1
-%>
<%-
if
@step
==
1
-%>
<%=
render
"users/registrations/step1"
%>
<%=
render
"users/registrations/step1"
%>
<%-
elsif
@step
.
to_i
==
2
-%>
<%-
elsif
@step
==
2
-%>
<%=
render
"users/registrations/step2"
%>
<%=
render
"users/registrations/step2"
%>
<%-
elsif
@step
.
to_i
==
3
-%>
<%-
elsif
@step
==
3
-%>
<%=
render
"users/registrations/step3"
%>
<%=
render
"users/registrations/step3"
%>
<%-
end
-%>
<%-
end
-%>
</div>
</div>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment