Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
YOHOBUYWAP
·
Commits
Go to a project
GitLab
Go to group
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
Plain Diff
Browse Files
Authored by
梁志锋
9 years ago
Commit
a1f5af61563d28c2888c663b468ebbee60f82826
2 parents
4ea133a0
d8013269
Merge branch 'develop' of
http://git.dev.yoho.cn/web/yohobuy
into develop
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
9 additions
and
14 deletions
library/Api/Yohobuy.php
library/Plugin/Helpers.php
static/js/cart/select-address.js
static/sass/cart/_chose-panel.scss
template/m.yohobuy.com/partials/cart/cart-content.phtml
yohobuy/m.yohobuy.com/application/models/Index/Cart.php
library/Api/Yohobuy.php
View file @
a1f5af6
...
...
@@ -143,7 +143,6 @@ class Yohobuy
if
(
!
empty
(
$data
))
{
$url
=
self
::
httpBuildQuery
(
$url
,
$data
);
}
echo
$url
;
/* 开启缓存的情况 */
if
(
$cache
&&
USE_CACHE
)
{
...
...
library/Plugin/Helpers.php
View file @
a1f5af6
...
...
@@ -576,7 +576,7 @@ class Helpers
$oneGoods
[
'id'
]
=
$value
[
'product_sku'
];
$oneGoods
[
'skn'
]
=
$value
[
'product_skn'
];
$oneGoods
[
'name'
]
=
$value
[
'product_name'
];
$oneGoods
[
'thumb'
]
=
!
empty
(
$value
[
'goods_images'
])
?
Images
::
getImageUrl
(
$value
[
'goods_images'
],
90
,
10
0
)
:
''
;
$oneGoods
[
'thumb'
]
=
!
empty
(
$value
[
'goods_images'
])
?
Images
::
getImageUrl
(
$value
[
'goods_images'
],
120
,
16
0
)
:
''
;
$oneGoods
[
'color'
]
=
$value
[
'color_name'
];
$oneGoods
[
'size'
]
=
$value
[
'size_name'
];
$oneGoods
[
'checked'
]
=
$value
[
'selected'
]
===
'Y'
;
...
...
static/js/cart/select-address.js
View file @
a1f5af6
...
...
@@ -15,8 +15,8 @@ $('.address-item').on('touchend', function() {
}).
on
(
'touchend'
,
'.edit'
,
function
()
{
window
.
location
.
href
=
$
(
this
).
data
(
'href'
);
return
false
;
}).
on
(
'touchend'
,
'.del'
,
function
()
{
deleteId
=
$
(
this
).
data
(
'address-id'
);
}).
on
(
'touchstart'
,
'.del'
,
function
()
{
deleteId
=
$
(
this
).
data
(
'id'
);
});
$confim
.
on
(
'touchend'
,
'.confim'
,
function
()
{
...
...
static/sass/cart/_chose-panel.scss
View file @
a1f5af6
...
...
@@ -41,6 +41,7 @@
.thumb
{
float
:
left
;
width
:
100rem
/
$pxConvertRem
;
margin-right
:
20rem
/
$pxConvertRem
;
}
.text-info
{
...
...
@@ -48,7 +49,7 @@
.name
{
font-size
:
28rem
/
$pxConvertRem
;
height
:
74rem
/
$pxConvertRem
;
overflow
:
hidden
;
overflow
:
hidden
;
display
:
-
webkit-box
;
-webkit-line-clamp
:
2
;
-webkit-box-orient
:
vertical
;
...
...
template/m.yohobuy.com/partials/cart/cart-content.phtml
View file @
a1f5af6
...
...
@@ -58,13 +58,7 @@
{
{/if
}
}
<div
class=
"price-compute"
>
<p>
<span>总价(¥
{
{price
}
})<i>-</i></span>
<span>活动价(¥
{
{activityPrice
}
})</span>
</p>
<p>
<span><i>=</i>商品总计金额
(¥
{
{sumPrice
}
})</span>
</p>
<p>
{
{formulaPrice
}
}</p>
</div>
<div
class=
"balance"
>
...
...
yohobuy/m.yohobuy.com/application/models/Index/Cart.php
View file @
a1f5af6
...
...
@@ -788,8 +788,9 @@ class CartModel
}
// 结算数据
$result
[
'price'
]
=
Helpers
::
transPrice
(
$data
[
'shopping_cart_data'
][
'order_amount'
]);
$result
[
'activityPrice'
]
=
Helpers
::
transPrice
(
$data
[
'shopping_cart_data'
][
'discount_amount'
]);
$result
[
'formulaPrice'
]
=
$data
[
'shopping_cart_data'
][
'promotion_formula'
];
/*$result['price'] = Helpers::transPrice($data['shopping_cart_data']['order_amount']);
$result['activityPrice'] = Helpers::transPrice($data['shopping_cart_data']['discount_amount']);*/
$result
[
'count'
]
=
$data
[
'shopping_cart_data'
][
'selected_goods_count'
];
$result
[
'isAllSelected'
]
=
(
$data
[
'shopping_cart_data'
][
'goods_count'
]
===
$data
[
'shopping_cart_data'
][
'selected_goods_count'
])
&&
(
$data
[
'shopping_cart_data'
][
'selected_goods_count'
]
>
0
);
$result
[
'sumPrice'
]
=
Helpers
::
transPrice
(
$data
[
'shopping_cart_data'
][
'last_order_amount'
]);
...
...
Please
register
or
login
to post a comment