Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mayi-mp-shop
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
程默
mayi-mp-shop
Commits
d6f14167
Commit
d6f14167
authored
Apr 08, 2021
by
张卓
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
已省价格保留两位小数
parent
cc14dd86
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
1 deletions
+2
-1
static/nativeComponents/GetIndexHomePage/index.js
+1
-0
static/nativeComponents/GetIndexHomePage/index.wxml
+1
-1
No files found.
static/nativeComponents/GetIndexHomePage/index.js
View file @
d6f14167
...
...
@@ -109,6 +109,7 @@ const componentOptions = {
ele
.
terminalProductGoods
.
imgUrl
=
DFSImg
(
ele
.
terminalProductGoods
.
imgUrl
)
ele
.
terminalProductGoods
.
discountPrice
=
(
ele
.
terminalProductGoods
.
discountPrice
-
0
).
toFixed
(
2
)
ele
.
terminalProductGoods
.
salePrice
=
(
ele
.
terminalProductGoods
.
salePrice
-
0
).
toFixed
(
2
)
ele
.
terminalProductGoods
.
discountPriceToatal
=
(
ele
.
terminalProductGoods
.
salePrice
-
ele
.
terminalProductGoods
.
discountPrice
).
toFixed
(
2
)
let
flag
=
Math
.
ceil
((
index
+
1
)
/
3
)
lists
[
flag
-
1
].
push
(
ele
)
})
...
...
static/nativeComponents/GetIndexHomePage/index.wxml
View file @
d6f14167
...
...
@@ -33,7 +33,7 @@
<view class="discount_price">折后价:¥{{item.terminalProductGoods.discountPrice}}</view>
<view class="show_price">
<view class="title">最高可省</view>
<view class="price"> {{
(item.terminalProductGoods.salePrice-item.terminalProductGoods.discountPrice).toFixed(2)
}}元</view>
<view class="price"> {{
item.terminalProductGoods.discountPriceToatal
}}元</view>
</view>
</view>
</swiper-item>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment