Browse Source

no message

feature/v1.0
xpz2018 5 years ago
parent
commit
7b09eac2ce
3 changed files with 36 additions and 17 deletions
  1. 26
      pages/process/order-info/index.wxml
  2. 16
      pages/process/order-price/index.js
  3. 11
      pages/process/order-price/index.wxml

26
pages/process/order-info/index.wxml

@ -6,7 +6,7 @@
<view wx:if="{{form}}"> <view wx:if="{{form}}">
<view class="flex flex-center info_status" style="justify-content: flex-start;" wx:if="{{form.status == 2}}"> <view class="flex flex-center info_status" style="justify-content: flex-start;" wx:if="{{form.status == 2}}">
<image style="height:42rpx;width:42rpx" src="/assets/image/icon_uncheck.png"></image> <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 class="text-white text-sg" style="margin-left:12rpx">待过重</view>
</view> </view>
<view class="flex flex-center info_status" style="justify-content: flex-start;" wx:elif="{{form.status == 3}}"> <view class="flex flex-center info_status" style="justify-content: flex-start;" wx:elif="{{form.status == 3}}">
<image style="height:42rpx;width:42rpx" src="/assets/image/icon_uncheck.png"></image> <image style="height:42rpx;width:42rpx" src="/assets/image/icon_uncheck.png"></image>
@ -56,6 +56,18 @@
<view class="text-gray">{{form.netWeight}}</view> <view class="text-gray">{{form.netWeight}}</view>
</view> </view>
</van-cell> </van-cell>
<van-cell wx:if="{{form.deductWeight}}">
<view slot="title" class="flex flex-justify">
<view class="text-black">扣重(KG)</view>
<view class="text-gray">-{{form.deductWeight}}</view>
</view>
</van-cell>
<van-cell wx:if="{{form.deductPercent}}">
<view slot="title" class="flex flex-justify">
<view class="text-black">扣点(%)</view>
<view class="text-gray">{{form.deductPercent}}</view>
</view>
</van-cell>
<van-cell> <van-cell>
<view slot="title" class="flex flex-justify"> <view slot="title" class="flex flex-justify">
<view class="text-black">定价员</view> <view class="text-black">定价员</view>
@ -81,7 +93,7 @@
</view> </view>
</view> </view>
</van-cell> </van-cell>
<van-cell>
<van-cell wx:if="{{form.emptyWeighingPicture && form.emptyWeighingPicture.length}}">
<view slot="title" class="text-black"> <view slot="title" class="text-black">
<view>过皮重照片</view> <view>过皮重照片</view>
<view class="flex" style="margin-top:18rpx"> <view class="flex" style="margin-top:18rpx">
@ -104,13 +116,19 @@
</van-cell> </van-cell>
<van-cell> <van-cell>
<view slot="title" class="flex flex-justify"> <view slot="title" class="flex flex-justify">
<view class="text-black">金额(元)</view>
<view class="text-black">扣减金额(元)</view>
<view class="text-gray">{{form.deductPrice || ''}}</view>
</view>
</van-cell>
<van-cell>
<view slot="title" class="flex flex-justify">
<view class="text-black">结算金额(元)</view>
<view class="text-gray">{{form.settlePrice || ''}}</view> <view class="text-gray">{{form.settlePrice || ''}}</view>
</view> </view>
</van-cell> </van-cell>
<van-cell> <van-cell>
<view slot="title" class="flex flex-justify"> <view slot="title" class="flex flex-justify">
<view class="text-black">订单时间</view>
<view class="text-black">单时间</view>
<view class="text-gray">{{form.createTime || ''}}</view> <view class="text-gray">{{form.createTime || ''}}</view>
</view> </view>
</van-cell> </van-cell>

16
pages/process/order-price/index.js

@ -98,14 +98,14 @@ Page({
util.showToast('请输入单价') util.showToast('请输入单价')
return return
} }
if(this.data.deductType == 1 && (util.isEmpty(this.data.form.deductWeight) || Number(this.data.form.deductWeight) <= 0)){
util.showToast('请输入扣重')
return
}
if(this.data.deductType == 2 && (util.isEmpty(this.data.form.deductPercent) || Number(this.data.form.deductPercent) <= 0)){
util.showToast('请输入扣点')
return
}
// if(this.data.deductType == 1 && (util.isEmpty(this.data.form.deductWeight) || Number(this.data.form.deductWeight) <= 0)){
// util.showToast('请输入扣重')
// return
// }
// if(this.data.deductType == 2 && (util.isEmpty(this.data.form.deductPercent) || Number(this.data.form.deductPercent) <= 0)){
// util.showToast('请输入扣点')
// return
// }
wx.showLoading({ title: '处理中', mask: true }) wx.showLoading({ title: '处理中', mask: true })
var data = {id: this.data.form.id} var data = {id: this.data.form.id}
if(Number(this.data.form.deductWeight) > 0){ if(Number(this.data.form.deductWeight) > 0){

11
pages/process/order-price/index.wxml

@ -40,9 +40,8 @@
<van-cell> <van-cell>
<view slot="title" class="flex flex-justify"> <view slot="title" class="flex flex-justify">
<view class="flex flex-center text-black" data-type="1" bindtap="changeDeductType"> <view class="flex flex-center text-black" data-type="1" bindtap="changeDeductType">
<van-checkbox value="{{ deductType == 1 }}"></van-checkbox>
<van-checkbox value="{{ deductType == 1 }}" icon-size="32rpx"></van-checkbox>
<text style="margin-left:8rpx">扣重(KG)</text> <text style="margin-left:8rpx">扣重(KG)</text>
<text class="text-red text-xl">*</text>
</view> </view>
<input id="deductWeight" type="number" disabled="{{deductType == 2}}" placeholder-style="color:#aaa" style="text-align: right" maxlength="8" <input id="deductWeight" type="number" disabled="{{deductType == 2}}" placeholder-style="color:#aaa" style="text-align: right" maxlength="8"
placeholder="请输入扣重重量" value="{{form.deductWeight}}" bindinput="bindInput" /> placeholder="请输入扣重重量" value="{{form.deductWeight}}" bindinput="bindInput" />
@ -51,9 +50,8 @@
<van-cell> <van-cell>
<view slot="title" class="flex flex-justify"> <view slot="title" class="flex flex-justify">
<view class="flex flex-center text-black" data-type="2" bindtap="changeDeductType"> <view class="flex flex-center text-black" data-type="2" bindtap="changeDeductType">
<van-checkbox value="{{ deductType == 2 }}"></van-checkbox>
<van-checkbox value="{{ deductType == 2 }}" icon-size="32rpx"></van-checkbox>
<text style="margin-left:8rpx">扣点(%)</text> <text style="margin-left:8rpx">扣点(%)</text>
<text class="text-red text-xl">*</text>
</view> </view>
<input id="deductPercent" type="number" disabled="{{deductType == 1}}" placeholder-style="color:#aaa" style="text-align: right" maxlength="8" <input id="deductPercent" type="number" disabled="{{deductType == 1}}" placeholder-style="color:#aaa" style="text-align: right" maxlength="8"
placeholder="请输入扣点比例" value="{{form.deductPercent}}" bindinput="bindInput" /> placeholder="请输入扣点比例" value="{{form.deductPercent}}" bindinput="bindInput" />
@ -62,7 +60,10 @@
<van-cell bind:click="paddingOrder"> <van-cell bind:click="paddingOrder">
<view slot="title" class="flex flex-justify"> <view slot="title" class="flex flex-justify">
<view class="text-black">是否无皮过磅</view> <view class="text-black">是否无皮过磅</view>
<van-checkbox value="{{ form.isWithoutTare }}"></van-checkbox>
<view class="flex flex-center">
<van-checkbox value="{{ form.isWithoutTare }}" icon-size="32rpx"></van-checkbox>
<view class="text-gray" style="margin-left:8rpx">{{ form.isWithoutTare ? '是' : '否'}}</view>
</view>
</view> </view>
</van-cell> </van-cell>
<van-index-anchor index="过磅信息" /> <van-index-anchor index="过磅信息" />

Loading…
Cancel
Save