Toggle navigation
Toggle navigation
This project
Loading...
Sign in
wangshusheng
/
YOHOBUYPC
·
Commits
Go to a project
GitLab
Go to dashboard
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
biao
9 years ago
Commit
914b3d26b1088fe1acb7b31aaa952db13806d68c
1 parent
7ad64222
优化删除购物车商品后页面颜色。 code review by LZF
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
1 deletions
static/js/cart/cart.js
static/sass/cart/_index.scss
static/js/cart/cart.js
View file @
914b3d2
...
...
@@ -10,11 +10,13 @@ var $ = require('jquery'),
var
chosePanel
=
require
(
'./chose-panel'
),
dialog
=
require
(
'../me/dialog'
),
loading
=
require
(
'../plugin/loading'
),
tip
=
require
(
'../plugin/tip'
);
var
$cartContent
=
$
(
'.cart-content'
),
cartType
=
$
(
'#cartType'
).
val
(),
$cartNav
=
$
(
'.cart-nav'
),
$cartPage
=
$
(
'.shopping-cart-page'
),
hasShowCartPresellTip
=
false
;
var
navHammer
,
...
...
@@ -22,19 +24,30 @@ var navHammer,
freebieHammer
,
switchChose
=
false
;
var
isRefreshByDelete
=
window
.
cookie
(
'_yoho-cart-refreshByDelete'
)
===
'true'
?
true
:
false
;
loading
.
showLoadingMask
();
function
needLoadRecommandForYou
()
{
return
window
.
isCookiesEnabled
()
?
$
(
'.cart-goods'
).
length
<=
0
&&
window
.
cookie
(
'_yoho-cart-refreshByDelete'
)
!==
'true'
:
$
(
'.cart-goods'
).
length
<=
0
&&
!
isRefreshByDelete
:
$
(
'.cart-goods'
).
length
<=
0
;
}
if
(
needLoadRecommandForYou
())
{
require
(
'../product/recommend-for-you'
);
}
else
{
if
(
isRefreshByDelete
)
{
$
(
'body'
).
css
(
'background-color'
,
'#f0f0f0'
);
}
require
(
'./good'
);
}
$cartPage
.
css
(
'display'
,
'block'
);
loading
.
hideLoadingMask
();
window
.
setCookie
(
'_yoho-cart-refreshByDelete'
,
false
);
ellipsis
.
init
();
...
...
static/sass/cart/_index.scss
View file @
914b3d2
...
...
@@ -8,6 +8,7 @@
margin-bottom
:
120rem
/
$pxConvertRem
;
overflow-x
:
hidden
;
background
:
#f0f0f0
;
display
:
none
;
.yoho-tip
{
z-index
:
4
;
...
...
Please
register
or
login
to post a comment