shish 4 лет назад
Родитель
Сommit
beb69cb25c

+ 18 - 2
ghsApp/src/admin/billing/result.vue

@@ -2,11 +2,14 @@
   <appResult :title="option.title">
 	<button v-if="option.title != '报损成功'" class="admin-button-com big" @click="gotoOrderDetail">订单详情</button>
 	<button class="admin-button-com big" @click="goBackHome">返回首页</button>
+  <!-- #ifdef MP-WEIXIN -->
+  <button v-if="option.title != '报损成功'" class="admin-button-com big"  open-type="share">分享给{{customName}}</button>
+  <!-- #endif -->
   </appResult>
 </template>
 <script>
 import appResult from "@/components/app-result";
-import { getDetail,getPayVoice} from "@/api/order/index";
+import { getDetail} from "@/api/order/index";
 import BLE from "@/mixins/BLE";
 export default {
   name: "BillingResult",
@@ -17,8 +20,18 @@ export default {
   data() {
     return {
       detailInfo: {},
+      customName:'客户'
     };
   },
+  onShareAppMessage(res) {
+		console.log("pagesOrder/info?id="+this.detailInfo.id)
+		let price = this.detailInfo.orderPrice ? parseFloat(this.detailInfo.orderPrice):0
+		return {
+			title: this.detailInfo.addTime.substr(5,11)+' ¥'+price,
+			desc: "",
+			path: "pagesOrder/info?id="+this.detailInfo.id,
+		}
+	},
   methods: {
     //打印订单
     printOrder() {
@@ -38,6 +51,9 @@ export default {
           id: this.option.orderId,
         });
         this.detailInfo = res.data;
+        if(this.detailInfo.customName && !this.$util.isEmpty(this.detailInfo.customName)) {
+          this.customName = this.detailInfo.customName
+        }
       }
     },
     //发货
@@ -63,7 +79,7 @@ export default {
 
 <style lang="scss" scoped>
 .admin-button-com {
-  margin-bottom: 20upx;
+  margin-bottom:30upx;
   width: 100%;
 }
 </style>

+ 4 - 0
ghsApp/src/api/order/index.js

@@ -26,6 +26,10 @@ export const getDetail = data => {
 	return https.get("/order/detail", data);
 };
 
+export const getInfo = data => {
+	return https.get("/order/info", data);
+};
+
 //到货前获取详情
 export const getArrivalDetail = data => {
 	return https.get("/order/arrival-detail", data);

+ 1 - 0
ghsApp/src/pages.json

@@ -82,6 +82,7 @@
 			"root": "pagesOrder",
 			"pages": [
 				{"path": "detail","style": {"navigationBarTitleText": "订单详情", "enablePullDownRefresh": true}},
+				{"path": "info","style": {"navigationBarTitleText": "订单详情", "enablePullDownRefresh": true}},
 				{"path": "arrival","style": {"navigationBarTitleText": "到货处理"}},
 				{"path": "result","style": {"navigationBarTitleText": "结果"}},
 				{"path": "refund","style": {"navigationBarTitleText": "退款"}},

+ 20 - 6
ghsApp/src/pagesOrder/detail.vue

@@ -222,6 +222,9 @@
 
 		</view>
 		<div class="app-footer">
+			<!-- #ifdef MP-WEIXIN -->
+			<button class="admin-button-com default" v-if="detailInfo.status == 4" open-type="share">分享给客户</button>
+			<!-- #endif -->
 			<button @click="cancelOrderFn(detailInfo)" v-if="detailInfo.status == 1" class="admin-button-com default" :class="active">取消</button>
 			<template v-for="s in detailInfo.buttonList">
 				<button :key="s.type" @click="clickBtn(s, detailInfo)" v-if="s.show == 1" :disabled="s.disable === 1" class="admin-button-com default" :class="s.disable === 1?'active':''">
@@ -248,7 +251,6 @@ import stepStatus from "./components/stepStatus";
 import TuiListCell from "@/components/plugin/list-cell";
 import { getDetail,debtPay,hasPay, freeShipping,confirmFinish,cancel } from "@/api/order/index";
 import { getOrderProduct } from "@/api/order-item/index";
-import { clearOrderApi } from "@/api/arrears/index";
 import productMins from "@/mixins/product";
 import { ORDER_STATUS } from "@/utils/declare";
 import BLE from "@/mixins/BLE";
@@ -279,11 +281,20 @@ export default {
 			showCancelBtn: true
 		};
 	},
-  onPullDownRefresh() {
-    this.init().then(res => {
-      uni.stopPullDownRefresh()
-    })
-  },
+	onPullDownRefresh() {
+		this.init().then(res => {
+		uni.stopPullDownRefresh()
+		})
+	},
+  	onShareAppMessage(res) {
+		console.log("pagesOrder/info?id="+this.detailInfo.id)
+		let price = this.detailInfo.orderPrice ? parseFloat(this.detailInfo.orderPrice):0
+		return {
+			title: this.detailInfo.addTime.substr(5,11)+' ¥'+price,
+			desc: "",
+			path: "pagesOrder/info?id="+this.detailInfo.id,
+		}
+	},
 	onShow() {
 		this.init();
 	},
@@ -338,6 +349,9 @@ export default {
 		},
 		modalCancel() {
 			this.freeShipModal = false;
+		},
+		shareOrder(info){
+
 		},
 		cancelOrderFn(info) {
 			let that = this

+ 765 - 0
ghsApp/src/pagesOrder/info.vue

@@ -0,0 +1,765 @@
+<template>
+	<view class="app-content">
+		<view v-if="!$util.isEmpty(detailInfo)" class="info-content_box">
+			<view class="title">
+				客户
+			</view>
+			<view class="address-des_bx content-box" @click='pageTo({url:"/pagesClient/member/detail",query: {id: detailInfo.customId}})'>
+				<view>
+					<view style="overflow:hidden;text-overflow:ellipsis;white-space: nowrap;width:450upx;"> {{ detailInfo.customName }} {{ detailInfo.customMobile }}</view>
+					<view style="margin-bottom:20upx;color:#333333">店长:{{ detailInfo.customSuper.name||''}}</view>
+					<view>{{ detailInfo.customAddress}}</view>
+				</view>
+				<view>
+				<i @click.stop="callUp(detailInfo.customMobile)" class="iconfont icondianhua1"></i>
+				<i @click.stop="navigateTo(detailInfo.lat,detailInfo.long,detailInfo.customName)" class="iconfont icondianhua" style="font-size:53upx;margin-left:40upx;margin-right:25upx;color:#3385ff;"></i>
+				</view>
+			</view>
+			<view class="title">
+				单据信息
+			</view>
+			<view class="bills-info_box content-box">
+				<view class="order-info_box">
+					<view>订单日期:</view>
+					<view>{{ detailInfo.addTime?detailInfo.addTime.substr(5,11):'' }}</view>
+				</view>
+				<view class="order-info_box">
+					<view>订单编号:</view>
+					<view>{{ detailInfo.orderSn }}</view>
+					<view class="price">
+						<button @click="copy(detailInfo.orderSn)" class="admin-button-com default">复制</button>
+					</view>
+				</view>
+				<view class="order-info_box">
+					<view>客户单号:</view>
+					<view>{{ detailInfo.cgInfo.orderSn }}</view>
+				</view>
+				<view class="order-info_box" v-if="detailInfo.book == 1">
+				<view>订单类型:</view>
+				<view>
+					<text style="color:white;border:1px solid #657cac;border-radius:20upx;font-size:20upx;padding:5upx 12upx;background:#657cac;">预订单</text>
+				</view>
+				</view>
+				<view class="order-info_box">
+					<view>送货时间:</view>
+					<view>{{ detailInfo.sendTimeWant }}</view>
+				</view>
+				<view class="order-info_box">
+					<view>开单人员:</view>
+					<view>{{ detailInfo.shopAdminName }}</view>
+				</view>
+				<view class="order-info_box" v-if="detailInfo.status != 1 && detailInfo.status!=5">
+					<view>客户下单:</view>
+					<view v-if="detailInfo.customShopAdminId == 0">--</view>
+					<view v-else>
+						<i class="iconfont icondagou" style="font-size:35upx;"></i>
+					</view>
+				</view>
+				<view class="order-info_box" v-if="detailInfo.status != 1 && detailInfo.status!=5">
+					<view>支付方式:</view>
+					<view>{{ detailInfo.payWay==0?'微信':detailInfo.payWay==1?'支付宝':detailInfo.payWay==2?'余额':detailInfo.payWay==4?'现金':detailInfo.payWay==5?'银行卡':'--' }}</view>
+				</view>
+				<view class="order-info_box">
+					<view>订单状态:</view>
+					<view>{{ detailInfo.status==1?'待付款':detailInfo.status==2?'待配送':detailInfo.status==3?'配送中':detailInfo.status==4?'已完成':detailInfo.status==5?'已取消':'已退款' }}</view>
+				</view>
+				<view v-if="detailInfo.status==1" class="order-info_box">
+					<view>过期时间:</view>
+					<view>{{detailInfo.deadline?detailInfo.deadline.substr(5,11):''}}</view>
+				</view>
+				<view v-if="detailInfo.refund == 2" class="order-info_box">
+					<view>累计退款:</view>
+					<view style="color:red;font-weight:bold;font-size:30upx;">{{parseFloat(detailInfo.tkPrice)}}</view>
+					<view class="price" v-if="detailInfo.refund==2">
+						<button @click="pageTo({url: '/pagesOrder/refundList',query: {orderSn: detailInfo.orderSn}})" class="admin-button-com">退款记录</button>
+					</view>
+				</view>
+				<view v-if="detailInfo.refund == 2" class="order-info_box">
+					<view>退款方式:</view>
+					<view style="color:red;font-weight:bold;font-size:30upx;">{{detailInfo.tkExplain||''}}</view>
+				</view>
+			</view>
+
+			<view class="bills-info_box content-box" style="margin-top:25upx;">
+				<view class="order-info_box" v-if="detailInfo.debt == 1">
+				<view>结算状态:</view>
+					<view style="color:red;font-weight:bold;">欠款</view>
+				</view>
+				<view class="order-info_box" v-else>
+				<view>结算状态:</view>
+					<view v-if="detailInfo.clearId > 0">已结清</view>
+					<view class="price" v-if="detailInfo.clearId > 0">
+					</view>
+					<view v-if="detailInfo.clearId == 0">--</view>          
+				</view>
+			</view>
+
+			<view class="content-box shipping-address" v-if="detailInfo.expressProgress!=''">
+				<view> 配送进展:<text>{{ detailInfo.expressProgress.progressName }}</text> </view>
+				<i class="iconfont iconqishouyinying"></i>
+			</view>
+			<view class="flex-space title">
+				商品信息
+			</view>
+			<view class="module-com content-box">
+				<view class="commodity-view">
+					<view class="commodity-list">
+						<view v-for="(s, idx) in detailInfo.product" :key="idx" class="commodity-item" >
+							<image class="item-icon" :src="s.cover" @click="pageTo({url:'/admin/item/detail',query:{id: s.productId}})" />
+							<view class="item-info">
+								<view class="info-line">
+									<text class="item-name">{{ s.name }}</text>
+									<text class="item-price">
+										<text class="unit"></text>
+										<text class="price">
+											<text v-if="detailInfo.stockChange == 1">{{parseFloat(s.xhNum)}}{{s.xhUnitName}}*¥{{parseFloat(s.xhUnitPrice)}}</text>
+											<text></text>
+										</text>
+									</text>
+								</view>
+								<view class="info-line">
+									<text class="item-type" v-if="detailInfo.book == 1">预订 {{ parseFloat(s.xhPreNum) }}{{s.xhUnitName}}*¥{{parseFloat(s.xhPreUnitPrice)}}</text>
+									<text class="item-type" v-else></text>
+									<text class="item-count" v-if="detailInfo.stockChange == 1">¥{{parseFloat(s.xhPrice)}}</text>
+									<text class="item-count" v-else></text>
+								</view>
+							</view>
+						</view>
+					</view>
+					<view class="summary-bar">
+						<view class="operate-view" ></view>
+						<view class="describe-view">
+							共{{ detailInfo.productStat.kind}}种,共
+							<text v-if="detailInfo.productStat.bigNum > 0">{{ detailInfo.productStat.bigNum }}扎</text>
+							<text v-if="detailInfo.productStat.smallNun > 0">{{detailInfo.productStat.smallNun}}支</text>
+							,合计 ¥<text class="price">{{ totalItemPrice }}</text>
+						</view>
+					</view>
+				</view>
+			</view>
+			<view v-if="detailInfo.remark!=''" class="content-box price-detail">
+				<div class="module-com input-line-wrap">
+					<tui-list-cell class="line-cell" :hover="false">
+						<div class="tui-title">备注</div>
+						<div>{{ detailInfo.remark }}</div>
+					</tui-list-cell>
+				</div>
+			</view>
+
+			<view class="content-box price-detail" v-if="detailInfo.book == 0">
+				<div class="module-com input-line-wrap">
+					<tui-list-cell class="line-cell" v-if="detailInfo.sendCost > 0" :hover="false">
+						<div class="tui-title">运费</div>
+						<div class="detail-price_box" style="font-size: 28upx">¥{{ parseFloat(detailInfo.sendCost) }}</div>
+					</tui-list-cell>
+					<tui-list-cell class="line-cell" v-if="detailInfo.labourCost > 0" :hover="false">
+						<div class="tui-title">人工资材费</div>
+						<div class="detail-price_box" style="font-size: 28upx">¥{{ parseFloat(detailInfo.labourCost) }}</div>
+					</tui-list-cell>
+					<tui-list-cell v-if="detailInfo.discountAmount > 0" class="line-cell" :hover="false">
+						<div class="tui-title"><text v-if="detailInfo.discountType == 4">红包</text><text v-else>优惠金额</text></div>
+						<div class="detail-price_box" style="font-size: 28upx">-¥{{ parseFloat(detailInfo.discountAmount) }}</div>
+					</tui-list-cell>
+					<tui-list-cell v-if="detailInfo.refundPrice > 0" class="line-cell" :hover="false">
+						<div class="tui-title">订单金额</div>
+						<div class="detail-price_box" style="font-size: 28upx">¥{{ parseFloat(detailInfo.orderPrice) }}</div>
+					</tui-list-cell>
+					<tui-list-cell v-if="detailInfo.refundPrice > 0" class="line-cell" :hover="false">
+						<div class="tui-title">退款金额</div>
+						<div class="detail-price_box" style="font-size: 28upx">-¥{{ parseFloat(detailInfo.refundPrice) }}</div>
+					</tui-list-cell>
+					<tui-list-cell class="line-cell" :hover="false">
+						<div class="tui-title">实际金额</div>
+						<div class="detail-price_box" style="font-size: 32upx;">¥{{ parseFloat(detailInfo.realPrice)}}</div>
+					</tui-list-cell>
+				</div>
+			</view>
+
+			<view class="content-box price-detail" v-else>
+				<div class="module-com input-line-wrap">
+				<tui-list-cell class="line-cell" :hover="false">
+					<div class="tui-title">重量(公斤)</div>
+					<div class="detail-price_box" style="font-size: 28upx;">
+					<text v-if="Number(detailInfo.miniKilo) > Number(detailInfo.weight)" style="color:#CCCCCC;margin-right:15upx;">未达{{parseFloat(detailInfo.miniKilo)}}公斤按{{parseFloat(detailInfo.miniKilo)}}公斤计算</text>
+					<text>{{ detailInfo.weight ? parseFloat(detailInfo.weight) : 0 }}</text>
+					</div>
+				</tui-list-cell>
+				<tui-list-cell class="line-cell" :hover="false">
+					<div class="tui-title">服务费</div>
+					<div class="detail-price_box" style="font-size: 28upx;">
+						<text style="color:#CCCCCC;margin-right:15upx;">{{ Number(detailInfo.miniKilo) > Number(detailInfo.weight) ? parseFloat(detailInfo.miniKilo) : parseFloat(detailInfo.weight) }}*¥{{ detailInfo.kiloFee ? parseFloat(detailInfo.kiloFee) : 0}}</text>
+						<text>¥{{ detailInfo.allKiloFee ? parseFloat(detailInfo.allKiloFee) : 0}}</text>
+					</div>
+				</tui-list-cell>
+				<tui-list-cell class="line-cell" :hover="false">
+					<div class="tui-title">商品金额</div>
+					<div class="detail-price_box" style="font-size: 28upx;">¥{{ detailInfo.itemPrice ? parseFloat(detailInfo.itemPrice) : 0 }}</div>
+				</tui-list-cell>
+				<tui-list-cell class="line-cell" :hover="false">
+					<div class="tui-title">总计</div>
+					<div class="detail-price_box red" style="font-size: 28upx;">¥{{ detailInfo.orderPrice ? parseFloat(detailInfo.orderPrice) : 0 }}</div>
+				</tui-list-cell>
+				<tui-list-cell class="line-cell" :hover="false">
+					<div class="tui-title">预付金额</div>
+					<div class="detail-price_box red" style="font-size: 28upx;">¥{{ detailInfo.bookPrice ? parseFloat(detailInfo.bookPrice) : 0}}</div>
+				</tui-list-cell>
+				<tui-list-cell class="line-cell" :hover="false" v-if="detailInfo.stockChange == 1">
+						<view class="tui-title">结账</view>
+						<view class="detail-price_box" style="font-size: 28upx;color:green;" v-if="settlePrice > 0">退 ¥{{settlePrice}}</view>
+						<view class="detail-price_box" style="font-size: 28upx;color:red;" v-else-if="settlePrice < 0">欠 ¥{{Math.abs(settlePrice)}}</view>
+						<view class="detail-price_box" style="font-size: 28upx;" v-else>0</view>
+				</tui-list-cell>
+				</div>
+			</view>
+
+		</view>
+		<div class="app-footer">
+		</div>
+	</view>
+</template>
+
+<script>
+import { mapGetters } from "vuex";
+import stepStatus from "./components/stepStatus";
+import TuiListCell from "@/components/plugin/list-cell";
+import { getInfo,debtPay,hasPay, freeShipping,confirmFinish,cancel } from "@/api/order/index";
+import { getOrderProduct } from "@/api/order-item/index";
+import productMins from "@/mixins/product";
+import { ORDER_STATUS } from "@/utils/declare";
+import BLE from "@/mixins/BLE";
+import { cloudPrintOrder, cancelOrder } from "@/api/order";
+import { hasHitNavigate } from "@/api/map";
+export default {
+	name: "orderDetail",
+	components: {
+		stepStatus,
+		TuiListCell
+	},
+	mixins: [productMins,BLE],
+	data() {
+		return {
+			ORDER_STATUS,
+			orderId:'',
+			selectJobType: "order_change",
+			autoLoad: false,
+			stepActive: 0,
+			totalItemPrice: 0,
+			form: {
+				name: ""
+			},
+			detailInfo: {},
+			freeShipModal: false,
+			loading: false,
+			settlePrice:0,
+			showCancelBtn: true
+		};
+	},
+  onPullDownRefresh() {
+    this.init().then(res => {
+      uni.stopPullDownRefresh()
+    })
+  },
+	onShow() {
+		this.init();
+	},
+	computed: {
+		...mapGetters({ loginInfo: "getLoginInfo" }),
+	},
+	methods: {
+		goRefund(){
+			if(this.detailInfo.payWay == 1){
+				this.$msg('支付宝订单暂不支持退款,请线下退款')
+				return false
+			}
+			this.$util.pageTo({url:'/pagesOrder/refund?id='+this.option.id})
+		},
+		navigateTo(latitude, longitude, address) {
+			// #ifdef APP-PLUS
+			let that = this
+			if(that.loginInfo.hasHitNavigate != 1){
+              that.$util.confirmModal({content:'打开后点右下角按钮可正常导航'},() => {
+				hasHitNavigate().then(res=>{ 
+				  console.log(res.code)
+				  that.$store.commit("setHitNavigation")
+				})
+				that.openNavigateto(latitude, longitude, address)
+              })
+			}else{
+				that.openNavigateto(latitude, longitude, address)
+			}
+			// #endif
+			// #ifdef MP-WEIXIN
+			 this.openNavigateto(latitude, longitude, address)
+			// #endif
+		},
+		openNavigateto(latitude, longitude, address){
+			// 将经纬度转换成Number
+			let latituded = Number(latitude);
+			let longituded = Number(longitude);					
+			uni.openLocation({
+				latitude: latituded,
+				longitude: longituded,
+				address: address,
+				success: function() {
+					console.log('success');
+				}
+			});
+		},
+		freeShipModalClick() {
+			freeShipping({ id: this.detailInfo.id }).then(res => {
+				this.init();
+				this.$msg("操作成功!");
+			})
+		},
+		modalCancel() {
+			this.freeShipModal = false;
+		},
+		cancelOrderFn(info) {
+			let that = this
+			that.$util.confirmModal({content:'确认取消?'},() => {
+				var params = {orderId:info.id}
+				cancelOrder(params).then((res) => {
+					if(res.code == 1){
+						this.showCancelBtn = false
+						this.detailInfo.status = 5
+						this.$msg("取消成功")
+					}
+				}).catch((error) => {
+					console.error(error);
+				})
+			})
+		},
+		showCancelOrder(cgInfo) {
+			if (cgInfo == undefined) {
+				return false
+			}
+			var status = cgInfo.status
+			var deadline = cgInfo.deadline
+			if (status != 1) {
+				return false
+			}
+
+			if (deadline == "" || deadline == undefined) {
+				return false
+			}
+			var orderTimestamp = this.formatDate(deadline)
+			var currTimestam = new Date().getTime() / 1000
+			var diff = orderTimestamp - currTimestam
+
+			//console.log(orderTimestamp)
+			//console.log(currTimestam)
+			//console.log(diff)
+			if (diff > 120) {
+				return true
+			}
+
+			return false
+		},
+		formatDate(deadline) {
+			var timeStr = String(deadline)
+			const [dateComponents, timeComponents] = timeStr.split(' ');
+			//console.log(dateComponents);
+			//console.log(timeComponents);
+
+			const [year, month, day] = dateComponents.split('-');
+			const [hours, minutes, seconds] = timeComponents.split(':');
+
+			const date = new Date(+year, month - 1, +day, +hours, +minutes, +seconds);
+			//console.log(date);
+
+			// Get Unix timestamp
+			const unixTimestamp = Math.floor(date.getTime() / 1000);
+			//console.log(unixTimestamp);
+			return unixTimestamp;
+		},
+		clickBtn(s, item) {
+			this.orderId = item.id;
+			if (s.type === "selfGet") {
+				// 自取
+				let self = this;
+				self.$util.confirmModal({content:'确认客户已自取'},() => {
+					self.freeShipModalClick()
+				})
+				this.freeShipModal = true;
+			}else if(s.type === 'arrival'){
+				//到货
+				this.pageTo({url: "/pagesOrder/arrival",query: {id: item.id}});
+			} else if (s.type === "print") {
+				if(item.hasCloudPrint == 1){
+					//云打印
+					uni.showLoading({title:"打印中..."})
+					cloudPrintOrder({id:item.id}).then((res) => {
+						item.printNum++
+						uni.hideLoading()
+					})
+				}else{
+					console.log('走蓝牙打印方式')
+					let BleVal = JSON.parse(item.printData);
+					switch(uni.getSystemInfoSync().platform){
+						case 'android':
+							this.destroyed(BleVal);
+							break;
+						case 'ios':
+							this.autoLinkBle(BleVal);
+							break;
+					}
+				}
+			} else if (s.type === "send") {
+				//发货
+				this.pageTo({url: "/pagesOrder/ship",query: {id: item.id}});
+			}else if (s.type === "debtPay") {
+				let self = this;
+				//延期收款
+				self.$util.confirmModal({content:'确认要延期收款?'},() => {
+					return debtPay({ id: self.option.id }).then(res => {
+						console.log(res)
+						uni.showToast({title:'操作成功!',icon:'none'})
+						self.init();
+					})
+				})
+			}else if (s.type === "hasPay") {
+				let self = this;
+				//已收款
+				self.$util.confirmModal({content:'您确认已收款?'},() => {
+					return hasPay({ id: self.option.id }).then(res => {
+						uni.showToast({title:'操作成功!',icon:'none'})
+						self.init();
+					})
+				})
+			}else if (s.type === "modifyProduct") {
+				//修改花材
+				let self = this;
+				let orderId = item.id
+				let customName = item.customName
+				let customId = item.customId
+				let modifyProductKey = 'modifyProduct_orderId_'+orderId
+
+				getOrderProduct({ id: orderId }).then(res => {
+					let productList = res.data.productList
+					uni.setStorageSync('selectList_'+modifyProductKey, productList)
+					self.$util.pageTo({url: '/admin/billing/index',type:2,query: {customId: customId,customName:customName,orderId:orderId,modifyProductKey:modifyProductKey}})
+				})
+
+			}else if(s.type == 'confirm'){
+				let self = this;
+				uni.showActionSheet({
+					itemList: ['结算方式:', '欠款', '已收款'],
+					success: function (res) {
+						if(res.tapIndex == 0){
+							return false
+						}
+						let payWay = 0
+						let title = res.tapIndex == 1 ? '确认客户欠款?' : '确认已收款?'
+						//1欠款 2已收款
+						let clearType = res.tapIndex == 1 ? 1 : 2;
+						//选择的已收款,还需要选择收款方式
+						if(clearType == 2){
+							uni.showActionSheet({
+								itemList: ['收款方式:', '微信', '支付宝','现金','银行卡'],
+								success: function (respond) {
+									let currentIndex = respond.tapIndex
+									let inWay = [{name:"未选择",id:-1},{name:"微信",id:0},{name:"支付宝",id:1},{name:"现金",id:4},{name:"银行卡",id:5}]
+									if(currentIndex == 0){
+										return false
+									}
+									payWay = inWay[currentIndex].id
+									let params = {id:item.id,clearType:clearType,payWay:payWay}
+									self.toConfrim(params,title)
+								}
+							})
+						}else{
+							let params = {id:item.id,clearType:clearType,payWay:payWay}
+							self.toConfrim(params,title)
+						}
+					}
+				});
+			}else if(s.type == 'cancel'){
+				let self = this;
+				self.$util.confirmModal({content:'确认取消订单?'},() => {
+					cancel({id:item.id}).then((res) => {
+						uni.showToast({title:res.msg,icon:'none'})
+						self.init();
+					})
+				})
+			}
+		},
+		toConfrim(params,title){
+			let that = this
+			that.$util.confirmModal({content:'订单完成'},() => {
+				that.toConfirmRequest(params)
+			})
+		},
+		toConfirmRequest(params){
+			let self = this;
+			confirmFinish(params).then((res) => {
+				uni.showToast({title:res.msg,icon:'none'})
+				self.init();
+			})
+		},
+		copy(val) {
+			const self = this;
+			uni.setClipboardData({
+				data: val,
+				success: function() {
+					self.$msg("复制成功");
+				}
+			});
+		},
+		callUp(mobile) {
+			this.$util.callUp(mobile)
+		},
+		async init() {
+			try {
+				if (this.loading) {
+					return new Promise.reject();
+				}
+				this.loading = true;
+				const res = await getInfo({
+					id: this.option.id
+				});
+				this.detailInfo = res.data;
+
+				this.settlePrice = Number(this.detailInfo.bookPrice) - Number(this.detailInfo.orderPrice)
+				this.settlePrice = parseFloat(this.settlePrice.toFixed(2))
+
+				this.totalItemPrice = 0
+				this.detailInfo.product.forEach(ele=>{
+						this.totalItemPrice += Number(ele.xhPrice)
+				})
+				this.totalItemPrice = this.totalItemPrice.toFixed(2)
+				this.totalItemPrice = parseFloat(this.totalItemPrice)
+
+				const { product } = this.detailInfo;
+
+				if (product) {
+					this.setSelectInfo({
+						selectJobType: this.selectJobType,
+						info: product.map(ele => { return { ...ele, bigCount: Number(ele.bigNum), smallCount: Number(ele.smallNum) } }),
+						selectJobId:this.selectJobId
+					});
+				}
+			} catch {
+			} finally {
+				this.loading = false;
+			}
+		},
+		gotoSelect() {
+			uni.navigateTo({url: `/pagesOrder/select?id=${this.detailInfo.id}`});
+		}
+	}
+};
+</script>
+
+<style lang="scss" scoped>
+.info-content_box {
+	padding: 0 20upx 100upx;
+	& > .title {
+		color: #666666;
+		font-size: 28upx;
+		font-weight: 600;
+		padding: 30upx 3upx;
+	}
+	& .address-des_bx {
+		display: flex;
+		padding: 20upx 10upx 30upx 20upx;
+		& > view:nth-child(1) {
+			flex: 1;
+			margin-top: 10upx;
+			& > view:nth-child(1) {
+				color: #333333;
+				font-size: 32upx;
+				font-weight: bold;
+			}
+			& > view:nth-child(2) {
+				color: #666666;
+				font-size: 28upx;
+				font-weight: 400;
+				margin-top: 20upx;
+			}
+		}
+		& > view:nth-child(2) {
+			display: flex;
+			& .icondianhua1 {
+				font-size: 50upx;
+				color: #3385ff;
+				margin-left: 0upx;
+			}
+		}
+	}
+	.bills-info_box {
+		padding: 30upx 20upx 30upx;
+		& > .order-info_box {
+			display: flex;
+			align-items: center;
+			font-size: 26upx;
+			font-weight: 400;
+			margin-bottom: 5upx;
+			& > view:nth-child(1) {
+				color: #999999;
+				width: 135upx;
+				text-align: right;
+			}
+			& > view:nth-child(2) {
+				color: #333333;
+			}
+			& > .price {
+				flex: 1;
+				font-size: 30upx;
+				color: #333333;
+				display: flex;
+				align-items: center;
+				justify-content: flex-end;
+				& .iconxiangyou {
+					color: #999999;
+					font-size: 25upx;
+					margin-left: 12upx;
+				}
+			}
+		}
+	}
+	.content-box {
+		background-color: #ffffff;
+		border-radius: 10upx;
+	}
+	.commodity-view {
+		display: flex;
+		flex-direction: column;
+		.commodity-list {
+			padding: 20upx;
+			.commodity-item {
+				display: flex;
+				margin-bottom: 20upx;
+				.item-icon {
+					flex-shrink: 0;
+					width: 140upx;
+					height: 140upx;
+				}
+				.item-info {
+					display: flex;
+					flex-direction: column;
+					justify-content: center;
+					flex: 1;
+					margin-left: 20upx;
+					.info-line {
+						margin-bottom: 20upx;
+						display: flex;
+						justify-content: space-between;
+						align-items: flex-end;
+						.item-name {
+							color: black;
+							font-size: 30upx;
+							font-weight: 700;
+							overflow: hidden;
+							white-space: nowrap;
+							text-overflow: ellipsis;
+							width:360upx;
+						}
+						.item-price {
+							color: #333;
+							font-size: 22upx;
+							.price {
+								font-size: 25upx;
+							}
+						}
+						.item-type {
+							color: #999;
+							font-size: 24upx;
+						}
+						.item-count {
+							color: #666;
+							font-size: 24upx;
+						}
+					}
+				}
+			}
+		}
+		.summary-bar {
+			padding: 0 20upx;
+			height: 90upx;
+			display: flex;
+
+			align-items: center;
+			justify-content: space-between;
+			border-top: 1upx solid #eeeeee;
+			.operate-view {
+				display: flex;
+
+				align-items: center;
+				color: #3385ff;
+				font-size: 26upx;
+				.iconfont {
+					margin-right: 20upx;
+					font-size: 40upx;
+				}
+			}
+			.describe-view {
+				display: flex;
+
+				align-items: center;
+				color: #333;
+				font-size: 24upx;
+				.price {
+					font-weight: bold;
+					font-size: 28upx;
+				}
+			}
+		}
+	}
+	.shipping-address {
+		display: flex;
+		align-items: center;
+		margin-top: 20upx;
+		& > view:nth-child(1) {
+			color: #999999;
+			font-size: 28upx;
+			font-weight: 400;
+			display: inline-block;
+			padding: 30upx 0 30upx 20upx;
+			flex: 1;
+			& > text {
+				color: #333333;
+				font-weight: 600;
+			}
+		}
+		& > view:nth-child(2) {
+			font-size: 60upx;
+			color: #d6e7ff;
+			margin-right: 10upx;
+		}
+	}
+	.price-detail {
+		margin-top: 20upx;
+		margin-bottom: 20upx;
+	}
+	.detail-price_box {
+		color: #333333;
+		font-size: 22upx;
+		text-align: right;
+		flex: 1;
+		font-weight: 600;
+		&.red {
+			color: #ff2842;
+		}
+	}
+}
+.app-footer {
+	display: flex;
+	align-items: center;
+	justify-content: flex-end;
+	& .admin-button-com {
+		padding: 0;
+		margin-right:40upx;
+		width: 180upx;
+		height: 90upx;
+		line-height: 90upx;
+		font-size:30upx;
+		text-align: center;
+		color: #3385ff;
+		border: 1upx solid #3385ff;
+		&.active{
+			color: #666666;
+			border: 1upx solid #ccc;
+		}
+	}
+}
+</style>