Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
V
venshop
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
huanvl
venshop
Commits
1a8d06d0
Commit
1a8d06d0
authored
Oct 24, 2013
by
hades
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
reskin
parent
6a645571
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
31 additions
and
8 deletions
+31
-8
venshop_app/app/assets/stylesheets/custom.css.scss
+1
-0
venshop_app/app/controllers/cards_controller.rb
+6
-1
venshop_app/app/views/cards/confirm_checkout.html.erb
+6
-4
venshop_app/app/views/cards/thankyou.html.erb
+13
-2
venshop_app/app/views/layouts/application_one_col.html.erb
+4
-1
venshop_app/config/routes.rb
+1
-0
No files found.
venshop_app/app/assets/stylesheets/custom.css.scss
View file @
1a8d06d0
...
...
@@ -362,6 +362,7 @@ footer {
width
:
100%
;
clear
:
left
;
padding-top
:
10px
;
padding-bottom
:
10px
;
}
.item
{
.thumbnail
{
...
...
venshop_app/app/controllers/cards_controller.rb
View file @
1a8d06d0
...
...
@@ -107,7 +107,7 @@ class CardsController < ApplicationController
end
def
confirm_checkout
add_breadcrumb
"Checkout"
,
url_for
(
action:
'checkout'
)
add_breadcrumb
"Check
out"
,
url_for
(
action:
'checkout'
)
add_breadcrumb
"Confirm"
,
url_for
(
action:
'confirm_checkout'
)
@card_infos
=
Hash
.
new
if
session
[
:SHOPPING_CARD_SESSION_NAME
]
!=
nil
...
...
@@ -116,8 +116,13 @@ class CardsController < ApplicationController
if
@card_infos
.
empty?
redirect_to
cards_path
end
if
request
.
post?
redirect_to
url_for
(
action:
'thankyou'
)
end
end
def
thankyou
add_breadcrumb
"Thank out"
,
url_for
(
action:
'thankyou'
)
render
:layout
=>
"application_one_col"
end
end
venshop_app/app/views/cards/confirm_checkout.html.erb
View file @
1a8d06d0
...
...
@@ -11,26 +11,28 @@
<td>
<%=
customer_info
[
:full_name
]
%>
</td>
</tr>
<tr>
<td>
Email
:
</td>
<td>
<b>
Email
</b>
:
</td>
<td>
<%=
customer_info
[
:email
]
%>
</td>
</tr>
<tr>
<td>
Phone
:
</td>
<td>
<b>
Phone
</b>
:
</td>
<td>
<%=
customer_info
[
:phone
]
%>
</td>
</tr>
<tr>
<td>
Address
:
</td>
<td>
<b>
Address
</b>
:
</td>
<td>
<%=
customer_info
[
:address
]
%>
</td>
</tr>
<tr>
<td>
Note
:
</td>
<td>
<b>
Note
</b>
:
</td>
<td>
<%=
customer_info
[
:note
]
%>
</td>
</tr>
</table>
<%=
render
partial:
'cards/item_list'
,
locals:
{
card_infos:
@card_infos
,
can_edit:
false
}
%>
<%=
form_tag
do
%>
<div
class=
"text-center"
>
The information above
<a
href=
"
<%=
url_for
(
action:
'checkout'
)
%>
"
class=
"btn btn-default"
>
Incorrect, click here
</a>
<%=
submit_tag
"Correct, click here"
,
class:
'btn btn-primary btn-submit'
%>
</div>
<%
end
%>
</div>
venshop_app/app/views/cards/thankyou.html.erb
View file @
1a8d06d0
<h1>
Cards#thankyou
</h1>
<p>
Find me in app/views/cards/thankyou.html.erb
</p>
<%
provide
(
:title
,
"Thank you"
)
%>
<div
class=
"body-box"
>
<h2
class=
"sprite-2"
>
Thank you
<span
class=
"sprite-2"
></span>
</h2>
<p>
</p>
<p>
Successfully order!
<br
/>
We will contact you as soon as possible!
</p>
<p>
</p>
<div
class=
"clearfix"
></div>
</div>
venshop_app/app/views/layouts/application_one_col.html.erb
View file @
1a8d06d0
...
...
@@ -21,7 +21,10 @@
<%=
render
'layouts/header'
%>
</div>
<div
class=
"container"
>
<%=
render
'layouts/breadcrumb'
,
breadcrumbs:
yield
(
:breadcrumbs
)
%>
<nav
class=
"breadcrumb"
>
<span>
You are in:
</span>
<%=
render_breadcrumbs
%>
</nav>
<div
class=
"clearfix"
></div>
<%
if
flash
.
any?
%>
<div
id=
"block-message"
class=
"hidden"
>
...
...
venshop_app/config/routes.rb
View file @
1a8d06d0
...
...
@@ -6,6 +6,7 @@ VenshopApp::Application.routes.draw do
get
"cards/checkout"
post
"cards/checkout"
get
"cards/confirm_checkout"
post
"cards/confirm_checkout"
get
"cards/thankyou"
resources
:users
resources
:sessions
,
only:
[
:new
,
:create
,
:destroy
]
...
...
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