Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
yohobuywap-node
·
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
ccbikai(👎🏻🍜)
8 years ago
Commit
658d97291adee9a29f5600916bcd165bdf884553
2 parents
b0a893f6
9f4ea2a6
Merge branch 'release/5.1' into grey
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
apps/guang/controllers/opt.js
utils/guang-process.js
apps/guang/controllers/opt.js
View file @
658d972
...
...
@@ -106,7 +106,7 @@ const favoriteBrand = (req, res, next) => {
/* 判断参数是否有效 */
let
id
=
req
.
body
.
id
,
opt
=
req
.
body
.
opt
||
'ok'
,
uid
=
req
.
body
.
uid
||
req
.
cookies
.
appUid
,
uid
=
req
.
user
.
uid
||
(
req
.
body
.
uid
&&
parseInt
(
crypto
.
decrypt
(
null
,
req
.
body
.
uid
)))
||
req
.
cookies
.
appUid
,
isBrand
=
req
.
body
.
isBrand
;
if
(
!
stringProcess
.
isNumeric
(
id
)
||
!
stringProcess
.
isNumeric
(
uid
))
{
...
...
utils/guang-process.js
View file @
658d972
...
...
@@ -270,7 +270,7 @@ const formatProduct = (productData, showTags, showNew, showSale, width, height,
// TODO student price
result
.
studentPrice
=
parseInt
(
productData
.
sales_price
*
100
*
0.9
)
/
100
;
result
.
is_soon_sold_out
=
(
productData
.
is_soon_sold_out
===
'Y'
);
let
url
=
helpers
.
urlFormat
(
`
/
product
/
pro_$
{
productData
.
product_id
}
_$
{
productData
.
goods_list
[
0
].
goods_id
}
/${productData.cn_alphabet}.html`
)
;
let
url
=
encodeURI
(
helpers
.
urlFormat
(
`
/
product
/
pro_$
{
productData
.
product_id
}
_$
{
productData
.
goods_list
[
0
].
goods_id
}
/${productData.cn_alphabet}.html`
)
)
;
result
.
url
=
url
.
replace
(
'http://'
,
'//'
);
...
...
Please
register
or
login
to post a comment