34 changed files with 829 additions and 122 deletions
Split View
Diff Options
-
3app.json
-
BINassets/image/icon-finace.png
-
BINassets/image/icon-payment.png
-
BINassets/image/icon_checking.png
-
BINassets/image/icon_close.png
-
BINassets/image/icon_finish.png
-
BINassets/image/icon_payment.png
-
BINassets/image/icon_pricing.png
-
BINassets/image/icon_uncheck.png
-
BINassets/image/tabbar/mall-blue.png
-
BINassets/image/tabbar/mall-gray.png
-
90components/vehicle-keyboard/index.js
-
6components/vehicle-keyboard/index.json
-
33components/vehicle-keyboard/index.wxml
-
113components/vehicle-keyboard/index.wxss
-
5pages/api/request.js
-
4pages/api/saas.js
-
9pages/index/index.js
-
70pages/login/index.js
-
2pages/login/index.wxml
-
73pages/process/index/index.js
-
30pages/process/index/index.wxml
-
59pages/process/order-check/index.js
-
12pages/process/order-check/index.json
-
94pages/process/order-check/index.wxml
-
4pages/process/order-check/index.wxss
-
59pages/process/order-info/index.js
-
10pages/process/order-info/index.json
-
118pages/process/order-info/index.wxml
-
10pages/process/order-info/index.wxss
-
94pages/process/order-list/index.js
-
12pages/process/order-list/index.json
-
40pages/process/order-list/index.wxml
-
1pages/process/order-list/index.wxss
@ -0,0 +1,90 @@ |
|||
Component({ |
|||
options: { |
|||
addGlobalClass: true, |
|||
}, |
|||
properties: { |
|||
plateNumber: { |
|||
type: Array, |
|||
value: ["", "", "", "", "", "", ""] |
|||
}, |
|||
safeBottom: { |
|||
type: Number, |
|||
value: 0 |
|||
} |
|||
}, |
|||
data: { |
|||
provinces: "京津沪冀豫云辽黑湘皖鲁新苏浙赣鄂桂甘晋蒙陕吉闽贵粤川青藏琼宁渝港澳台", |
|||
letters: "ABCDEFGHIJKLMNOPQRSTUVWXYZ", |
|||
numbers: "0123456789", |
|||
visible: false, |
|||
activeIndex: -1, |
|||
type: 0, |
|||
disabled: true, |
|||
mode: 0 // 键盘模式 0 关闭状态 1 显示省份输入 2 显示数字和字母输入
|
|||
}, |
|||
lifetimes: { |
|||
attached: function () { |
|||
|
|||
}, |
|||
}, |
|||
methods: { |
|||
show: function (number, type) { |
|||
var index = 0 |
|||
if(number && number.length){ |
|||
this.data.plateNumber = number.split('') |
|||
index = this.data.plateNumber.length - 1 |
|||
} |
|||
this.data.type = type |
|||
this.updateNumber() |
|||
this.setData({ plateNumber: this.data.plateNumber, mode: index == 0 ? 1 : 2, activeIndex: index, visible: true}) |
|||
}, |
|||
hide: function () { |
|||
this.setData({visible: false, plateNumber: ["", "", "", "", "", "", ""]}) |
|||
this.triggerEvent("change", null) |
|||
}, |
|||
updateNumber: function(){ |
|||
this.data.disabled = false |
|||
for (let index = 0; index < this.data.plateNumber.length; index++) { |
|||
const element = this.data.plateNumber[index] |
|||
if(element.length == 0){ |
|||
this.data.disabled = true |
|||
break |
|||
} |
|||
} |
|||
this.setData({disabled: this.data.disabled, plateNumber: this.data.plateNumber}) |
|||
}, |
|||
inputKeyboard: function(e){ |
|||
let index = typeof e === 'number' ? e : e.currentTarget.dataset.index |
|||
if(e.currentTarget && this.data.plateNumber[index].length == 0){ |
|||
return |
|||
} |
|||
this.setData({ mode: index == 0 ? 1 : 2, activeIndex: index }) |
|||
}, |
|||
tapDelete: function(e){ |
|||
let activeIndex = this.data.activeIndex |
|||
this.data.plateNumber[activeIndex] = '' |
|||
this.updateNumber() |
|||
if (activeIndex > 0) { |
|||
this.inputKeyboard(--activeIndex) |
|||
} |
|||
}, |
|||
tapFinish: function(){ |
|||
if(this.data.disabled){ |
|||
return |
|||
} |
|||
this.setData({visible: false, activeIndex: -1 }) |
|||
this.triggerEvent("change", {plateNumber: this.data.plateNumber.join(''), type: this.data.type}) |
|||
}, |
|||
tapKeyboard: function(e){ |
|||
let val = e.currentTarget.dataset.val |
|||
let activeIndex = this.data.activeIndex |
|||
this.data.plateNumber[activeIndex] = val |
|||
this.updateNumber() |
|||
if (activeIndex < 6) { |
|||
this.inputKeyboard(++activeIndex) |
|||
} else { |
|||
this.tapFinish() |
|||
} |
|||
}, |
|||
} |
|||
}) |
|||
@ -0,0 +1,6 @@ |
|||
{ |
|||
"component": true, |
|||
"usingComponents": { |
|||
"van-popup": "../popup/index" |
|||
} |
|||
} |
|||
@ -0,0 +1,33 @@ |
|||
<van-popup position="bottom" show="{{ visible }}" bind:close="hide" z-index="29"> |
|||
<view class="flex flex-justify license-number" style="padding:24rpx 32rpx"> |
|||
<view class="item {{activeIndex == 0 ? 'active':''}}" bindtap="inputKeyboard" data-index="0">{{plateNumber[0]}}</view> |
|||
<view class="item {{activeIndex == 1 ? 'active':''}}" bindtap="inputKeyboard" data-index="1">{{plateNumber[1]}}</view> |
|||
<view class="item item-dot"><view class="dot"></view></view> |
|||
<view class="item {{activeIndex == 2 ? 'active':''}}" bindtap="inputKeyboard" data-index="2">{{plateNumber[2]}}</view> |
|||
<view class="item {{activeIndex == 3 ? 'active':''}}" bindtap="inputKeyboard" data-index="3">{{plateNumber[3]}}</view> |
|||
<view class="item {{activeIndex == 4 ? 'active':''}}" bindtap="inputKeyboard" data-index="4">{{plateNumber[4]}}</view> |
|||
<view class="item {{activeIndex == 5 ? 'active':''}}" bindtap="inputKeyboard" data-index="5">{{plateNumber[5]}}</view> |
|||
<view class="item {{activeIndex == 6 ? 'active':''}}" bindtap="inputKeyboard" data-index="6">{{plateNumber[6]}}</view> |
|||
</view> |
|||
<view class="kb-keyboard" style="background: #d9d9d9"> |
|||
<view class="kb-keyboard-provs flex-brick" hidden="{{!(mode==1)}}"> |
|||
<view class="kb-keyboard_td" wx:for="{{provinces}}" bindtap="tapKeyboard" data-val="{{item}}" wx:key="index"> {{item}}</view> |
|||
</view> |
|||
<view class="kb-keyboard-nums flex-brick" hidden="{{!(mode==2)}}"> |
|||
<view class="kb-keyboard_td {{activeIndex == 1 ? 'disabled' : '' }}" wx:for="{{numbers}}" bindtap="tapKeyboard" |
|||
data-val="{{item}}" wx:key="index">{{item}}</view> |
|||
</view> |
|||
<view class="kb-keyboard-letters flex-brick" hidden="{{!(mode==2)}}"> |
|||
<view class="kb-keyboard_td {{activeIndex < 1 ? 'disabled' : '' }}" wx:for="{{letters}}" |
|||
bindtap="tapKeyboard" data-val="{{item}}" wx:key="index">{{item}}</view> |
|||
</view> |
|||
|
|||
<view class="kb-keyboard-action flex-brick"> |
|||
<view class="kb-keyboard_td kb-keyboard__del {{activeIndex == 0 && !plateNumber[0] ? 'disabled':''}}" bindtap="tapDelete"> |
|||
<view class="ico-del"></view> |
|||
</view> |
|||
<view class="kb-keyboard_td kb-keyboard__finished {{disabled ? 'disabled':''}}" bindtap="tapFinish">确定</view> |
|||
</view> |
|||
</view> |
|||
<view style="height:{{safeBottom}}rpx"></view> |
|||
</van-popup> |
|||
@ -0,0 +1,113 @@ |
|||
|
|||
.license-number .item { |
|||
width: 64rpx; |
|||
height: 72rpx; |
|||
line-height: 72rpx; |
|||
text-align: center; |
|||
border: 1rpx solid #999590; |
|||
border-radius: 8rpx; |
|||
display: flex; |
|||
font-size: 28rpx; |
|||
align-items: center; |
|||
justify-content: center; |
|||
} |
|||
.license-number .item.item-new-energy { |
|||
line-height: 1em; |
|||
display: flex; |
|||
align-items: center; |
|||
border: 1rpx dashed #999590; |
|||
} |
|||
.license-number .item.item-new-energy .ico { |
|||
line-height: 1em; |
|||
font-size: 36rpx; |
|||
margin-bottom: -5rpx; |
|||
color: #777; |
|||
} |
|||
.license-number .item.item-new-energy .tit { |
|||
font-size: 12px; |
|||
transform: scale(0.7); |
|||
color: #777; |
|||
} |
|||
|
|||
.license-number .item.active { |
|||
border: 1rpx solid #008AFF; |
|||
color:#008AFF; |
|||
} |
|||
|
|||
.license-number .item.item-dot { |
|||
border: none; |
|||
width: auto; |
|||
padding: 0 6rpx; |
|||
} |
|||
.license-number .item.item-dot .dot { |
|||
width: 12rpx; |
|||
height: 12rpx; |
|||
background: #a09c96; |
|||
border-radius: 10rpx; |
|||
} |
|||
|
|||
.kb-keyboard { |
|||
padding: 6rpx; |
|||
position: relative; |
|||
} |
|||
.flex-brick { |
|||
display: flex; |
|||
flex-flow: row wrap; |
|||
} |
|||
.kb-keyboard-action { |
|||
display: flex; |
|||
justify-content: space-between; |
|||
position: absolute; |
|||
bottom: 6rpx; |
|||
right: 6rpx; |
|||
} |
|||
.kb-keyboard_td { |
|||
color: #1e1e1e; |
|||
box-shadow: 1rpx 1rpx 1rpx #919191; |
|||
background: #fff; |
|||
display: flex; |
|||
align-items: center; |
|||
justify-content: center; |
|||
width: calc((100vw - 12rpx) / 10 - 12rpx); |
|||
font-size: 18px; |
|||
height: 48px; |
|||
margin: 6rpx; |
|||
border-radius:5px; |
|||
} |
|||
|
|||
.kb-keyboard_td.disabled { |
|||
opacity: 0.5; |
|||
pointer-events: none; |
|||
} |
|||
|
|||
.kb-keyboard_td:active { |
|||
background: #f2f2f2; |
|||
} |
|||
.kb-keyboard__del { |
|||
align-self: flex-end; |
|||
width: calc(((100vw - 12rpx) / 10 - 12rpx) * 1.8); |
|||
height: 48px; |
|||
display: flex; |
|||
justify-content: center; |
|||
align-items: center; |
|||
padding-right: 1rpx; |
|||
} |
|||
.kb-keyboard__del .ico-del { |
|||
width: 44rpx; |
|||
height: 30rpx; |
|||
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACwAAAAeCAMAAABg6AyVAAAAclBMVEUAAAAwMDAxMTEMDAwpKSkpKSkwMDAqKioxMTExMTEpKSkqKiokJCQpKSkpKSkqKioqKioqKioqKioqKiopKSkoKCgoKCgnJycqKioqKioqKioqKioqKioqKioqKiorKysrKysoKCgqKioAAAAlJSUqKipvWYGQAAAAJXRSTlMA/lcC+OyZhmk+lioH8OXd1MlOPzQZDCDcvr2ysaWjajsTEgEiwq/YugAAAM9JREFUOMud1McWgyAQBdABKxp7S+/v/38xDUPAY/DwNs7iLoQZhoycCswkiFY69RL8SaTbA/yaZnJGQD9Z7ZA1NBuAVPoNgpaW4UuFPKVluCuxHmgZHgqUnTxmHAqSEWHsTXCao7rKOmaM8U/Jn2Vs4jbAtieZkL30aFlo4CbDXrVHsLeWlgkd1z6O3teOiMsPaZj7SG5EE62swqkvm25qZRWOkNAkfLTu2P4bzge0X51rU+ztdh0kmbtlRC3D7/Cs3B+s6yqwLxnX9WVfjA8P3SLCPZZ7QgAAAABJRU5ErkJggg==); |
|||
background-size: 100% 100%; |
|||
} |
|||
.kb-keyboard__finished { |
|||
width: calc(((100vw - 12rpx) / 10 - 12rpx) * 1.8); |
|||
} |
|||
|
|||
|
|||
@keyframes breath { |
|||
from { |
|||
border-color:rgba(11, 245, 183, 0.3); |
|||
} |
|||
40% { border-color: #0bf5b7c2; } |
|||
60% { border-color: #0bf5b7c2; } |
|||
to { border-color: rgba(11, 245, 183, 0.3); } |
|||
} |
|||
@ -0,0 +1,59 @@ |
|||
// pages/process/order-check/index.js
|
|||
import Dialog from '../../../components/dialog/dialog' |
|||
const app = getApp() |
|||
|
|||
Page({ |
|||
/** |
|||
* 页面的初始数据 |
|||
*/ |
|||
data: { |
|||
safeBottom: app.globalData.safeBottom, |
|||
form: { |
|||
plateNumber: null |
|||
} |
|||
}, |
|||
/** |
|||
* 生命周期函数--监听页面加载 |
|||
*/ |
|||
onLoad: function (options) { |
|||
this.setData({ |
|||
safeBottom: app.globalData.safeBottom |
|||
}) |
|||
}, |
|||
showPlate: function (e) { |
|||
this.keyboard = this.keyboard || this.selectComponent('#wux-keyboard') |
|||
this.keyboard.show(this.data.form.plateNumber, 0) |
|||
}, |
|||
onPlatenumber: function({detail}){ |
|||
if(detail && detail.plateNumber){ |
|||
this.setData({ ['form.plateNumber']: detail.plateNumber }) |
|||
} |
|||
}, |
|||
showCategory: function(){ |
|||
|
|||
}, |
|||
bindInput: function (e) { |
|||
this.data.form[e.target.id] = e.detail.value |
|||
}, |
|||
onChange: function({ detail }) { |
|||
// 需要手动对 checked 状态进行更新
|
|||
this.setData({ ['form.isDefault']: detail ? 1 : 0 }) |
|||
}, |
|||
paddingOrder: function(){ |
|||
this.setData({ ['form.checking']: !this.data.form.checking }) |
|||
}, |
|||
cancelOrder: function(e){ |
|||
Dialog.confirm({ title: '温馨提示', message: '确定取消该订单?' }).then(() => { |
|||
}) |
|||
}, |
|||
viewImage: function (e) { |
|||
var imgList = [] |
|||
for (let index = 0; index < this.data.imgList.length; index++) { |
|||
if (this.data.imgList[index].indexOf('.mp4') >= 0) { |
|||
continue |
|||
} |
|||
imgList.push(this.data.imgList[index]) |
|||
} |
|||
wx.previewImage({ urls: imgList, current: e.currentTarget.dataset.url }) |
|||
} |
|||
}) |
|||
@ -0,0 +1,12 @@ |
|||
{ |
|||
"usingComponents": { |
|||
"van-index-anchor": "/components/index-anchor/index", |
|||
"van-cell": "/components/cell/index", |
|||
"van-button": "/components/button/index", |
|||
"van-checkbox": "/components/checkbox/index", |
|||
"van-loading": "/components/loading/index", |
|||
"van-image": "/components/image/index", |
|||
"van-dialog": "/components/dialog/index", |
|||
"vehicle-keyboard": "/components/vehicle-keyboard/index" |
|||
} |
|||
} |
|||
@ -0,0 +1,94 @@ |
|||
<!--pages/process/order-check/index.wxml--> |
|||
<cu-custom bgColor="bg-white" isBack="{{true}}"> |
|||
<view slot="content">定价详情</view> |
|||
</cu-custom> |
|||
|
|||
<van-index-anchor index="订单信息" /> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">客户姓名</view> |
|||
<view class="text-gray">客户姓名</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell bind:click="showPlate"> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">车牌号码</view> |
|||
<view class="text-gray">{{form.plateNumber || '请输入车牌号码'}}</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell bind:click="showCategory"> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black"> |
|||
<text>废纸品类</text> |
|||
<text class="text-red text-xl">*</text> |
|||
</view> |
|||
<view class="text-gray">请选择废纸品类</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-index-anchor index="定价信息" /> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black"> |
|||
<text>单价(元/KG)</text> |
|||
<text class="text-red text-xl">*</text> |
|||
</view> |
|||
<input id="price" type="number" placeholder-style="color:#aaa" style="text-align: right" maxlength="8" |
|||
placeholder="请输单价" value="{{form.price}}" bindinput="bindInput" /> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black"> |
|||
<text>扣重(KG)</text> |
|||
<text class="text-red text-xl">*</text> |
|||
</view> |
|||
<input id="weight" type="number" placeholder-style="color:#aaa" style="text-align: right" maxlength="8" |
|||
placeholder="请输入扣重重量" value="{{form.account}}" bindinput="bindInput" /> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black"> |
|||
<text>扣点(%)</text> |
|||
<text class="text-red text-xl">*</text> |
|||
</view> |
|||
<input id="weight" type="number" placeholder-style="color:#aaa" style="text-align: right" maxlength="8" |
|||
placeholder="请输入扣点比例" value="{{form.account}}" bindinput="bindInput" /> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell bind:click="paddingOrder"> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">是否无皮过磅</view> |
|||
<van-checkbox value="{{ form.checking }}"></van-checkbox> |
|||
</view> |
|||
</van-cell> |
|||
<van-index-anchor index="过磅信息" /> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">毛重(KG)</view> |
|||
<view class="text-gray">2000.00</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black"> |
|||
<view>过毛重照片</view> |
|||
<view class="flex" style="margin-top:18rpx"></view> |
|||
<van-image use-loading-slot width="100" height="100" custom-class="page-icon" src="{{'https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fa3.att.hudong.com%2F02%2F38%2F01300000237560123245382609951.jpg&refer=http%3A%2F%2Fa3.att.hudong.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=jpeg?sec=1613740606&t=80056f95b1e837a4d0f770c72a09cfe5'}}" bind:click="viewImage"> |
|||
<view class="image-load" slot="loading"><van-loading type="spinner" size="32" /></view> |
|||
</van-image> |
|||
<van-image use-loading-slot width="100" height="100" custom-class="page-icon" src="{{'https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fa3.att.hudong.com%2F02%2F38%2F01300000237560123245382609951.jpg&refer=http%3A%2F%2Fa3.att.hudong.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=jpeg?sec=1613740606&t=80056f95b1e837a4d0f770c72a09cfe5'}}" bind:click="viewImage"> |
|||
<view class="image-load" slot="loading"><van-loading type="spinner" size="32" /></view> |
|||
</van-image> |
|||
</view> |
|||
</view> |
|||
</van-cell> |
|||
|
|||
<view style="height:{{136 + safeBottom}}rpx;"></view> |
|||
<view class="cu-bar bg-white foot" style="height:{{120 + safeBottom}}rpx;padding:0rpx 32rpx {{safeBottom}}rpx 32rpx;" wx:if="{{form}}"> |
|||
<van-button plain type="default" custom-style="height:88rpx;width:254rpx" bind:click="cancelOrder">取消</van-button> |
|||
<van-button type="info" custom-style="margin-left:32rpx;height:88rpx;width:400rpx" bind:click="priceOrder">提交</van-button> |
|||
</view> |
|||
|
|||
<van-dialog id="van-dialog" /> |
|||
<vehicle-keyboard id="wux-keyboard" safeBottom="{{safeBottom}}" bind:change="onPlatenumber"></vehicle-keyboard> |
|||
@ -0,0 +1,4 @@ |
|||
/* pages/process/order-check/index.wxss */ |
|||
.page-icon { |
|||
margin-right: 24rpx; |
|||
} |
|||
@ -0,0 +1,59 @@ |
|||
// pages/process/order-check/index.js
|
|||
import Dialog from '../../../components/dialog/dialog' |
|||
const app = getApp() |
|||
|
|||
Page({ |
|||
/** |
|||
* 页面的初始数据 |
|||
*/ |
|||
data: { |
|||
safeBottom: app.globalData.safeBottom, |
|||
form: { |
|||
plateNumber: null |
|||
} |
|||
}, |
|||
/** |
|||
* 生命周期函数--监听页面加载 |
|||
*/ |
|||
onLoad: function (options) { |
|||
this.setData({ |
|||
safeBottom: app.globalData.safeBottom |
|||
}) |
|||
}, |
|||
showPlate: function (e) { |
|||
this.keyboard = this.keyboard || this.selectComponent('#wux-keyboard') |
|||
this.keyboard.show(this.data.form.plateNumber, 0) |
|||
}, |
|||
onPlatenumber: function({detail}){ |
|||
if(detail && detail.plateNumber){ |
|||
this.setData({ ['form.plateNumber']: detail.plateNumber }) |
|||
} |
|||
}, |
|||
showCategory: function(){ |
|||
|
|||
}, |
|||
bindInput: function (e) { |
|||
this.data.form[e.target.id] = e.detail.value |
|||
}, |
|||
onChange: function({ detail }) { |
|||
// 需要手动对 checked 状态进行更新
|
|||
this.setData({ ['form.isDefault']: detail ? 1 : 0 }) |
|||
}, |
|||
paddingOrder: function(){ |
|||
this.setData({ ['form.checking']: !this.data.form.checking }) |
|||
}, |
|||
cancelOrder: function(e){ |
|||
Dialog.confirm({ title: '温馨提示', message: '确定取消该订单?' }).then(() => { |
|||
}) |
|||
}, |
|||
viewImage: function (e) { |
|||
var imgList = [] |
|||
for (let index = 0; index < this.data.imgList.length; index++) { |
|||
if (this.data.imgList[index].indexOf('.mp4') >= 0) { |
|||
continue |
|||
} |
|||
imgList.push(this.data.imgList[index]) |
|||
} |
|||
wx.previewImage({ urls: imgList, current: e.currentTarget.dataset.url }) |
|||
} |
|||
}) |
|||
@ -0,0 +1,10 @@ |
|||
{ |
|||
"usingComponents": { |
|||
"van-index-anchor": "/components/index-anchor/index", |
|||
"van-cell": "/components/cell/index", |
|||
"van-button": "/components/button/index", |
|||
"van-loading": "/components/loading/index", |
|||
"van-image": "/components/image/index", |
|||
"van-dialog": "/components/dialog/index" |
|||
} |
|||
} |
|||
@ -0,0 +1,118 @@ |
|||
<!--pages/process/order-check/index.wxml--> |
|||
<cu-custom bgColor="bg-white" isBack="{{true}}"> |
|||
<view slot="content">过磅详情</view> |
|||
</cu-custom> |
|||
<view class="flex flex-center info_status" style="justify-content: flex-start;"> |
|||
<image style="height:42rpx;width:42rpx" src="/assets/image/icon_uncheck.png"></image> |
|||
<view class="text-white text-sg" style="margin-left:12rpx">待过磅审核</view> |
|||
</view> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">客户姓名</view> |
|||
<view class="text-gray">刘财顺</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">车牌号码</view> |
|||
<view class="text-gray">{{form.plateNumber || '请输入车牌号码'}}</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">废纸品类</view> |
|||
<view class="text-gray">黄纸板</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">毛重(KG)</view> |
|||
<view class="text-gray">黄纸板</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">皮重(KG)</view> |
|||
<view class="text-gray">黄纸板</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">净重(KG)</view> |
|||
<view class="text-gray">黄纸板</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">定价员</view> |
|||
<view class="text-gray">黄纸板</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">定价时间</view> |
|||
<view class="text-gray">2021年1月20日 21:46:27</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black"> |
|||
<view>过毛重照片</view> |
|||
<view class="flex" style="margin-top:18rpx"></view> |
|||
<van-image use-loading-slot width="100" height="100" custom-class="page-icon" src="{{'https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fa3.att.hudong.com%2F02%2F38%2F01300000237560123245382609951.jpg&refer=http%3A%2F%2Fa3.att.hudong.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=jpeg?sec=1613740606&t=80056f95b1e837a4d0f770c72a09cfe5'}}" bind:click="viewImage"> |
|||
<view class="image-load" slot="loading"><van-loading type="spinner" size="32" /></view> |
|||
</van-image> |
|||
<van-image use-loading-slot width="100" height="100" custom-class="page-icon" src="{{'https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fa3.att.hudong.com%2F02%2F38%2F01300000237560123245382609951.jpg&refer=http%3A%2F%2Fa3.att.hudong.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=jpeg?sec=1613740606&t=80056f95b1e837a4d0f770c72a09cfe5'}}" bind:click="viewImage"> |
|||
<view class="image-load" slot="loading"><van-loading type="spinner" size="32" /></view> |
|||
</van-image> |
|||
</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black"> |
|||
<view>过皮重照片</view> |
|||
<view class="flex" style="margin-top:18rpx"></view> |
|||
<van-image use-loading-slot width="100" height="100" custom-class="page-icon" src="{{'https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fa3.att.hudong.com%2F02%2F38%2F01300000237560123245382609951.jpg&refer=http%3A%2F%2Fa3.att.hudong.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=jpeg?sec=1613740606&t=80056f95b1e837a4d0f770c72a09cfe5'}}" bind:click="viewImage"> |
|||
<view class="image-load" slot="loading"><van-loading type="spinner" size="32" /></view> |
|||
</van-image> |
|||
<van-image use-loading-slot width="100" height="100" custom-class="page-icon" src="{{'https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fa3.att.hudong.com%2F02%2F38%2F01300000237560123245382609951.jpg&refer=http%3A%2F%2Fa3.att.hudong.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=jpeg?sec=1613740606&t=80056f95b1e837a4d0f770c72a09cfe5'}}" bind:click="viewImage"> |
|||
<view class="image-load" slot="loading"><van-loading type="spinner" size="32" /></view> |
|||
</van-image> |
|||
</view> |
|||
</view> |
|||
</van-cell> |
|||
|
|||
<van-index-anchor index="订单信息" /> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">单价(元/KG)</view> |
|||
<view class="text-gray">1.80</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">金额(元)</view> |
|||
<view class="text-gray">47001.80</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">订单时间</view> |
|||
<view class="text-gray">2021年1月20日 21:46:27</view> |
|||
</view> |
|||
</van-cell> |
|||
<van-cell> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view class="text-black">订单编号</view> |
|||
<view class="text-gray">XXP123456709978957</view> |
|||
</view> |
|||
</van-cell> |
|||
|
|||
<view style="height:{{136 + safeBottom}}rpx;"></view> |
|||
<view class="cu-bar bg-white foot" style="height:{{120 + safeBottom}}rpx;padding:0rpx 32rpx {{safeBottom}}rpx 32rpx;" wx:if="{{form}}"> |
|||
<van-button plain type="default" custom-style="height:88rpx;width:254rpx" bind:click="cancelOrder">重新过皮重</van-button> |
|||
<van-button type="info" custom-style="margin-left:32rpx;height:88rpx;width:400rpx" bind:click="priceOrder">通过审核</van-button> |
|||
</view> |
|||
|
|||
<van-dialog id="van-dialog" /> |
|||
@ -0,0 +1,10 @@ |
|||
/* pages/process/order-check/index.wxss */ |
|||
.page-icon { |
|||
margin-right: 24rpx; |
|||
} |
|||
|
|||
.info_status{ |
|||
background-image: linear-gradient(90deg, #FF4D2E 6%, #FF952F 100%); |
|||
height:90rpx; |
|||
padding: 0rpx 32rpx; |
|||
} |
|||
@ -0,0 +1,94 @@ |
|||
// pages/process/order-list/index.js
|
|||
import Dialog from '../../../components/dialog/dialog' |
|||
import { getOrderList, cancelOrder, receiptOrder} from "../../api/saas" |
|||
const event = require('../../../utils/event') |
|||
const util = require('../../../utils/util') |
|||
const app = getApp() |
|||
|
|||
Page({ |
|||
|
|||
/** |
|||
* 页面的初始数据 |
|||
*/ |
|||
data: { |
|||
height: app.globalData.fragmentHeight, |
|||
loading: true, |
|||
requesting: false, |
|||
finished: false, |
|||
top: 0, |
|||
orderList: [], |
|||
form: { |
|||
status: 0, |
|||
pageNum: 1 |
|||
} |
|||
}, |
|||
/** |
|||
* 生命周期函数--监听页面加载 |
|||
*/ |
|||
onLoad: function (options) { |
|||
if(options.status){ |
|||
this.data.form.status = Number(options.status) |
|||
} |
|||
this.setData({ height: app.globalData.fragmentHeight }) |
|||
this.fetchOrderList() |
|||
}, |
|||
onRefreshList: function () { |
|||
this.setData({ |
|||
orderList: [], |
|||
['form.pageNum']: 1, |
|||
loading: true, |
|||
finished: false |
|||
}) |
|||
this.fetchOrderList() |
|||
}, |
|||
fetchOrderList: function () { |
|||
if (this.data.requesting || this.data.finished) { |
|||
return |
|||
} |
|||
if (this.data.loading) { |
|||
this.data.requesting = true |
|||
} else { |
|||
this.setData({ requesting: true }) |
|||
} |
|||
getOrderList(this.data.form).then(result => { |
|||
if (result.data.records.length) { |
|||
var respList = result.data.records |
|||
let nowList = `orderList[${this.data.orderList.length}]` |
|||
var num = this.data.form.pageNum |
|||
var finished = ((num - 1) * this.data.form.pageSize + respList.length) >= result.data.total |
|||
if(this.data.form.pageNum == 1){ |
|||
this.setData({ |
|||
[nowList]: respList, |
|||
['form.pageNum']: (num + 1), |
|||
top: 0, |
|||
finished, |
|||
requesting: false, |
|||
loading: false |
|||
}) |
|||
} else { |
|||
this.setData({ |
|||
[nowList]: respList, |
|||
['form.pageNum']: (num + 1), |
|||
finished, |
|||
requesting: false, |
|||
loading: false |
|||
}) |
|||
} |
|||
} else { |
|||
this.setData({ finished: true, requesting: false, loading: false }) |
|||
} |
|||
}).catch(err => { |
|||
//异常回调
|
|||
this.setData({ requesting: false, loading: false }) |
|||
util.showToast(err) |
|||
}) |
|||
}, |
|||
cancelOrder: function(e){ |
|||
Dialog.confirm({ title: '温馨提示', message: '确定取消该订单?' }).then(() => { |
|||
}) |
|||
}, |
|||
priceOrder: function(e){ |
|||
wx.navigateTo({ url: '/pages/process/order-info/index?id=' }) |
|||
} |
|||
|
|||
}) |
|||
@ -0,0 +1,12 @@ |
|||
{ |
|||
"usingComponents": { |
|||
"refresh-view": "/components/refresher/index", |
|||
"van-button": "/components/button/index", |
|||
"van-index-bar": "/components/index-bar/index", |
|||
"van-index-anchor": "/components/index-anchor/index", |
|||
"van-cell": "/components/cell/index", |
|||
"van-divider": "/components/divider/index", |
|||
"van-loading": "/components/loading/index", |
|||
"van-dialog": "/components/dialog/index" |
|||
} |
|||
} |
|||
@ -0,0 +1,40 @@ |
|||
<!--pages/process/order-list/index.wxml--> |
|||
<cu-custom bgColor="bg-white" isBack="{{true}}"> |
|||
<view slot="content">定价列表</view> |
|||
</cu-custom> |
|||
|
|||
<refresh-view bind:refresh="onRefreshList" height="{{height}}" triggered="{{requesting}}" scrollTop="{{top}}" bind:scrolltolower="fetchOrderList"> |
|||
<view class="list-empty" style="height:{{height}}rpx" wx:if="{{!orderList.length}}"> |
|||
<view style="margin-bottom:24px" wx:if="{{loading}}"> |
|||
<van-loading type="spinner" size="32" /> |
|||
</view> |
|||
<image class="img-empty" src="/assets/image/list_empty.png" wx:else></image> |
|||
<view class="text-empty">{{loading? '正在加载' : '暂无数据'}}</view> |
|||
</view> |
|||
<van-index-bar index-list="{{null}}" wx:else> |
|||
<view wx:for="{{6}}" wx:key="index"> |
|||
<van-index-anchor index="01月13日" /> |
|||
<van-cell wx:for="{{4}}" wx:key="index"> |
|||
<view slot="title" class="flex flex-justify"> |
|||
<view> |
|||
<view class="text-sg text-black">客户名称:刘财顺</view> |
|||
<view class="text-sm text-gray">毛重:2000.00KG</view> |
|||
</view> |
|||
<view class="flex flex-center"> |
|||
<van-button plain type="default" custom-style="height:64rpx;width:132rpx" bind:click="cancelOrder">取消 |
|||
</van-button> |
|||
<van-button plain type="info" custom-style="margin-left:24rpx;height:64rpx;width:132rpx" |
|||
bind:click="priceOrder">定价</van-button> |
|||
</view> |
|||
</view> |
|||
</van-cell> |
|||
</view> |
|||
</van-index-bar> |
|||
<!--加载更多的UI--> |
|||
<van-divider content-position="center" wx:if="{{ form.pageNum > 1}}" custom-style="padding:0rpx 120rpx"> |
|||
<van-loading type="spinner" size="16" wx:if="{{!finished}}" /> |
|||
<text class="text-sm" style="margin-left:8rpx">{{finished?'到底啦~':'加载中...'}}</text> |
|||
</van-divider> |
|||
</refresh-view> |
|||
|
|||
<van-dialog id="van-dialog" /> |
|||
@ -0,0 +1 @@ |
|||
/* pages/process/order-list/index.wxss */ |
|||
Write
Preview
Loading…
Cancel
Save