浏览代码

都能运app xu

xuwenqiang1992 2 年之前
父节点
当前提交
b72bee8c68

+ 1 - 1
common/libs/request.js

@@ -2,7 +2,7 @@ const devBaseUrl = "http://192.168.1.24:51106";
 const proBaseUrl = "http://192.168.1.24:51106";
 //const proBaseUrl = "http://61.163.210.202:39510";
 // const devBaseUrl = "http://218.3.230.230:39510";
-// const proBaseUrl = "http://218.3.230.230:39510"; 
+// const proBaseUrl = "http://218.3.230.230:39510";
 
 
 const httpGet = (url, data, checkToken = true) => {

+ 20 - 2
pages.json

@@ -26,10 +26,28 @@
 
 		},
 		{
-			"path" : "pages/feedback/scanOrderCode",
+			"path" : "pages/feedback/signOrderCode",
 			"style" :
 			{
-				"navigationBarTitleText": "扫码装车",
+				"navigationBarTitleText": "扫码签收",
+				"enablePullDownRefresh": true
+			}
+
+		},
+		{
+			"path" : "pages/order/recordOrder",
+			"style" :
+			{
+				"navigationBarTitleText": "签收记录",
+				"enablePullDownRefresh": true
+			}
+
+		},
+		{
+			"path" : "pages/feedback/traceCamera",
+			"style" :
+			{
+				"navigationBarTitleText": "拍照签收",
 				"enablePullDownRefresh": false
 			}
 

+ 286 - 373
pages/feedback/print.vue

@@ -1,394 +1,307 @@
 <template>
-	<view>
-		<uni-list :border="false">
-			<uni-list-item v-for="(item,index) in breedTaskList" :key="item.id" :index="index" :threshold="0">
-				<template slot="body">
-					<uni-card :title="item.printBill.billCode" :subTitle="item.printBreed.breedName" :extra="parseBreedTaskStatus(item)">
-						<view class="uni-body">
-							<view>
-								<text class="textTitle">印品名称</text>
-								<text class="">{{item.printBill.billName}}</text>
-							</view>
-							<view v-show="item.showMore == true">
-								<view>
-									<text class="textTitle">印刷要求</text>
-									<text class="">{{item.printBreed.printRequire | ignoreNull}}</text>
-								</view>
-								<view>
-									<text class="textTitle">客户名称</text>
-									<text class="">{{item.printBill.clientName}}</text>
-								</view>
-								<view>
-									<text class="textTitle">产品类型</text>
-									<text class="">{{item.printBill.productName}}</text>
-								</view>
-								<view>
-									<text class="textTitle">用纸</text>
-									<text class="">{{item.printBreed.actualPaperName | ignoreNull}}</text>
-								</view>
-							</view>
-						</view>
-						<view slot="actions" class="card-actions">
-							<view class="card-actions-item" @click="viewBreedTaskMore(item)">
-								<uni-icons v-if="item.showMore == false" type="bottom" size="18" color="#999"></uni-icons>
-								<uni-icons v-if="item.showMore == true" type="top" size="18" color="#999"></uni-icons>
-								<text class="card-actions-item-text" v-if="item.showMore == false">展开</text>
-								<text class="card-actions-item-text" v-if="item.showMore == true">折叠</text>
-							</view>
-							<view class="card-actions-item" @click="viewBreedTaskDetail(item)">
-								<uni-icons type="info-filled" size="18" color="#999"></uni-icons>
-								<text class="card-actions-item-text">详情</text>
-							</view>
-							<view class="card-actions-item" @click="viewBreedTaskStep(item)">
-								<uni-icons type="tune" size="18" color="#999"></uni-icons>
-								<text class="card-actions-item-text">脚印</text>
-							</view>
-							<view class="card-actions-item" @click="feedBack(item)">
-								<uni-icons type="compose" size="18" color="#999"></uni-icons>
-								<text class="card-actions-item-text">反馈</text>
-							</view>
-						</view>
-					</uni-card>
-				</template>
-			</uni-list-item>
-		</uni-list>
-<!-- 		<view v-show="isLoadMore">
-			<uni-load-more :status="loadStatus" showIcon @clickLoadMore="loadMoreBill()"></uni-load-more>
-		</view> -->
+  <view style="padding-bottom:118rpx;">
+    <uni-list :border="false">
+      <view v-if="branchLineName" class="branch-tit">{{branchLineName}}-{{deliveryBillCode}}</view>
+      <uni-list-item v-for="(item,index) in breedTaskList" :key="item.id" :index="index" :threshold="0">
+        <template slot="body">
+            <uni-card>
+              <u-row>
+                <u-col span="12">
+                  <view class="demo-layout">
+                    <view><span>{{item.shipmentPackageCount}}</span>{{item.shipmentUnit}}</view>
+                    <view>{{item.erpOrderCode}}</view>
+                    <view>{{item.shipmentName}}</view>
+                    <view style="font-size: 28rpx">{{item.receiveAddress}}</view>
+                  </view>
+                </u-col>
+              </u-row>
+            </uni-card>
+        </template>
+      </uni-list-item>
+    </uni-list>
+    <view class="footer">
+      <view>
+        <view style="padding: 10rpx 0">
+          <text class="footer-text">包&nbsp;&nbsp;&nbsp;&nbsp;数:<span>{{totalUnit}}</span></text><br>
+          <text class="footer-text">订单数:<span>{{breedTaskList.length}}</span></text>
+        </view>
+      </view>
+      <view @click="confirmOrderCodes">确认交接</view>
+    </view>
 
-		<u-popup :show="feedBackPopupShow" :overlay="true" mode="bottom" :closeable="true" :closeOnClickOverlay="true"
-			@close="feedBackPopupClose">
-			<view class="u-popup-slot">
-				<uni-section
-					:title="focuseTask.printBill.billCode + '(' + focuseTask.printBreed.breedName + ')'"
-					type="line"></uni-section>
-				<view>
-					<uni-forms ref="feedBackForm">
-						<uni-forms-item label="是否完成" required name="feedBackComplete">
-							<uni-data-checkbox v-model="feedBackData.feedBackComplete" :multiple="true" :localdata="feedBackCompleteStatus" />
-						</uni-forms-item>
-						<uni-forms-item label="反馈数量" required name="feedBackCount">
-							<uni-easyinput type="number" v-model="feedBackData.feedBackCount"
-								placeholder="请输入数量" />
-						</uni-forms-item>
-						<uni-forms-item label="反馈备注" name="feedBackMemo">
-							<uni-easyinput type="textarea" v-model="feedBackData.feedBackMemo" placeholder="请输入备注" />
-						</uni-forms-item>
-					</uni-forms>
-					<button type="primary" @click="submitFeedBackForm('feedBackForm')">提交</button>
-				</view>
-			</view>
-		</u-popup>
-		<view class="footer">
-			<view>
-				<view>
-					<text class="footer-text">总数:18</text><br>
-					<text style="margin-top: -10rpx;" class="footer-text">包数:26</text>
-				</view>
-			</view>
-			<view @click="confirmOrderCodes">确认交接</view>
-		</view>
-
-		<uni-fab style="bottom: 100rpx;" ref="fab" :pattern="fabPattern" icon="scan" :popMenu="false" horizontal="right" vertical="bottom"
-			@fabClick="scanFabClick" />
-	</view>
+    <uni-fab style="bottom: 100rpx;" ref="fab" :pattern="fabPattern" icon="color" :popMenu="false" horizontal="right" vertical="bottom"
+             @fabClick="scanFabClick" />
+    <u-loading-page :loading="loading"></u-loading-page>
+  </view>
 </template>
 
 <script>
-	import request from '@/common/libs/request.js';
-	export default {
-		data() {
-			return {
-				fabPattern: {
-					color: '#7A7E83',
-					backgroundColor: '#fff',
-					selectedColor: '#007AFF',
-					buttonColor: '#007AFF',
-					iconColor: '#fff'
-				},
-				idMachineInfo: 0,
-				breedTaskList: [],
-				feedBackPopupShow: false,
-				focuseTask: {
-					printBill:{},
-					printBreed:{}
-				},
-				feedBackData: {
-					feedBackCount: 0,
-					feedBackComplete:[1],
-					feedBackMemo: ''
-				},
-				feedBackCompleteStatus:[
-					{
-						text: '任务已完成',
-						value: 1
-					}
-				]
-			}
-		},
-		onLoad() {
-			// if (process.env.NODE_ENV === 'development') {
-			// 	this.fillBreedTaskByMachine(2, 1);
-			// }
-		},
-		methods: {
-			confirmOrderCodes(){
-
-			},
-			searchPrintBreed() {
-
-			},
-			scanFabClick() {
-				let _that = this;
-				uni.scanCode({
-					onlyFromCamera: true,
-					scanType: ['barCode', 'qrCode'],
-					success: function(res) {
-						if (res.result.match(new RegExp("^machine.*$"))) {
-							let idMachine = res.result.split("-")[1];
-							_that.idMachineInfo = idMachine;
-							_that.fillBreedTaskByMachine(idMachine, 1);
-						} else if (res.result.match(new RegExp("^printbill.*$"))) {
-
-						}
-					}
-				})
-			},
-			fillBreedTaskByMachine(idMachine, pageIndex) {
-				let _that = this;
-				let listData = {
-					params: JSON.stringify({
-						idProcess: 5,
-						idMachineInfo: idMachine,
-						keyWord: ""
-					}),
-					page: JSON.stringify({
-						pageIndex: pageIndex,
-						pageSize: 20
-					})
-				}
+import request from '@/common/libs/request.js';
+export default {
+  data() {
+    return {
+      token:"",
+      loading:false,
+      branchLineName:'',
+      deliveryBillCode:'',
+      totalUnit:0,
+      fabPattern: {
+        color: '#7A7E83',
+        backgroundColor: '#fff',
+        selectedColor: '#007AFF',
+        buttonColor: '#007AFF',
+        iconColor: '#fff'
+      },
+      breedTaskList: []
+    }
+  },
+  mounted() {
+    this.initData()
+  },
+  methods: {
+    confirmOrderCodes(){
+      let _that = this;
+      var ids = [];
+      if(_that.breedTaskList.length<=0){
+        uni.showToast({
+          title: "请先扫码",
+          icon: 'none'
+        })
+        return
+      }
+      _that.loading = true;
+      for (let i = 0; i < _that.breedTaskList.length; i++) {
+        ids.push(_that.breedTaskList[i].id)
+      }
+      let parms = {
+        idBillItems: ids.join(','),
+        token: _that.token
+      }
+      request.httpPost("/dnyDriver/handOverBillItems", parms, true).then(res => {
+        _that.loading = false;
+        _that.initData()
+        if (res.httpCode == 200) {
+          _that.breedTaskList = [];
+          _that.branchLineName = "";
+          _that.deliveryBillCode = "";
+          _that.totalUnit=0;
+          uni.showToast({
+            title: "交接成功",
+          })
+        }else {
+          uni.showToast({
+            title: res.msg,
+            icon: 'none',
+            mask: true,
+            duration: 3000,
+          })
+        }
+      });
+    },
+    initData(){
+      let _that = this;
+      request.httpPost("/dnyDriver/driverFormToken", {},true).then(tokenRes => {
+        _that.token = tokenRes.data
+      })
+    },
+    scanFabClick() {
+      let _that = this;
+      uni.scanCode({
+        onlyFromCamera: true,
+        scanType: ['barCode', 'qrCode'],
+        success: function(res) {
+          if (res.result.indexOf('dnySendBill') != -1) {
+            let qrCode = res.result
+            _that.truckUpOrder(qrCode)
+          }else {
+            uni.showToast({
+              title: "请扫送货单的码",
+              icon: 'none'
+            })
+          }
 
-				request.httpPost("/printbill/queryBreedTasksToFeedback", listData, true).then(res => {
-					if (res.httpCode == 200) {
-						res.data.forEach(item => {
-							item.showMore = false
-						})
-						_that.breedTaskList = res.data;
-					}
-				});
-			},
-			parseBreedTaskStatus(task) {
-				if (task.pauseStatus == 0) {
-					if (task.taskStatus == 0) {
-						return "未开始";
-					} else if (task.taskStatus == 1) {
-						return "生产中";
-					} else if (task.taskStatus == 2) {
-						return "终止";
-					} else if (task.taskStatus == 5) {
-						return "完成";
-					} else if (task.taskStatus == 10) {
-						return "已完成";
-					}
-				} else {
-					return "暂停";
-				}
-			},
-			viewBreedTaskMore(task) {
-				task.showMore = !task.showMore
-			},
-			feedBack(task) {
-				let _that = this;
-				_that.focuseTask = task;
-				console.log(JSON.stringify(_that.feedBackData));
-				if (task.taskStatus == 0) {
-					//反馈开始
-					uni.showModal({
-					    title: '印刷反馈',
-					    content: '是否反馈任务开始?',
-					    success: function (resConfirm) {
-					        if (resConfirm.confirm) {
-					            let postData = {
-					            	item: JSON.stringify({
-					            		idTask: task.id,
-										taskStatus: 0,
-										isComplete: true,
-										feedbackCount: "",
-										memo: ""
-					            	})
-					            }
-					            request.httpPost("/printbill/feedbackTask", postData, true).then(resFeedBack => {
-					            	if (resFeedBack.httpCode == 200) {
-										task.taskStatus = 1;
-					            		uni.showToast({
-					            			title:"反馈成功"
-					            		})
-					            	} else {
-										uni.showToast({
-											title: resFeedBack.msg
-										})
-									}
-					            });
-					        } else if (resConfirm.cancel) {
-					            console.log('用户点击取消');
-					        }
-					    }
-					});
-				} else if (task.taskStatus == 1) {
-					//反馈完成
-					_that.feedBackPopupShow = true;
-				}
-			},
-			feedBackPopupClose() {
-				this.feedBackPopupShow = false;
-				console.log(JSON.stringify(this.feedBackData));
-			},
-			submitFeedBackForm(ref) {
-				let _that = this;
-				let isComplete = true;
-				if (_that.feedBackData.feedBackComplete.length == 0) {
-					isComplete = false
-				}
-				let postData = {
-					item: JSON.stringify({
-						idTask: _that.focuseTask.id,
-						taskStatus: 1,
-						isComplete: isComplete,
-						feedbackCount:_that.feedBackData.feedBackCount,
-						memo: _that.feedBackData.feedBackMemo
-					})
-				}
-				request.httpPost("/printbill/feedbackTask", postData, true).then(resFeedBack => {
-					if (resFeedBack.httpCode == 200) {
-						_that.focuseTask.taskStatus = 1;
-						uni.showToast({
-							title:"反馈成功"
-						})
-					} else {
-						uni.showToast({
-							title: resFeedBack.msg
-						})
-					}
-				});
-			},
-			viewBreedTaskDetail(task) {
-				uni.navigateTo({
-					url: "../printbill/detail?id=" + task.idPrintBill + "&billCode=" + task.printBill.billCode,
-					animationType: 'pop-in'
-				})
-			},
-			viewBreedTaskStep(task) {
-				uni.navigateTo({
-					url: "../printbill/step?id=" + task.idPrintBill + "&billCode=" + task.printBill.billCode,
-					animationType: 'pop-in'
-				})
-			}
-		}
-	}
+        }
+      })
+    },
+    truckUpOrder(qrCode){
+      let _that = this;
+      _that.loading = true;
+      let parms = {
+        qrCode: qrCode
+      }
+      request.httpPost("/dnyDriver/handOverScanBillBranch", parms, true).then(res => {
+        console.log(res);
+        _that.loading = false
+        _that.breedTaskList = [];
+        _that.totalUnit = 0;
+        if(res.httpCode==200){
+          var datas = res.data;
+          _that.branchLineName = datas[0].branchLineName
+          _that.deliveryBillCode = datas[0].deliveryBillCode
+          for (let i = 0; i < datas.length; i++) {
+            var items = datas[i]
+            var itemData = {
+              'erpOrderCode':items.erpOrderCode,//发货单号
+              'receiveAddress':items.receiveAddress,
+              'shipmentPackageCount':items.shipmentPackageCount,
+              'shipmentUnit':items.shipmentUnit,
+              'shipmentName':items.shipmentName,
+              'id':items.id
+            }
+            _that.totalUnit+=items.shipmentPackageCount
+            _that.breedTaskList.push(itemData)
+          }
+          console.log("res333",_that.breedTaskList);
+        }else {
+          uni.showToast({
+            title: res.msg,
+            icon: 'none',
+            mask: true,
+            duration: 4000,
+          })
+        }
+      })
+    },
+    deleteBtn(index){
+      this.totalUnit = this.totalUnit-this.breedTaskList[index].shipmentPackageCount
+      this.breedTaskList.splice(index, 1)
+    },
+  }
+}
 </script>
 
 <style lang="scss" scoped>
+.branch-tit{
+  font-size: 36rpx;
+  margin-left: 10rpx;
+  padding-top: 20rpx;
+}
+.footer-text{
+  line-height: 18rpx;
+}
+.footer-text span{
+  font-weight: bold;
+  color: #e4493c;
+}
+.demo-layout span{
+  font-weight: bold;
+  color: #e4493c;
+  padding: 0 5rpx;
+}
+.span-txt{
+  font-weight: bold;
+  color: #e4493c;
+}
+.demo-layout{
+  font-size: 36rpx;
+}
+/deep/ .uni-card .uni-card__header{
+  border-bottom: none !important;
+}
+/deep/ .uni-list-item__container {
+  padding: 0rpx;
+}
+/deep/ .fab{
+  .uniui-plusempty:before {
+    //content: "\e67b";
+    content: '\e654' !important;
+  }
+}
+.card-actions {
+  display: flex;
+  flex-direction: row;
+  justify-content: space-around;
+  align-items: center;
+  height: 45px;
+  border-top: 1px #eee solid;
+}
 
-	/deep/ .uni-list-item__container {
-		padding: 0rpx;
-	}
-
-	.card-actions {
-		display: flex;
-		flex-direction: row;
-		justify-content: space-around;
-		align-items: center;
-		height: 45px;
-		border-top: 1px #eee solid;
-	}
-
-	.card-actions-item {
-		display: flex;
-		flex-direction: row;
-		align-items: center;
-	}
-
-	.card-actions-item-text {
-		font-size: 12px;
-		color: #666;
-		margin-left: 5px;
-	}
+.card-actions-item {
+  display: flex;
+  flex-direction: row;
+  align-items: center;
+}
 
-	.textTitle {
-		border-left: 0px solid #007AFF;
-		display: inline-block;
-		width: 180rpx;
-		text-align: left;
-		margin-bottom: 5px;
-		color: #8799a3;
-	}
+.card-actions-item-text {
+  font-size: 12px;
+  color: #666;
+  margin-left: 5px;
+}
 
-	.u-popup-slot {
-		width: 750rpx;
-		height: 400px;
-		@include flex;
-		justify-content: center;
-		align-items: center;
-		padding: 20px;
-	}
-	.footer {
-		position: fixed;
-		bottom: 0;
-		z-index: 10;
-		display: flex;
-		justify-content: space-between;
-		width: 100%;
-		height: 108rpx;
-		background: #FFFFFF;
-		border-top: 1px solid #E8E8E8;
+.textTitle {
+  border-left: 0px solid #007AFF;
+  display: inline-block;
+  width: 180rpx;
+  text-align: left;
+  margin-bottom: 5px;
+  color: #8799a3;
+}
 
-		>view {
-			width: 50%;
-			height: 100%;
-			font-size: 34rpx;
-			font-weight: 600;
-			display: flex;
-			justify-content: center;
-			align-items: center;
+.u-popup-slot {
+  width: 750rpx;
+  height: 400px;
+  @include flex;
+  justify-content: center;
+  align-items: center;
+  padding: 20px;
+}
+.footer {
+  position: fixed;
+  bottom: 0;
+  z-index: 10;
+  display: flex;
+  justify-content: space-between;
+  width: 100%;
+  height: 108rpx;
+  background: #FFFFFF;
+  border-top: 1px solid #E8E8E8;
 
-			&:active {
-				opacity: 0.8;
-			}
+  >view {
+    width: 50%;
+    height: 100%;
+    font-size: 34rpx;
+    font-weight: 600;
+    display: flex;
+    justify-content: center;
+    align-items: center;
 
-			.cart {
-				width: 67rpx;
-				height: 67rpx;
-				margin-top: 10rpx;
-				margin-right: 25rpx;
-			}
+    &:active {
+      opacity: 0.8;
+    }
 
-			.amout {
-				font-size: 34rpx;
+    .cart {
+      width: 67rpx;
+      height: 67rpx;
+      margin-top: 10rpx;
+      margin-right: 25rpx;
+    }
 
-				>text {
-					font-size: 20rpx;
-				}
-			}
+    .amout {
+      font-size: 34rpx;
 
-			.badge {
-				position: relative;
+      >text {
+        font-size: 20rpx;
+      }
+    }
 
-				>text {
-					position: absolute;
-					top: 2rpx;
-					right: 10rpx;
-					z-index: 10;
-					font-size: 22rpx;
-					background: #FF3D00;
-					border-radius: 50%;
-					color: #fff;
-					padding: 0 10rpx 2rpx;
-				}
-			}
-		}
+    .badge {
+      position: relative;
 
-		>view:last-child {
-			background: #FFD202;
-		}
-	}
+      >text {
+        position: absolute;
+        top: 2rpx;
+        right: 10rpx;
+        z-index: 10;
+        font-size: 22rpx;
+        background: #FF3D00;
+        border-radius: 50%;
+        color: #fff;
+        padding: 0 10rpx 2rpx;
+      }
+    }
+  }
+  >view:last-child {
+    background: #FFD202;
+  }
+}
 </style>

+ 0 - 196
pages/feedback/scanOrderCode.vue

@@ -1,196 +0,0 @@
-<template>
-	<view class="page-container">
-		<view>
-			<appScan ref="appScan" @scanHitERPCode="scanHitERPCode"></appScan>
-		</view>
-
-		<view class="codeList">
-			<view class="codeItem" v-for="(item,index) in hitOrders" :title="item.orderCode" :index="index" :threshold="0">
-				{{item.orderCode}}
-			</view>
-
-		</view>
-
-
-		<view class="footer">
-			<view>
-				<view>
-					<text>总数:18</text><br>
-					<text>包数:26</text>
-				</view>
-			</view>
-			<view @click="confirmOrderCodes">确认装车</view>
-		</view>
-	</view>
-</template>
-
-<script>
-	import appScan from "../../components/app-continue-scancode/app-continue-scancode.vue"
-	import request from '@/common/libs/request.js';
-	export default {
-		components: {
-			appScan
-		},
-		data() {
-			return {
-				totalCount: 0,
-				hitOrders: []
-			}
-		},
-		methods: {
-			scanHitERPCode(e) {
-				let _that = this;
-				console.log(e.code);
-				if (e.code.match(new RegExp("^sendOrder.*$"))) {
-					let ids = e.code.split("-");
-					console.log(ids);
-					if (!_that.checkCodeExists(ids[2])) {
-						_that.hitOrders.push({
-							id: ids[2],
-							orderCode: ids[1]
-						})
-						console.log(ids)
-						// this.totalCount++
-					}
-				}
-			},
-			checkCodeExists(id) {
-				let _that = this;
-				let code = _that.hitOrders.find(function(v) {
-					return (v.id == id);
-				})
-				return ((code) && (code != null) && (code != undefined));
-			},
-			confirmOrderCodes() {
-				let _that = this;
-				if (_that.hitOrders.length > 0) {
-					uni.$emit('confirmHitERPCode', {
-						hits: _that.hitOrders
-					})
-					setTimeout(() => {
-						uni.navigateBack({})
-					}, 500)
-				}
-			}
-		}
-	}
-</script>
-
-<style lang="scss" scoped>
-	.footer-text{
-		line-height: 18rpx;
-	}
-	.page-container {
-		position: relative;
-		height: 100%;
-		overflow: hidden;
-		background-color: rgba(0, 0, 0, 0.6);
-
-		.input {
-			position: relative;
-			z-index: 20;
-			margin-top: 80rpx;
-			height: 70rpx;
-			padding: 0 80rpx;
-
-			/deep/ .search-input {
-				height: 70rpx;
-				color: #fff;
-				border-radius: 40rpx;
-				border: 1px solid #FFD202;
-			}
-		}
-	}
-
-	.wx-scan-container {
-		margin-top: 100rpx;
-		height: 450rpx;
-
-		.wx-tip {
-			font-size: 30rpx;
-			color: #FFFFFF;
-			text-align: center;
-			margin-top: 30rpx;
-		}
-	}
-
-	.codeList {
-		position: absolute;
-		display: flex;
-		flex-direction: row;
-		flex-wrap: wrap;
-		justify-content: space-between;
-		top: 340px;
-		bottom: 50px;
-		z-index: 10;
-		width: 100%;
-		background: #FFFFFF;
-		.codeItem {
-			width: 48%;
-			height: 30rpx;
-			border: 0px;
-			margin-top: 2rpx;
-		}
-	}
-
-	.footer {
-		position: fixed;
-		bottom: 0;
-		z-index: 10;
-		display: flex;
-		justify-content: space-between;
-		width: 100%;
-		height: 108rpx;
-		background: #FFFFFF;
-		border-top: 1px solid #E8E8E8;
-
-		>view {
-			width: 50%;
-			height: 100%;
-			font-size: 34rpx;
-			font-weight: 600;
-			display: flex;
-			justify-content: center;
-			align-items: center;
-
-			&:active {
-				opacity: 0.8;
-			}
-
-			.cart {
-				width: 67rpx;
-				height: 67rpx;
-				margin-top: 10rpx;
-				margin-right: 25rpx;
-			}
-
-			.amout {
-				font-size: 34rpx;
-
-				>text {
-					font-size: 20rpx;
-				}
-			}
-
-			.badge {
-				position: relative;
-
-				>text {
-					position: absolute;
-					top: 2rpx;
-					right: 10rpx;
-					z-index: 10;
-					font-size: 22rpx;
-					background: #FF3D00;
-					border-radius: 50%;
-					color: #fff;
-					padding: 0 10rpx 2rpx;
-				}
-			}
-		}
-
-		>view:last-child {
-			background: #FFD202;
-		}
-	}
-</style>

+ 8 - 103
pages/feedback/scancodeCar.vue

@@ -1,5 +1,5 @@
 <template>
-	<view>
+	<view style="padding-bottom:118rpx;">
 		<uni-list :border="false">
 			<uni-list-item v-for="(item,index) in breedTaskList" :key="item.id" :index="index" :threshold="0">
 				<template slot="body">
@@ -31,7 +31,6 @@
 
 		<uni-fab style="bottom: 100rpx;" ref="fab" :pattern="fabPattern" icon="color" :popMenu="false" horizontal="right" vertical="bottom"
 			@fabClick="scanFabClick" />
-			<u-notify ref="uNotify"></u-notify>
 	</view>
 </template>
 
@@ -42,7 +41,6 @@
 			return {
 				token:"",
 				totalUnit:0,
-				hitOrders:[],
 				fabPattern: {
 					color: '#7A7E83',
 					backgroundColor: '#fff',
@@ -50,31 +48,9 @@
 					buttonColor: '#007AFF',
 					iconColor: '#fff'
 				},
-				idMachineInfo: 0,
-				breedTaskList: [],
-				feedBackPopupShow: false,
-				focuseTask: {
-					printBill:{},
-					printBreed:{}
-				},
-				feedBackData: {
-					feedBackCount: 0,
-					feedBackComplete:[1],
-					feedBackMemo: ''
-				},
-				feedBackCompleteStatus:[
-					{
-						text: '任务已完成',
-						value: 1
-					}
-				]
+				breedTaskList: []
 			}
 		},
-		onLoad() {
-			// if (process.env.NODE_ENV === 'development') {
-			// 	this.fillBreedTaskByMachine(2, 1);
-			// }
-		},
 		mounted() {
 			this.initData()
 		},
@@ -87,6 +63,7 @@
 						title: "请先扫码",
 						icon: 'none'
 					})
+          return
 				}
 				for (let i = 0; i < _that.breedTaskList.length; i++) {
 					ids.push(_that.breedTaskList[i].id)
@@ -95,12 +72,9 @@
 					idBillItems: ids.join(','),
 					token: _that.token
 				}
-				console.log(parms);
 				request.httpPost("/dnyDriver/truckUp", parms, true).then(res => {
-					console.log(res);
 					_that.initData()
 					if (res.httpCode == 200) {
-					_that.hitOrders = [];
 					_that.breedTaskList = [];
 					_that.totalUnit=0;
 					uni.showToast({
@@ -116,9 +90,6 @@
 					}
 				});
 			},
-			searchPrintBreed() {
-
-			},
 			initData(){
 				let _that = this;
 				request.httpPost("/dnyDriver/driverFormToken", {},true).then(tokenRes => {
@@ -132,16 +103,17 @@
 					onlyFromCamera: true,
 					scanType: ['barCode', 'qrCode'],
 					success: function(res) {
-            console.log("res",res);
-            console.log(res.result)
             if (res.result.indexOf('sendOrder') != -1) {
               let idOrder = res.result.split("-")[2];
-              console.log(idOrder)
               _that.truckUpOrder(idOrder)
             }else if(res.result.indexOf('orderLabel') != -1){
               let orderCode = res.result.split("-")[1];
-              console.log(orderCode)
               _that.getShipDetails(orderCode)
+            }else {
+              uni.showToast({
+                title: "请扫包上的标签码",
+                icon: 'none'
+              })
             }
 
 					}
@@ -244,78 +216,11 @@
 
 				});
 			},
-			parseBreedTaskStatus(task) {
-				if (task.pauseStatus == 0) {
-					if (task.taskStatus == 0) {
-						return "未开始";
-					} else if (task.taskStatus == 1) {
-						return "生产中";
-					} else if (task.taskStatus == 2) {
-						return "终止";
-					} else if (task.taskStatus == 5) {
-						return "完成";
-					} else if (task.taskStatus == 10) {
-						return "已完成";
-					}
-				} else {
-					return "暂停";
-				}
-			},
-			viewBreedTaskMore(task) {
-				task.showMore = !task.showMore
-			},
 
 			deleteBtn(index){
 				this.totalUnit = this.totalUnit-this.breedTaskList[index].shipmentPackageCount
 				this.breedTaskList.splice(index, 1)
-				this.hitOrders.splice(index, 1)
-
-
-			},
-			feedBackPopupClose() {
-				this.feedBackPopupShow = false;
-				console.log(JSON.stringify(this.feedBackData));
 			},
-			submitFeedBackForm(ref) {
-				let _that = this;
-				let isComplete = true;
-				if (_that.feedBackData.feedBackComplete.length == 0) {
-					isComplete = false
-				}
-				let postData = {
-					item: JSON.stringify({
-						idTask: _that.focuseTask.id,
-						taskStatus: 1,
-						isComplete: isComplete,
-						feedbackCount:_that.feedBackData.feedBackCount,
-						memo: _that.feedBackData.feedBackMemo
-					})
-				}
-				request.httpPost("/printbill/feedbackTask", postData, true).then(resFeedBack => {
-					if (resFeedBack.httpCode == 200) {
-						_that.focuseTask.taskStatus = 1;
-						uni.showToast({
-							title:"反馈成功"
-						})
-					} else {
-						uni.showToast({
-							title: resFeedBack.msg
-						})
-					}
-				});
-			},
-			viewBreedTaskDetail(task) {
-				uni.navigateTo({
-					url: "../printbill/detail?id=" + task.idPrintBill + "&billCode=" + task.printBill.billCode,
-					animationType: 'pop-in'
-				})
-			},
-			viewBreedTaskStep(task) {
-				uni.navigateTo({
-					url: "../printbill/step?id=" + task.idPrintBill + "&billCode=" + task.printBill.billCode,
-					animationType: 'pop-in'
-				})
-			}
 		}
 	}
 </script>

+ 228 - 0
pages/feedback/signOrderCode.vue

@@ -0,0 +1,228 @@
+<template>
+  <view class="">
+    <u-sticky v-if="!signVisible"  style="background-color: white;padding: 0;">
+      <uni-search-bar @confirm="searchBill" placeholder="请输入搜索内容"></uni-search-bar>
+    </u-sticky>
+    <uni-list style="margin-top: -20rpx">
+      <uni-list-item style="margin-top: 0;padding-top: 0" v-for="(item,index) in billList" :key="item.id" :index="index" :threshold="0">
+        <template slot="body">
+          <uni-card>
+            <view class="demo-layout">
+              <view>
+                <text class="tag-con">支付状态</text>
+                <span>{{ item.shipmentPackageCount }}</span>{{ item.shipmentUnit }}&nbsp;&nbsp;&nbsp;&nbsp;代收金额:<span>{{ item.shipmentMoney }}</span>&nbsp;&nbsp;&nbsp;&nbsp;
+              </view>
+              <view>{{ item.erpOrderCode }}</view>
+              <view>{{ item.clientName }}</view>
+              <view>{{ item.shipmentName }}&{{item.productName}}</view>
+              <view style="font-size: 28rpx">{{ item.receiveAddress }}</view>
+            </view>
+            <view slot="actions" class="card-actions">
+              <view class="card-actions-item" @click="viewDetail(item)">
+                <uni-icons type="info-filled" size="18" color="#999"></uni-icons>
+                <text class="card-actions-item-text">货款代收</text>
+              </view>
+              <view class="card-actions-item" @click="viewOrderTrace(item,index)">
+                <uni-icons type="camera-filled" size="18" color="#999"></uni-icons>
+                <text class="card-actions-item-text">拍照签收</text>
+              </view>
+            </view>
+          </uni-card>
+        </template>
+      </uni-list-item>
+    </uni-list>
+    <view v-show="isLoadMore && !signVisible">
+      <uni-load-more :status="loadStatus" showIcon @clickLoadMore="loadMoreBill()"></uni-load-more>
+    </view>
+    <uni-fab style="bottom: 100rpx;" ref="fab" :pattern="fabPattern" icon="color" :popMenu="false" horizontal="right"
+             vertical="bottom"
+             @fabClick="scanFabClick"/>
+  </view>
+</template>
+
+<script>
+import request from '@/common/libs/request.js';
+
+export default {
+  data() {
+    return {
+      signVisible:false,
+      fabPattern: {
+        color: '#7A7E83',
+        backgroundColor: '#fff',
+        selectedColor: '#007AFF',
+        buttonColor: '#007AFF',
+        iconColor: '#fff'
+      },
+      billList: [],
+      page: {
+        pageIndex: 1,
+        pageSize: 20
+      },
+      isLoadMore: true,
+      loadStatus: 'noMore',
+    }
+  },
+  onLoad() {
+    this.getSignBillList();
+  },
+  created(){
+    uni.$on('eventName',this.handelEvent)
+  },
+  onPullDownRefresh() {
+    this.billList = [];
+    this.getSignBillList();
+  },
+  methods: {
+    handelEvent(data){
+      this.billList.splice(data, 1)
+    },
+    scanFabClick() {
+      //扫码
+      let _that = this;
+      uni.scanCode({
+        onlyFromCamera: true,
+        scanType: ['barCode', 'qrCode'],
+        success: function (res) {
+          console.log("res1212",res);
+          if (res.result.indexOf('sendOrder') != -1) {
+            let idOrder = res.result.split("-")[2];
+            _that.truckUpOrder(idOrder)
+          }else if(res.result.indexOf('orderLabel') != -1){
+            let orderCode = res.result.split("-")[1];
+            _that.getShipDetails(orderCode)
+          }else {
+            uni.showToast({
+              title: "请扫正确的二维码",
+              icon: 'none'
+            })
+          }
+
+        }
+      })
+    },
+    truckUpOrder(idOrder){
+      let _that = this;
+      let parms = {
+        idOrder: idOrder
+      }
+      request.httpPost("/dnyDriver/signInScanSendOrder", parms, true).then(res => {
+        console.log('res444',res);
+      })
+    },
+    getShipDetails(orderCode){
+      let _that = this;
+      let parms = {
+        orderCode: orderCode
+      }
+      request.httpPost("/dnyDriver/signInScanERPOrder", parms, true).then(res => {
+        _that.signVisible = true;
+
+      })
+    },
+    getSignBillList: function () {
+      let _that = this;
+      var info = {
+        ltItemState: 10
+      }
+      let listData = {
+        params: JSON.stringify(info),
+        page: JSON.stringify(_that.page)
+      }
+      request.httpPost("/dnyDriver/driverQuerySignInItem", listData, true).then(res => {
+        // console.log("res1111", res);
+        uni.stopPullDownRefresh();
+        if (!res.data || res.data.length == 0) {
+          this.loadStatus = "noMore";
+          return;
+        }
+        this.billList = this.billList.concat(res.data);
+        this.loadStatus = "more";
+        // supplierIndex = 0;
+      });
+    },
+    searchBill(res) {
+    },
+    loadMoreBill: function () {
+      this.loadStatus = "loading";
+      setTimeout(() => {
+        this.page.pageIndex += 1;
+        this.getSignBillList();
+      }, 100);
+    },
+    viewDetail: function (item) {
+      // console.log(item.id);
+      uni.navigateTo({
+        url: "./detail?id=" + item.id + "&billCode=" + item.billCode,
+        animationType: 'pop-in'
+      })
+    },
+    parseBillState: function (item) {
+      if (item.voidFlag == 1) {
+        return "已作废";
+      } else if (item.billState == 1) {
+        return "已下达";
+      } else {
+        return "";
+      }
+    },
+    viewOrderTrace: function (item,index) {
+      // console.log(item.id);
+      uni.navigateTo({
+        url: "../feedback/traceCamera?idOrder=" + item.id + "&orderCode=" + item.erpOrderCode + "&shipmentName=" + item.shipmentName+ "&index=" + index
+      });
+    }
+  }
+}
+</script>
+
+<style lang="scss" scoped>
+.tag-con {
+  color: #e4493c;
+  margin-right: 20rpx;
+}
+/deep/ .uni-list-item__container {
+  padding: 0rpx;
+}
+.demo-layout span {
+  font-weight: bold;
+  color: #e4493c;
+  padding: 0 5rpx;
+}
+
+/deep/ .uni-list-item__container {
+  padding: 0 rpx;
+}
+/deep/ .uni-card uni-card--border{
+  padding: 0 rpx;
+}
+.card-actions {
+  display: flex;
+  flex-direction: row;
+  justify-content: space-around;
+  align-items: center;
+  height: 45px;
+  border-top: 1px #eee solid;
+}
+
+.card-actions-item {
+  display: flex;
+  flex-direction: row;
+  align-items: center;
+}
+
+.card-actions-item-text {
+  font-size: 12px;
+  color: #666;
+  margin-left: 5px;
+}
+
+.textTitle {
+  border-left: 0px solid #007AFF;
+  display: inline-block;
+  width: 180 rpx;
+  text-align: left;
+  margin-bottom: 5px;
+  color: #8799a3;
+}
+</style>

+ 109 - 0
pages/feedback/traceCamera.vue

@@ -0,0 +1,109 @@
+<template>
+	<view>
+		<uni-section :title="orderCode+'/'+shipmentName" type="line">
+			<view class="example">
+				<u-upload
+					:fileList="imageList"
+					:sizeType="imageSizeType"
+					@delete="deletePic"
+					@afterRead="readPic"
+					name="1"
+					previewImage
+					:maxCount="3"
+				>
+				</u-upload>
+				<button type="primary" @click="submitTrace()">提交</button>
+			</view>
+		</uni-section>
+	</view>
+</template>
+
+<script>
+	import request from '@/common/libs/request.js';
+	export default {
+		data() {
+			return {
+				orderCode:'',
+				idOrder:'',
+				imageSizeType:['original','compressed'],
+				imageList: [],
+				imageSrcList: []
+			}
+		},
+		onLoad(option){
+			if(option && option.idOrder){
+				this.idOrder = option.idOrder
+				this.orderCode = option.orderCode
+        this.shipmentName = option.shipmentName
+        this.index = option.index
+				// this.getSrcTraceImage()
+			}
+		},
+		methods: {
+			// 删除图片
+			deletePic(event) {
+				this.imageList.splice(event.index, 1)
+			},
+      async readPic(event) {
+				this.imageList.push(event.file)
+			},
+			submitTrace() {
+        let _that = this
+        if(_that.imageList.length<=0){
+          uni.showToast({
+            title: "请先拍照上传图片",
+            icon: 'none'
+          })
+          return
+        }
+				// 请求前
+				uni.showLoading({
+					mask:true  //是否显示透明蒙层,防止触摸穿透,默认:false
+				});
+
+
+				let uploadFiles = []
+				for (let i = 0; i < _that.imageList.length; i++) {
+					uploadFiles.push({
+						uri: _that.imageList[i].url,
+						name: 'traceImage' + i
+					})
+				}
+				// _that.imageList.forEach(x => {
+				// 	uploadFiles.push({
+				// 		uri: x.url
+				// 	})
+				// })
+				let token = uni.getStorageSync('erpToken');
+				let uploadUrl = "http://192.168.1.24:51106/driverSign/signItem";
+				if (process.env.NODE_ENV === 'production') {
+					uploadUrl = "http://192.168.1.24:51106/driverSign/signItem"
+				}
+        console.log("111",uploadFiles);
+        uni.uploadFile({
+					url: uploadUrl,
+					files: uploadFiles,
+					header: {
+						'Access-Token': token
+					},
+					formData: {
+            idItem: _that.idOrder
+					},
+					success: (res) => {
+						console.log("222",res);
+            uni.hideLoading();
+            uni.navigateBack({})
+            uni.$emit("eventName",_that.index)
+					}
+				})
+			}
+		}
+	}
+</script>
+
+<style>
+	.example {
+		padding: 15px;
+		background-color: #fff;
+	}
+</style>

+ 3 - 0
pages/index/me.vue

@@ -33,6 +33,9 @@
 	export default {
 		mounted() {
 			this.initData()
+      uni.setNavigationBarTitle({
+        title:'个人中心'
+      })
 		},
 		data() {
 			return {

+ 10 - 4
pages/index/order.vue

@@ -1,6 +1,6 @@
 <template>
 	<view>
-		配送列表
+		配送列表54546564564
 	</view>
 </template>
 
@@ -8,12 +8,18 @@
 	export default {
 		data() {
 			return {
-				
+
 			}
 		},
+    mounted() {
+      console.log('2222222222222');
+      uni.setNavigationBarTitle({
+        title:'配送列表'
+      })
+    },
 		methods: {
-			
-		}
+
+		},
 	}
 </script>
 

+ 10 - 7
pages/index/tabbar.vue

@@ -2,7 +2,7 @@
 	<view>
 		<workTable ref="workTableRef" v-if="pageCurrent=='workTable'"></workTable>
 		<me v-if="pageCurrent=='me'"></me>
-    <me v-if="pageCurrent=='order'"></me>
+    <order v-if="pageCurrent=='order'"></order>
 
 		<view class="box">
 			<view class="cu-bar tabbar bg-white shadow foot">
@@ -20,12 +20,6 @@
 					</view>
 					<view :class="pageCurrent=='workTable'?'color_main':'text-gray'">工作台</view>
 				</view>
-
-<!-- 				<view @click="navChange" class="action text-gray add-action" data-cur="workTable">
-					<image class="logo_btn" mode="widthFix" src="../../static/logo.png"></image>
-					<view :class="pageCurrent=='workTable'?'color_main':'text-gray'">工作台</view>
-				</view> -->
-
 				<view class="action" @click="navChange" data-cur="me">
 					<view class='cuIcon-cu-image'>
 						<view class="cu-tag badge">
@@ -57,6 +51,15 @@
 				pageCurrent: 'workTable'
 			}
 		},
+    onPullDownRefresh() {
+      console.log('refresh');
+      if (this.pageCurrent == 'workTable') {
+        this.$refs['workTableRef'].pullDownRefresh();
+        setTimeout(function () {
+          uni.stopPullDownRefresh();
+        }, 1000);
+      }
+    },
 		methods: {
 
 			navChange: function(e) {

+ 268 - 304
pages/index/workTable.vue

@@ -1,315 +1,279 @@
 <template>
-	<view class="wrap">
-		<view class="orderMonitor">
-			<u-row  class="userinfo-topbox" gutter="16" justify="center">
-				<u-col span="6" text-align="center" style="margin: 1px;">
-					<view style="color: #CCFFFF;">{{defaultTruckCode}}</view>
-				</u-col>
-				<u-col span="6" text-align="center" style="margin: 1px;">
-					<view style="color: #CCFFFF;"></view>
-				</u-col>
-			</u-row>
-			<u-row style="margin-top: -25rpx;"  class="userinfo-topbox" gutter="16" justify="center">
-				<u-col span="6" text-align="center" style="margin: 1px;">
-					<view style="color: #CCFFFF;">未配送订单</view>
-					<view class="number">50</view>
-				</u-col>
-				<u-col span="6" text-align="center" style="margin: 1px;">
-					<view style="color: #CCFFFF;">已配送订单</view>
-					<view class="number">20</view>
-				</u-col>
-			</u-row>
-		</view>
-		<view class="workbench-title">常用应用</view>
-		<view class="toolbar">
-			<u-grid class="grid" :col="4" :border="false">
-				<u-grid-item @click="navTo('/pages/feedback/scancodeCar')"  :index="0">
-						<view   class="home-icon icon-color02">
-							<i class="iconfont icon-cangpeitubiao_huanhuorukutuihuoruku"></i>
-						</view>
-						<view class="grid-text">扫码装车</view>
-				</u-grid-item>
-				<u-grid-item @click="navTo('/pages/feedback/print')"  :index="1">
-						<view class="home-icon icon-color02">
-							<i class="iconfont icon-fahuo"></i>
-						</view>
-						<view class="grid-text">支线交接</view>
-				</u-grid-item>
-				<u-grid-item @click="scanFabClick"  :index="2">
-						<view class="home-icon icon-color02">
-							<i class="iconfont icon-kechengfankui"></i>
-						</view>
-						<view class="grid-text">扫码签收</view>
-				</u-grid-item>
-			</u-grid>
-		</view>
-	</view>
+  <view class="wrap">
+    <view class="orderMonitor">
+      <u-row class="userinfo-topbox" gutter="16" justify="center">
+        <u-col span="6" text-align="center" style="margin: 1px;">
+          <view style="color: #CCFFFF;">{{ defaultTruckCode }}</view>
+        </u-col>
+        <u-col span="6" text-align="center" style="margin: 1px;">
+          <view style="color: #CCFFFF;"></view>
+        </u-col>
+      </u-row>
+      <u-row style="margin-top:-25rpx;" class="userinfo-topbox" gutter="16" justify="center">
+        <u-col span="6" text-align="center" style="margin: 1px;">
+          <view style="color: #CCFFFF;">未配送订单</view>
+          <view class="number">50</view>
+        </u-col>
+        <u-col span="6" text-align="center" style="margin: 1px;">
+          <view style="color: #CCFFFF;">已配送订单</view>
+          <view class="number">20</view>
+        </u-col>
+      </u-row>
+    </view>
+    <view class="workbench-title">常用应用</view>
+    <view class="toolbar">
+      <u-grid class="grid" :col="4" :border="false">
+        <u-grid-item @click="navTo('/pages/feedback/scancodeCar')" :index="0">
+          <view class="home-icon icon-color02">
+            <i class="iconfont icon-cangpeitubiao_huanhuorukutuihuoruku"></i>
+          </view>
+          <view class="grid-text">扫码装车</view>
+        </u-grid-item>
+        <u-grid-item @click="navTo('/pages/feedback/print')" :index="1">
+          <view class="home-icon icon-color02">
+            <i class="iconfont icon-fahuo"></i>
+          </view>
+          <view class="grid-text">支线交接</view>
+        </u-grid-item>
+        <u-grid-item @click="navTo('/pages/feedback/signOrderCode')" :index="2">
+          <view class="home-icon icon-color02">
+            <i class="iconfont icon-kechengfankui"></i>
+          </view>
+          <view class="grid-text">扫码签收</view>
+        </u-grid-item>
+      </u-grid>
+    </view>
+    <view class="workbench-title">查询统计</view>
+    <view class="toolbar">
+      <u-grid class="grid" :col="4" :border="false">
+        <u-grid-item @click="navTo('/pages/order/recordOrder')" :index="0">
+          <view class="home-icon icon-color01">
+            <i class="iconfont icon-lishigongdan"></i>
+          </view>
+          <view class="grid-text">签收记录</view>
+        </u-grid-item>
+      </u-grid>
+    </view>
+
+  </view>
 </template>
 
 <script>
-	import request from '@/common/libs/request.js';
-	export default {
-
-		data() {
-			return {
-				defaultTruckCode:"",
-				orderData:[],
-				cardData: "",
-				listData: {
-					total: 0,
-					page: 1,
-					pageSize: 20
-				},
-			}
-		},
-		onLoad(){
-
-		},
-		mounted: function(option) {
-			this.initData()
-			// this.getCurrentItems();
-			//不再这里调用,由主页刷新获取
-			// this.getIndexCardPanelData();
-		},
-
-		methods: {
-			initData() {
-				let _that = this;
-				request.httpPost("/dnyDriver/getDriverInfo", {}).then(res => {
-					if (res.httpCode == 200) {
-						uni.setStorageSync("idDefaultTruck", res.data.idDefaultTruck);
-						_that.defaultTruckCode =  res.data.defaultTruckCode
-					} else {
-						uni.showToast({
-							title: res.msg,
-							icon: "error"
-						})
-					}
-				});
-			},
-			navTo(url) {
-				uni.navigateTo({
-					url: url
-				});
-			},
-			scanClickCar(){
-				let _that = this;
-				console.log("1111")
-				uni.reLaunch({
-					url: '/pages/feedback/scanOrderCode',
-				})
-			},
-			scanFabClick(e) {
-			let _that = this;
-			//扫码
-			uni.scanCode({
-				onlyFromCamera: true,
-				scanType: ['barCode', 'qrCode'],
-				success: function(res) {
-					console.log("121221",res)
-					_that.billScanOrderCode(res.result)
-
-				}
-			})
-
-
-		},
-		billScanOrderCode(idOrder) {
-			let _that = this;
-			let dataInfo = {
-				"idOrder": idOrder,
-			}
-
-			request.httpPost("/dnyDriver/scanOrderCode", dataInfo, true).then(res => {
-				if (res.httpCode == 200) {
-					console.log("3333",res)
-				}
-			});
-		},
-		getCurrentItems(){
-			const _that = this;
-			var page = {
-				pageIndex: _that.listData.page,
-				pageSize: _that.listData.pageSize
-			}
-			var data = {
-				"page": JSON.stringify(page)
-			}
-			request.httpPost("/dnyDriver/showCurrentTransitioningItems", data, false).then(res => {
-				if (res.httpCode == 200) {
-					console.log("4444",res)
-					_that.orderData = res.data
-				}else {
-					uni.showToast({
-						title: res.msg,
-						icon: "error"
-					})
-				}
-
-
-			})
-		},
-		}
-	}
+import request from '@/common/libs/request.js';
+
+export default {
+
+  data() {
+    return {
+      defaultTruckCode: "",
+      orderData: [],
+      cardData: "",
+      listData: {
+        total: 0,
+        page: 1,
+        pageSize: 20
+      },
+    }
+  },
+  mounted: function (option) {
+    this.initData()
+    uni.setNavigationBarTitle({
+      title:'工作台'
+    })
+  },
+
+  methods: {
+    initData() {
+      let _that = this;
+      request.httpPost("/dnyDriver/getDriverInfo", {}).then(res => {
+        // console.log("res33333",res);
+        if (res.httpCode == 200) {
+          uni.setStorageSync("idDefaultTruck", res.data.idDefaultTruck);
+          _that.defaultTruckCode = res.data.defaultTruckCode
+        } else {
+          uni.showToast({
+            title: res.msg,
+            icon: "error"
+          })
+        }
+      });
+    },
+    navTo(url) {
+      uni.navigateTo({
+        url: url
+      });
+    },
+    pullDownRefresh: function() {
+      this.initData();
+    }
+  }
+}
 </script>
 
 <style lang="scss">
-	.orderMonitor {
-		height: 190upx;
-		border-radius: 4upx;
-		color: #F0F0F0;
-		// background-image: linear-gradient(to right, #ffffff 0%, #ffffff 100%);
-		background-image: linear-gradient(to right, #006699 0%, #6699CC 100%);
-		border: #ffffff;
-		padding: 16upx;
-		margin: 16upx;
-		box-shadow: 4upx 4upx 6upx rgba(102, 153, 204, 0.4);
-	}
-
-.userinfo-topbox{
-	padding: 4px 8px;
-	color: #000000;
-	.number{
-		font-size: 14px;
-		font-weight: bold;
-		color: #FF9900;
-	}
+.orderMonitor {
+  height: 190 upx;
+  border-radius: 4 upx;
+  color: #F0F0F0;
+  // background-image: linear-gradient(to right, #ffffff 0%, #ffffff 100%);
+  background-image: linear-gradient(to right, #006699 0%, #6699CC 100%);
+  border: #ffffff;
+  padding: 16 upx;
+  margin: 16 upx;
+  box-shadow: 4 upx 4 upx 6 upx rgba(102, 153, 204, 0.4);
+}
+
+.userinfo-topbox {
+  padding: 4px 8px;
+  color: #000000;
+
+  .number {
+    font-size: 14px;
+    font-weight: bold;
+    color: #FF9900;
+  }
+}
+
+.userinfo-infobox {
+  color: #000000;
+  background-image: linear-gradient(to right, #CCCCCC 0%, #CCCCCC 100%);
+
+  .number {
+    font-size: 12px;
+  }
+}
+
+.wrap {
+  background: #FFFFFF;
+
+  .search {
+    padding: 20 rpx 20 rpx 0;
+    background: #f8f8f8;
+    height: 105 rpx;
+  }
+
+  .scroll-list {
+    height: calc(100vh - var(--window-top) - var(--window-bottom) - 105rpx); // 105rpx 为 .search 的高度
+    width: 100%;
+
+    .loadmore {
+      padding: 30 rpx;
+    }
+  }
+
+  .box {
+    padding-bottom: 10 rpx;
+
+    .item {
+      margin: 0 20 rpx 20 rpx;
+      padding: 8 rpx 20 rpx;
+      border-radius: 20 rpx;
+      box-sizing: border-box;
+      background-color: #fff;
+      font-size: 28 rpx;
+
+      .title {
+        display: flex;
+        justify-content: space-between;
+        background-color: #fff;
+        padding-left: 15 rpx;
+        align-items: center;
+
+        .text {
+          margin: 0 20 rpx;
+          font-size: 35 rpx;
+          font-weight: bold;
+        }
+
+      }
+    }
+
+  }
+
+  .list {
+
+    .u-cell-item-box {
+
+      .u-swipe-content {
+        width: 750 rpx;
+      }
+
+      .u-cell_title {
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+        min-width: 655 rpx;
+      }
+
+      .u-border-bottom:last-child:after {
+        border-bottom: 0;
+      }
+    }
+  }
+
+  .form {
+    display: flex;
+    flex-direction: column;
+    padding: 20 rpx 30 rpx;
+
+    .u-cell-item-box {
+      border-radius: 20 rpx;
+    }
+  }
+
+  .form-footer {
+    display: flex;
+    margin: 10 rpx;
+    padding-bottom: 30 rpx;
+
+    .btn {
+      flex: 1;
+      margin: 20 rpx;
+    }
+  }
+
+  .u-cell-box {
+
+    .u-cell {
+      font-size: 30 rpx;
+    }
+
+    .u-cell_title {
+      font-size: 30 rpx;
+    }
+
+    .u-cell__left-icon-wrap {
+      margin-right: 18 rpx;
+    }
+  }
 }
-.userinfo-infobox{
-	color: #000000;
-	background-image: linear-gradient(to right, #CCCCCC 0%, #CCCCCC 100%);
-	.number{
-		font-size: 12px;
-	}
+
+.workbench-title {
+  font-size: 38rpx;
+  font-weight: bold;
+  color: #333333;
+  padding: 15rpx 44rpx;
+  display: inline-block;
+
 }
 
-	.wrap {
-		background: #FFFFFF;
-		.search {
-			padding: 20rpx 20rpx 0;
-			background: #f8f8f8;
-			height: 105rpx;
-		}
-
-		.scroll-list {
-			height: calc(100vh - var(--window-top) - var(--window-bottom) - 105rpx); // 105rpx 为 .search 的高度
-			width: 100%;
-
-			.loadmore {
-				padding: 30rpx;
-			}
-		}
-
-		.box {
-			padding-bottom: 10rpx;
-
-			.item {
-				margin: 0 20rpx 20rpx;
-				padding: 8rpx 20rpx;
-				border-radius: 20rpx;
-				box-sizing: border-box;
-				background-color: #fff;
-				font-size: 28rpx;
-
-				.title {
-					display: flex;
-					justify-content: space-between;
-					background-color: #fff;
-					padding-left: 15rpx;
-					align-items: center;
-
-					.text {
-						margin: 0 20rpx;
-						font-size: 35rpx;
-						font-weight: bold;
-					}
-
-				}
-			}
-
-		}
-
-		.list {
-
-			.u-cell-item-box {
-
-				.u-swipe-content {
-					width: 750rpx;
-				}
-
-				.u-cell_title {
-					overflow: hidden;
-					white-space: nowrap;
-					text-overflow: ellipsis;
-					min-width: 655rpx;
-				}
-
-				.u-border-bottom:last-child:after {
-					border-bottom: 0;
-				}
-			}
-		}
-
-		.form {
-			display: flex;
-			flex-direction: column;
-			padding: 20rpx 30rpx;
-
-			.u-cell-item-box {
-				border-radius: 20rpx;
-			}
-		}
-
-		.form-footer {
-			display: flex;
-			margin: 10rpx;
-			padding-bottom: 30rpx;
-
-			.btn {
-				flex: 1;
-				margin: 20rpx;
-			}
-		}
-
-		.u-cell-box {
-
-			.u-cell {
-				font-size: 30rpx;
-			}
-
-			.u-cell_title {
-				font-size: 30rpx;
-			}
-
-			.u-cell__left-icon-wrap {
-				margin-right: 18rpx;
-			}
-		}
-	}
-
-	.workbench-title {
-		font-size: 32rpx;
-		font-weight: bold;
-		color: #333333;
-		padding: 15px 30rpx;
-	}
-
-
-	.grid {
-
-		.grid-icon {
-			color: #666;
-		}
-
-		.grid-text {
-			font-size: 24rpx;
-			padding: 15rpx;
-			color: #202328;
-		}
-	}
-
-	.toolbar {
-
-		background-color: #fff;
-	}
+
+.grid {
+
+  .grid-icon {
+    color: #666;
+  }
+
+  .grid-text {
+    font-size: 24 rpx;
+    padding: 15 rpx;
+    color: #202328;
+  }
+}
+
+.toolbar {
+
+  background-color: #fff;
+  padding-bottom: 30rpx;
+}
 </style>

+ 215 - 0
pages/order/recordOrder.vue

@@ -0,0 +1,215 @@
+<template>
+  <view class="">
+    <u-sticky v-if="!signVisible"  style="background-color: white;padding: 0;">
+      <uni-search-bar @confirm="searchBill" placeholder="请输入搜索内容"></uni-search-bar>
+    </u-sticky>
+    <uni-list style="margin-top: -20rpx">
+      <uni-list-item style="margin-top: 0;padding-top: 0" v-for="(item,index) in billList" :key="item.id" :index="index" :threshold="0">
+        <template slot="body">
+          <uni-card>
+            <view class="demo-layout">
+              <view>
+                <text class="tag-con">支付状态</text>
+                <span>{{ item.shipmentPackageCount }}</span>{{ item.shipmentUnit }}&nbsp;&nbsp;&nbsp;&nbsp;代收金额:<span>{{ item.shipmentMoney }}</span>&nbsp;&nbsp;&nbsp;&nbsp;
+              </view>
+              <view>{{ item.erpOrderCode }}</view>
+              <view>{{ item.clientName }}</view>
+              <view>{{ item.shipmentName }}&{{item.productName}}</view>
+              <view style="font-size: 28rpx">{{ item.receiveAddress }}</view>
+            </view>
+          </uni-card>
+        </template>
+      </uni-list-item>
+    </uni-list>
+    <view v-show="isLoadMore && !signVisible">
+      <uni-load-more :status="loadStatus" showIcon @clickLoadMore="loadMoreBill()"></uni-load-more>
+    </view>
+  </view>
+</template>
+
+<script>
+import request from '@/common/libs/request.js';
+
+export default {
+  data() {
+    return {
+      signVisible:false,
+      fabPattern: {
+        color: '#7A7E83',
+        backgroundColor: '#fff',
+        selectedColor: '#007AFF',
+        buttonColor: '#007AFF',
+        iconColor: '#fff'
+      },
+      billList: [],
+      page: {
+        pageIndex: 1,
+        pageSize: 20
+      },
+      isLoadMore: true,
+      loadStatus: 'noMore',
+    }
+  },
+  onLoad() {
+    this.getSignBillList();
+  },
+  created(){
+    uni.$on('eventName',this.handelEvent)
+  },
+  onPullDownRefresh() {
+    this.billList = [];
+    this.getSignBillList();
+  },
+  methods: {
+    handelEvent(data){
+      this.billList.splice(data, 1)
+    },
+    scanFabClick() {
+      //扫码
+      let _that = this;
+      uni.scanCode({
+        onlyFromCamera: true,
+        scanType: ['barCode', 'qrCode'],
+        success: function (res) {
+          console.log("res1212",res);
+          if (res.result.indexOf('sendOrder') != -1) {
+            let idOrder = res.result.split("-")[2];
+            _that.truckUpOrder(idOrder)
+          }else if(res.result.indexOf('orderLabel') != -1){
+            let orderCode = res.result.split("-")[1];
+            _that.getShipDetails(orderCode)
+          }else {
+            uni.showToast({
+              title: "请扫正确的二维码",
+              icon: 'none'
+            })
+          }
+
+        }
+      })
+    },
+    truckUpOrder(idOrder){
+      let _that = this;
+      let parms = {
+        idOrder: idOrder
+      }
+      request.httpPost("/dnyDriver/signInScanSendOrder", parms, true).then(res => {
+        console.log('res444',res);
+      })
+    },
+    getShipDetails(orderCode){
+      let _that = this;
+      let parms = {
+        orderCode: orderCode
+      }
+      request.httpPost("/dnyDriver/signInScanERPOrder", parms, true).then(res => {
+        _that.signVisible = true;
+
+      })
+    },
+    getSignBillList: function () {
+      let _that = this;
+      var info = {
+      }
+      let listData = {
+        params: JSON.stringify(info),
+        page: JSON.stringify(_that.page)
+      }
+      request.httpPost("/dnyDriver/driverQuerySignInItem", listData, true).then(res => {
+        // console.log("res1111", res);
+        uni.stopPullDownRefresh();
+        if (!res.data || res.data.length == 0) {
+          this.loadStatus = "noMore";
+          return;
+        }
+        this.billList = this.billList.concat(res.data);
+        this.loadStatus = "more";
+        // supplierIndex = 0;
+      });
+    },
+    searchBill(res) {
+    },
+    loadMoreBill: function () {
+      this.loadStatus = "loading";
+      setTimeout(() => {
+        this.page.pageIndex += 1;
+        this.getSignBillList();
+      }, 100);
+    },
+    viewDetail: function (item) {
+      // console.log(item.id);
+      uni.navigateTo({
+        url: "./detail?id=" + item.id + "&billCode=" + item.billCode,
+        animationType: 'pop-in'
+      })
+    },
+    parseBillState: function (item) {
+      if (item.voidFlag == 1) {
+        return "已作废";
+      } else if (item.billState == 1) {
+        return "已下达";
+      } else {
+        return "";
+      }
+    },
+    viewOrderTrace: function (item,index) {
+      // console.log(item.id);
+      uni.navigateTo({
+        url: "../feedback/traceCamera?idOrder=" + item.id + "&orderCode=" + item.erpOrderCode + "&shipmentName=" + item.shipmentName+ "&index=" + index
+      });
+    }
+  }
+}
+</script>
+
+<style lang="scss" scoped>
+.tag-con {
+  color: #e4493c;
+  margin-right: 20rpx;
+}
+/deep/ .uni-list-item__container {
+  padding: 0rpx;
+}
+.demo-layout span {
+  font-weight: bold;
+  color: #e4493c;
+  padding: 0 5rpx;
+}
+
+/deep/ .uni-list-item__container {
+  padding: 0 rpx;
+}
+/deep/ .uni-card uni-card--border{
+  padding: 0 rpx;
+}
+.card-actions {
+  display: flex;
+  flex-direction: row;
+  justify-content: space-around;
+  align-items: center;
+  height: 45px;
+  border-top: 1px #eee solid;
+}
+
+.card-actions-item {
+  display: flex;
+  flex-direction: row;
+  align-items: center;
+}
+
+.card-actions-item-text {
+  font-size: 12px;
+  color: #666;
+  margin-left: 5px;
+}
+
+.textTitle {
+  border-left: 0px solid #007AFF;
+  display: inline-block;
+  width: 180 rpx;
+  text-align: left;
+  margin-bottom: 5px;
+  color: #8799a3;
+}
+</style>
+

文件差异内容过多而无法显示
+ 2 - 2
unpackage/dist/dev/app-plus/app-config-service.js


文件差异内容过多而无法显示
+ 8143 - 15637
unpackage/dist/dev/app-plus/app-service.js


文件差异内容过多而无法显示
+ 6798 - 6713
unpackage/dist/dev/app-plus/app-view.js