Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
yohobuy-node
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
1
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
yyq
7 years ago
Commit
eda71a3bddd9bea33c479d30a1919447503ef4c7
1 parent
e380618e
fix coupons
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
5 deletions
public/js/product/index/top-coupon.js
public/js/product/index/top-coupon.js
View file @
eda71a3
...
...
@@ -216,20 +216,22 @@ function pickCoupon(info) {
}
function
couponSlide
(
num
)
{
if
(
!
this
.
$btns
)
{
this
.
$btns
=
$couponBtn
.
children
();
var
that
=
this
||
window
;
if
(
!
that
.
$btns
)
{
that
.
$btns
=
$couponBtn
.
children
();
}
$couponItem
.
eq
(
0
).
animate
({
'margin-left'
:
-
itemWidth
*
num
});
th
is
.
$btns
.
removeClass
(
'btn-end'
);
th
at
.
$btns
.
removeClass
(
'btn-end'
);
if
(
!
num
)
{
th
is
.
$btns
.
eq
(
0
).
addClass
(
'btn-end'
);
th
at
.
$btns
.
eq
(
0
).
addClass
(
'btn-end'
);
}
else
if
(
num
>=
$couponItem
.
length
-
3
)
{
th
is
.
$btns
.
eq
(
1
).
addClass
(
'btn-end'
);
th
at
.
$btns
.
eq
(
1
).
addClass
(
'btn-end'
);
}
}
...
...
Please
register
or
login
to post a comment