Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
YOHOBUYPC
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
2
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
郭成尧
9 years ago
Commit
eead40dd6a31c7dbf106e624d351cc2041dbad5e
1 parent
6a67b3bc
'价格添加.00'
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
yohobuy/www.yohobuy.com/application/models/Shopping/Cart.php
yohobuy/www.yohobuy.com/application/models/Shopping/Cart.php
View file @
eead40d
...
...
@@ -500,9 +500,9 @@ class CartModel
$build
[
'title'
]
=
$value
[
'product_name'
];
$build
[
'img'
]
=
Helpers
::
getImageUrl
(
$value
[
'default_images'
],
100
,
100
);
$build
[
'alt'
]
=
$value
[
'product_name'
];
$build
[
'price'
]
=
$value
[
'sales_price'
]
;
$build
[
'price'
]
=
strstr
(
strval
(
$value
[
'sales_price'
]),
'.'
)
?
$value
[
'sales_price'
]
:
$value
[
'sales_price'
]
.
'.00'
;
if
(
$value
[
'sales_price'
]
!==
[
'market_price'
])
{
$build
[
'marketPrice'
]
=
$value
[
'market_price'
]
;
$build
[
'marketPrice'
]
=
strstr
(
strval
(
$value
[
'market_price'
]),
'.'
)
?
$value
[
'market_price'
]
:
$value
[
'market_price'
]
.
'.00'
;
}
$result
[
'data'
][
'item'
][]
=
$build
;
...
...
@@ -1009,7 +1009,7 @@ class CartModel
* @param int $redEnvelopes 红包
* @return array 接口返回的数据
*/
public
static
function
orderSub
(
$uid
,
$addressId
,
$cartType
,
$deliveryTimeId
,
$deliveryWayId
,
$invoiceType
,
$invoiceTitle
,
$invoiceContent
,
$receiverMobile
,
$paymentId
,
$paymentType
,
$remark
,
$couponCode
,
$promotionCode
,
$yohoCoin
,
$isPreContact
,
$isPrintPrice
,
$redEnvelopes
)
public
static
function
orderSub
(
$uid
,
$addressId
,
$cartType
,
$deliveryTimeId
,
$deliveryWayId
,
$invoiceType
,
$invoiceTitle
,
$invoiceContent
,
$receiverMobile
,
$paymentId
,
$paymentType
,
$remark
,
$couponCode
,
$promotionCode
,
$yohoCoin
,
$isPreContact
,
$isPrintPrice
,
$redEnvelopes
)
{
$result
=
array
(
'code'
=>
400
,
'message'
=>
self
::
ERROR_400_MESSAGE
);
...
...
@@ -1050,7 +1050,7 @@ class CartModel
$userAgent
=
isset
(
$unionInfo
[
'client_id'
])
?
'YOHO!Buy/3.8.2.259(Model/PC;Channel/'
.
$unionInfo
[
'client_id'
]
.
';uid/'
.
$uid
.
')'
:
null
;
}
$orderSubRes
=
CartData
::
orderSub
(
$uid
,
$addressId
,
$cartType
,
$deliveryTimeId
,
$deliveryWayId
,
$invoiceType
,
$invoiceTitle
,
$invoiceContent
,
$receiverMobile
,
$paymentId
,
$paymentType
,
$remark
,
$couponCode
,
$promotionCode
,
$yohoCoin
,
$isPreContact
,
$isPrintPrice
,
$unionKey
,
$userAgent
,
$redEnvelopes
);
$orderSubRes
=
CartData
::
orderSub
(
$uid
,
$addressId
,
$cartType
,
$deliveryTimeId
,
$deliveryWayId
,
$invoiceType
,
$invoiceTitle
,
$invoiceContent
,
$receiverMobile
,
$paymentId
,
$paymentType
,
$remark
,
$couponCode
,
$promotionCode
,
$yohoCoin
,
$isPreContact
,
$isPrintPrice
,
$unionKey
,
$userAgent
,
$redEnvelopes
);
if
(
$orderSubRes
&&
isset
(
$orderSubRes
[
'code'
]))
{
$result
=
$orderSubRes
;
}
...
...
Please
register
or
login
to post a comment