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
刘传洋
8 years ago
Commit
8f92f3503f5b0a45ae089cdde553c21ce7992481
1 parent
a286f6d7
m
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
45 additions
and
41 deletions
apps/cart/views/action/cart.hbs
public/hbs/cart/cart-gifts-win-tpl.hbs
public/hbs/cart/cart-product-info-tpl.hbs
public/js/cart/cart-goods-win.js
public/js/cart/cart-together.js
apps/cart/views/action/cart.hbs
View file @
8f92f35
...
...
@@ -367,6 +367,7 @@
<i
class=
"iconfont"
>

</i>
</div>
<div
class=
"content goods-select-content"
>
<div
class=
"detail-body"
></div>
</div>
</div>
</div>
...
...
public/hbs/cart/cart-gifts-win-tpl.hbs
View file @
8f92f35
<div
class=
"detail-body"
>
<div
class=
"slide-img"
>
<p
class=
"sell-class-title"
>
<!--选赠品:-->
<em
class=
"slide-img-title"
>
<span
class=
"active"
>
{{
promotionTitle
}}
</span>
<!--<code class="spacing">|</code>
<span>59元加价购</span>
<code class="spacing">|</code>
<span>99元加价购</span>-->
</em>
</p>
<div
class=
"side-img-dd"
>
<ul
class=
"img-list"
>
{{#
each
goodsList
}}
<li
class=
"img-item
{{#if
active
}}
active
{{/if}}
"
data-id=
"
{{
id
}}
"
data-skn=
"
{{
skn
}}
"
data-ispricegift=
"
{{
isPriceGift
}}
"
data-isgift=
"
{{
isGift
}}
"
>
<span
class=
"hide goods-id"
>
{{
goods_id
}}
</span>
<div
class=
"good"
>
<a
href=
"javascript:void(0)"
target=
"_blank"
>
{{!--{{link}}--}}
<img
class=
"lazy"
src=
"
{{
imgCover
}}
"
/>
</a>
</div>
{{#
if_cond
..
/
selectedSkn
'=='
skn
}}
<i
class=
"iconfont checked"
>

</i>
{{/
if_cond
}}
</li>
{{/
each
}}
</ul>
<div
class=
"img-brand-switch"
>
<a
class=
"prev iconfont"
href=
"javascript:;"
>

</a>
<a
class=
"next iconfont"
href=
"javascript:;"
>

</a>
</div>
<div
class=
"slide-img"
>
<p
class=
"sell-class-title"
>
{{#if
isGift
}}
选赠品:
{{/if}}
<!--选赠品:-->
{{#if
isPriceGift
}}{{
promotionTitle
}}{{/if}}
{{!--<em class="slide-img-title">
<span class="active">{{promotionTitle}}</span>
<!--<code class="spacing">|</code>
<span>59元加价购</span>
<code class="spacing">|</code>
<span>99元加价购</span>-->
</em>--}}
</p>
<div
class=
"side-img-dd"
>
<ul
class=
"img-list"
>
{{#
each
goodsList
}}
<li
class=
"img-item
{{#if
active
}}
active
{{/if}}
"
data-id=
"
{{
id
}}
"
data-skn=
"
{{
skn
}}
"
data-ispricegift=
"
{{
isPriceGift
}}
"
data-isgift=
"
{{
isGift
}}
"
>
<span
class=
"hide goods-id"
>
{{
goods_id
}}
</span>
<div
class=
"good"
>
<a
href=
"javascript:void(0)"
target=
"_blank"
>
{{!--{{link}}--}}
<img
class=
"lazy"
src=
"
{{
imgCover
}}
"
/>
</a>
</div>
{{#
if_cond
..
/
selectedSkn
'=='
skn
}}
<i
class=
"iconfont checked"
>

</i>
{{/
if_cond
}}
</li>
{{/
each
}}
</ul>
<div
class=
"img-brand-switch"
>
<a
class=
"prev iconfont"
href=
"javascript:;"
>

</a>
<a
class=
"next iconfont"
href=
"javascript:;"
>

</a>
</div>
</div>
<div
class=
"product-detail-info"
data-promotionid=
"
{{
promotionId
}}
"
{{#if
swap
}}
data-swap=
"
{{
swap
}}
"
{{/if}}
>
{{#
productInfo
}}
{{>
cart-product-info-tpl
}}
{{/
productInfo
}}
</div>
</div>
<div
class=
"product-detail-info"
data-promotionid=
"
{{
promotionId
}}
"
data-maxselectnum=
"
{{
maxSelectNumber
}}
"
{{#if
swap
}}
data-swap=
"
{{
swap
}}
"
{{/if}}
>
{{#
productInfo
}}
{{>
cart-product-info-tpl
}}
{{/
productInfo
}}
</div>
...
...
public/hbs/cart/cart-product-info-tpl.hbs
View file @
8f92f35
...
...
@@ -30,7 +30,7 @@
<div
class=
"price"
>
{{#if
salePrice
}}
<span
class=
"newprice"
>
现价:
<b
class=
"promotion-price"
>
¥
{{
salePrice
}}
</b></span>
<span
class=
"oldprice"
>
原
价:
<del>
¥
{{
marketPrice
}}
</del></span>
<span
class=
"oldprice"
>
活动
价:
<del>
¥
{{
marketPrice
}}
</del></span>
{{^}}
<span
class=
"newprice
{{#
presalePrice
}}
none
{{/
presalePrice
}}
"
>
原价:
<b
class=
"promotion-price"
>
¥
{{
marketPrice
}}
</b></span>
{{/if}}
...
...
public/js/cart/cart-goods-win.js
View file @
8f92f35
...
...
@@ -19,7 +19,7 @@ var $ = require('yoho-jquery'),
'[data-role=pg-resel-btn]'
];
function
renderAndShowGiftWin
(
plist
)
{
$goodsSelWin
.
find
(
'.
content
'
).
empty
().
html
(
giftsWinTpl
(
plist
));
$goodsSelWin
.
find
(
'.
detail-body
'
).
empty
().
html
(
giftsWinTpl
(
plist
));
capi
.
showMDialog
(
'#Y_goodsSelectWinDialog'
);
}
...
...
public/js/cart/cart-together.js
View file @
8f92f35
...
...
@@ -158,7 +158,7 @@ $('.bottom-tab-slide').on('click', '.bottom-title', function() {
function
showTogetherSelWin
(
id
,
skn
)
{
capi
.
getProductInfo
(
id
,
skn
).
then
(
res
=>
{
$goodsSelWin
.
find
(
'.
content
'
).
empty
().
append
(
productInfoTpl
(
res
));
$goodsSelWin
.
find
(
'.
detail-body
'
).
empty
().
append
(
productInfoTpl
(
res
));
});
capi
.
showMDialog
(
'#Y_goodsSelectWinDialog'
);
...
...
Please
register
or
login
to post a comment