Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
严立
/
mini-shimao
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
db659438
authored
Sep 17, 2020
by
zqm
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
MM - 订单详情
parent
6c9dbda5
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
73 additions
and
19 deletions
pages/mine/order/order.js
pages/pay/order-detail/order-detail.js
pages/pay/order-detail/order-detail.wxml
pages/mine/order/order.js
View file @
db659438
...
...
@@ -37,10 +37,19 @@ Page({
isFinished
:
false
},
onLoad
:
function
(
options
)
{
this
.
setData
({
option
:
options
})
this
.
setData
({
option
:
options
})
App
.
login
({
timeout
:
0
,
success
:
(
result
)
=>
{
this
.
setOrderType
()
},
})
},
/**
* 查询订单列表
* @function
...
...
pages/pay/order-detail/order-detail.js
View file @
db659438
...
...
@@ -2,6 +2,7 @@ let App = getApp()
Page
({
data
:
{
showNotice
:
false
,
swiperCurrent
:
0
,
showCodePopup
:
false
,
imageBase
:
App
.
globalData
.
appImageBase
,
...
...
@@ -75,31 +76,30 @@ Page({
},
})
},
// /api/v1/order/getVolumesByOrderId
// 使用须知
handleNotice
()
{
let
showNotice
=
true
this
.
setData
({
showNotice
})
},
// 一键扫码
onFastScan
:
function
(
event
)
{
wx
.
showLoading
({
title
:
'加载中'
,
})
App
.
wxRequest
({
url
:
'/api/v1/order/getVolumesByOrderId'
,
data
:
{
'orderId'
:
this
.
data
.
orderInfo
.
id
},
success
:
(
response
)
=>
{
let
funcResponse
=
response
.
data
console
.
log
(
response
,
'一键扫码'
);
wx
.
hideLoading
()
let
list
=
response
.
data
// let funcCodeInfo = {
// 'codeNo': funcResponse.serialNumber,
// 'codeName': funcResponse.name,
// 'codeBase64': funcResponse.qrcode,
// }
this
.
setData
({
showCodePopup
:
true
,
codeList
:
list
...
...
@@ -230,7 +230,25 @@ Page({
}
})
},
// 多二维码 复制券码
setClipboard
(
e
)
{
const
code
=
e
.
currentTarget
.
dataset
.
code
wx
.
setClipboardData
({
data
:
code
,
success
(
res
)
{
wx
.
showToast
({
title
:
'复制成功'
,
})
// wx.getClipboardData({
// success(res) {
// console.log(res.data) // data
// }
// })
}
})
},
// 单个二维码 复制券码
onCodeCopy
:
function
()
{
wx
.
setClipboardData
({
data
:
this
.
data
.
codeInfo
.
codeNo
,
...
...
pages/pay/order-detail/order-detail.wxml
View file @
db659438
...
...
@@ -50,7 +50,7 @@
<view class="info-content col con-c">
<view class="info-content-item row">
<text class="info-content-item-label">使用门店</text>
<text class="info-content-item-title">{{
shopInfo.n
ame}}</text>
<text class="info-content-item-title">{{
orderInfo.officeN
ame}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label"></text>
...
...
@@ -66,19 +66,27 @@
<view class="info-content col con-c">
<view class="info-content-item row">
<text class="info-content-item-label">使用门店</text>
<text class="info-content-item-title">{{
shopInfo.n
ame}}</text>
<text class="info-content-item-title">{{
orderInfo.officeN
ame}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label"></text>
<text class="info-content-item-describe">周一至周日 10:00 - 20:00</text>
</view>
<view class="info-content-item row">
<
!-- <
view class="info-content-item row">
<text class="info-content-item-label">订单信息</text>
<text class="info-content-item-tip">儿童营地</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label"></text>
<text class="info-content-item-tip">18030303030</text>
</view> -->
<view class="info-content-item row">
<text class="info-content-item-label">订单信息</text>
<text class="info-content-item-tip">{{orderInfo.contactName}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label"></text>
<text class="info-content-item-tip">{{orderInfo.contactPhone}}</text>
</view>
</view>
<block wx:if="{{orderInfo.state===2}}">
...
...
@@ -96,9 +104,10 @@
</block>
</block>
<!-- 餐品 -->
<block wx:if="{{orderInfo.commodityType === 5}}">
<!-- 餐品 -->
<block wx:if="{{orderInfo.commodityType === 5||orderInfo.commodityType === 4}}">
<view class="info-content col con-c {{ orderInfo.state!==2?'p-relative':'' }}">
<view class="info-content-item row">
<text class="info-content-item-label">使用门店</text>
...
...
@@ -211,6 +220,13 @@
</block>
</view>
<view class="notice-wrapper row con-e" bindtap="handleNotice">
<view class="notice">使用须知</view>
<!-- <view class="notice">活动须知</view>
<view class="notice">观影须知</view> -->
<l-icon name="right" color="#959DAA" size="22" />
</view>
<!-- 商品信息 -->
<view class="commodity col">
<view class="commodity-title">
...
...
@@ -279,7 +295,7 @@
<view class="code-num-wrapper row align-c con-a">
<view class="code-num-title {{codeUsed ? 'code-used' : ''}}">券码{{index+1}}:</view>
<view class="code-num {{codeUsed ? 'code-used' : ''}}">{{item.serialNumber}}</view>
<view class="num-copy" wx:if="{{!codeUsed}}" bindtap="setClipboard" data-index="{{index}}">复制</view>
<view class="num-copy" wx:if="{{!codeUsed}}" bindtap="setClipboard" data-
code="{{item.serialNumber}}" data-
index="{{index}}">复制</view>
</view>
<view class="code-used-seal" wx:if="{{codeUsed}}">
<image mode="widthFix" src="./image/used.png"></image>
...
...
@@ -322,3 +338,13 @@
</view>
</view>
</view>
<!-- 使用须知 -->
<l-popup show="{{showNotice}}" content-align="bottom">
<view class="notice-popup-wrapper">
<view class="notice-popup-title">购买须知</view>
<scroll-view scroll-y class="notice-popup-content">
</scroll-view>
</view>
</l-popup>
\ No newline at end of file
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