Browse Source

收款工具

zhengjinyi 3 năm trước cách đây
mục cha
commit
898a232a84

+ 75 - 27
components/cm-module/receipt/receipt-details.vue

@@ -1,7 +1,7 @@
 <template name="information">
 	<view class="information-template">
 		<!-- 订单信息 -->
-		<view class="list-title" @click.stop="orderDetail(order.id)">
+		<view class="list-title" @click.stop="orderDetail(order.orderId)">
 			<view class="list-title-t">
 				<view class="list-title-tip">
 					<text class="badges">{{ order.orderType | formatOrderType }}</text>
@@ -9,7 +9,7 @@
 				<view class="list-title-tag" v-if="order.organizeId == 3">
 					<text class="badges">维沙</text>
 				</view>
-				<view class="list-title-num">{{ order.statusName }}</view>
+				<view class="list-title-num">{{ order.status | stateExpFormat }}</view>
 			</view>
 			<view class="list-title-b">
 				客户名称:<text class="text">{{ order.userName }}</text>
@@ -56,7 +56,7 @@
 						}})
 					</text>
 				</text>
-				<text v-else>¥0.00(原¥0.00折扣取消¥0.00)</text>
+				<text class="text" v-else>¥0.00(原¥0.00折扣取消¥0.00)</text>
 			</view>
 			<view class="list-title-b" v-if="order.returnedPurchaseFee > 0">
 				退货退款:
@@ -86,29 +86,6 @@ export default {
 	created() {
 		this.initData(this.orderInfo)
 	},
-	filters: {
-		formatOrderType(value) {
-			switch (value) {
-				case 0:
-					return '协销订单'
-					break
-				case 1:
-					return '自主订单'
-					break
-				case 2:
-					return '客服订单'
-					break
-			}
-		},
-		NumFormat(value) {
-			//处理金额
-			if (value) {
-				return Number(value).toFixed(2)
-			} else {
-				return '0.00'
-			}
-		}
-	},
 	watch: {
 		orderInfo: {
 			handler: function(val) {
@@ -129,4 +106,75 @@ export default {
 }
 </script>
 
-<style lang="scss"></style>
+<style lang="scss">
+	.list-title {
+		width: 100%;
+		height: auto;
+	
+		.list-title-t {
+			width: 100%;
+			height: 50rpx;
+			float: left;
+			font-size: $font-size-24;
+			padding-bottom: 10rpx;
+			.list-title-tip {
+				float: left;
+				.badges {
+					display: block;
+					float: left;
+					padding: 0 15rpx;
+					height: 40rpx;
+					line-height: 40rpx;
+					border-radius: 20rpx;
+					background: rgba(248, 204, 148, 0.5);
+					font-size: $font-size-24;
+					text-align: center;
+					color: #666666;
+				}
+			}
+			.list-title-tag {
+				float: left;
+				margin-left: 20rpx;
+				.badges {
+					display: block;
+					float: left;
+					padding: 0 15rpx;
+					height: 40rpx;
+					line-height: 40rpx;
+					border-radius: 20rpx;
+					background: linear-gradient(270deg, #fee9ba 0%, #f0cb72 100%);
+					font-size: $font-size-24;
+					text-align: center;
+					color: #666666;
+				}
+			}
+			.list-title-num {
+				float: left;
+				text-align: left;
+				color: #e15616;
+				line-height: 40rpx;
+				margin-left: 20rpx;
+			}
+		}
+		.list-title-b {
+			width: 100%;
+			height: 40rpx;
+			float: left;
+			font-size: $font-size-24;
+			line-height: 40rpx;
+			color: #666666;
+			text-align: left;
+			.text {
+				color: #999999;
+			}
+			.list-title-b-item {
+				width: 50%;
+				height: 100%;
+				float: left;
+			}
+			&.sms {
+				height: auto;
+			}
+		}
+	}
+</style>

+ 21 - 22
components/cm-module/receipt/receipt-modal.vue

@@ -1,7 +1,7 @@
 <template name="modal">
 	<view class="modal-template">
 		<!-- 自定义弹窗内容 -->
-		<tui-modal :show="show" :padding="'40rpx 80rpx'" @cancel="handleClickCancel" :custom="true" fadeIn>
+		<tui-modal :show="show" :padding="'40rpx 60rpx'" @cancel="handleClickCancel" :custom="true" fadeIn>
 			<view class="tui-modal-custom">
 				<!-- 当收款金额等于所选订单的剩余应收金额 -->
 				<template v-if="handleType == 1">
@@ -22,56 +22,57 @@
 					</view>
 					<view class="tui-prompt-text">
 						剩余应收:<text class="text"
-							>¥{{ (amount - hanldOrder.payableAmount) | NumFormat }}({{
+							>¥{{ (amount - hanldOrder.surplusAmount) | NumFormat }}({{
 								hanldOrder.orderNums
 							}}个订单)</text
 						>
 					</view>
 				</template>
-				<!-- 当收款金额于所选订单的剩余应收金额 -->
+				<!-- 当收款金额于所选订单的剩余应收金额 -->
 				<template v-if="handleType == 2">
 					<view class="tui-prompt-text">
 						收款金额:<text class="text">¥{{ amount | NumFormat }}</text>
 					</view>
 					<view class="tui-prompt-text">
 						剩余应收:<text class="text"
-							>¥{{ hanldOrder.payableAmount | NumFormat }}({{ hanldOrder.orderNums }}个订单)</text
+							>¥{{ hanldOrder.surplusAmount | NumFormat }}({{ hanldOrder.orderNums }}个订单)</text
 						>
 					</view>
 					<view class="tui-prompt-text">
-						本次收款后,订单剩余未收款金额:<text class="text"
-							>¥{{ (amount - hanldOrder.payableAmount) | NumFormat }}</text
-						>抹平确认还是等值确认
+						本次收款金额超出剩余应收金额:<text class="text"
+							>¥{{ (amount - hanldOrder.surplusAmount) | NumFormat }}</text
+						>关联订单的同时将超出金额退到机构余额吗
 					</view>
 				</template>
-				<!-- 当收款金额于所选订单的剩余应收金额 -->
+				<!-- 当收款金额于所选订单的剩余应收金额 -->
 				<template v-if="handleType == 3">
 					<view class="tui-prompt-text">
 						收款金额:<text class="text">¥{{ amount | NumFormat }}</text>
 					</view>
 					<view class="tui-prompt-text">
 						剩余应收:<text class="text"
-							>¥{{ hanldOrder.payableAmount | NumFormat }}({{ hanldOrder.orderNums }}个订单)</text
+							>¥{{ hanldOrder.surplusAmount | NumFormat }}({{ hanldOrder.orderNums }}个订单)</text
 						>
 					</view>
 					<view class="tui-prompt-text">
-						本次收款金额超出剩余应收金额:<text class="text"
-							>¥{{ (amount - hanldOrder.payableAmount) | NumFormat }}</text
-						>关联订单的同时将超出金额退到机构余额吗
+						本次收款后,订单剩余未收款金额:<text class="text"
+							>¥{{ (hanldOrder.surplusAmount - amount ) | NumFormat }}</text
+						>抹平确认还是等值确认
 					</view>
 				</template>
 				<view class="tui-prompt-flex" v-if="handleType == 1">
 					<view class="btn btn-cancel" @click="handleClickCancel">取消</view>
-					<view class="btn btn-confirm" @click="handleClick">确认收款</view>
+					<view class="btn btn-confirm" @click="handleClick(4)">确认收款</view>
 				</view>
 				<view class="tui-prompt-flex" v-if="handleType == 2">
-					<view class="btn btn-warning" @click="handleClick">抹平确认</view>
-					<view class="btn btn-confirm" @click="handleClick">等值确认</view>
+					<view class="btn btn-cancel" @click="handleClickCancel">取消</view>
+					<view class="btn btn-confirm" @click="handleClick(3)">退到余额</view>
 				</view>
 				<view class="tui-prompt-flex" v-if="handleType == 3">
-					<view class="btn btn-cancel" @click="handleClickCancel">取消</view>
-					<view class="btn btn-confirm" @click="handleClick">退到余额</view>
+					<view class="btn btn-warning" @click="handleClick(1)">抹平确认</view>
+					<view class="btn btn-confirm" @click="handleClick(4)">等值确认</view>
 				</view>
+				
 			</view>
 		</tui-modal>
 	</view>
@@ -124,10 +125,8 @@ export default {
 			console.log('hanldOrder', this.hanldOrder)
 			console.log('amount', this.amount)
 		},
-		handleClick(e) {
-			this.$emit('click', {
-				index: Number(dataset.index)
-			})
+		handleClick(type) {
+			this.$emit('click',type)
 		},
 		handleClickCancel() {
 			this.$emit('cancel')
@@ -142,7 +141,7 @@ export default {
 	color: #333333;
 	line-height: 44rpx;
 	.text {
-		color: #999999;
+		color: $color-system;
 	}
 }
 .tui-prompt-flex {

+ 269 - 0
components/cm-module/receipt/receipt-orderDetails.vue

@@ -0,0 +1,269 @@
+<template name="information">
+	<view class="information-template">
+		<!-- 订单信息 -->
+		<view class="modal-content-mask" @click.stop="handleClickCancel">
+			<view class="modal-content-alert">
+				<scroll-view class="modal-content-scroll" scroll-y="true" >
+					<view class="list-title clearfix">
+						<view class="list-title-b"
+							>进度:<text :style="{ color: formatColor(receiptInfo.receiptStatus) }"
+								>{{ receiptInfo.receiptStatus | formatStateType }}</text
+							>
+						</view>
+						<view class="list-title-b">
+							<view class="list-title-b-item">
+								确认人:<text class="text">{{
+									receiptInfo.confirmUserName ? receiptInfo.confirmUserName : '无'
+								}}</text>
+							</view>
+							<view class="list-title-b-item ri">
+								<text class="text">{{ receiptInfo.confirmDate ? receiptInfo.confirmDate : '无' }}</text>
+							</view>
+						</view>
+						<view class="list-title-b">
+							<view class="list-title-b-item">
+								审核人:<text class="text">{{
+									receiptInfo.reviewUserName ? receiptInfo.reviewUserName : '无'
+								}}</text>
+							</view>
+							<view class="list-title-b-item ri">
+								<text class="text">{{ receiptInfo.reviewDate ? receiptInfo.reviewDate : '无' }}</text>
+							</view>
+						</view>
+						<view class="list-title-b">
+							备注:<text>{{ receiptInfo.reviewReason }}</text>
+						</view>
+					</view>
+					<view class="list-title clearfix" v-for="(order, index) in receiptInfo.orderList" :key="index" @click.stop="orderDetail(order.orderId)">
+						<view class="list-title-t">
+							<view class="list-title-tip">
+								<text class="badges">{{ order.orderType | formatOrderType }}</text>
+							</view>
+							<view class="list-title-tag" v-if="order.organizeId == 3">
+								<text class="badges">维沙</text>
+							</view>
+							<view class="list-title-num">{{ order.status | stateExpFormat }}</view>
+						</view>
+						<view class="list-title-b">
+							客户名称:<text class="text">{{ order.userName }}</text>
+						</view>
+						<view class="list-title-b">
+							订单编号:<text class="text">{{ order.orderNo }} ( {{ order.orderId }} )</text>
+						</view>
+						<view class="list-title-b">
+							下单日期:<text class="text">{{ order.orderTime }}</text>
+						</view>
+						<view class="list-title-b">
+							<view class="list-title-b-item ">
+								订单金额:<text class="text">¥{{ order.payTotalFee | NumFormat }}</text>
+							</view>
+							<view class="list-title-b-item ">
+								余额抵扣:<text class="text">¥{{ order.balancePayFee | NumFormat }}</text>
+							</view>
+						</view>
+						<view class="list-title-b">
+							<view class="list-title-b-item ">
+								应收金额:<text class="text">¥{{ order.payableAmount | NumFormat }}</text>
+							</view>
+							<view class="list-title-b-item ">
+								已收金额:<text class="text">¥{{ order.paidAmount | NumFormat }}</text>
+							</view>
+						</view>
+						<view class="list-title-b">
+							<view class="list-title-b-item ">
+								剩余应收:<text class="text">¥{{ order.surplusAmount | NumFormat }}</text>
+							</view>
+							<view class="list-title-b-item ">
+								待审金额:<text class="text">¥{{ order.receiptAmount | NumFormat }}</text>
+							</view>
+						</view>
+						<view class="list-title-b">
+							经理折扣:
+							<text class="text" v-if="order.discountFee - order.returnedPurchaseFee > 0">
+								¥{{ order.discountFee - order.returnedPurchaseFee }}
+								<text>
+									(原¥{{ order.discountFee }} 折扣取消¥{{
+										order.discountFee - order.returnedPurchaseFee > 0
+											? order.returnedPurchaseFee
+											: order.discountFee
+									}})
+								</text>
+							</text>
+							<text class="text" v-else>¥0.00(原¥0.00折扣取消¥0.00)</text>
+						</view>
+						<view class="list-title-b" v-if="order.returnedPurchaseFee > 0">
+							退货退款:
+							<text class="text">
+								(原¥{{ order.returnedPurchaseFee }} 折扣取消¥{{
+									j.discountFee - j.returnedPurchaseFee > 0 ? order.returnedPurchaseFee : order.discountFee
+								}})
+							</text>
+						</view>
+					</view>
+				</scroll-view>
+			</view>
+		</view>
+		
+	</view>
+</template>
+
+<script>
+export default {
+	name: 'information',
+	props: {
+		receipt: {
+			type: Object
+		}
+	},
+	data() {
+		return {
+			receiptInfo: {}
+		}
+	},
+	created() {
+		this.initData(this.receipt)
+	},
+	watch: {
+		orderInfo: {
+			handler: function(val) {
+				this.initData(val)
+			},
+			deep: true //对象内部的属性监听,也叫深度监听
+		}
+	},
+	methods: {
+		initData(data) {
+			this.receiptInfo = data
+			console.log('this.receiptInfo',this.receiptInfo)
+		},
+		formatColor(state) {
+			//设置邀请码状态亚瑟
+			let stateColor = '',
+				stateColorObject = {
+					1: '#FEAC20',
+					2: '#4cd964',
+					3: '#34CC8C',
+					4: '#F94B4B',
+					5: '#007aff'
+				}
+			Object.keys(stateColorObject).forEach(function(key) {
+				if (key == state) {
+					stateColor = stateColorObject[key]
+				}
+			})
+			return stateColor
+		},
+		handleClickCancel(){// 隐藏
+			this.$emit('cancel')
+		},
+		orderDetail(id) {
+			//订单详情跳转
+			this.$api.navigateTo(`/pages/relation/order/detail?orderId=${id}`)
+		}
+	}
+}
+</script>
+
+<style lang="scss">
+	.modal-content-mask{
+		width: 100%;
+		height: 100%;
+		background: rgba(0,0,0,0.6);
+		position: fixed;
+		top: 0;
+		left: 0;
+		z-index: 1000;
+		.modal-content-alert{
+			width: 600rpx;
+			height: 600rpx;
+			padding: 24rpx;
+			background: #FFFFFF;
+			border-radius: 20rpx;
+			position: absolute;
+			top: 0;
+			left: 0;
+			bottom: 0;
+			right: 0;
+			margin: auto;
+			overflow: hidden;
+			.modal-content-scroll{
+				width: 100%;
+				height: 600rpx;
+				padding-bottom: 24rpx;
+			}
+		}
+	}
+	.list-title {
+		width: 100%;
+		height: auto;
+		padding: 10rpx 0;
+		.list-title-t {
+			width: 100%;
+			height: 50rpx;
+			float: left;
+			font-size: $font-size-24;
+			padding-bottom: 10rpx;
+			.list-title-tip {
+				float: left;
+				.badges {
+					display: block;
+					float: left;
+					padding: 0 15rpx;
+					height: 40rpx;
+					line-height: 40rpx;
+					border-radius: 20rpx;
+					background: rgba(248, 204, 148, 0.5);
+					font-size: $font-size-24;
+					text-align: center;
+					color: #666666;
+				}
+			}
+			.list-title-tag {
+				float: left;
+				margin-left: 20rpx;
+				.badges {
+					display: block;
+					float: left;
+					padding: 0 15rpx;
+					height: 40rpx;
+					line-height: 40rpx;
+					border-radius: 20rpx;
+					background: linear-gradient(270deg, #fee9ba 0%, #f0cb72 100%);
+					font-size: $font-size-24;
+					text-align: center;
+					color: #666666;
+				}
+			}
+			.list-title-num {
+				float: left;
+				text-align: left;
+				color: #e15616;
+				line-height: 40rpx;
+				margin-left: 20rpx;
+			}
+		}
+		.list-title-b {
+			width: 100%;
+			height: 44rpx;
+			float: left;
+			font-size: $font-size-24;
+			line-height: 40rpx;
+			color: #666666;
+			text-align: left;
+			.text {
+				color: #999999;
+			}
+			.list-title-b-item {
+				width: 50%;
+				height: 100%;
+				float: left;
+				&.ri{
+					text-align: right;
+				}
+			}
+			&.sms {
+				height: auto;
+			}
+		}
+	}
+</style>

+ 60 - 0
filters/filters.js

@@ -0,0 +1,60 @@
+export function NumFormat(value) {
+    //处理金额
+    if (value) {
+        return Number(value).toFixed(2)
+    } else {
+        return '0.00'
+    }
+}
+export function formatReceiptType(value) {// 款项类型:1订单款,2非订单款,3返佣款 4订单款或者非订单款(因财务阶段无法区分订单非订单), 5供应商退款
+    const map = {
+        1: '订单',
+        2: '非订单',
+        3: '返佣',
+        4: '订单款或者非订单款',
+        5: '供应商退款'
+    }
+    return map[value]
+}
+
+export function formatStateType(value) {// 收款状态: 1待确认、2已确认(待审核)、3审核通过、4审核未通过、5收款撤销【线上支付成功为审核通过】
+    const map = {
+        1: '待确认',
+        2: '已确认(待审核)',
+        3: '审核通过',
+        4: '审核未通过',
+        5: '收款撤销'
+    }
+    return map[value]
+}
+
+export function formatOrderType(value) {// 订单来源
+    const map = {
+        0: '协销订单',
+        1: '自主订单',
+        2: '客服订单',
+    }
+    return map[value]
+}
+
+export function stateExpFormat(value) {// 订单状态
+    const map = {
+        0: '待确认',
+        4: '交易完成',
+        5: '订单完成',
+        6: '已关闭',
+        7: '交易全退',
+        77: '交易全退',
+        11: '待收款待发货',
+        12: '待收款部分发货',
+        13: '待收款已发货',
+        21: '部分收款待发货',
+        22: '部分收款部分发货',
+        23: '部分收款已发货',
+        31: '已收款待发货',
+        32: '已收款部分发货',
+        33: '已收款已发货',
+        111: '待收款待发货'
+    }
+    return map[value]
+}

+ 5 - 0
main.js

@@ -5,6 +5,11 @@ import './services/index.js'
 import{msg,modal,json,prePage} from '@/utils/util.js'
 import * as Api from '@/common/config/caimeiApi.js'
 import * as Regs from '@/common/config/common.js'
+import * as filters from '@/filters/filters.js'
+//注册全局过滤器 
+Object.keys(filters).forEach(key => {
+    Vue.filter(key, filters[key])
+})
 import cuCustom from './components/cu-custom.vue'
 import tuCustom from './components/tui-custom/tui-custom.vue'
 import boCustom from './components/tui-custom/bo-custom.vue'

+ 8 - 0
pages.json

@@ -93,6 +93,14 @@
 				"navigationStyle":"custom"
 			}
 		},
+		{
+			"path": "pages/relation/return/list",
+			"style": {
+				"navigationBarTitleText": "口头返佣关联",
+				"enablePullDownRefresh":true,
+				"navigationStyle":"custom"
+			}
+		},
 		{
 			"path": "pages/relation/refund/index",
 			"style": {

+ 0 - 10
pages/collection/detail.vue

@@ -121,16 +121,6 @@
 			this.payDetailsId = option.id
 			this.getOrderReceiptDetail(option.id)
 		},
-		filters: {
-			NumFormat(value) {
-				//处理金额
-				if (value) {
-					return Number(value).toFixed(2)
-				} else {
-					return '0.00'
-				}
-			}
-		},
 		methods: {
 			getOrderReceiptDetail(id){
 				// 收款详情

+ 45 - 166
pages/collection/list.vue

@@ -44,10 +44,10 @@
 							<view class="list-title" @click.stop="receiptDetail(receipt)">
 								<view class="list-title-t">
 									<view class="list-title-tip">
-										<text class="badges">{{ receipt.receiptType | formatSourceType }}</text>
+										<text class="badges">{{ receipt.receiptType | formatReceiptType }}</text>
 									</view>
 									<view class="list-title-num" :style="{ color: formatColor(receipt.receiptStatus) }">{{
-										receipt.receiptStatus | formatStateType
+										receipt.receiptStatusText 
 									}}</view>
 								</view>
 								<view class="list-title-b">
@@ -95,6 +95,10 @@
 				</view>
 			</view>
 		</view>
+		<!-- 口头返佣按钮 -->
+		<view class="tui-icon-button" v-if="currents == 2" @click="toNoSms('/pages/relation/return/list')">
+			<text class="iconfont icon-jiahao"></text>
+		</view>
 		<!--右抽屉-->
 		<tui-drawer mode="right" :visible="rightDrawer" @close="closeDrawer">
 			<view class="d-container clearfix" :style="{ paddingTop: CustomBar + 10 + 'px' }">
@@ -135,7 +139,7 @@
 		<tui-modal :show="modal1" :padding="'40rpx 30rpx'" @cancel="hideMobel1" :custom="true" fadeIn >
 			<view class="tui-modal-custom">
 				<view class="tui-prompt-title">非订单款项</view>
-				<view class="tui-prompt-textarea">
+				<view class="tui-prompt-textarea" :class="modal1 ? 'show' : 'none'">
 					<textarea
 						class="textarea"
 						placeholder="请填写说明(必填)"
@@ -164,7 +168,7 @@
 			endDate : '',//筛选结束时间
 			pageNum:1,	//页码
 			pageSize:10,	//每页数量
-			receiptStatus:1, //收款状态:0全部 1待确认、2已确认(待审核)、3审核通过、4审核未通过、5收款撤销【线上支付成功为审核通过】
+			receiptStatus:0, //收款状态:0全部 1待确认、2已确认(待审核)、3审核通过、4审核未通过、5收款撤销【线上支付成功为审核通过】
 			receiptType:1,	//收款款项类型:1订单款,2非订单款,3返佣款 4订单款或者非订单款(因财务阶段无法区分订单非订单), 5供应商退款
 			smsContent:'',	//收款短信
 			startDate:''//筛选开始时间
@@ -269,54 +273,6 @@
 			})
 			this.initGetStotage()
 		},
-		filters: {
-			formatSourceType(value) {// 款项类型:1订单款,2非订单款,3返佣款 4订单款或者非订单款(因财务阶段无法区分订单非订单), 5供应商退款
-				switch (value) {
-					case 1:
-						return '订单'
-						break
-					case 2:
-						return '非订单'
-						break
-					case 3:
-						return '返佣'
-						break
-					case 4:
-						return '订单款或者非订单款'
-						break
-					case 5:
-						return '供应商退款'
-						break
-				}
-			},
-			formatStateType(value) {// 收款状态: 1待确认、2已确认(待审核)、3审核通过、4审核未通过、5收款撤销【线上支付成功为审核通过】
-				switch (value) {
-					case 1:
-						return '待确认'
-						break
-					case 2:
-						return '已确认'
-						break
-					case 3:
-						return '审核通过'
-						break
-					case 4:
-						return '审核未通过'
-						break
-					case 5:
-						return '收款撤销'
-						break
-				}
-			},
-			NumFormat(value) {
-				//处理金额
-				if (value) {
-					return Number(value).toFixed(2)
-				} else {
-					return '0.00'
-				}
-			}
-		},
 		computed: {
 			...mapState(['hasLogin']),
 			startDate() {
@@ -419,14 +375,14 @@
 				console.log('this.tabCurrents',this.tabCurrents)
 				console.log('this.receipt',receipt.receiptType)
 				switch(receipt.receiptType){
-					case 1:// 1:订单
-						if(this.tabCurrents == 1 || this.tabCurrents == 0){// 订单待确认
+					case 1:// 1:订单 1待确认、2已确认(待审核)、3审核通过、4审核未通过、5收款撤销【线上支付成功为审核通过】
+						if(receipt.receiptStatus == 1 || receipt.receiptStatus == 4 || receipt.receiptStatus == 5){// 订单待确认
 							console.log('订单待确认')
 							this.$api.navigateTo(`/pages/relation/ordinary/index?id=${receipt.id}`)
-						}else if(this.tabCurrents == 2){// 待审核
+						}else if(receipt.receiptStatus == 2){// 待审核
 							console.log('待审核')
 							this.$api.navigateTo(`/pages/relation/ordinary/examine-detail?id=${receipt.id}`)
-						}else if(this.tabCurrents == 3){// 审核通过
+						}else if(receipt.receiptStatus == 3){// 审核通过
 							console.log('审核通过')
 							this.$api.navigateTo(`/pages/relation/ordinary/detail?id=${receipt.id}`)
 						}
@@ -435,16 +391,16 @@
 						this.$api.navigateTo(`/pages/relation/nonorder/detail?id=${receipt.id}`)
 						break
 					case 3:// 3:返佣 
-						if(this.tabCurrents == 1 || this.tabCurrents == 0){// 返佣待确认
+						if(receipt.receiptStatus == 1 || receipt.receiptStatus == 4 || receipt.receiptStatus == 5){// 返佣待确认
 							this.$api.navigateTo(`/pages/relation/return/index?id=${receipt.id}`)
-						}else if(this.tabCurrents == 2){
+						}else if(receipt.receiptStatus == 2){
 							this.$api.navigateTo(`/pages/relation/return/detail?id=${receipt.id}`)
 						}
 						break
 					case 5:// 4:供应商退款
-						if(this.tabCurrents == 1 || this.tabCurrents == 0){// 返佣待确认
+						if(receipt.receiptStatus == 1 || receipt.receiptStatus == 4 || receipt.receiptStatus == 5){// 返佣待确认
 							this.$api.navigateTo(`/pages/relation/refund/index?id=${receipt.id}`)
-						}else if(this.tabCurrents == 2){
+						}else if(receipt.receiptStatus == 2){
 							this.$api.navigateTo(`/pages/relation/refund/detail?id=${receipt.id}`)
 						}
 						break
@@ -556,11 +512,11 @@
 				//设置邀请码状态亚瑟
 				let stateColor = '',
 					stateColorObject = {
-						1: '#4cd964',
-						2: '#FEAC20',
+						1: '#FEAC20',
+						2: '#4cd964',
 						3: '#34CC8C',
-						4: '#007aff',
-						5: '#F94B4B'
+						4: '#F94B4B',
+						5: '#007aff'
 					}
 				Object.keys(stateColorObject).forEach(function(key) {
 					if (key == state) {
@@ -585,6 +541,9 @@
 						this.pullUpOn = true
 						this.currents = index
 						this.listQuery.receiptType = type
+						if(index == 1){
+							this.listQuery.receiptStatus = 0
+						}
 						this.getOrderDatainit()
 						this.tabCurrents = 0
 						break
@@ -596,6 +555,9 @@
 						this.getOrderDatainit()
 				}
 			},
+			toNoSms(url) {
+				this.$api.navigateTo(url)
+			},
 			navBack() {
 				uni.navigateBack({
 					delta: 1
@@ -964,108 +926,6 @@
 			}
 		}
 	}
-
-	.goods-title {
-		width: 100%;
-		height: 48rpx;
-		float: left;
-		margin-top: 24rpx;
-
-		.title-logo {
-			width: 48rpx;
-			height: 48rpx;
-			float: left;
-
-			image {
-				width: 48rpx;
-				height: 48rpx;
-			}
-		}
-
-		.title-text {
-			float: left;
-			margin-left: 16rpx;
-			font-size: $font-size-28;
-			color: $text-color;
-			text-align: left;
-			line-height: 48rpx;
-			font-weight: bold;
-		}
-	}
-
-	.goods-item {
-		width: 100%;
-		height: auto;
-		padding: 24rpx 0;
-
-		.pros-img {
-			width: 210rpx;
-			height: 210rpx;
-			border-radius: 10rpx;
-			margin: 0 26rpx 0 0;
-			border: 1px solid #f3f3f3;
-			float: left;
-
-			image {
-				width: 100%;
-				height: 100%;
-				border-radius: 10rpx;
-			}
-		}
-	}
-
-	.pros-product {
-		width: 465rpx;
-		height: 210rpx;
-		line-height: 36rpx;
-		font-size: $font-size-26;
-		position: relative;
-		float: left;
-
-		.producttitle {
-			width: 100%;
-			display: inline-block;
-			height: auto;
-			text-overflow: ellipsis;
-			display: -webkit-box;
-			word-break: break-all;
-			-webkit-box-orient: vertical;
-			-webkit-line-clamp: 2;
-			overflow: hidden;
-			margin-bottom: 8rpx;
-		}
-
-		.productspec {
-			height: 36rpx;
-			color: #999999;
-		}
-
-		.productprice {
-			height: 48rpx;
-			position: absolute;
-			width: 100%;
-			bottom: 0;
-
-			.price {
-				line-height: 48rpx;
-				font-size: $font-size-28;
-				width: 48%;
-				color: #ff2a2a;
-				float: left;
-			}
-
-			.count {
-				height: 100%;
-				float: right;
-				position: relative;
-
-				.small {
-					color: #666666;
-				}
-			}
-		}
-	}
-
 	.d-container {
 		width: 580rpx;
 		padding: 80rpx 0;
@@ -1194,6 +1054,22 @@
 			}
 		}
 	}
+	.tui-icon-button{
+		width: 80rpx;
+		height: 80rpx;
+		line-height: 80rpx;
+		text-align: center;
+		border-radius: 50%;
+		background: linear-gradient(45deg, #1CBBB4 0%, #0081FF 100%);
+		box-shadow: 0 8rpx 8rpx 0 rgba(86, 119, 252, 0.2);
+		position: fixed;
+		bottom: 120rpx;
+		right: 20rpx;
+		.icon-jiahao{
+			font-size: $font-size-44;
+			color: #FFFFFF;
+		}
+	}
 	.tui-prompt-title{
 		line-height: 44rpx;
 		text-align: center;
@@ -1206,6 +1082,9 @@
 		border-radius: 8rpx;
 		padding:15rpx 20rpx;
 		margin-top: 10rpx;
+		&.none{
+			display: none;
+		}
 		.textarea {
 			width: 100%;
 			height: 100%;

+ 413 - 602
pages/relation/nonorder/detail.vue

@@ -1,704 +1,515 @@
 <template>
 	<view class="container mine clearfix">
 		<!-- <cu-custom :navbar-data='nvabarData'  @navigateBack="hanldNavigateBack"></cu-custom> -->
-		<view class="tui-header-box first"
+		<view
+			class="tui-header-box first"
 			:style="{ height: isCmcustomClass == 'fiexd' ? CustomBar + 10 + 'px' : CustomBar + 30 + 'px' }"
-			:class="isCmcustomClass">
+			:class="isCmcustomClass"
+		>
 			<view class="header-top" :style="{ paddingTop: top + 'px', lineHeight: CustomBar + 30 + 'px' }"></view>
 			<view class="header-sit">
 				<text class="iconfont icon-fanhui" @click.stop="this.$api.navigateBack(1)"></text>
-				<text class="header-sit-text">款项详情</text>
+				<text class="header-sit-text">审核详情</text>
 			</view>
 		</view>
-		<view class="tui-header-box"
-			:style="{ height: CustomBar + 30 + 'px', backgroundImage: 'url(https://static.caimei365.com/app/crm/image/statistic_bg1.png)' }">
+		<view
+			class="tui-header-box"
+			:style="{
+				height: CustomBar + 30 + 'px',
+				backgroundImage: 'url(https://static.caimei365.com/app/crm/image/statistic_bg1.png)'
+			}"
+		>
 		</view>
-		<view class="distinguish-section" :style="{ top: CustomBar - 14 + 'px', left: 0 + 'px' }">
+		<view class="distinguish-section" :style="{ top: CustomBar - 4 + 'px', left: 0 + 'px' }">
 			<view class="distinguish-section-conten">
 				<view class="section-top">
 					<view class="title">
 						<view class="list-title-tip">
-							<text class="badges">{{ payment.sourceType | formatSourceType }}款</text>
+							<text class="badges">{{ receiptInfo.receiptType | formatSourceType }}款</text>
 						</view>
 						<view class="title-text">收款信息</view>
 					</view>
 					<view class="button" @click="toNoSms('/pages/collection/list')">
-						<text class="iconfont icon-wodedingdan"></text>
-						收款列表
+						<text class="iconfont icon-wodedingdan"></text> 收款列表
 					</view>
 				</view>
 				<view class="section-top-item">
 					<view class="list-title-b">
-						<view class="list-title-b-item "> 
-							收款金额:<text class="text">¥{{ payment.receiptAmount | NumFormat }} </text>
+						<view class="list-title-b-item ">
+							收款金额:<text class="text">¥{{ receiptInfo.receiptAmount | NumFormat }}</text>
 						</view>
-						<view class="list-title-b-item "> 
-							收款类型:<text class="text">{{ payment.receiptType }} </text>
+						<view class="list-title-b-item ">
+							收款类型:<text class="text">{{ receiptInfo.payTypeText }}</text>
 						</view>
 					</view>
 					<view class="list-title-b">
-						收款时间:<text class="text">{{ payment.receiptDate }}</text>
+						款时间:<text class="text">{{ receiptInfo.receiptDate }}</text>
 					</view>
-					<template v-if="payment.smsContent">
+					<template v-if="receiptInfo.smsContent">
 						<view class="list-title-b">收款短信:</view>
 						<view class="list-title-b sms">
-							<text class="text">{{ payment.smsContent }}</text>
+							<text class="text">{{ receiptInfo.smsContent ? receiptInfo.smsContent : '无' }}</text>
 						</view>
 					</template>
-					<view class="list-icon">无人确认</view>
+					<view class="list-icon" v-if="receiptInfo.tipMsg">
+						<image
+							class="list-icon-image"
+							src="https://static.caimei365.com/app/crm/image/icon-noconfirm@2x.png"
+							mode=""
+							v-if="receiptInfo.receiptStatus == 1"
+						></image>
+						<image
+							class="list-icon-image"
+							src="https://static.caimei365.com/app/crm/image/icon-noaudit@2x.png"
+							mode=""
+							v-if="receiptInfo.receiptStatus == 2"
+						></image>
+					</view>
 				</view>
-				<view class="section-title">关联订单</view>
-				<view class="section-mid">
-					<view class="list-title">
-						<view class="list-title-t">
-							<view class="list-title-tip">
-								<text class="badges">{{ payment.order.orderType | formatOrderType }}</text>
-							</view>
-							<view class="list-title-num">{{
-								payment.order.state | StateExpFormat
-							}}</view>
-						</view>
-						<view class="list-title-b">
-							订单编号:<text class="text">{{ payment.order.number }} ( {{ payment.order.orderId }} )</text>
-						</view>
-						<view class="list-title-b">
-							下单日期:<text class="text">{{ payment.order.creatTime }}</text>
-						</view>
-						<view class="list-title-b">
-							客户名称:<text class="text">{{ payment.order.userName }}</text>
-						</view>
-						<view class="list-title-b">
-							<view class="list-title-b-item ">
-								订单金额:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-							<view class="list-title-b-item ">
-								余额抵扣:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-						</view>
-						<view class="list-title-b">
-							<view class="list-title-b-item ">
-								应收金额:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-							<view class="list-title-b-item ">
-								已收金额:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-						</view>
-						<view class="list-title-b">
-							<view class="list-title-b-item ">
-								剩余应收:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-							<view class="list-title-b-item ">
-								待审金额:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
+				<template v-if="receiptInfo.orderList">
+					<view class="section-title">关联订单</view>
+					<view class="section-mid">
+						<view class="tui-order-item" v-for="(order, orderIndex) in receiptInfo.orderList" :key="orderIndex">
+							<receipt-details :orderInfo="order"></receipt-details>
 						</view>
 					</view>
-				</view>
+				</template>
 				<view class="section-title">状态</view>
 				<view class="section-mid">
 					<view class="list-title">
-						<view class="list-title-b">进度:<text
-								:style="{ color: formatColor(payment.confirmType) }">{{ payment.confirmType | formatStateType }}</text>
+						<view class="list-title-b"
+							>进度:<text :style="{ color: formatColor(receiptInfo.receiptStatus) }"
+								>{{ receiptInfo.receiptStatusText }}</text
+							>
 						</view>
+						<view class="list-title-b"
+							>确认人:<text class="text">{{
+								receiptInfo.confirmUserName ? receiptInfo.confirmUserName : '无'
+							}}</text></view
+						>
+						<view class="list-title-b"
+							>确认时间:<text class="text">{{
+								receiptInfo.confirmDate ? receiptInfo.confirmDate : '无'
+							}}</text></view
+						>
+						<view class="list-title-b"
+							>审核人:<text class="text">{{
+								receiptInfo.reviewUserName ? receiptInfo.reviewUserName : '无'
+							}}</text></view
+						>
+						<view class="list-title-b"
+							>审核时间:<text class="text">{{
+								receiptInfo.reviewDate ? receiptInfo.reviewDate : '无'
+							}}</text></view
+						>
 					</view>
 				</view>
-				<view class="section-tips">注:款项和订单已确认关联,等待审核</view>
 			</view>
 		</view>
-		<!-- 弹窗提示 -->
-		<tui-modal :show="modal" @click="handleClick" @cancel="hideMobel" :title="contentModalTitle"
-			:content="contentModalText" :button="modalButton" color="#333" :size="32" shape="circle"
-			:maskClosable="false">
-		</tui-modal>
 	</view>
 </template>
 <script>
-	import wxLogin from '@/services/wxLogin.js'
-	import {
-		mapState,
-		mapMutations
-	} from 'vuex'
+import wxLogin from '@/services/wxLogin.js'
+import receiptDetails from '@/components/cm-module/receipt/receipt-details'
+import { mapState, mapMutations } from 'vuex'
 
-	export default {
-		data() {
-			return {
-				isIphoneX: this.$store.state.isIphoneX,
-				nvabarData: {
-					//顶部自定义导航
-					showCapsule: 1, // 是否显示左上角图标  1表示显示  0表示不显示,
-					showSearch: 0,
-					title: '', // 导航栏 中间的标题
-					haveBack: false,
-					home: false,
-					textLeft: this.$store.state.isIphone,
-					bgColor: '#D33020',
-					textColor: '#ffffff'
-				},
-				payment: {
-					id: 6090,
-					receiptAmount: 5000, //收款金额
-					associateAmount: 5000, //关联金额
-					receiptType: '广发银行0115',
-					receiptDate: '2022-02-15 10:58:25', // 收款时间
-					reviewDate: '2022-02-15 10:58:25', // 审核时间
-					smsContent: '【中信银行】您尾号0897的中信卡于05月29日14:42,二代支付存入人民币99.00元,当前余额为人民币13871.67元。',
-					confirmType: 1,
-					userName: '采美网络信息有限公司',
-					sourceType: 2,
-					state: 11,
-					isChecked: false,
-					order: {
-						orderId: 18751,
-						number: 'W164488903271223',
-						receiptAmount: 5000, //收款金额
-						associateAmount: 5000, //关联金额
-						orderType: 1, // 订单类型
-						creatTime: '2022-02-15 10:58:25', // 下单日期
-						userName: '采美网络信息有限公司',
-						state: 11, //订单状态
-					}
-				},
-				modalButton: [{
-						text: '取消',
-						type: 'gray',
-						plain: true //是否空心
-					},
-					{
-						text: '确认',
-						customStyle: {
-							color: '#fff',
-							bgColor: '#4688fa'
-						},
-						plain: false
-					}
-				],
-				params: {
-					type: 1,
-					banksType: 1,
-					amount: '',
-					chargeValue: '',
-					remarks: '',
-					time: this.$api.getNowFormatDate()
-				},
-				infoData: {},
-				isCmcustomClass: 'left',
-				CustomBar: this.CustomBar, // 顶部导航栏高度
-				height: 64, //header高度
-				top: 0, //标题图标距离顶部距离
-				scrollH: 0, //滚动总高度
-				opcity: 1,
-				isCheckedCharge: false,
-				contentModalTitle: '',
-				contentModalText: '', //操作文字提示语句
-				modal: false,
+export default {
+	components: {
+		receiptDetails
+	},
+	data() {
+		return {
+			isIphoneX: this.$store.state.isIphoneX,
+			CustomBar: this.CustomBar, // 顶部导航栏高度
+			height: 64, //header高度
+			top: 0, //标题图标距离顶部距离
+			scrollH: 0, //滚动总高度
+			opcity: 1,
+			isCmcustomClass: 'left',
+			nvabarData: {
+				//顶部自定义导航
+				showCapsule: 1, // 是否显示左上角图标  1表示显示  0表示不显示,
+				showSearch: 0,
+				title: '', // 导航栏 中间的标题
+				haveBack: false,
+				home: false,
+				textLeft: this.$store.state.isIphone,
+				bgColor: '#D33020',
+				textColor: '#ffffff'
+			},
+			receiptInfo: {},
+			receiptId: 0
+		}
+	},
+	onLoad(option) {
+		let obj = {}
+		// #ifdef MP-WEIXIN
+		obj = wx.getMenuButtonBoundingClientRect()
+		// #endif
+		// #ifdef MP-BAIDU
+		obj = swan.getMenuButtonBoundingClientRect()
+		// #endif
+		// #ifdef MP-ALIPAY
+		my.hideAddToDesktopMenu()
+		// #endif
+		uni.getSystemInfo({
+			success: res => {
+				this.width = obj.left || res.windowWidth
+				this.height = obj.top ? obj.top + obj.height + 8 : res.statusBarHeight + 44
+				this.top = obj.top ? obj.top + (obj.height - 32) / 2 : res.statusBarHeight + 6
+				this.scrollH = res.windowWidth * 0.6
+			}
+		})
+		this.receiptId = option.id
+		this.getOrderReceiptDetail(this.receiptId)
+	},
+	filters: {
+		formatSourceType(value) {
+			switch (value) {
+				case 1:
+					return '订单'
+					break
+				case 2:
+					return '非订单'
+					break
+				case 3:
+					return '返佣'
+					break
+				case 4:
+					return '订单款或者非订单款'
+					break
+				case 5:
+					return '供应商退款'
+					break
 			}
 		},
-		onLoad() {
-			let obj = {}
-			// #ifdef MP-WEIXIN
-			obj = wx.getMenuButtonBoundingClientRect()
-			// #endif
-			// #ifdef MP-BAIDU
-			obj = swan.getMenuButtonBoundingClientRect()
-			// #endif
-			// #ifdef MP-ALIPAY
-			my.hideAddToDesktopMenu()
-			// #endif
-			uni.getSystemInfo({
-				success: res => {
-					this.width = obj.left || res.windowWidth
-					this.height = obj.top ? obj.top + obj.height + 8 : res.statusBarHeight + 44
-					this.top = obj.top ? obj.top + (obj.height - 32) / 2 : res.statusBarHeight + 6
-					this.scrollH = res.windowWidth * 0.6
-				}
-			})
+		formatStateType(value) {
+			switch (value) {
+				case 0:
+					return '待确认'
+					break
+				case 1:
+					return '已确认'
+					break
+				case 2:
+					return '待审核'
+					break
+				case 3:
+					return '审核通过'
+					break
+			}
 		},
-		filters: {
-			formatSourceType(value) {
-				switch (value) {
-					case 1:
-						return '订单'
-						break
-					case 2:
-						return '非订单'
-						break
-					case 3:
-						return '返佣'
-						break
-					case 4:
-						return '供应商退款'
-						break
-				}
-			},
-			formatOrderType(value) {
-				switch (value) {
-					case 1:
-						return '自主订单'
-						break
-					case 2:
-						return '协销订单'
-						break
-					case 3:
-						return '客服订单'
-						break
-				}
-			},
-			formatStateType(value) {
-				switch (value) {
-					case 0:
-						return '待确认'
-						break
-					case 1:
-						return '已确认'
-						break
-					case 2:
-						return '待审核'
-						break
-					case 3:
-						return '审核通过'
-						break
-				}
-			},
-			StateExpFormat(state) {
-				//订单状态文字和颜色
-				var HtmlStateText = '',
-					stateTextObject = {
-						0: '待确认',
-						4: '交易完成',
-						5: '订单完成',
-						6: '已关闭',
-						7: '交易全退',
-						77: '交易全退',
-						11: '待付款待发货',
-						12: '待付款部分发货',
-						13: '待付款已发货',
-						21: '部分付款待发货',
-						22: '部分付款部分发货',
-						23: '部分付款已发货',
-						31: '已付款待发货',
-						32: '已付款部分发货',
-						33: '已付款已发货',
-						111: '待付款待发货'
-					}
-				Object.keys(stateTextObject).forEach(function(key) {
-					if (key == state) {
-						HtmlStateText = stateTextObject[key]
-					}
-				})
-				return HtmlStateText
-			},
-			NumFormat(value) {
-				//处理金额
-				if (value) {
-					return Number(value).toFixed(2)
-				} else {
-					return '0.00'
-				}
+		NumFormat(value) {
+			//处理金额
+			if (value) {
+				return Number(value).toFixed(2)
+			} else {
+				return '0.00'
 			}
+		}
+	},
+	computed: {
+		...mapState(['hasLogin', 'userInfo'])
+	},
+	methods: {
+		getOrderReceiptDetail(id) {
+			// 收款详情
+			this.OrderService.orderReceiptDetail({ id: id })
+				.then(response => {
+					this.receiptInfo = response.data
+					this.skeletonShow = false
+				})
+				.catch(err => {
+					this.$util.msg(err.msg, 2000)
+				})
 		},
-		computed: {
-			...mapState(['hasLogin', 'userInfo'])
+		toNoSms(url) {
+			this.$api.navigateTo(url)
 		},
-		methods: {
-			bindPickerChange(type, e) {
-				// 选择选项
-				switch (type) {
-					case 1:
-						this.paymentTypeText = this.paymentActions[e.target.value].name
-						this.params.type = this.paymentActions[e.target.value].value
-						console.log('款项类型', this.paymentTypeText)
-						console.log('款项类型', this.params.type)
-						break
-					case 2:
-						this.banksTypeText = this.banksActions[e.target.value].name
-						this.params.banksType = this.banksActions[e.target.value].value
-						console.log('收款类型', this.params.banksType)
-						break
-				}
-			},
-			showTuiDateTime() {
-				this.$refs.dateTime.show()
-			},
-			confirmDistinguish() {
-				if (this.params.amount == '') {
-					this.$util.msg('请输入收款金额', 2000)
-					return
+		formatColor(state) {
+			//设置邀请码状态亚瑟
+			let stateColor = '',
+				stateColorObject = {
+					0: '#4cd964',
+					1: '#4cd964',
+					2: '#4cd964',
+					3: '#007aff'
 				}
-				if (this.isCheckedCharge) {
-					if (this.params.chargeValue == '') {
-						this.$util.msg('请输入手续费', 2000)
-						return
-					}
+			Object.keys(stateColorObject).forEach(function(key) {
+				if (key == state) {
+					stateColor = stateColorObject[key]
 				}
-				if (this.params.remarks == '') {
-					this.$util.msg('请填写收款备注', 2000)
-					return
-				}
-				if (this.params.type == 1) {
-					this.contentModalTitle = '确定收款吗?'
-					this.contentModalText = '确认前请仔细检查各项数据是否正确,确认收款后将不能进行修改。' //操作文字提示语句
-				} else if (this.params.type == 2) {
-					this.contentModalTitle = ''
-					this.contentModalText = '确定返佣收款吗?' //操作文字提示语句
-				} else if (this.params.type == 3) {
-					this.contentModalTitle = ''
-					this.contentModalText = '确定供应商退款吗?' //操作文字提示语句
-				}
-				this.modal = true
-				console.log('收款')
-			},
-			handleClick(e) {
-				// 确认收款
-				if (e.index == 1) {
-					this.$api.navigateTo('/pages/collection/detail')
-				}
-				this.modal = false
-			},
-			hideMobel() {
-				this.modal = false
-			},
-			checkedCharge() {
-				// 勾选手续费
-				this.isCheckedCharge = !this.isCheckedCharge
-			},
-			changeNumber(e) {
-				// 校验输入为数字
-				if (!this.$api.isNumber(e.detail.value)) {
-					this.params.amount = ''
-				} else {
-					this.params.amount = e.detail.value
-				}
-			},
-			toNoSms(url) {
-				this.$api.navigateTo(url)
-			},
-			formatColor(state) {
-				//设置邀请码状态亚瑟
-				let stateColor = '',
-					stateColorObject = {
-						0: '#f0ad4e',
-						1: '#4cd964',
-						2: '#dd524d',
-						3: '#007aff'
-					}
-				Object.keys(stateColorObject).forEach(function(key) {
-					if (key == state) {
-						stateColor = stateColorObject[key]
-					}
-				})
-				return stateColor
-			},
-		},
-		onPageScroll(e) {
-			//实时获取到滚动的值
-			// if (e.scrollTop > 30) {
-			// 	this.isCmcustomClass = 'fiexd'
-			// } else {
-			// 	this.isCmcustomClass = 'left'
-			// }
-		},
-		onPullDownRefresh() {
-			setTimeout(() => {
-				// this.initSsoMemberCollectionList()
-				uni.stopPullDownRefresh()
-			}, 200)
-		},
-		onShow() {
-			if (this.hasLogin) {
-				this.GetDataInfo()
-			}
+			})
+			return stateColor
 		}
-	}
+	},
+	onPageScroll(e) {
+		//实时获取到滚动的值
+		// if (e.scrollTop > 30) {
+		// 	this.isCmcustomClass = 'fiexd'
+		// } else {
+		// 	this.isCmcustomClass = 'left'
+		// }
+	},
+	onPullDownRefresh() {
+		setTimeout(() => {
+			this.getOrderReceiptDetail(this.receiptId)
+			uni.stopPullDownRefresh()
+		}, 200)
+	},
+	onShow() {}
+}
 </script>
 
 <style lang="scss">
-	@import '@/uni.scss';
+@import '@/uni.scss';
 
-	page {
-		background: #fff;
-	}
+page {
+	background: #fff;
+}
 
-	.tui-header-box {
-		width: 100%;
-		background: #ffffff;
-		z-index: 999;
-		background-size: cover;
-		background-image: url(https://static.caimei365.com/app/crm/image/statistic_bg2.png);
+.tui-header-box {
+	width: 100%;
+	background: #ffffff;
+	z-index: 999;
+	background-size: cover;
+	background-image: url(https://static.caimei365.com/app/crm/image/statistic_bg2.png);
 
-		&.fiexd {
-			position: fixed;
-			top: 0;
-			left: 0;
-		}
+	&.fiexd {
+		position: fixed;
+		top: 0;
+		left: 0;
 	}
+}
 
-	.header-top {
-		width: 100%;
-		font-size: 16px;
-		font-weight: 500;
-		height: 32px;
-		display: flex;
-		align-items: center;
-		justify-content: center;
-		position: relative;
-		padding: 0 40rpx;
+.header-top {
+	width: 100%;
+	font-size: 16px;
+	font-weight: 500;
+	height: 32px;
+	display: flex;
+	align-items: center;
+	justify-content: center;
+	position: relative;
+	padding: 0 40rpx;
+}
+
+.header-sit {
+	width: 100%;
+	box-sizing: border-box;
+	height: 80rpx;
+	line-height: 80rpx;
+	box-sizing: border-box;
+	color: #ffffff;
+
+	.header-sit-text {
+		text-align: left;
+		font-size: $font-size-40;
+		font-weight: 600;
+		font-family: '正楷';
 	}
 
-	.header-sit {
-		width: 100%;
-		box-sizing: border-box;
+	.icon-fanhui {
+		display: block;
+		width: 80rpx;
 		height: 80rpx;
+		float: left;
+		text-align: center;
 		line-height: 80rpx;
-		box-sizing: border-box;
-		color: #ffffff;
+		font-size: 42rpx;
+	}
 
-		.header-sit-text {
-			text-align: left;
-			font-size: $font-size-40;
-			font-weight: 600;
-			font-family: '正楷';
-		}
+	.icon-iconfonticonfontsousuo1 {
+		font-size: 42rpx;
+		margin-left: 30rpx;
+	}
+}
 
-		.icon-fanhui {
-			display: block;
-			width: 80rpx;
-			height: 80rpx;
-			float: left;
-			text-align: center;
-			line-height: 80rpx;
-			font-size: 42rpx;
-		}
+.mine {
+	width: 100%;
+	height: 100%;
+	position: relative;
+}
 
-		.icon-iconfonticonfontsousuo1 {
-			font-size: 42rpx;
-			margin-left: 30rpx;
-		}
-	}
+.distinguish-section {
+	width: 100%;
+	position: absolute;
+	padding: 40rpx 20rpx;
+	box-sizing: border-box;
+}
 
-	.mine {
-		width: 100%;
-		height: 100%;
-		position: relative;
-	}
+.distinguish-section-conten {
+	width: 100%;
+	height: auto;
+	position: relative;
+	background-color: #ffffff;
+	border-radius: 20rpx;
+	padding: 20rpx;
+	box-shadow: 0 10rpx 10rpx 0 rgba(86, 119, 252, 0.2);
 
-	.distinguish-section {
+	.section-top {
 		width: 100%;
-		position: absolute;
-		padding: 40rpx 20rpx;
+		height: 66rpx;
 		box-sizing: border-box;
-	}
-
-	.distinguish-section-conten {
-		width: 100%;
-		height: auto;
-		position: relative;
-		background-color: #ffffff;
-		border-radius: 20rpx;
-		padding: 20rpx;
-		box-shadow: 0 10rpx 10rpx 0 rgba(86, 119, 252, 0.2);
-
-		.section-top {
-			width: 100%;
+		.title {
+			float: left;
 			height: 66rpx;
-			box-sizing: border-box;
-			.title {
+			padding: 13rpx 0;
+			.list-title-tip {
 				float: left;
-				height: 66rpx;
-				padding: 13rpx 0;
-				.list-title-tip {
-					float: left;
-					margin-right: 15rpx;
-					.badges {
-						display: block;
-						float: left;
-						padding: 0 15rpx;
-						height: 40rpx;
-						line-height: 40rpx;
-						border-radius: 4rpx;
-						background: $btn-confirm;
-						font-size: $font-size-24;
-						text-align: center;
-						color: #ffffff;
-					}
-				}
-				.title-text{
+				margin-right: 15rpx;
+				.badges {
+					display: block;
 					float: left;
-					line-height: 40rpx;
+					padding: 0 15rpx;
 					height: 40rpx;
-					color: #333333;
-					text-align: left;
-					font-weight: 600;
+					line-height: 40rpx;
+					border-radius: 4rpx;
+					background: $btn-confirm;
+					font-size: $font-size-24;
+					text-align: center;
+					color: #ffffff;
 				}
 			}
-
-			.button {
-				float: right;
-				box-sizing: border-box;
-				padding: 0 24rpx;
-				height: 100%;
-				line-height: 66rpx;
-				background: $btn-confirm;
-				border-radius: 8rpx;
-				text-align: center;
-				color: #ffffff;
+			.title-text {
+				float: left;
+				line-height: 40rpx;
+				height: 40rpx;
+				color: #333333;
+				text-align: left;
+				font-weight: 600;
 			}
 		}
 
-		.section-top-item {
+		.button {
+			float: right;
+			box-sizing: border-box;
+			padding: 0 24rpx;
+			height: 100%;
+			line-height: 66rpx;
+			background: $btn-confirm;
+			border-radius: 8rpx;
+			text-align: center;
+			color: #ffffff;
+		}
+	}
+
+	.section-top-item {
+		width: 100%;
+		height: auto;
+		margin-top: 10rpx;
+		position: relative;
+		float: left;
+		.list-title-b {
 			width: 100%;
-			height: auto;
-			margin-top: 10rpx;
-			position: relative;
+			height: 44rpx;
 			float: left;
-			.list-title-b {
-				width: 100%;
-				height: 44rpx;
+			font-size: $font-size-24;
+			line-height: 44rpx;
+			color: #999999;
+			text-align: left;
+			.text {
+				color: #999999;
+			}
+			.list-title-b-item {
+				width: 50%;
+				height: 100%;
 				float: left;
-				font-size: $font-size-24;
-				line-height: 44rpx;
-				color: #666666;
-				text-align: left;
-				.text{
-					color: #999999;
-				}
-				.list-title-b-item {
-					width: 50%;
-					height: 100%;
-					float: left;
-				}
-				&.sms {
-					height: 120rpx;
-					padding: 10rpx;
-					border-radius: 4rpx;
-					background: #F7F7F7;
-				}
 			}
-			.list-icon {
-				width: 120rpx;
-				height: 60rpx;
-				border: 1px solid #e1e1e1;
-				border-radius: 10rpx;
-				text-align: center;
-				font-size: 20rpx;
-				line-height: 60rpx;
-				position: absolute;
-				right: 90rpx;
-				top: 40rpx;
-				color: #dd524d;
-				z-index: 99;
-				transform: rotate(45deg);
-				-webkit-transform: rotate(45deg);
-				-moz-transform: rotate(45deg);
-				font-family: '正楷';
+			&.sms {
+				height: 120rpx;
+				padding: 10rpx;
+				border-radius: 4rpx;
+				background: #f7f7f7;
 			}
 		}
-
-		.section-title {
-			width: 100%;
-			height: 66rpx;
-			float: left;
-			font-size: $font-size-28;
-			line-height: 66rpx;
-			color: #333333;
-			text-align: left;
-			font-weight: 600;
+		.list-icon {
+			width: 120rpx;
+			height: 120rpx;
+			border-radius: 10rpx;
+			position: absolute;
+			right: 0;
+			top: 0;
+			color: #dd524d;
+			z-index: 99;
+			.list-icon-image{
+				width: 120rpx;
+				height: 120rpx;
+				display: block;
+			}
 		}
+	}
 
-		.section-mid {
-			width: 100%;
-			height: auto;
-			display: flex;
-			flex-direction: column;
-			position: relative;
-			border-radius: 0 0 20rpx 20rpx;
-			.list-title {
-				width: 100%;
-				height: auto;
-				.list-title-t {
-					width: 100%;
-					height: 50rpx;
-					float: left;
-					font-size: $font-size-28;
-					padding-bottom: 10rpx;
-
-					.list-title-num {
-						float: left;
-						text-align: left;
-						color: #e15616;
-						margin-left: 30rpx;
-						line-height: 40rpx;
-					}
-
-					.list-title-tip {
-						float: left;
-
-						.badges {
-							display: block;
-							float: left;
-							padding: 0 15rpx;
-							height: 40rpx;
-							line-height: 40rpx;
-							border-radius: 4rpx;
-							background: radial-gradient(circle, rgba(255, 180, 39, 1) 0%, rgba(245, 142, 77, 1) 100%);
-							font-size: $font-size-24;
-							text-align: center;
-							color: #ffffff;
-						}
-					}
-				}
+	.section-title {
+		width: 100%;
+		height: 66rpx;
+		float: left;
+		font-size: $font-size-28;
+		line-height: 66rpx;
+		color: #333333;
+		text-align: left;
+		font-weight: 600;
+	}
 
-				.list-title-b {
-					width: 100%;
-					height: 50rpx;
-					float: left;
-					font-size: $font-size-24;
-					line-height: 50rpx;
-					color: #666666;
-					text-align: left;	
-					.text{
-						color: #999999;
-					}					
-					.list-title-b-item {
-						width: 50%;
-						height: 100%;
-						float: left;
-					}
-				}
-			}
-		}
-		.section-tips{
+	.section-mid {
+		width: 100%;
+		height: auto;
+		display: flex;
+		flex-direction: column;
+		position: relative;
+		border-radius: 0 0 20rpx 20rpx;
+		.list-title-b {
 			width: 100%;
 			height: 50rpx;
-			font-size: $font-size-28;
+			float: left;
+			font-size: $font-size-24;
 			line-height: 50rpx;
-			color: $uni-color-error;
+			color: #666666;
 			text-align: left;
+			.text{
+				color: #999999;
+			}
+			.list-title-b-item {
+				width: 50%;
+				height: 100%;
+				float: left;
+			}
 		}
 	}
-	.distinguish-button {
+	.section-tips {
 		width: 100%;
-		position: fixed;
-		bottom: 0;
-		left: 0;
-		background-color: #ffffff;
-		padding: 0 50rpx;
-		padding-top: 20rpx;
-		display: flex;
-		.button {
-			flex: 1;
-			height: 80rpx;
-			margin: 0 20rpx;
-			border-radius: 40rpx;
-			text-align: center;
-			color: #ffffff;
-			line-height: 80rpx;
-			font-size: $font-size-28;
-			box-shadow: 0 10rpx 14rpx 0 rgba(86, 119, 252, 0.2);
-			&.confirm{
-				background: $btn-confirm;
-			}
-			&.cancel{
-				background: $uni-color-error;
-			}
+		height: 50rpx;
+		font-size: $font-size-28;
+		line-height: 50rpx;
+		color: $uni-color-error;
+		text-align: left;
+	}
+}
+.distinguish-button {
+	width: 100%;
+	position: fixed;
+	bottom: 0;
+	left: 0;
+	background-color: #ffffff;
+	padding: 0 50rpx;
+	padding-top: 20rpx;
+	display: flex;
+	.button {
+		flex: 1;
+		height: 80rpx;
+		margin: 0 20rpx;
+		border-radius: 40rpx;
+		text-align: center;
+		color: #ffffff;
+		line-height: 80rpx;
+		font-size: $font-size-28;
+		box-shadow: 0 10rpx 14rpx 0 rgba(86, 119, 252, 0.2);
+		&.confirm {
+			background: $btn-confirm;
+		}
+		&.cancel {
+			background: $uni-color-error;
 		}
 	}
+}
 </style>

+ 375 - 552
pages/relation/order/detail.vue

@@ -1,40 +1,43 @@
 <template>
 	<view class="container mine clearfix">
 		<!-- <cu-custom :navbar-data='nvabarData'  @navigateBack="hanldNavigateBack"></cu-custom> -->
-		<view class="tui-header-box first"
+		<view
+			class="tui-header-box first"
 			:style="{ height: isCmcustomClass == 'fiexd' ? CustomBar + 10 + 'px' : CustomBar + 30 + 'px' }"
-			:class="isCmcustomClass">
+			:class="isCmcustomClass"
+		>
 			<view class="header-top" :style="{ paddingTop: top + 'px', lineHeight: CustomBar + 30 + 'px' }"></view>
-			<view class="header-sit"> 
+			<view class="header-sit">
 				<text class="iconfont icon-fanhui" @click.stop="this.$api.navigateBack(1)"></text>
-				<text class="header-sit-text">订单详情</text>
+				<text class="header-sit-text">订单详情</text>
 			</view>
 		</view>
-		<view class="tui-header-box"
-			:style="{ height: CustomBar + 30 + 'px', backgroundImage: 'url(https://static.caimei365.com/app/crm/image/statistic_bg1.png)' }">
+		<view
+			class="tui-header-box"
+			:style="{
+				height: CustomBar + 30 + 'px',
+				backgroundImage: 'url(https://static.caimei365.com/app/crm/image/statistic_bg1.png)'
+			}"
+		>
 		</view>
 		<view class="distinguish-section" :style="{ top: CustomBar - 14 + 'px', left: 0 + 'px' }">
 			<view class="distinguish-section-conten">
 				<view class="section-top">
 					<view class="section-badges">
 						<view class="list-title-tip">
-							<text class="badges">{{ payment.orderType | formatOrderType }}</text>
+							<text class="badges">{{ order.orderType | formatOrderType }}</text>
 						</view>
-						<view class="list-title-num">{{ payment.confirmType | StateExpFormat }}</view>
+						<view class="list-title-tag" v-if="order.organizeId == 3">
+							<text class="badges">维沙</text>
+						</view>
+						<view class="list-title-num">{{ order.status | stateExpFormat }}</view>
 					</view>
-					<view class="button" @click="toNoSms('/pages/collection/list')"> 
-						<text class="iconfont icon-wodedingdan"></text> 
-						收款列表 
+					<view class="button" @click="toNoSms('/pages/collection/list')">
+						<text class="iconfont icon-wodedingdan"></text> 收款列表
 					</view>
 				</view>
 				<view class="section-mid">
 					<view class="list-title">
-						<view class="list-title-t">
-							<view class="list-title-tip">
-								<text class="badges">{{ order.orderType | formatOrderType }}</text>
-							</view>
-							<view class="list-title-num">{{ order.confirmType | StateExpFormat }}</view>
-						</view>
 						<view class="list-title-b">
 							客户名称:<text class="text">{{ order.userName }}</text>
 						</view>
@@ -56,7 +59,7 @@
 							经理折扣:
 							<text class="text" v-if="order.discountFee - order.returnedPurchaseFee > 0">
 								¥{{ order.discountFee - order.returnedPurchaseFee }}
-								<text>
+								<text class="text">
 									(原¥{{ order.discountFee }} 折扣取消¥{{
 										order.discountFee - order.returnedPurchaseFee > 0
 											? order.returnedPurchaseFee
@@ -64,10 +67,10 @@
 									}})
 								</text>
 							</text>
-							<text v-else>¥0.00(原¥0.00折扣取消¥0.00)</text>
+							<text class="text" v-else>¥0.00(原¥0.00折扣取消¥0.00)</text>
 						</view>
 						<view class="list-title-b" v-if="order.returnedPurchaseFee > 0">
-							退货退款:
+							退货退款: 
 							<text class="text">
 								(原¥{{ order.returnedPurchaseFee }} 折扣取消¥{{
 									j.discountFee - j.returnedPurchaseFee > 0
@@ -89,36 +92,50 @@
 								剩余应收:<text class="text">¥{{ order.surplusAmount | NumFormat }}</text>
 							</view>
 							<view class="list-title-b-item ">
-								待审金额:<text class="text">¥{{ order.receiptAmount | NumFormat }}</text>
+								待审金额:<text class="text">¥{{ order.unCheckAmount | NumFormat }}</text>
 							</view>
 						</view>
 					</view>
 				</view>
 				<view class="section-mid supper">
-					<view class="list-title supper">
-						<view class="list-title-b">
-							子订单号(标识):<text class="text">{{ payment.number }} ( {{ payment.id }} )</text>
-						</view>
-						<view class="list-title-b">
-							供应商:<text class="text">{{ payment.userName }}</text>
-						</view>
-						<view class="list-title-b">
-							订单金额:<text class="text">¥{{ payment.receiptAmount | NumFormat }}</text>
-						</view>
-					</view>	
-					<view class="list-goods">
-						<view class="list-goods-item" v-for="(product, index) in payment.productList" :key="index">
-							<view class="list-goods-image">
-								<image class="list-image" :src="product.image" mode=""></image>
-								<view class="list-tags" v-if="product.productType == 1">赠品</view>
+					<view v-for="(shop, index) in order.shopOrderList" :key="index">
+						<view class="list-title supper">
+							<view class="list-title-b">
+								子订单号(标识):<text class="text">{{ shop.orderNo }} ( {{ shop.shopOrderId }} )</text>
+							</view>
+							<view class="list-title-b">
+								供应商:<text class="text">{{ shop.shopName }}</text>
 							</view>
-							<view class="list-goods-mains">
-								<view class="list-name">{{ product.name }}</view>
-								<view class="list-text">
-									<view class="list-text-item">单价:¥{{ product.price | NumFormat }}</view>
-									<view class="list-text-item">数量:{{ product.productNum }}</view>
+							<view class="list-title-b">
+								订单金额:<text class="text">¥{{ shop.needPayAmount | NumFormat }}</text>
+							</view>
+						</view>
+						<view class="list-goods">
+							<view
+								class="list-goods-item"
+								v-for="(product, pIndex) in shop.orderProductList"
+								:key="pIndex"
+							>
+								<view class="list-goods-image">
+									<image class="list-image" :src="product.image" mode=""></image>
+									<view class="list-tags" v-if="product.productType == 1">赠品</view>
+								</view>
+								<view class="list-goods-mains">
+									<view class="list-name">{{ product.name }}</view>
+									<view class="list-text">
+										<view class="list-text-item"
+											>单价:¥{{
+												product.productType == 1 ? '0.00' : product.discountPrice | NumFormat
+											}}</view
+										>
+										<view class="list-text-item">数量:{{ product.num }}</view>
+									</view>
+									<view class="list-text"
+										>合计:¥{{
+											product.productType == 1 ? '0.00' : product.totalFee | NumFormat
+										}}</view
+									>
 								</view>
-								<view class="list-text">合计:¥{{ product.totalPrice | NumFormat }}</view>
 							</view>
 						</view>
 					</view>
@@ -126,570 +143,376 @@
 			</view>
 		</view>
 		<!-- 弹窗提示 -->
-		<tui-modal :show="modal" @click="handleClick" @cancel="hideMobel" :title="contentModalTitle"
-			:content="contentModalText" :button="modalButton" color="#333" :size="32" shape="circle"
-			:maskClosable="false">
+		<tui-modal
+			:show="modal"
+			@click="handleClick"
+			@cancel="hideMobel"
+			:title="contentModalTitle"
+			:content="contentModalText"
+			:button="modalButton"
+			color="#333"
+			:size="32"
+			shape="circle"
+			:maskClosable="false"
+		>
 		</tui-modal>
 	</view>
 </template>
 <script>
-	import wxLogin from '@/services/wxLogin.js'
-	import {
-		mapState,
-		mapMutations
-	} from 'vuex'
+import wxLogin from '@/services/wxLogin.js'
+import { mapState, mapMutations } from 'vuex'
 
-	export default {
-		data() {
-			return {
-				isIphoneX:this.$store.state.isIphoneX,
-				nvabarData: {
-					//顶部自定义导航
-					showCapsule: 1, // 是否显示左上角图标  1表示显示  0表示不显示,
-					showSearch: 0,
-					title: '', // 导航栏 中间的标题
-					haveBack: false,
-					home: false,
-					textLeft: this.$store.state.isIphone,
-					bgColor: '#D33020',
-					textColor: '#ffffff'
-				},
-				payment:{
-					id: 6090,
-					number: 'W164488903271223',
-					receiptAmount: 5000, //收款金额
-					associateAmount: 5000, //关联金额
-					orderType: 1, //收款类型
-					receiptDate: '2022-02-15 10:58:25', // 收款时间
-					reviewDate: '2022-02-15 10:58:25', // 审核时间
-					smsContent:
-						'【中信银行】您尾号0897的中信卡于05月29日14:42,二代支付存入人民币99.00元,当前余额为人民币13871.67元。',
-					confirmType: 11,
-					userName: '采美网络信息有限公司',
-					sourceType: 2,
-					state: 1,
-					isChecked: false,
-					productList:[
-						{
-							image:'https://img.caimei365.com/group1/M00/00/38/rB-lGGGbNPCAXPlfAAbfLUx_7cE227.png',
-							name:'Skin 2 Skin Med 颜层面部皮肤注射泵 禾雅堂AI水光注射仪 含底座',
-							productType:0,
-							price:1000000,
-							productNum:1,
-							totalPrice:1000000
-						},
-						{
-							image:'https://img.caimei365.com/group1/M00/00/38/rB-lGGGbNPCAXPlfAAbfLUx_7cE227.png',
-							name:'Skin 2 Skin Med 颜层面部皮肤注射泵 禾雅堂AI水光注射仪 含底座',
-							productType:1,
-							price:1000000,
-							productNum:1,
-							totalPrice:1000000
-						},
-						{
-							image:'https://img.caimei365.com/group1/M00/00/38/rB-lGGGbNPCAXPlfAAbfLUx_7cE227.png',
-							name:'Skin 2 Skin Med 颜层面部皮肤注射泵 禾雅堂AI水光注射仪 含底座',
-							productType:0,
-							price:1000000,
-							productNum:1,
-							totalPrice:1000000
-						},
-						{
-							image:'https://img.caimei365.com/group1/M00/00/38/rB-lGGGbNPCAXPlfAAbfLUx_7cE227.png',
-							name:'Skin 2 Skin Med 颜层面部皮肤注射泵 禾雅堂AI水光注射仪 含底座',
-							productType:1,
-							price:1000000,
-							productNum:1,
-							totalPrice:1000000
-						},
-						{
-							image:'https://img.caimei365.com/group1/M00/00/38/rB-lGGGbNPCAXPlfAAbfLUx_7cE227.png',
-							name:'Skin 2 Skin Med 颜层面部皮肤注射泵 禾雅堂AI水光注射仪 含底座',
-							productType:0,
-							price:1000000,
-							productNum:1,
-							totalPrice:1000000
-						},
-						{
-							image:'https://img.caimei365.com/group1/M00/00/38/rB-lGGGbNPCAXPlfAAbfLUx_7cE227.png',
-							name:'Skin 2 Skin Med 颜层面部皮肤注射泵 禾雅堂AI水光注射仪 含底座',
-							productType:1,
-							price:1000000,
-							productNum:1,
-							totalPrice:1000000
-						},
-						{
-							image:'https://img.caimei365.com/group1/M00/00/38/rB-lGGGbNPCAXPlfAAbfLUx_7cE227.png',
-							name:'Skin 2 Skin Med 颜层面部皮肤注射泵 禾雅堂AI水光注射仪 含底座',
-							productType:0,
-							price:1000000,
-							productNum:1,
-							totalPrice:1000000
-						},
-						{
-							image:'https://img.caimei365.com/group1/M00/00/38/rB-lGGGbNPCAXPlfAAbfLUx_7cE227.png',
-							name:'Skin 2 Skin Med 颜层面部皮肤注射泵 禾雅堂AI水光注射仪 含底座',
-							productType:1,
-							price:1000000,
-							productNum:1,
-							totalPrice:1000000
-						},
-					]
-				},
-				modalButton: [{
-						text: '取消',
-						type: 'gray',
-						plain: true //是否空心
-					},
-					{
-						text: '确认',
-						customStyle: {
-							color: '#fff',
-							bgColor: '#4688fa'
-						},
-						plain: false
-					}
-				],
-				params: {
-					type: 1,
-					banksType: 1,
-					amount: '',
-					chargeValue: '',
-					remarks: '',
-					time: this.$api.getNowFormatDate()
-				},
-				infoData: {},
-				isCmcustomClass: 'left',
-				CustomBar: this.CustomBar, // 顶部导航栏高度
-				height: 64, //header高度
-				top: 0, //标题图标距离顶部距离
-				scrollH: 0, //滚动总高度
-				opcity: 1,
-				isCheckedCharge: false,
-				contentModalTitle: '',
-				contentModalText: '', //操作文字提示语句
-				modal: false,
-			}
-		},
-		onLoad() {
-			let obj = {}
-			// #ifdef MP-WEIXIN
-			obj = wx.getMenuButtonBoundingClientRect()
-			// #endif
-			// #ifdef MP-BAIDU
-			obj = swan.getMenuButtonBoundingClientRect()
-			// #endif
-			// #ifdef MP-ALIPAY
-			my.hideAddToDesktopMenu()
-			// #endif
-			uni.getSystemInfo({
-				success: res => {
-					this.width = obj.left || res.windowWidth
-					this.height = obj.top ? obj.top + obj.height + 8 : res.statusBarHeight + 44
-					this.top = obj.top ? obj.top + (obj.height - 32) / 2 : res.statusBarHeight + 6
-					this.scrollH = res.windowWidth * 0.6
-				}
-			})
-		},
-		filters: {
-			formatOrderType(value) {
-				switch (value) {
-					case 0:
-						return '协销订单'
-						break
-					case 1:
-						return '自主订单'
-						break
-					case 2:
-						return '客服订单'
-						break
-				}
-			},
-			StateExpFormat(state) {
-				//订单状态文字和颜色
-				var HtmlStateText = '',
-					stateTextObject = {
-						0: '待确认',
-						4: '交易完成',
-						5: '订单完成',
-						6: '已关闭',
-						7: '交易全退',
-						77: '交易全退',
-						11: '待付款待发货',
-						12: '待付款部分发货',
-						13: '待付款已发货',
-						21: '部分付款待发货',
-						22: '部分付款部分发货',
-						23: '部分付款已发货',
-						31: '已付款待发货',
-						32: '已付款部分发货',
-						33: '已付款已发货',
-						111: '待付款待发货'
-					}
-				Object.keys(stateTextObject).forEach(function(key) {
-					if (key == state) {
-						HtmlStateText = stateTextObject[key]
-					}
-				})
-				return HtmlStateText
+export default {
+	data() {
+		return {
+			isIphoneX: this.$store.state.isIphoneX,
+			CustomBar: this.CustomBar, // 顶部导航栏高度
+			height: 64, //header高度
+			top: 0, //标题图标距离顶部距离
+			scrollH: 0, //滚动总高度
+			opcity: 1,
+			isCmcustomClass: 'left',
+			nvabarData: {
+				//顶部自定义导航
+				showCapsule: 1, // 是否显示左上角图标  1表示显示  0表示不显示,
+				showSearch: 0,
+				title: '', // 导航栏 中间的标题
+				haveBack: false,
+				home: false,
+				textLeft: this.$store.state.isIphone,
+				bgColor: '#D33020',
+				textColor: '#ffffff'
 			},
-			NumFormat(value) {
-				//处理金额
-				if (value) {
-					return Number(value).toFixed(2)
-				} else {
-					return '0.00'
-				}
+			order: {},
+			orderId: 0
+		}
+	},
+	onLoad(option) {
+		let obj = {}
+		// #ifdef MP-WEIXIN
+		obj = wx.getMenuButtonBoundingClientRect()
+		// #endif
+		// #ifdef MP-BAIDU
+		obj = swan.getMenuButtonBoundingClientRect()
+		// #endif
+		// #ifdef MP-ALIPAY
+		my.hideAddToDesktopMenu()
+		// #endif
+		uni.getSystemInfo({
+			success: res => {
+				this.width = obj.left || res.windowWidth
+				this.height = obj.top ? obj.top + obj.height + 8 : res.statusBarHeight + 44
+				this.top = obj.top ? obj.top + (obj.height - 32) / 2 : res.statusBarHeight + 6
+				this.scrollH = res.windowWidth * 0.6
 			}
+		})
+		this.orderId = option.orderId
+		this.getOrderReceiptOrdersInfo(this.orderId)
+	},
+	computed: {
+		...mapState(['hasLogin'])
+	},
+	methods: {
+		getOrderReceiptOrdersInfo(orderId) {
+			// 收款详情
+			this.OrderService.orderReceiptOrdersInfo({ orderId: orderId })
+				.then(response => {
+					this.order = response.data
+					this.skeletonShow = false
+				})
+				.catch(err => {
+					this.$util.msg(err.msg, 2000)
+				})
 		},
-		computed: {
-			...mapState(['hasLogin'])
+		toNoSms(url) {
+			this.$api.navigateTo(url)
 		},
-		methods: {
-			bindPickerChange(type, e) {
-				// 选择选项
-				switch (type) {
-					case 1:
-						this.paymentTypeText = this.paymentActions[e.target.value].name
-						this.params.type = this.paymentActions[e.target.value].value
-						console.log('款项类型', this.paymentTypeText)
-						console.log('款项类型', this.params.type)
-						break
-					case 2:
-						this.banksTypeText = this.banksActions[e.target.value].name
-						this.params.banksType = this.banksActions[e.target.value].value
-						console.log('收款类型', this.params.banksType)
-						break
-				}
-			},
-			showTuiDateTime() {
-				this.$refs.dateTime.show()
-			},
-			confirmDistinguish() {
-				if (this.params.amount == '') {
-					this.$util.msg('请输入收款金额', 2000)
-					return
-				}
-				if (this.isCheckedCharge) {
-					if (this.params.chargeValue == '') {
-						this.$util.msg('请输入手续费', 2000)
-						return
-					}
-				}
-				if (this.params.remarks == '') {
-					this.$util.msg('请填写收款备注', 2000)
-					return
-				}
-				if (this.params.type == 1) {
-					this.contentModalTitle = '确定收款吗?'
-					this.contentModalText = '确认前请仔细检查各项数据是否正确,确认收款后将不能进行修改。' //操作文字提示语句
-				} else if (this.params.type == 2) {
-					this.contentModalTitle = ''
-					this.contentModalText = '确定返佣收款吗?' //操作文字提示语句
-				} else if (this.params.type == 3) {
-					this.contentModalTitle = ''
-					this.contentModalText = '确定供应商退款吗?' //操作文字提示语句
-				}
-				this.modal = true
-				console.log('收款')
-			},
-			handleClick(e) {
-				// 确认收款
-				if (e.index == 1) {
-					this.$api.navigateTo('/pages/collection/detail')
+		formatColor(state) {
+			//设置颜色
+			let stateColor = '',
+				stateColorObject = {
+					1: '#FEAC20',
+					2: '#4cd964',
+					3: '#34CC8C',
+					4: '#F94B4B',
+					5: '#007aff'
 				}
-				this.modal = false
-			},
-			hideMobel() {
-				this.modal = false
-			},
-			checkedCharge() {
-				// 勾选手续费
-				this.isCheckedCharge = !this.isCheckedCharge
-			},
-			changeNumber(e) {
-				// 校验输入为数字
-				if (!this.$api.isNumber(e.detail.value)) {
-					this.params.amount = ''
-				} else {
-					this.params.amount = e.detail.value
+			Object.keys(stateColorObject).forEach(function(key) {
+				if (key == state) {
+					stateColor = stateColorObject[key]
 				}
-			},
-			toNoSms(url){
-				this.$api.navigateTo(url)
-			},
-			formatColor(state) {
-				//设置邀请码状态亚瑟
-				let stateColor = '',
-					stateColorObject = {
-						0: '#f0ad4e',
-						1: '#4cd964',
-						2: '#dd524d',
-						3: '#007aff'
-					}
-				Object.keys(stateColorObject).forEach(function(key) {
-					if (key == state) {
-						stateColor = stateColorObject[key]
-					}
-				})
-				return stateColor
-			},
-		},
-		onPageScroll(e) {
-			//实时获取到滚动的值
-			if (e.scrollTop > 30) {
-				this.isCmcustomClass = 'fiexd'
-			} else {
-				this.isCmcustomClass = 'left'
-			}
-		},
-		onPullDownRefresh() {
-			setTimeout(() => {
-				// this.initSsoMemberCollectionList()
-				uni.stopPullDownRefresh()
-			}, 200)
+			})
+			return stateColor
 		},
-		onShow() {
-			if (this.hasLogin) {
-				this.GetDataInfo()
-			}
-		}
-	}
+	},
+	onPageScroll(e) {
+		//实时获取到滚动的值
+		// if (e.scrollTop > 30) {
+		// 	this.isCmcustomClass = 'fiexd'
+		// } else {
+		// 	this.isCmcustomClass = 'left'
+		// }
+	},
+	onPullDownRefresh() {
+		setTimeout(() => {
+			this.getOrderReceiptOrdersInfo(this.orderId)
+			uni.stopPullDownRefresh()
+		}, 200)
+	},
+	onShow() {}
+}
 </script>
 
 <style lang="scss">
-	@import '@/uni.scss';
+@import '@/uni.scss';
 
-	page {
-		background: #fff;
-	}
+page {
+	background: #fff;
+}
 
-	.tui-header-box {
-		width: 100%;
-		background: #ffffff;
-		z-index: 999;
-		background-size: cover;
-		background-image: url(https://static.caimei365.com/app/crm/image/statistic_bg2.png);
-		&.fiexd {
-			position: fixed;
-			top: 0;
-			left: 0;
-		}
+.tui-header-box {
+	width: 100%;
+	background: #ffffff;
+	z-index: 999;
+	background-size: cover;
+	background-image: url(https://static.caimei365.com/app/crm/image/statistic_bg2.png);
+	&.fiexd {
+		position: fixed;
+		top: 0;
+		left: 0;
 	}
+}
 
-	.header-top {
-		width: 100%;
-		font-size: 16px;
-		font-weight: 500;
-		height: 32px;
-		display: flex;
-		align-items: center;
-		justify-content: center;
-		position: relative;
-		padding: 0 40rpx;
+.header-top {
+	width: 100%;
+	font-size: 16px;
+	font-weight: 500;
+	height: 32px;
+	display: flex;
+	align-items: center;
+	justify-content: center;
+	position: relative;
+	padding: 0 40rpx;
+}
+
+.header-sit {
+	width: 100%;
+	box-sizing: border-box;
+	height: 80rpx;
+	line-height: 80rpx;
+	box-sizing: border-box;
+	color: #ffffff;
+
+	.header-sit-text {
+		text-align: left;
+		font-size: $font-size-40;
+		font-weight: 600;
+		font-family: '正楷';
 	}
 
-	.header-sit {
-		width: 100%;
-		box-sizing: border-box;
+	.icon-fanhui {
+		display: block;
+		width: 80rpx;
 		height: 80rpx;
+		float: left;
+		text-align: center;
 		line-height: 80rpx;
-		box-sizing: border-box;
-		color: #ffffff;
-	
-		.header-sit-text {
-			text-align: left;
-			font-size: $font-size-40;
-			font-weight: 600;
-			font-family: '正楷';
-		}
-	
-		.icon-fanhui {
-			display: block;
-			width: 80rpx;
-			height: 80rpx;
-			float: left;
-			text-align: center;
-			line-height: 80rpx;
-			font-size: 42rpx;
-		}
-	
-		.icon-iconfonticonfontsousuo1 {
-			font-size: 42rpx;
-			margin-left: 30rpx;
-		}
+		font-size: 42rpx;
 	}
 
-	.mine {
-		width: 100%;
-		height: 100%;
-		position: relative;
+	.icon-iconfonticonfontsousuo1 {
+		font-size: 42rpx;
+		margin-left: 30rpx;
 	}
+}
 
-	.distinguish-section {
-		width: 100%;
-		position: absolute;
-		padding: 40rpx 20rpx;
-		box-sizing: border-box;
-	}
+.mine {
+	width: 100%;
+	height: 100%;
+	position: relative;
+}
 
-	.distinguish-section-conten {
+.distinguish-section {
+	width: 100%;
+	position: absolute;
+	padding: 40rpx 20rpx;
+	box-sizing: border-box;
+}
+
+.distinguish-section-conten {
+	width: 100%;
+	height: auto;
+	position: relative;
+	background-color: #ffffff;
+	border-radius: 20rpx;
+	padding: 20rpx;
+	box-shadow: 0 10rpx 10rpx 0 rgba(86, 119, 252, 0.2);
+	.section-top {
 		width: 100%;
-		height: auto;
-		position: relative;
-		background-color: #ffffff;
-		border-radius: 20rpx;
-		padding: 20rpx;
-		box-shadow: 0 10rpx 10rpx 0 rgba(86, 119, 252, 0.2);
-		.section-top {
-			width: 100%;
+		height: 66rpx;
+		box-sizing: border-box;
+		.section-badges {
+			float: left;
 			height: 66rpx;
-			box-sizing: border-box;
-			.section-badges {
+			padding: 13rpx 0;
+			.list-title-tip {
 				float: left;
-				height: 66rpx;
-				padding: 13rpx 0;
-				.list-title-tip {
+				.badges {
+					display: block;
 					float: left;
-					.badges {
-						display: block;
-						float: left;
-						padding: 0 15rpx;
-						height: 40rpx;
-						line-height: 40rpx;
-						border-radius: 4rpx;
-						background: radial-gradient(circle, rgba(255, 180, 39, 1) 0%, rgba(245, 142, 77, 1) 100%);
-						font-size: $font-size-24;
-						text-align: center;
-						color: #ffffff;
-					}
+					padding: 0 15rpx;
+					height: 40rpx;
+					line-height: 40rpx;
+					border-radius: 20rpx;
+					background: rgba(248, 204, 148, 0.5);
+					font-size: $font-size-24;
+					text-align: center;
+					color: #666666;
 				}
-				.list-title-num {
+			}
+			.list-title-tag {
+				float: left;
+				margin-left: 20rpx;
+				.badges {
+					display: block;
 					float: left;
-					text-align: left;
-					color: #e15616;
+					padding: 0 15rpx;
+					height: 40rpx;
 					line-height: 40rpx;
-					margin-left: 20rpx;
+					border-radius: 20rpx;
+					background: linear-gradient(270deg, #fee9ba 0%, #f0cb72 100%);
+					font-size: $font-size-24;
+					text-align: center;
+					color: #666666;
 				}
 			}
-			.button {
-				float: right;
-				box-sizing: border-box;
-				padding: 0 24rpx;
-				height: 100%;
-				line-height: 66rpx;
-				background: $btn-confirm;
-				border-radius: 8rpx;
-				text-align: center;
-				color: #ffffff;
+			.list-title-num {
+				float: left;
+				text-align: left;
+				color: #e15616;
+				line-height: 40rpx;
+				margin-left: 20rpx;
 			}
 		}
-		.section-mid{
-			width: 100%;
-			height: auto;
-			display: flex;
-			flex-direction: column;
-			padding: 15rpx 0;
-			position: relative;
-			border-radius:0 0 20rpx 20rpx;
-			&.supper{
-				padding: 0;
-				.list-goods{
+		.button {
+			float: right;
+			box-sizing: border-box;
+			padding: 0 24rpx;
+			height: 100%;
+			line-height: 66rpx;
+			background: $btn-confirm;
+			border-radius: 8rpx;
+			text-align: center;
+			color: #ffffff;
+		}
+	}
+	.section-mid {
+		width: 100%;
+		height: auto;
+		display: flex;
+		flex-direction: column;
+		padding: 15rpx 0;
+		position: relative;
+		border-radius: 0 0 20rpx 20rpx;
+		&.supper {
+			padding: 0;
+			.list-goods {
+				width: 100%;
+				height: auto;
+				margin-top: 20rpx;
+				.list-goods-item {
 					width: 100%;
-					height: auto;
-					margin-top: 20rpx;
-					.list-goods-item{
-						width: 100%;
+					height: 180rpx;
+					margin-bottom: 20rpx;
+					.list-goods-image {
+						width: 180rpx;
 						height: 180rpx;
-						margin-bottom: 20rpx;
-						.list-goods-image{
-							width: 180rpx;
-							height: 180rpx;
+						border-radius: 8rpx;
+						float: left;
+						position: relative;
+						border: 1px solid #E1E1E1;
+						.list-image {
+							width: 100%;
+							height: 100%;
 							border-radius: 8rpx;
-							float: left;
-							position: relative;
-							.list-image{
-								width: 180rpx;
-								height: 180rpx;
-								border-radius: 8rpx;
-								display: block;
-							}
-							.list-tags{
-								padding: 0 15rpx;
-								height: 40rpx;
-								text-align: center;
-								line-height: 40rpx;
-								font-size: 22rpx;
-								border-radius: 8rpx 20rpx 0 20rpx;
-								color: #FFFFFF;
-								background-color: #dd524d;
-								position: absolute;
-								top: 0;
-								left: 0;
-							}
+							display: block;
 						}
-						.list-goods-mains{
-							width: 480rpx;
-							height: 100%;
+						.list-tags {
+							padding: 0 15rpx;
+							height: 40rpx;
+							text-align: center;
+							line-height: 40rpx;
+							font-size: 22rpx;
+							border-radius: 8rpx 20rpx 0 20rpx;
+							color: #ffffff;
+							background-color: #dd524d;
+							position: absolute;
+							top: 0;
+							left: 0;
+						}
+					}
+					.list-goods-mains {
+						width: 480rpx;
+						height: 100%;
+						float: left;
+						padding: 10rpx 0;
+						padding-left: 24rpx;
+						.list-name {
+							width: 100%;
+							line-height: 40rpx;
+							font-size: $font-size-24;
+							color: #333333;
+							text-align: left;
+							text-overflow: ellipsis;
+							overflow: hidden;
+							display: -webkit-box;
+							-webkit-line-clamp: 2;
+							line-clamp: 2;
+							-webkit-box-orient: vertical;
+						}
+						.list-text {
+							width: 100%;
+							height: 40rpx;
 							float: left;
-							padding:10rpx 0;
-							padding-left: 24rpx;
-							.list-name{
-								width: 100%;
-								line-height: 40rpx;
-								font-size: $font-size-24;
-								color: #333333;
-								text-align: left;
-								text-overflow: ellipsis;
-								overflow: hidden;
-								display: -webkit-box;
-								-webkit-line-clamp: 2;
-								line-clamp: 2;
-								-webkit-box-orient: vertical;
-							}
-							.list-text{
-								width: 100%;
-								height: 40rpx;
+							font-size: $font-size-24;
+							line-height: 40rpx;
+							color: #999999;
+							text-align: left;
+							.list-text-item {
+								width: 50%;
+								height: 100%;
 								float: left;
-								font-size: $font-size-24;
-								line-height: 40rpx;
-								color: #999999;
-								text-align: left;
-								.list-text-item {
-									width: 50%;
-									height: 100%;
-									float: left;
-								}
 							}
 						}
 					}
 				}
 			}
-			.list-title {
+		}
+		.list-title {
+			width: 100%;
+			height: auto;
+			&.supper {
+				background-color: #f7f7f7;
+				padding: 0 10rpx;
+			}
+			.list-title-b {
 				width: 100%;
-				height: auto;
-				&.supper{
-					background-color: #F7F7F7;
-					padding:0 10rpx;
+				height: 50rpx;
+				float: left;
+				font-size: $font-size-24;
+				line-height: 50rpx;
+				color: #666666;
+				text-align: left;
+				.text {
+					color: #999999;
 				}
-				.list-title-b {
-					width: 100%;
-					height: 50rpx;
+				.list-title-b-item {
+					width: 50%;
+					height: 100%;
 					float: left;
-					font-size: $font-size-24;
-					line-height: 50rpx;
-					color: #666666;
-					text-align: left;
-					.text{
-						color: #999999;
-					}
-					.list-title-b-item {
-						width: 50%;
-						height: 100%;
-						float: left;
-					}
 				}
 			}
 		}
 	}
+}
 </style>

+ 336 - 583
pages/relation/ordinary/detail.vue

@@ -1,566 +1,398 @@
 <template>
 	<view class="container mine clearfix">
 		<!-- <cu-custom :navbar-data='nvabarData'  @navigateBack="hanldNavigateBack"></cu-custom> -->
-		<view class="tui-header-box first"
+		<view
+			class="tui-header-box first"
 			:style="{ height: isCmcustomClass == 'fiexd' ? CustomBar + 10 + 'px' : CustomBar + 30 + 'px' }"
-			:class="isCmcustomClass">
+			:class="isCmcustomClass"
+		>
 			<view class="header-top" :style="{ paddingTop: top + 'px', lineHeight: CustomBar + 30 + 'px' }"></view>
 			<view class="header-sit">
 				<text class="iconfont icon-fanhui" @click.stop="this.$api.navigateBack(1)"></text>
 				<text class="header-sit-text">审核详情</text>
 			</view>
 		</view>
-		<view class="tui-header-box"
-			:style="{ height: CustomBar + 30 + 'px', backgroundImage: 'url(https://static.caimei365.com/app/crm/image/statistic_bg1.png)' }">
+		<view
+			class="tui-header-box"
+			:style="{
+				height: CustomBar + 30 + 'px',
+				backgroundImage: 'url(https://static.caimei365.com/app/crm/image/statistic_bg1.png)'
+			}"
+		>
 		</view>
-		<view class="distinguish-section" :style="{ top: CustomBar - 14 + 'px', left: 0 + 'px' }">
+		<view class="distinguish-section" :style="{ top: CustomBar - 4 + 'px', left: 0 + 'px' }">
 			<view class="distinguish-section-conten">
 				<view class="section-top">
 					<view class="title">
 						<view class="list-title-tip">
-							<text class="badges">{{ payment.sourceType | formatSourceType }}款</text>
+							<text class="badges">{{ receiptInfo.receiptType | formatReceiptType }}款</text>
 						</view>
 						<view class="title-text">收款信息</view>
 					</view>
 					<view class="button" @click="toNoSms('/pages/collection/list')">
-						<text class="iconfont icon-wodedingdan"></text>
-						收款列表
+						<text class="iconfont icon-wodedingdan"></text> 收款列表
 					</view>
 				</view>
 				<view class="section-top-item">
 					<view class="list-title-b">
-						<view class="list-title-b-item "> 
-							收款金额:<text class="text">¥{{ payment.receiptAmount | NumFormat }}</text>
+						<view class="list-title-b-item ">
+							收款金额:<text class="text">¥{{ receiptInfo.receiptAmount | NumFormat }}</text>
 						</view>
-						<view class="list-title-b-item "> 
-							收款类型:<text class="text">{{ payment.receiptType }}</text>
+						<view class="list-title-b-item ">
+							收款类型:<text class="text">{{ receiptInfo.payTypeText }}</text>
 						</view>
 					</view>
 					<view class="list-title-b">
-						款时间:<text class="text">{{ payment.receiptDate }}</text>
+						款时间:<text class="text">{{ receiptInfo.receiptDate }}</text>
 					</view>
-					<template v-if="payment.smsContent">
+					<template v-if="receiptInfo.smsContent">
 						<view class="list-title-b">收款短信:</view>
 						<view class="list-title-b sms">
-							<text class="text">{{ payment.smsContent }}</text>
+							<text class="text">{{ receiptInfo.smsContent ? receiptInfo.smsContent : '无' }}</text>
 						</view>
 					</template>
 				</view>
 				<view class="section-title">关联订单</view>
 				<view class="section-mid">
-					<view class="list-title">
-						<view class="list-title-t">
-							<view class="list-title-tip">
-								<text class="badges">{{ payment.order.orderType | formatOrderType }}</text>
-							</view>
-							<view class="list-title-num">{{
-								payment.order.state | StateExpFormat
-							}}</view>
-						</view>
-						<view class="list-title-b">
-							订单编号:<text class="text">{{ payment.order.number }} ( {{ payment.order.orderId }} )</text>
-						</view>
-						<view class="list-title-b">
-							下单日期:<text class="text">{{ payment.order.creatTime }}</text>
-						</view>
-						<view class="list-title-b">
-							客户名称:<text class="text">{{ payment.order.userName }}</text>
-						</view>
-						<view class="list-title-b">
-							<view class="list-title-b-item ">
-								订单金额:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-							<view class="list-title-b-item ">
-								余额抵扣:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-						</view>
-						<view class="list-title-b">
-							<view class="list-title-b-item ">
-								应收金额:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-							<view class="list-title-b-item ">
-								已收金额:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-						</view>
-						<view class="list-title-b">
-							<view class="list-title-b-item ">
-								剩余应收:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-							<view class="list-title-b-item ">
-								待审金额:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-						</view>
-						<view class="list-title-b">
-							经理折扣:<text class="text">¥{{ payment.receiptAmount }}(原¥0.00,折扣取消¥0.00)</text>
-						</view>
+					<view class="tui-order-item" v-for="(order, orderIndex) in receiptInfo.orderList" :key="orderIndex">
+						<receipt-details :orderInfo="order"></receipt-details>
 					</view>
 				</view>
 				<view class="section-title">状态</view>
 				<view class="section-mid">
 					<view class="list-title">
-						<view class="list-title-b">进度:<text
-								:style="{ color: formatColor(payment.confirmType) }">{{ payment.confirmType | formatStateType }}(待审核)</text>
+						<view class="list-title-b"
+							>进度:<text :style="{ color: formatColor(receiptInfo.receiptStatus) }"
+								>{{ receiptInfo.receiptStatus | formatStateType }}</text
+							>
 						</view>
-						<view class="list-title-b">确认人:<text class="text">正大单</text></view>
-						<view class="list-title-b">确认时间:<text class="text">{{ payment.receiptDate }}</text></view>
-						<view class="list-title-b">审核人:<text class="text">正大单</text></view>
-						<view class="list-title-b">审核时间:<text class="text">{{ payment.receiptDate }}</text></view>
+						<view class="list-title-b"
+							>确认人:<text class="text">{{
+								receiptInfo.confirmUserName ? receiptInfo.confirmUserName : '无'
+							}}</text></view
+						>
+						<view class="list-title-b"
+							>确认时间:<text class="text">{{
+								receiptInfo.confirmDate ? receiptInfo.confirmDate : '无'
+							}}</text></view
+						>
+						<view class="list-title-b"
+							>审核人:<text class="text">{{
+								receiptInfo.reviewUserName ? receiptInfo.reviewUserName : '无'
+							}}</text></view
+						>
+						<view class="list-title-b"
+							>审核时间:<text class="text">{{
+								receiptInfo.reviewDate ? receiptInfo.reviewDate : '无'
+							}}</text></view
+						>
 					</view>
 				</view>
 			</view>
 		</view>
-		<!-- 弹窗提示 -->
-		<tui-modal :show="modal" @click="handleClick" @cancel="hideMobel" :title="contentModalTitle"
-			:content="contentModalText" :button="modalButton" color="#333" :size="32" shape="circle"
-			:maskClosable="false">
-		</tui-modal>
 	</view>
 </template>
 <script>
-	import wxLogin from '@/services/wxLogin.js'
-	import {
-		mapState,
-		mapMutations
-	} from 'vuex'
+import wxLogin from '@/services/wxLogin.js'
+import receiptDetails from '@/components/cm-module/receipt/receipt-details'
+import { mapState, mapMutations } from 'vuex'
 
-	export default {
-		data() {
-			return {
-				isIphoneX: this.$store.state.isIphoneX,
-				nvabarData: {
-					//顶部自定义导航
-					showCapsule: 1, // 是否显示左上角图标  1表示显示  0表示不显示,
-					showSearch: 0,
-					title: '', // 导航栏 中间的标题
-					haveBack: false,
-					home: false,
-					textLeft: this.$store.state.isIphone,
-					bgColor: '#D33020',
-					textColor: '#ffffff'
-				},
-				payment: {
-					id: 6090,
-					receiptAmount: 5000, //收款金额
-					associateAmount: 5000, //关联金额
-					receiptType: '广发银行0115',
-					receiptDate: '2022-02-15 10:58:25', // 收款时间
-					reviewDate: '2022-02-15 10:58:25', // 审核时间
-					smsContent: '【中信银行】您尾号0897的中信卡于05月29日14:42,二代支付存入人民币99.00元,当前余额为人民币13871.67元。',
-					confirmType: 3,
-					userName: '采美网络信息有限公司',
-					sourceType: 1,
-					state: 11,
-					isChecked: false,
-					order: {
-						orderId: 18751,
-						number: 'W164488903271223',
-						receiptAmount: 5000, //收款金额
-						associateAmount: 5000, //关联金额
-						orderType: 1, // 订单类型
-						creatTime: '2022-02-15 10:58:25', // 下单日期
-						userName: '采美网络信息有限公司',
-						state: 11, //订单状态
-					}
-				},
-				modalButton: [{
-						text: '取消',
-						type: 'gray',
-						plain: true //是否空心
-					},
-					{
-						text: '确认',
-						customStyle: {
-							color: '#fff',
-							bgColor: '#4688fa'
-						},
-						plain: false
-					}
-				],
-				params: {
-					type: 1,
-					banksType: 1,
-					amount: '',
-					chargeValue: '',
-					remarks: '',
-					time: this.$api.getNowFormatDate()
-				},
-				infoData: {},
-				isCmcustomClass: 'left',
-				CustomBar: this.CustomBar, // 顶部导航栏高度
-				height: 64, //header高度
-				top: 0, //标题图标距离顶部距离
-				scrollH: 0, //滚动总高度
-				opcity: 1,
-				isCheckedCharge: false,
-				contentModalTitle: '',
-				contentModalText: '', //操作文字提示语句
-				modal: false,
-			}
-		},
-		onLoad() {
-			let obj = {}
-			// #ifdef MP-WEIXIN
-			obj = wx.getMenuButtonBoundingClientRect()
-			// #endif
-			// #ifdef MP-BAIDU
-			obj = swan.getMenuButtonBoundingClientRect()
-			// #endif
-			// #ifdef MP-ALIPAY
-			my.hideAddToDesktopMenu()
-			// #endif
-			uni.getSystemInfo({
-				success: res => {
-					this.width = obj.left || res.windowWidth
-					this.height = obj.top ? obj.top + obj.height + 8 : res.statusBarHeight + 44
-					this.top = obj.top ? obj.top + (obj.height - 32) / 2 : res.statusBarHeight + 6
-					this.scrollH = res.windowWidth * 0.6
-				}
-			})
-		},
-		filters: {
-			formatSourceType(value) {
-				switch (value) {
-					case 1:
-						return '订单'
-						break
-					case 2:
-						return '非订单'
-						break
-					case 3:
-						return '返佣'
-						break
-					case 4:
-						return '供应商退款'
-						break
-				}
-			},
-			formatOrderType(value) {
-				switch (value) {
-					case 1:
-						return '自主订单'
-						break
-					case 2:
-						return '协销订单'
-						break
-					case 3:
-						return '客服订单'
-						break
-				}
-			},
-			formatStateType(value) {
-				switch (value) {
-					case 0:
-						return '待确认'
-						break
-					case 1:
-						return '已确认'
-						break
-					case 2:
-						return '待审核'
-						break
-					case 3:
-						return '审核通过'
-						break
-				}
-			},
-			StateExpFormat(state) {
-				//订单状态文字和颜色
-				var HtmlStateText = '',
-					stateTextObject = {
-						0: '待确认',
-						4: '交易完成',
-						5: '订单完成',
-						6: '已关闭',
-						7: '交易全退',
-						77: '交易全退',
-						11: '待付款待发货',
-						12: '待付款部分发货',
-						13: '待付款已发货',
-						21: '部分付款待发货',
-						22: '部分付款部分发货',
-						23: '部分付款已发货',
-						31: '已付款待发货',
-						32: '已付款部分发货',
-						33: '已付款已发货',
-						111: '待付款待发货'
-					}
-				Object.keys(stateTextObject).forEach(function(key) {
-					if (key == state) {
-						HtmlStateText = stateTextObject[key]
-					}
-				})
-				return HtmlStateText
+export default {
+	components: {
+		receiptDetails
+	},
+	data() {
+		return {
+			isIphoneX: this.$store.state.isIphoneX,
+			CustomBar: this.CustomBar, // 顶部导航栏高度
+			height: 64, //header高度
+			top: 0, //标题图标距离顶部距离
+			scrollH: 0, //滚动总高度
+			opcity: 1,
+			isCmcustomClass: 'left',
+			nvabarData: {
+				//顶部自定义导航
+				showCapsule: 1, // 是否显示左上角图标  1表示显示  0表示不显示,
+				showSearch: 0,
+				title: '', // 导航栏 中间的标题
+				haveBack: false,
+				home: false,
+				textLeft: this.$store.state.isIphone,
+				bgColor: '#D33020',
+				textColor: '#ffffff'
 			},
-			NumFormat(value) {
-				//处理金额
-				if (value) {
-					return Number(value).toFixed(2)
-				} else {
-					return '0.00'
-				}
+			receiptInfo: {},
+			receiptId: 0
+		}
+	},
+	onLoad(option) {
+		let obj = {}
+		// #ifdef MP-WEIXIN
+		obj = wx.getMenuButtonBoundingClientRect()
+		// #endif
+		// #ifdef MP-BAIDU
+		obj = swan.getMenuButtonBoundingClientRect()
+		// #endif
+		// #ifdef MP-ALIPAY
+		my.hideAddToDesktopMenu()
+		// #endif
+		uni.getSystemInfo({
+			success: res => {
+				this.width = obj.left || res.windowWidth
+				this.height = obj.top ? obj.top + obj.height + 8 : res.statusBarHeight + 44
+				this.top = obj.top ? obj.top + (obj.height - 32) / 2 : res.statusBarHeight + 6
+				this.scrollH = res.windowWidth * 0.6
 			}
+		})
+		this.receiptId = option.id
+		this.getOrderReceiptDetail(this.receiptId)
+	},
+	computed: {
+		...mapState(['hasLogin', 'userInfo'])
+	},
+	methods: {
+		getOrderReceiptDetail(id) {
+			// 收款详情
+			this.OrderService.orderReceiptDetail({ id: id })
+				.then(response => {
+					this.receiptInfo = response.data
+					this.skeletonShow = false
+				})
+				.catch(err => {
+					this.$util.msg(err.msg, 2000)
+				})
 		},
-		computed: {
-			...mapState(['hasLogin', 'userInfo'])
+		toNoSms(url) {
+			this.$api.navigateTo(url)
 		},
-		methods: {
-			bindPickerChange(type, e) {
-				// 选择选项
-				switch (type) {
-					case 1:
-						this.paymentTypeText = this.paymentActions[e.target.value].name
-						this.params.type = this.paymentActions[e.target.value].value
-						console.log('款项类型', this.paymentTypeText)
-						console.log('款项类型', this.params.type)
-						break
-					case 2:
-						this.banksTypeText = this.banksActions[e.target.value].name
-						this.params.banksType = this.banksActions[e.target.value].value
-						console.log('收款类型', this.params.banksType)
-						break
-				}
-			},
-			showTuiDateTime() {
-				this.$refs.dateTime.show()
-			},
-			confirmDistinguish() {
-				if (this.params.amount == '') {
-					this.$util.msg('请输入收款金额', 2000)
-					return
-				}
-				if (this.isCheckedCharge) {
-					if (this.params.chargeValue == '') {
-						this.$util.msg('请输入手续费', 2000)
-						return
-					}
-				}
-				if (this.params.remarks == '') {
-					this.$util.msg('请填写收款备注', 2000)
-					return
+		formatColor(state) {
+			//设置邀请码状态亚瑟
+			let stateColor = '',
+				stateColorObject = {
+					1: '#FEAC20',
+					2: '#4cd964',
+					3: '#34CC8C',
+					4: '#F94B4B',
+					5: '#007aff'
 				}
-				if (this.params.type == 1) {
-					this.contentModalTitle = '确定收款吗?'
-					this.contentModalText = '确认前请仔细检查各项数据是否正确,确认收款后将不能进行修改。' //操作文字提示语句
-				} else if (this.params.type == 2) {
-					this.contentModalTitle = ''
-					this.contentModalText = '确定返佣收款吗?' //操作文字提示语句
-				} else if (this.params.type == 3) {
-					this.contentModalTitle = ''
-					this.contentModalText = '确定供应商退款吗?' //操作文字提示语句
+			Object.keys(stateColorObject).forEach(function(key) {
+				if (key == state) {
+					stateColor = stateColorObject[key]
 				}
-				this.modal = true
-				console.log('收款')
-			},
-			handleClick(e) {
-				// 确认收款
-				if (e.index == 1) {
-					this.$api.navigateTo('/pages/collection/detail')
-				}
-				this.modal = false
-			},
-			hideMobel() {
-				this.modal = false
-			},
-			checkedCharge() {
-				// 勾选手续费
-				this.isCheckedCharge = !this.isCheckedCharge
-			},
-			changeNumber(e) {
-				// 校验输入为数字
-				if (!this.$api.isNumber(e.detail.value)) {
-					this.params.amount = ''
-				} else {
-					this.params.amount = e.detail.value
-				}
-			},
-			toNoSms(url) {
-				this.$api.navigateTo(url)
-			},
-			formatColor(state) {
-				//设置邀请码状态亚瑟
-				let stateColor = '',
-					stateColorObject = {
-						0: '#f0ad4e',
-						1: '#4cd964',
-						2: '#dd524d',
-						3: '#007aff'
-					}
-				Object.keys(stateColorObject).forEach(function(key) {
-					if (key == state) {
-						stateColor = stateColorObject[key]
-					}
-				})
-				return stateColor
-			},
-		},
-		onPageScroll(e) {
-			//实时获取到滚动的值
-			// if (e.scrollTop > 30) {
-			// 	this.isCmcustomClass = 'fiexd'
-			// } else {
-			// 	this.isCmcustomClass = 'left'
-			// }
-		},
-		onPullDownRefresh() {
-			setTimeout(() => {
-				// this.initSsoMemberCollectionList()
-				uni.stopPullDownRefresh()
-			}, 200)
+			})
+			return stateColor
 		},
-		onShow() {
-			if (this.hasLogin) {
-				this.GetDataInfo()
-			}
-		}
-	}
+	},
+	onPageScroll(e) {
+		//实时获取到滚动的值
+		// if (e.scrollTop > 30) {
+		// 	this.isCmcustomClass = 'fiexd'
+		// } else {
+		// 	this.isCmcustomClass = 'left'
+		// }
+	},
+	onPullDownRefresh() {
+		setTimeout(() => {
+			this.getOrderReceiptDetail(this.receiptId)
+			uni.stopPullDownRefresh()
+		}, 200)
+	},
+	onShow() {}
+}
 </script>
 
 <style lang="scss">
-	@import '@/uni.scss';
+@import '@/uni.scss';
 
-	page {
-		background: #fff;
-	}
+page {
+	background: #fff;
+}
 
-	.tui-header-box {
-		width: 100%;
-		background: #ffffff;
-		z-index: 999;
-		background-size: cover;
-		background-image: url(https://static.caimei365.com/app/crm/image/statistic_bg2.png);
+.tui-header-box {
+	width: 100%;
+	background: #ffffff;
+	z-index: 999;
+	background-size: cover;
+	background-image: url(https://static.caimei365.com/app/crm/image/statistic_bg2.png);
 
-		&.fiexd {
-			position: fixed;
-			top: 0;
-			left: 0;
-		}
+	&.fiexd {
+		position: fixed;
+		top: 0;
+		left: 0;
 	}
+}
 
-	.header-top {
-		width: 100%;
-		font-size: 16px;
-		font-weight: 500;
-		height: 32px;
-		display: flex;
-		align-items: center;
-		justify-content: center;
-		position: relative;
-		padding: 0 40rpx;
+.header-top {
+	width: 100%;
+	font-size: 16px;
+	font-weight: 500;
+	height: 32px;
+	display: flex;
+	align-items: center;
+	justify-content: center;
+	position: relative;
+	padding: 0 40rpx;
+}
+
+.header-sit {
+	width: 100%;
+	box-sizing: border-box;
+	height: 80rpx;
+	line-height: 80rpx;
+	box-sizing: border-box;
+	color: #ffffff;
+
+	.header-sit-text {
+		text-align: left;
+		font-size: $font-size-40;
+		font-weight: 600;
+		font-family: '正楷';
 	}
 
-	.header-sit {
-		width: 100%;
-		box-sizing: border-box;
+	.icon-fanhui {
+		display: block;
+		width: 80rpx;
 		height: 80rpx;
+		float: left;
+		text-align: center;
 		line-height: 80rpx;
-		box-sizing: border-box;
-		color: #ffffff;
+		font-size: 42rpx;
+	}
 
-		.header-sit-text {
-			text-align: left;
-			font-size: $font-size-40;
-			font-weight: 600;
-			font-family: '正楷';
-		}
+	.icon-iconfonticonfontsousuo1 {
+		font-size: 42rpx;
+		margin-left: 30rpx;
+	}
+}
 
-		.icon-fanhui {
-			display: block;
-			width: 80rpx;
-			height: 80rpx;
-			float: left;
-			text-align: center;
-			line-height: 80rpx;
-			font-size: 42rpx;
-		}
+.mine {
+	width: 100%;
+	height: 100%;
+	position: relative;
+}
 
-		.icon-iconfonticonfontsousuo1 {
-			font-size: 42rpx;
-			margin-left: 30rpx;
-		}
-	}
+.distinguish-section {
+	width: 100%;
+	position: absolute;
+	padding: 40rpx 20rpx;
+	box-sizing: border-box;
+}
 
-	.mine {
-		width: 100%;
-		height: 100%;
-		position: relative;
-	}
+.distinguish-section-conten {
+	width: 100%;
+	height: auto;
+	position: relative;
+	background-color: #ffffff;
+	border-radius: 20rpx;
+	padding: 20rpx;
+	box-shadow: 0 10rpx 10rpx 0 rgba(86, 119, 252, 0.2);
 
-	.distinguish-section {
+	.section-top {
 		width: 100%;
-		position: absolute;
-		padding: 40rpx 20rpx;
+		height: 66rpx;
 		box-sizing: border-box;
-	}
-
-	.distinguish-section-conten {
-		width: 100%;
-		height: auto;
-		position: relative;
-		background-color: #ffffff;
-		border-radius: 20rpx;
-		padding: 20rpx;
-		box-shadow: 0 10rpx 10rpx 0 rgba(86, 119, 252, 0.2);
-
-		.section-top {
-			width: 100%;
+		.title {
+			float: left;
 			height: 66rpx;
-			box-sizing: border-box;
-			.title {
+			padding: 13rpx 0;
+			.list-title-tip {
 				float: left;
-				height: 66rpx;
-				padding: 13rpx 0;
-				.list-title-tip {
-					float: left;
-					margin-right: 15rpx;
-					.badges {
-						display: block;
-						float: left;
-						padding: 0 15rpx;
-						height: 40rpx;
-						line-height: 40rpx;
-						border-radius: 4rpx;
-						background: $btn-confirm;
-						font-size: $font-size-24;
-						text-align: center;
-						color: #ffffff;
-					}
-				}
-				.title-text{
+				margin-right: 15rpx;
+				.badges {
+					display: block;
 					float: left;
-					line-height: 40rpx;
+					padding: 0 15rpx;
 					height: 40rpx;
-					color: #333333;
-					text-align: left;
-					font-weight: 600;
+					line-height: 40rpx;
+					border-radius: 4rpx;
+					background: $btn-confirm;
+					font-size: $font-size-24;
+					text-align: center;
+					color: #ffffff;
 				}
 			}
+			.title-text {
+				float: left;
+				line-height: 40rpx;
+				height: 40rpx;
+				color: #333333;
+				text-align: left;
+				font-weight: 600;
+			}
+		}
+
+		.button {
+			float: right;
+			box-sizing: border-box;
+			padding: 0 24rpx;
+			height: 100%;
+			line-height: 66rpx;
+			background: $btn-confirm;
+			border-radius: 8rpx;
+			text-align: center;
+			color: #ffffff;
+		}
+	}
 
-			.button {
-				float: right;
-				box-sizing: border-box;
-				padding: 0 24rpx;
+	.section-top-item {
+		width: 100%;
+		height: auto;
+		margin-top: 10rpx;
+		position: relative;
+		float: left;
+		.list-title-b {
+			width: 100%;
+			height: 44rpx;
+			float: left;
+			font-size: $font-size-24;
+			line-height: 44rpx;
+			color: #999999;
+			text-align: left;
+			.text {
+				color: #999999;
+			}
+			.list-title-b-item {
+				width: 50%;
 				height: 100%;
-				line-height: 66rpx;
-				background: $btn-confirm;
-				border-radius: 8rpx;
-				text-align: center;
-				color: #ffffff;
+				float: left;
+			}
+			&.sms {
+				height: 120rpx;
+				padding: 10rpx;
+				border-radius: 4rpx;
+				background: #f7f7f7;
 			}
 		}
+	}
 
-		.section-top-item {
+	.section-title {
+		width: 100%;
+		height: 66rpx;
+		float: left;
+		font-size: $font-size-28;
+		line-height: 66rpx;
+		color: #333333;
+		text-align: left;
+		font-weight: 600;
+	}
+
+	.section-mid {
+		width: 100%;
+		height: auto;
+		display: flex;
+		flex-direction: column;
+		position: relative;
+		border-radius: 0 0 20rpx 20rpx;
+		.list-title {
 			width: 100%;
 			height: auto;
-			margin-top: 10rpx;
-			position: relative;
-			float: left;
 			.list-title-b {
 				width: 100%;
-				height: 44rpx;
+				height: 50rpx;
 				float: left;
 				font-size: $font-size-24;
-				line-height: 44rpx;
-				color: #999999;
+				line-height: 50rpx;
+				color: #666666;
 				text-align: left;
 				.text{
 					color: #999999;
@@ -570,122 +402,43 @@
 					height: 100%;
 					float: left;
 				}
-				&.sms {
-					height: 120rpx;
-					padding: 10rpx;
-					border-radius: 4rpx;
-					background: #F7F7F7;
-				}
 			}
 		}
-
-		.section-title {
-			width: 100%;
-			height: 66rpx;
-			float: left;
-			font-size: $font-size-28;
-			line-height: 66rpx;
-			color: #333333;
-			text-align: left;
-			font-weight: 600;
-		}
-
-		.section-mid {
-			width: 100%;
-			height: auto;
-			display: flex;
-			flex-direction: column;
-			position: relative;
-			border-radius: 0 0 20rpx 20rpx;
-			.list-title {
-				width: 100%;
-				height: auto;
-				.list-title-t {
-					width: 100%;
-					height: 50rpx;
-					float: left;
-					font-size: $font-size-28;
-					padding-bottom: 10rpx;
-
-					.list-title-num {
-						float: left;
-						text-align: left;
-						color: #e15616;
-						margin-left: 30rpx;
-						line-height: 40rpx;
-					}
-
-					.list-title-tip {
-						float: left;
-
-						.badges {
-							display: block;
-							float: left;
-							padding: 0 15rpx;
-							height: 40rpx;
-							line-height: 40rpx;
-							border-radius: 4rpx;
-							background: radial-gradient(circle, rgba(255, 180, 39, 1) 0%, rgba(245, 142, 77, 1) 100%);
-							font-size: $font-size-24;
-							text-align: center;
-							color: #ffffff;
-						}
-					}
-				}
-
-				.list-title-b {
-					width: 100%;
-					height: 50rpx;
-					float: left;
-					font-size: $font-size-24;
-					line-height: 50rpx;
-					color: #666666;
-					text-align: left;
-					.text{
-						color: #999999;
-					}
-					.list-title-b-item {
-						width: 50%;
-						height: 100%;
-						float: left;
-					}
-				}
-			}
-		}
-		.section-tips{
-			width: 100%;
-			height: 50rpx;
-			font-size: $font-size-28;
-			line-height: 50rpx;
-			color: $uni-color-error;
-			text-align: left;
-		}
 	}
-	.distinguish-button {
+	.section-tips {
 		width: 100%;
-		position: fixed;
-		bottom: 0;
-		left: 0;
-		background-color: #ffffff;
-		padding: 0 50rpx;
-		padding-top: 20rpx;
-		display: flex;
-		.button {
-			flex: 1;
-			height: 80rpx;
-			margin: 0 20rpx;
-			border-radius: 40rpx;
-			text-align: center;
-			color: #ffffff;
-			line-height: 80rpx;
-			font-size: $font-size-28;
-			box-shadow: 0 10rpx 14rpx 0 rgba(86, 119, 252, 0.2);
-			&.confirm{
-				background: $btn-confirm;
-			}
-			&.cancel{
-				background: $uni-color-error;
-			}
+		height: 50rpx;
+		font-size: $font-size-28;
+		line-height: 50rpx;
+		color: $uni-color-error;
+		text-align: left;
+	}
+}
+.distinguish-button {
+	width: 100%;
+	position: fixed;
+	bottom: 0;
+	left: 0;
+	background-color: #ffffff;
+	padding: 0 50rpx;
+	padding-top: 20rpx;
+	display: flex;
+	.button {
+		flex: 1;
+		height: 80rpx;
+		margin: 0 20rpx;
+		border-radius: 40rpx;
+		text-align: center;
+		color: #ffffff;
+		line-height: 80rpx;
+		font-size: $font-size-28;
+		box-shadow: 0 10rpx 14rpx 0 rgba(86, 119, 252, 0.2);
+		&.confirm {
+			background: $btn-confirm;
+		}
+		&.cancel {
+			background: $uni-color-error;
 		}
 	}
+}
 </style>

+ 176 - 303
pages/relation/ordinary/examine-detail.vue

@@ -13,12 +13,12 @@
 		<view class="tui-header-box"
 			:style="{ height: CustomBar + 30 + 'px', backgroundImage: 'url(https://static.caimei365.com/app/crm/image/statistic_bg1.png)' }">
 		</view>
-		<view class="distinguish-section" :style="{ top: CustomBar - 14 + 'px', left: 0 + 'px' }">
+		<view class="distinguish-section" :style="{ top: CustomBar - 4 + 'px', left: 0 + 'px' }">
 			<view class="distinguish-section-conten">
 				<view class="section-top">
 					<view class="title">
 						<view class="list-title-tip">
-							<text class="badges">{{ payment.sourceType | formatSourceType }}款</text>
+							<text class="badges">{{ receiptInfo.receiptType | formatReceiptType }}款</text>
 						</view>
 						<view class="title-text">收款信息</view>
 					</view>
@@ -30,104 +30,102 @@
 				<view class="section-top-item">
 					<view class="list-title-b">
 						<view class="list-title-b-item "> 
-							收款金额:<text class="text">¥{{ payment.receiptAmount | NumFormat }} </text>
+							收款金额:<text class="text">¥{{ receiptInfo.receiptAmount | NumFormat }} </text>
 						</view>
 						<view class="list-title-b-item "> 
-							收款类型:<text class="text">{{ payment.receiptType }} </text>
+							收款类型:<text class="text">{{ receiptInfo.payTypeText }} </text>
 						</view>
 					</view>
 					<view class="list-title-b">
-						收款时间:<text class="text">{{ payment.receiptDate }}</text>
+						收款时间:<text class="text">{{ receiptInfo.receiptDate }}</text>
 					</view>
-					<template v-if="payment.smsContent">
+					<template v-if="receiptInfo.smsContent">
 						<view class="list-title-b">收款短信:</view>
 						<view class="list-title-b sms">
-							<text class="text">{{ payment.smsContent }}</text>
+							<text class="text">{{ receiptInfo.smsContent ? receiptInfo.smsContent : '无' }}</text>
 						</view>
 					</template>
-					<view class="list-icon">无人确认</view>
+					<view class="list-icon" v-if="receiptInfo.tipMsg">
+						<image
+							class="list-icon-image"
+							src="https://static.caimei365.com/app/crm/image/icon-noconfirm@2x.png"
+							mode=""
+							v-if="receiptInfo.receiptStatus == 1"
+						></image>
+						<image
+							class="list-icon-image"
+							src="https://static.caimei365.com/app/crm/image/icon-noaudit@2x.png"
+							mode=""
+							v-if="receiptInfo.receiptStatus == 2"
+						></image>
+					</view>
 				</view>
 				<view class="section-title">关联订单</view>
 				<view class="section-mid">
-					<view class="list-title">
-						<view class="list-title-t">
-							<view class="list-title-tip">
-								<text class="badges">{{ payment.order.orderType | formatOrderType }}</text>
-							</view>
-							<view class="list-title-num">{{
-								payment.order.state | StateExpFormat
-							}}</view>
-						</view>
-						<view class="list-title-b">
-							订单编号:<text class="text">{{ payment.order.number }} ( {{ payment.order.orderId }} )</text>
-						</view>
-						<view class="list-title-b">
-							下单日期:<text class="text">{{ payment.order.creatTime }}</text>
-						</view>
-						<view class="list-title-b">
-							客户名称:<text class="text">{{ payment.order.userName }}</text>
-						</view>
-						<view class="list-title-b">
-							<view class="list-title-b-item ">
-								订单金额:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-							<view class="list-title-b-item ">
-								余额抵扣:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-						</view>
-						<view class="list-title-b">
-							<view class="list-title-b-item ">
-								应收金额:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-							<view class="list-title-b-item ">
-								已收金额:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-						</view>
-						<view class="list-title-b">
-							<view class="list-title-b-item ">
-								剩余应收:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-							<view class="list-title-b-item ">
-								待审金额:<text class="text">¥{{ payment.order.receiptAmount | NumFormat }}</text>
-							</view>
-						</view>
+					<view class="tui-order-item" v-for="(order, orderIndex) in receiptInfo.orderList" :key="orderIndex">
+						<receipt-details :orderInfo="order"></receipt-details>
 					</view>
 				</view>
 				<view class="section-title">状态</view>
 				<view class="section-mid">
 					<view class="list-title">
 						<view class="list-title-b">进度:<text
-								:style="{ color: formatColor(payment.confirmType) }">{{ payment.confirmType | formatStateType }}(待审核)</text>
+								:style="{ color: formatColor(receiptInfo.receiptStatus) }">{{ receiptInfo.receiptStatus | formatStateType }}</text>
 						</view>
 						<view class="list-title-b">确认人:<text class="text">正大单</text></view>
-						<view class="list-title-b">确认时间:<text class="text">{{ payment.receiptDate }}</text></view>
+						<view class="list-title-b">确认时间:<text class="text">{{ receiptInfo.confirmDate }}</text></view>
 					</view>
 				</view>
 				<view class="section-tips">注:款项和订单已确认关联,等待审核</view>
 			</view>
 		</view>
 		<view class="distinguish-button" :style="{ paddingBottom: isIphoneX ? '68rpx' : '24rpx' }">
-			<view class="button cancel" @click="confirmDistinguish">不通过</view>
-			<view class="button confirm" @click="confirmDistinguish">通过</view>
+			<view class="button cancel" @click="confirmDistinguish(2)">不通过</view>
+			<view class="button confirm" @click="confirmDistinguish(1)">通过</view>
 		</view>
-		<!-- 弹窗提示 -->
-		<tui-modal :show="modal" @click="handleClick" @cancel="hideMobel" :title="contentModalTitle"
-			:content="contentModalText" :button="modalButton" color="#333" :size="32" shape="circle"
-			:maskClosable="false">
-		</tui-modal>
+		<!-- 审核通过弹窗 -->
+		<tui-modal :show="modal" @click="handleClick" @cancel="hideMobel" :content="contentModalText" color="#333"
+			:size="32" shape="circle" :maskClosable="false"></tui-modal>
+		<!--不通过审核备注弹窗  -->
+		<tui-modal :show="modal1" :padding="'40rpx 30rpx'" @cancel="hideMobel1" :custom="true" fadeIn >
+			<view class="tui-modal-custom">
+				<view class="tui-prompt-title">确认不通过</view>
+				<view class="tui-prompt-textarea">
+					<textarea
+						class="textarea"
+						placeholder="请填写不通过说明(必填)"
+						v-model="noReviewReason"
+					/>
+				</view>
+				<view class="tui-prompt-flex">
+					<view class="btn btn-cancel" @click="hideMobel1">取消</view>
+					<view class="btn btn-confirm" @click="handleClick1">确定</view>
+				</view>
+			</view>
+		</tui-modal>	
 	</view>
 </template>
 <script>
 	import wxLogin from '@/services/wxLogin.js'
+	import receiptDetails from '@/components/cm-module/receipt/receipt-details'
 	import {
 		mapState,
 		mapMutations
 	} from 'vuex'
 
 	export default {
+		components: {
+			receiptDetails
+		},
 		data() {
 			return {
 				isIphoneX: this.$store.state.isIphoneX,
+				CustomBar: this.CustomBar, // 顶部导航栏高度
+				height: 64, //header高度
+				top: 0, //标题图标距离顶部距离
+				scrollH: 0, //滚动总高度
+				opcity: 1,
+				isCmcustomClass: 'left',
 				nvabarData: {
 					//顶部自定义导航
 					showCapsule: 1, // 是否显示左上角图标  1表示显示  0表示不显示,
@@ -139,66 +137,20 @@
 					bgColor: '#D33020',
 					textColor: '#ffffff'
 				},
-				payment: {
-					id: 6090,
-					receiptAmount: 5000, //收款金额
-					associateAmount: 5000, //关联金额
-					receiptType: '广发银行0115',
-					receiptDate: '2022-02-15 10:58:25', // 收款时间
-					reviewDate: '2022-02-15 10:58:25', // 审核时间
-					smsContent: '【中信银行】您尾号0897的中信卡于05月29日14:42,二代支付存入人民币99.00元,当前余额为人民币13871.67元。',
-					confirmType: 1,
-					userName: '采美网络信息有限公司',
-					sourceType: 1,
-					state: 11,
-					isChecked: false,
-					order: {
-						orderId: 18751,
-						number: 'W164488903271223',
-						receiptAmount: 5000, //收款金额
-						associateAmount: 5000, //关联金额
-						orderType: 1, // 订单类型
-						creatTime: '2022-02-15 10:58:25', // 下单日期
-						userName: '采美网络信息有限公司',
-						state: 11, //订单状态
-					}
-				},
-				modalButton: [{
-						text: '取消',
-						type: 'gray',
-						plain: true //是否空心
-					},
-					{
-						text: '确认',
-						customStyle: {
-							color: '#fff',
-							bgColor: '#4688fa'
-						},
-						plain: false
-					}
-				],
+				receiptInfo: {},
+				receiptId:0,
+				noReviewReason:'',
 				params: {
-					type: 1,
-					banksType: 1,
-					amount: '',
-					chargeValue: '',
-					remarks: '',
-					time: this.$api.getNowFormatDate()
+					id: 0,
+					receiptStatus: 1
 				},
-				infoData: {},
-				isCmcustomClass: 'left',
-				CustomBar: this.CustomBar, // 顶部导航栏高度
-				height: 64, //header高度
-				top: 0, //标题图标距离顶部距离
-				scrollH: 0, //滚动总高度
-				opcity: 1,
-				isCheckedCharge: false,
-				contentModalTitle: '',
-				contentModalText: '', //操作文字提示语句
+				contentModalText: '确认通过审核?', //操作文字提示语句
 				modal: false,
+				modal1: false,
+				
 			}
 		},
-		onLoad() {
+		onLoad(option) {
 			let obj = {}
 			// #ifdef MP-WEIXIN
 			obj = wx.getMenuButtonBoundingClientRect()
@@ -217,162 +169,79 @@
 					this.scrollH = res.windowWidth * 0.6
 				}
 			})
+			this.receiptId = this.params.id = option.id
+			this.getOrderReceiptDetail(this.receiptId)
 		},
 		filters: {
-			formatSourceType(value) {
-				switch (value) {
-					case 1:
-						return '订单'
-						break
-					case 2:
-						return '非订单'
-						break
-					case 3:
-						return '返佣'
-						break
-					case 4:
-						return '供应商退款'
-						break
-				}
-			},
-			formatOrderType(value) {
-				switch (value) {
-					case 1:
-						return '自主订单'
-						break
-					case 2:
-						return '协销订单'
-						break
-					case 3:
-						return '客服订单'
-						break
-				}
-			},
-			formatStateType(value) {
-				switch (value) {
-					case 0:
-						return '待确认'
-						break
-					case 1:
-						return '已确认'
-						break
-					case 2:
-						return '待审核'
-						break
-					case 3:
-						return '审核通过'
-						break
-				}
-			},
-			StateExpFormat(state) {
-				//订单状态文字和颜色
-				var HtmlStateText = '',
-					stateTextObject = {
-						0: '待确认',
-						4: '交易完成',
-						5: '订单完成',
-						6: '已关闭',
-						7: '交易全退',
-						77: '交易全退',
-						11: '待付款待发货',
-						12: '待付款部分发货',
-						13: '待付款已发货',
-						21: '部分付款待发货',
-						22: '部分付款部分发货',
-						23: '部分付款已发货',
-						31: '已付款待发货',
-						32: '已付款部分发货',
-						33: '已付款已发货',
-						111: '待付款待发货'
-					}
-				Object.keys(stateTextObject).forEach(function(key) {
-					if (key == state) {
-						HtmlStateText = stateTextObject[key]
-					}
-				})
-				return HtmlStateText
-			},
-			NumFormat(value) {
-				//处理金额
-				if (value) {
-					return Number(value).toFixed(2)
-				} else {
-					return '0.00'
-				}
-			}
+			
 		},
 		computed: {
-			...mapState(['hasLogin', 'userInfo'])
+			...mapState(['hasLogin'])
 		},
 		methods: {
-			bindPickerChange(type, e) {
-				// 选择选项
-				switch (type) {
+			getOrderReceiptDetail(id){
+				// 收款详情
+				this.OrderService.orderReceiptDetail({ id : id})
+					.then(response => {
+						this.receiptInfo = response.data
+						this.skeletonShow = false
+					})
+					.catch(err => {
+						this.$util.msg(err.msg, 2000)
+					})
+			},
+			orderReceiptAudit(params){
+				//操作审核款项
+				this.OrderService.orderReceiptAudit(params)
+				.then(response => {
+					this.$util.msg('操作成功~', 2000, true, 'success')
+					if(this.params.receiptStatus == 3){//通过审核跳转
+						this.$api.navigateTo(`/pages/relation/ordinary/detail?id=${this.params.id}`)
+					}else{//不通过审核跳转
+						this.$api.navigateTo(`/pages/relation/ordinary/index?id=${this.params.id}`)
+					}
+				})
+				.catch(error => {
+					this.$util.msg(error.msg, 2000)
+				})
+			},
+			confirmDistinguish(type) {
+				switch(type){
 					case 1:
-						this.paymentTypeText = this.paymentActions[e.target.value].name
-						this.params.type = this.paymentActions[e.target.value].value
-						console.log('款项类型', this.paymentTypeText)
-						console.log('款项类型', this.params.type)
+						//通过审核
+						this.params.receiptStatus = 3
+						this.modal = true
 						break
 					case 2:
-						this.banksTypeText = this.banksActions[e.target.value].name
-						this.params.banksType = this.banksActions[e.target.value].value
-						console.log('收款类型', this.params.banksType)
+						//不通过审核显示备注弹窗
+						this.params.receiptStatus = 4
+						this.modal1 = true
 						break
 				}
 			},
-			showTuiDateTime() {
-				this.$refs.dateTime.show()
-			},
-			confirmDistinguish() {
-				if (this.params.amount == '') {
-					this.$util.msg('请输入收款金额', 2000)
-					return
-				}
-				if (this.isCheckedCharge) {
-					if (this.params.chargeValue == '') {
-						this.$util.msg('请输入手续费', 2000)
-						return
-					}
-				}
-				if (this.params.remarks == '') {
-					this.$util.msg('请填写收款备注', 2000)
-					return
-				}
-				if (this.params.type == 1) {
-					this.contentModalTitle = '确定收款吗?'
-					this.contentModalText = '确认前请仔细检查各项数据是否正确,确认收款后将不能进行修改。' //操作文字提示语句
-				} else if (this.params.type == 2) {
-					this.contentModalTitle = ''
-					this.contentModalText = '确定返佣收款吗?' //操作文字提示语句
-				} else if (this.params.type == 3) {
-					this.contentModalTitle = ''
-					this.contentModalText = '确定供应商退款吗?' //操作文字提示语句
-				}
-				this.modal = true
-				console.log('收款')
-			},
 			handleClick(e) {
-				// 确认收款
-				if (e.index == 1) {
-					this.$api.navigateTo('/pages/collection/detail')
+				// 通过审核
+				let index = e.index
+				if (index == 1) { 
+					this.orderReceiptAudit(this.params)
 				}
 				this.modal = false
 			},
+			handleClick1() {
+				// 不通过审核
+				if(this.noReviewReason == ''){
+					this.$util.msg('请输入不通过说明!', 2000)
+					return
+				}
+				this.params.reviewReason = this.noReviewReason
+				this.orderReceiptAudit(this.params)
+				this.modal1 = false
+			},
 			hideMobel() {
 				this.modal = false
 			},
-			checkedCharge() {
-				// 勾选手续费
-				this.isCheckedCharge = !this.isCheckedCharge
-			},
-			changeNumber(e) {
-				// 校验输入为数字
-				if (!this.$api.isNumber(e.detail.value)) {
-					this.params.amount = ''
-				} else {
-					this.params.amount = e.detail.value
-				}
+			hideMobel1() {
+				this.modal1 = false
 			},
 			toNoSms(url) {
 				this.$api.navigateTo(url)
@@ -381,10 +250,11 @@
 				//设置邀请码状态亚瑟
 				let stateColor = '',
 					stateColorObject = {
-						0: '#f0ad4e',
-						1: '#4cd964',
-						2: '#dd524d',
-						3: '#007aff'
+						1: '#FEAC20',
+						2: '#4cd964',
+						3: '#34CC8C',
+						4: '#F94B4B',
+						5: '#007aff'
 					}
 				Object.keys(stateColorObject).forEach(function(key) {
 					if (key == state) {
@@ -404,14 +274,12 @@
 		},
 		onPullDownRefresh() {
 			setTimeout(() => {
-				// this.initSsoMemberCollectionList()
+				this.getOrderReceiptDetail(this.receiptId)
 				uni.stopPullDownRefresh()
 			}, 200)
 		},
 		onShow() {
-			if (this.hasLogin) {
-				this.GetDataInfo()
-			}
+			
 		}
 	}
 </script>
@@ -580,21 +448,18 @@
 			}
 			.list-icon {
 				width: 120rpx;
-				height: 60rpx;
-				border: 1px solid #e1e1e1;
+				height: 120rpx;
 				border-radius: 10rpx;
-				text-align: center;
-				font-size: 20rpx;
-				line-height: 60rpx;
 				position: absolute;
-				right: 90rpx;
-				top: 40rpx;
+				right: 0;
+				top: 0;
 				color: #dd524d;
 				z-index: 99;
-				transform: rotate(45deg);
-				-webkit-transform: rotate(45deg);
-				-moz-transform: rotate(45deg);
-				font-family: '正楷';
+				.list-icon-image{
+					width: 120rpx;
+					height: 120rpx;
+					display: block;
+				}
 			}
 		}
 
@@ -619,39 +484,6 @@
 			.list-title {
 				width: 100%;
 				height: auto;
-				.list-title-t {
-					width: 100%;
-					height: 50rpx;
-					float: left;
-					font-size: $font-size-28;
-					padding-bottom: 10rpx;
-
-					.list-title-num {
-						float: left;
-						text-align: left;
-						color: #e15616;
-						margin-left: 30rpx;
-						line-height: 40rpx;
-					}
-
-					.list-title-tip {
-						float: left;
-
-						.badges {
-							display: block;
-							float: left;
-							padding: 0 15rpx;
-							height: 40rpx;
-							line-height: 40rpx;
-							border-radius: 4rpx;
-							background: radial-gradient(circle, rgba(255, 180, 39, 1) 0%, rgba(245, 142, 77, 1) 100%);
-							font-size: $font-size-24;
-							text-align: center;
-							color: #ffffff;
-						}
-					}
-				}
-
 				.list-title-b {
 					width: 100%;
 					height: 50rpx;
@@ -707,4 +539,45 @@
 			}
 		}
 	}
+	.tui-prompt-title{
+		line-height: 44rpx;
+		text-align: center;
+	}
+	.tui-prompt-textarea{
+		width: 100%;
+		height: 160rpx;
+		box-sizing: border-box;
+		background: #f7f7f7;
+		border-radius: 8rpx;
+		padding:15rpx 20rpx;
+		margin: 20rpx 0;
+		.textarea {
+			width: 100%;
+			height: 100%;
+			font-size: $font-size-26;
+		}
+	}
+	.tui-prompt-flex{
+		width: 100%;
+		height: 70rpx;
+		display: flex;
+		margin-top: 20rpx;
+		.btn{
+			flex: 1;
+			line-height: 70rpx;
+			font-size: $font-size-26;
+			text-align: center;
+			color: #FFFFFF;
+			border-radius: 33rpx;
+			margin: 0 24rpx;
+			&.btn-cancel{
+				background: #F7F7F7;
+				color: #999999;
+			}
+			&.btn-confirm{
+				background: $color-system;
+			}
+		}
+		
+	}
 </style>

+ 129 - 152
pages/relation/ordinary/index.vue

@@ -23,14 +23,14 @@
 				<view v-if="!isShowHeader">
 					<view class="tui-header-top">
 						<view class="title"> 收款信息 </view>
-						<view class="tui-header-button">
-							<!-- <view class="button btn-confirm" @click.stop="btnConfirm"> 设为非订单款项 </view> -->
+						<view class="tui-header-button" v-if="receiptInfo.orderList.length>0">
+							<view class="button btn-confirm" @click.stop="showReceiptModel"> 查看关联信息 </view>
 						</view>
 					</view>
 					<view class="tui-header-item">
 						<view class="list-title-t">
 							<view class="list-title-tip">
-								<text class="badges">{{ receiptInfo.receiptType | formatSourceType }}</text>
+								<text class="badges">{{ receiptInfo.receiptType | formatReceiptType }}款</text>
 							</view>
 							<view class="list-title-num" :style="{ color: formatColor(receiptInfo.receiptStatus) }">{{
 								receiptInfo.receiptStatus | formatStateType
@@ -47,12 +47,10 @@
 						<view class="list-title-b">
 							收款时间:<text class="text">{{ receiptInfo.receiptDate }}</text>
 						</view>
-						<template v-if="receiptInfo.smsContent">
-							<view class="list-title-b">收款短信:</view>
-							<view class="list-title-b sms">
-								<text class="text">{{ receiptInfo.smsContent }}</text>
-							</view>
-						</template>
+						<view class="list-title-b">收款短信:</view>
+						<view class="list-title-b sms">
+							<text class="text">{{ receiptInfo.smsContent ? receiptInfo.smsContent : '无' }}</text>
+						</view>
 						<view class="list-icon" v-if="receiptInfo.tipMsg">
 							<image
 								class="list-icon-image"
@@ -175,7 +173,7 @@
 		<tui-modal
 			:show="modal"
 			@click="handleClick"
-			@cancel="hideMobel"
+			@cancel="hideMobel(0)"
 			:content="contentModalText"
 			color="#333"
 			:size="32"
@@ -188,16 +186,23 @@
 			:show="modal1" 
 			:amount="receiptInfo.receiptAmount"
 			:totalOrder="totalOrder" 
-			:modelTpye="1" 
-			@cancel="hideMobel1" 
+			:modelTpye="modelTpye" 
+			@cancel="hideMobel(1)" 
 			@click="handleClick1">
 		</receipt-modal>
+		<receipt-orderDetails 
+			v-if="modal2"
+			:receipt="receiptInfo"
+			@cancel="hideMobel(2)"
+			>
+		</receipt-orderDetails>
 	</view>
 </template>
 <script>
 import receiptModal from '@/components/cm-module/receipt/receipt-modal'
 import receiptDetails from '@/components/cm-module/receipt/receipt-details'
 import receiptRefund from '@/components/cm-module/receipt/receipt-refund'
+import receiptOrderDetails from '@/components/cm-module/receipt/receipt-orderDetails'
 import empty from '@/components/empty'
 import wxLogin from '@/services/wxLogin.js'
 import { mapState, mapMutations } from 'vuex'
@@ -222,7 +227,8 @@ export default {
 		empty,
 		receiptModal,
 		receiptDetails,
-		receiptRefund
+		receiptRefund,
+		receiptOrderDetails
 	},
 	data() {
 		return {
@@ -273,6 +279,7 @@ export default {
 			contentModalText: '', //操作文字提示语句
 			modal: false,
 			modal1: false,
+			modal2: false,
 			hanldOrder: '', //储存监听订单信息
 			OperationType: '', //操作类型
 			isCmcustomClass: 'left',
@@ -282,67 +289,25 @@ export default {
 			scrollH: 0, //滚动总高度
 			opcity: 1,
 			checkedOrderList: [],
+			checkedIds:[],
 			checkedRefundIndex: 0,
+			confirmParams:{
+				confirmType:4,
+				id:0,
+				orderIds:'',
+			},
 			skeletonShow: true,
+			modelTpye:1,// 收款弹窗类型
 			totalOrder: {
 				orderNums:1,
 				payTotalFee: 0, // 订单金额
 				balancePayFee: 0, // 余额抵扣
 				payableAmount: 0, // 应收金额
-				paidAmount: 0 //  已收金额
+				paidAmount: 0 ,//  已收金额
+				surplusAmount:0 // 剩余应收
 			} // 统计都选相同的订单数据
 		}
 	},
-	filters: {
-		formatSourceType(value) {
-			// 款项类型:1订单款,2非订单款,3返佣款 4订单款或者非订单款(因财务阶段无法区分订单非订单), 5供应商退款
-			switch (value) {
-				case 1:
-					return '订单'
-					break
-				case 2:
-					return '非订单'
-					break
-				case 3:
-					return '返佣'
-					break
-				case 4:
-					return '订单款或者非订单款'
-					break
-				case 5:
-					return '供应商退款'
-					break
-			}
-		},
-		formatStateType(value) {
-			// 收款状态: 1待确认、2已确认(待审核)、3审核通过、4审核未通过、5收款撤销【线上支付成功为审核通过】
-			switch (value) {
-				case 1:
-					return '待确认'
-					break
-				case 2:
-					return '已确认'
-					break
-				case 3:
-					return '审核通过'
-					break
-				case 4:
-					return '审核未通过'
-					break
-				case 5:
-					return '收款撤销'
-					break
-			}
-		},
-		NumFormat(value) {
-			//处理金额
-			if (value) {
-				return Number(value).toFixed(2)
-			} else {
-				return '0.00'
-			}
-		}
-	},
 	onLoad(option) {
 		console.log('option', option)
 		let obj = {}
@@ -354,7 +319,7 @@ export default {
 				this.scrollH = res.windowWidth * 0.6
 			}
 		})
-		this.listQuery.id = this.refundListQuery.id = option.id
+		this.listQuery.id = this.refundListQuery.id = this.confirmParams.id = option.id
 		this.getOrderReceiptDetail(this.listQuery.id)
 	},
 	computed: {
@@ -560,13 +525,44 @@ export default {
 			}
 			this.modal = false
 		},
+		handleClick1(data){
+			switch(data){
+				case 1: // 小额抹平确认
+					console.log('小额抹平确认')
+					this.confirmParams.confirmType = data
+					this.confirmParams.orderIds = this.checkedIds.join(',')
+					this.orderReceiptConfirm()
+					this.modal1 = false
+					break
+				case 3: // 大额退款余额
+					console.log('大额退款余额')
+					this.confirmParams.confirmType = data
+					this.confirmParams.orderIds = this.checkedIds.join(',')
+					this.orderReceiptConfirm()
+					this.modal1 = false
+					break
+				case 4: // 确认关联
+					console.log('确认关联')
+					this.confirmParams.confirmType = data
+					this.confirmParams.orderIds = this.checkedIds.join(',')
+					this.orderReceiptConfirm()
+					this.modal1 = false
+					break
+			}
+		},
+		orderReceiptConfirm(){
+			//确认关联或抹平或退款余额
+			this.OrderService.orderReceiptConfirm(this.confirmParams)
+				.then(response => {
+					this.$api.navigateTo(`/pages/relation/ordinary/examine-detail?id=${this.confirmParams.id}`)
+				})
+				.catch(error => {
+					this.$util.msg(error.msg, 2000)
+				})
+		},
 		confirmDistinguish() {
 			// 点击确认
 			const list = []
-			let payTotalFee = 0 //订单金额
-			let balancePayFee = 0 //余额抵扣
-			let payableAmount = 0 //应收金额
-			let paidAmount = 0 //已收金额
 			this.checkedOrderList.forEach(el => {
 				if (list.indexOf(el.userId) == -1) {
 					list.push(el.userId)
@@ -576,22 +572,64 @@ export default {
 				this.$util.msg('请选择需要关联的订单!', 2000)
 				return
 			}
+			if(this.currents === 1){// 订金订单每次只能关联一个订单
+				if (this.checkedOrderList.length > 1) {
+					this.$util.msg('订金订单每次只能关联一个订单!', 2000)
+					return
+				}
+			}
+			if(this.currents === 3){// 退款子订单每次只能关联一个子订单
+				if (this.checkedOrderList.length > 1) {
+					this.$util.msg('只能选择一个子订单!', 2000)
+					return
+				}
+			}
 			if (list.length > 1) {
 				this.$util.msg('请选择相同机构的订单!', 2000)
 				return
 			}
+			let payTotalFee = 0 //订单金额
+			let balancePayFee = 0 //余额抵扣
+			let payableAmount = 0 //应收金额
+			let paidAmount = 0 //已收金额
+			let surplusAmount = 0 //剩余应收
 			this.checkedOrderList.forEach(el => {
 				payTotalFee += el.payTotalFee
 				balancePayFee += el.balancePayFee
 				payableAmount += el.payableAmount
 				paidAmount += el.paidAmount
+				surplusAmount += el.surplusAmount
+				this.checkedIds.push(el.orderId)
 			})
+			// 赋值
 			this.totalOrder.payTotalFee = Number(payTotalFee.toFixed(2))
+			this.totalOrder.surplusAmount = Number(surplusAmount.toFixed(2))
 			this.totalOrder.balancePayFee = Number(balancePayFee.toFixed(2))
 			this.totalOrder.payableAmount = Number(payableAmount.toFixed(2))
 			this.totalOrder.paidAmount = Number(paidAmount.toFixed(2))
 			this.totalOrder.orderNums = this.checkedOrderList.length
+			
+			if(this.currents === 1){// 收款金额必须等于订金订单金额才能关联
+				if (this.receiptInfo.receiptAmount != this.totalOrder.payTotalFee) {
+					this.$util.msg('收款金额必须等于订金订单金额才能关联!', 2000)
+					return
+				}
+			}
 			console.log('totalOrder', this.totalOrder)
+			 //处理收款状态的几种类型
+			if(this.receiptInfo.receiptAmount == this.totalOrder.payableAmount || (this.totalOrder.payableAmount - this.receiptInfo.receiptAmount) > 10){
+				//收款金额等于订单应收金额 或者是 订单应收总金额减去收款金额大于等于10
+				this.modelTpye = 1
+				console.log('收款金额等于订单应收金额 或者是 订单应收总金额减去收款金额大于等于10',this.modelTpye)
+			}else if(this.receiptInfo.receiptAmount > this.totalOrder.payableAmount){
+				//收款金额大于订单应收金额(可退款到余额)
+				this.modelTpye = 2
+				console.log('收款金额大于订单应收金额(可退款到余额)',this.modelTpye)
+			}else if((this.totalOrder.payableAmount - this.receiptInfo.receiptAmount) <= 10){
+				//订单应收总金额减去收款金额小于等于10元时,才能抹平确认
+				this.modelTpye = 3
+				console.log('订单应收总金额减去收款金额小于等于10元时,才能抹平确认)',this.modelTpye)
+			}
 			this.modal1 = true
 		},
 		checkedOrder(order) {
@@ -609,21 +647,28 @@ export default {
 			this.checkedRefundIndex = index
 			this.checkedOrderList.push(order)
 		},
-		hideMobel() {
-			this.modal = false
-		},
-		hideMobel1() {
-			this.modal1 = false
+		hideMobel(type) {
+			switch(type){
+				case 0:
+					this.modal = false
+					break
+				case 1:
+					this.modal1 = false
+					break
+				case 2:
+					this.modal2 = false
+					break
+			}
 		},
 		formatColor(state) {
-			//设置邀请码状态亚瑟
+			//设置颜色
 			let stateColor = '',
 				stateColorObject = {
-					1: '#f0ad4e',
+					1: '#FEAC20',
 					2: '#4cd964',
-					3: '#dd524d',
-					4: '#007aff',
-					5: '#EEC1AB'
+					3: '#34CC8C',
+					4: '#F94B4B',
+					5: '#007aff'
 				}
 			Object.keys(stateColorObject).forEach(function(key) {
 				if (key == state) {
@@ -683,6 +728,9 @@ export default {
 						this.getOrderReceiptOrders()
 					}
 			}
+		},
+		showReceiptModel(){//
+			this.modal2 = true
 		}
 	},
 	onPageScroll(e) {
@@ -832,7 +880,7 @@ page {
 				color: #ffffff;
 				margin-left: 10rpx;
 				&.btn-confirm {
-					background: $btn-confirm;
+					background: #f0ad4e
 				}
 				&.btn-error {
 					background: #ff5000;
@@ -906,7 +954,7 @@ page {
 			border-radius: 10rpx;
 			position: absolute;
 			right: 0;
-			top: -70rpx;
+			top: 0;
 			color: #dd524d;
 			z-index: 99;
 			.list-icon-image{
@@ -1162,77 +1210,6 @@ page {
 		}
 	}
 }
-
-.list-title {
-	width: 100%;
-	height: auto;
-
-	.list-title-t {
-		width: 100%;
-		height: 50rpx;
-		float: left;
-		font-size: $font-size-24;
-		padding-bottom: 10rpx;
-		.list-title-tip {
-			float: left;
-			.badges {
-				display: block;
-				float: left;
-				padding: 0 15rpx;
-				height: 40rpx;
-				line-height: 40rpx;
-				border-radius: 20rpx;
-				background: rgba(248, 204, 148, 0.5);
-				font-size: $font-size-24;
-				text-align: center;
-				color: #666666;
-			}
-		}
-		.list-title-tag {
-			float: left;
-			margin-left: 20rpx;
-			.badges {
-				display: block;
-				float: left;
-				padding: 0 15rpx;
-				height: 40rpx;
-				line-height: 40rpx;
-				border-radius: 20rpx;
-				background: linear-gradient(270deg, #fee9ba 0%, #f0cb72 100%);
-				font-size: $font-size-24;
-				text-align: center;
-				color: #666666;
-			}
-		}
-		.list-title-num {
-			float: left;
-			text-align: left;
-			color: #e15616;
-			line-height: 40rpx;
-			margin-left: 20rpx;
-		}
-	}
-	.list-title-b {
-		width: 100%;
-		height: 40rpx;
-		float: left;
-		font-size: $font-size-24;
-		line-height: 40rpx;
-		color: #666666;
-		text-align: left;
-		.text {
-			color: #999999;
-		}
-		.list-title-b-item {
-			width: 50%;
-			height: 100%;
-			float: left;
-		}
-		&.sms {
-			height: auto;
-		}
-	}
-}
 .d-container {
 	width: 580rpx;
 	padding: 80rpx 0;

+ 8 - 4
pages/relation/refund/detail.vue

@@ -219,6 +219,9 @@
 						return '返佣'
 						break
 					case 4:
+						return '订单款或者非订单款'
+						break
+					case 5:
 						return '供应商退款'
 						break
 				}
@@ -365,10 +368,11 @@
 				//设置邀请码状态亚瑟
 				let stateColor = '',
 					stateColorObject = {
-						0: '#f0ad4e',
-						1: '#4cd964',
-						2: '#dd524d',
-						3: '#007aff'
+						1: '#FEAC20',
+						2: '#4cd964',
+						3: '#34CC8C',
+						4: '#007aff',
+						5: '#F94B4B'
 					}
 				Object.keys(stateColorObject).forEach(function(key) {
 					if (key == state) {

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 306 - 559
pages/relation/refund/index.vue


+ 8 - 4
pages/relation/return/detail.vue

@@ -219,6 +219,9 @@
 						return '返佣'
 						break
 					case 4:
+						return '订单款或者非订单款'
+						break
+					case 5:
 						return '供应商退款'
 						break
 				}
@@ -365,10 +368,11 @@
 				//设置邀请码状态亚瑟
 				let stateColor = '',
 					stateColorObject = {
-						0: '#f0ad4e',
-						1: '#4cd964',
-						2: '#dd524d',
-						3: '#007aff'
+						1: '#FEAC20',
+						2: '#4cd964',
+						3: '#34CC8C',
+						4: '#007aff',
+						5: '#F94B4B'
 					}
 				Object.keys(stateColorObject).forEach(function(key) {
 					if (key == state) {

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 316 - 555
pages/relation/return/index.vue


+ 739 - 0
pages/relation/return/list.vue

@@ -0,0 +1,739 @@
+<template>
+	<view class="container mine clearfix">
+		<view
+			class="tui-header-box first"
+			:style="{ height: isCmcustomClass == 'fiexd' ? CustomBar + 6 + 'px' : CustomBar + 6 + 'px' }"
+			:class="isCmcustomClass"
+		>
+			<view class="header-top" :style="{ paddingTop: top + 'px', lineHeight: CustomBar + 20 + 'px' }"></view>
+			<view class="header-sit">
+				<text class="iconfont icon-fanhui" @click.stop="this.$api.navigateBack(1)"></text>
+				<text class="header-sit-text">口头返佣关联</text>
+			</view>
+		</view>
+		<tui-skeleton v-if="skeletonShow" backgroundColor="#fafafa" borderRadius="10rpx" :isLoading	="true" :loadingType="7"></tui-skeleton>
+		<view class="container-content" v-else>
+			<view class="tui-header-tabs day clearfix" :style="{ top: CustomBar + 6 + 'px' }">
+				<view class="tui-header-tabmain">
+					<input
+						class="input"
+						type="text"
+						confirm-type="search"
+						@confirm="subMitSearch()"
+						placeholder="请输入供应商名称"
+					/>
+					<text class="iconfont icon-sousuo"></text>
+				</view>
+			</view>
+			<view
+				class="user-section"
+				:style="{
+					top: isIphoneX ? CustomBar + 66 + 'px' : CustomBar + 56 + 'px',
+					left: 0 + 'px',
+					paddingBottom: isIphoneX ? '178rpx' : '144rpx'
+				}"
+			>
+				<view class="header-content">
+					<view :class="{ 'tui-order-list': scrollTop >= 0 }" class="clearfix">
+						<!-- 空白页 -->
+						<empty v-if="isEmpty" :typeIndex="currents" :navbarHeight="navbarHeight"></empty>
+						<!-- 列表 -->
+						<view v-else class="tui-order-content">
+							<view
+								class="tui-order-item"
+								v-for="(order, index) in orderList"
+								:key="index"
+							>
+								<view class="list-title" @click.stop="orderDetail(order.mainOrder.orderId)">
+									<view class="list-title-t">
+										<view class="list-title-tip">
+											<text class="badges">{{ order.mainOrder.orderType | formatOrderType }}</text>
+										</view>
+										<view class="list-title-tag" v-if="order.mainOrder.organizeId == 3">
+											<text class="badges">维沙</text>
+										</view>
+										<view class="list-title-num">{{ order.mainOrder.status | stateExpFormat }}</view>
+									</view>
+									<view class="list-title-a">
+										<view class="list-title-a-text">
+											子订单编号:<text class="text">{{ order.shopOrderNo }} ( {{ order.shopOrderId }} )</text>
+										</view>
+										<view class="list-title-a-text">
+											供应商名称:<text class="text">{{ order.shopName }}</text>
+										</view>
+										<view class="list-title-a-text">
+											订单金额:<text class="text">¥{{ order.needPayAmount | NumFormat }}</text>
+										</view>
+									</view>
+									<view class="list-title-b">
+										客户名称:<text class="text">{{ order.mainOrder.userName ? order.mainOrder.userName : '无' }}</text>
+									</view>
+									<view class="list-title-b">
+										订单编号:<text class="text">{{ order.mainOrder.orderNo }} ( {{ order.mainOrder.orderId }} )</text>
+									</view>
+									<view class="list-title-b">
+										下单日期:<text class="text">{{ order.mainOrder.orderTime }}</text>
+									</view>
+									<view class="list-title-b">
+										<view class="list-title-b-item ">
+											订单金额:<text class="text">¥{{ order.mainOrder.payTotalFee | NumFormat }}</text>
+										</view>
+										<view class="list-title-b-item ">
+											已收金额:<text class="text">¥{{ order.mainOrder.paidAmount | NumFormat }}</text>
+										</view>
+									</view>
+								</view>
+								<view class="list-checked" @click="checkedOrder(order,index)">
+									<text
+										class="iconfont"
+										:class="checkedIndex == index ? 'icon-yixuanze' : 'icon-weixuanze'"
+									></text>
+								</view>
+								<view class="list-detail" @click="handelDetail(order)">
+									<text class="iconfont icon-xiayibu"></text>
+								</view>
+							</view>
+							<!--加载loadding-->
+							<tui-loadmore :visible="loadding" :index="3" type="black"></tui-loadmore>
+							<tui-nomore :visible="!pullUpOn" bgcolor="#F7F7F7" :text="nomoreText"></tui-nomore>
+							<!--加载loadding-->
+						</view>
+					</view>
+				</view>
+			</view>
+			<view class="distinguish-button" :style="{ paddingBottom: isIphoneX ? '68rpx' : '24rpx' }">
+				<view class="button" @click="confirmDistinguish">口头返佣</view>
+			</view>
+		</view>	
+		<!-- 弹窗 -->
+		<tui-modal :show="modal1" :padding="'40rpx 30rpx'" @cancel="hideMobel(1)" :custom="true" fadeIn >
+			<view class="tui-modal-custom">
+				<view class="tui-prompt-text">
+					返佣金额为<text class="text">¥1000</text>,
+					订单根据成本计算得出的佣金为<text class="text">¥1000</text>,
+					金额不一致不能关联,请在后台修改成本使得子订单佣金等与返佣金额后在关联	
+				</view>
+				<view class="tui-prompt-flex">
+					<view class="btn btn-confirm" @click="handleClick1">知道了</view>
+				</view>
+			</view>
+		</tui-modal>	
+		<!--设非订单款项弹窗  -->
+		<tui-modal :show="modal" :padding="'40rpx 30rpx'" @cancel="hideMobel(0)" :custom="true" fadeIn >
+			<view class="tui-modal-custom">
+				<view class="tui-prompt-title">口头约定佣金</view>
+				<view class="tui-prompt-input">
+					<input 
+						class="input" 
+						type="number" 
+						placeholder="请输入口头约定佣金(必填)" 
+						@blur="changeNumber($event)" 
+						v-model="noOrderReason" 
+					/>
+				</view>
+				<view class="tui-prompt-flex">
+					<view class="btn btn-cancel" @click="hideMobel">取消</view>
+					<view class="btn btn-confirm" @click="handleClick">确定</view>
+				</view>
+			</view>
+		</tui-modal>	
+	</view>
+</template>
+<script>
+import headerBack from '@/components/cm-module/headerNavbar/header-back' //自定义导航
+import modalLayer from '@/components/modal-layer'
+import empty from '@/components/empty'
+import wxLogin from '@/services/wxLogin.js'
+import { mapState, mapMutations } from 'vuex'
+const defaultListQuery = {
+	pageNum: 1, //页数
+	pageSize: 10, //条数
+	id: 0,
+	shopName: '',
+}
+export default {
+	components: {
+		empty
+	},
+	data() {
+		return {
+			CustomBar: this.CustomBar, // 顶部导航栏高度
+			isIphoneX: this.$store.state.isIphoneX,
+			skeletonShow:false,
+			listQuery: Object.assign({}, defaultListQuery),
+			orderList: [],
+			checkedOrderList: [],
+			checkedIndex:'',
+			noOrderReason:'',//设置费订单款备注
+			scrollTop: 0,
+			isEmpty: false,
+			loadding: false,
+			pullUpOn: true,
+			hasNextPage: false,
+			pullFlag: true,
+			navbarHeight: '',
+			nomoreText: '上拉显示更多',
+			contentModalText: '', //操作文字提示语句
+			modal: false,
+			modal1: false,
+			confirmParams:{
+				shopOrderId:0,
+				verbalAmount:0,
+				rebateRemarks:''
+			},
+			rightDrawer: false,
+			hanldReceipt: {}, //储存监听收款信息
+			handleOperId: 0, //操作类型
+			height: 64, //header高度
+			top: 0, //标题图标距离顶部距离
+			scrollH: 0, //滚动总高度
+			opcity: 1
+		}
+	},
+	onLoad() {
+		let obj = {}
+		uni.getSystemInfo({
+			success: res => {
+				this.width = obj.left || res.windowWidth
+				this.height = obj.top ? obj.top + obj.height + 8 : res.statusBarHeight + 44
+				this.top = obj.top ? obj.top + (obj.height - 32) / 2 : res.statusBarHeight + 6
+				this.scrollH = res.windowWidth * 0.6
+			}
+		})
+	},
+	computed: {
+		...mapState(['hasLogin']),	
+	},
+	methods: {
+		getOrderReceiptRebateOrders() {
+			// 收款详情-订单列表
+			this.OrderService.orderReceiptRebateOrders(this.listQuery)
+				.then(response => {
+					let data = response.data
+					this.hasNextPage = response.data.hasNextPage
+					if (data.list && data.list.length > 0) {
+						this.isEmpty = false
+						this.orderList = data.list.map((el, index) => {
+							el.isChecked = false
+							return el
+						})
+						this.pullFlag = false
+						setTimeout(() => {
+							this.pullFlag = true
+						}, 500)
+						if (this.hasNextPage) {
+							this.pullUpOn = false
+							this.nomoreText = '上拉显示更多'
+						} else {
+							if (this.orderList.length < 3) {
+								this.pullUpOn = true
+							} else {
+								this.pullUpOn = false
+								this.loadding = false
+								this.nomoreText = '已至底部'
+							}
+						}
+					} else {
+						this.isEmpty = true
+					}
+					this.skeletonShow = false
+				})
+				.catch(err => {
+					this.$util.msg(err.msg, 2000)
+				})
+		},
+		getOnReachBottomData(index) {
+			//上拉加载
+			this.listQuery.pageNum += 1
+			this.OrderService.orderReceiptRebateOrders(this.listQuery)
+				.then(response => {
+					let data = response.data
+					if (data.list && data.list.length > 0) {
+						this.hasNextPage = data.hasNextPage
+						let list = data.list.map((el, index) => {
+							el.isChecked = false
+							return el
+						})
+						this.orderList = this.orderList.concat(list)
+						this.pullFlag = false // 防上拉暴滑
+						setTimeout(() => {
+							this.pullFlag = true
+						}, 500)
+						if (this.hasNextPage) {
+							this.pullUpOn = false
+							this.nomoreText = '上拉显示更多'
+						} else {
+							this.pullUpOn = false
+							this.loadding = false
+							this.nomoreText = '已至底部'
+						}
+					}
+				})
+				.catch(error => {
+					this.$util.msg(error.msg, 2000)
+				})
+		},
+		confirmDistinguish() {
+			// 点击确认
+			const list = []
+			this.checkedOrderList.forEach(el => {
+				if (list.indexOf(el.userId) == -1) {
+					list.push(el.userId)
+				}
+			})
+			if (this.checkedOrderList.length == 0) {
+				this.$util.msg('请选择需要关联的订单!', 2000)
+				return
+			}
+			if (this.checkedOrderList.length > 1) {
+				this.$util.msg('只能选择一个子订单!', 2000)
+				return
+			}
+			this.checkedOrderList.forEach(el => {
+				payTotalFee += el.payTotalFee
+				balancePayFee += el.balancePayFee
+				payableAmount += el.payableAmount
+				paidAmount += el.paidAmount
+				surplusAmount += el.surplusAmount
+				this.checkedIds.push(el.orderId)
+			})
+			this.modal = true
+		},
+		checkedOrder(order,index) {
+			// 勾选关联订单
+			this.checkedIndex = index
+			if (order.isChecked) {
+				this.checkedOrderList.push(order)
+			} else {
+				this.checkedOrderList.splice(this.checkedOrderList.indexOf(order), 1)
+			}
+		},
+		hideMobel(type) {
+			switch(type){
+				case 0:
+					this.modal = false
+					break
+				case 1:
+					this.modal1 = false
+					break
+			}
+		},
+		handleClick() {
+			//用户操作订单
+			this.modal = false
+			//  var commission = Number(checkedList.attr('brokerage'));
+			//  brokeobj.brokerage =Math.round(commission * 100) / 100;
+			//收款金额不等于子订单佣金金额
+			this.modal1 = true
+		},
+		handleClick1() {
+			//用户操作订单
+			// 确认关联
+			this.modal1 = false
+		},
+		orderDetail(id) {
+			//订单详情跳转
+			this.isModalLayer = true
+			this.$api.navigateTo(`/pages/relation/order/detail?orderId=${id}`)
+		},
+		changeNumber(e) {
+			// 校验输入为数字
+			this.params.receiptAmount = this.checkedNumberVal(e.detail.value)
+			console.log('receiptAmount', this.params.receiptAmount)
+		},
+		formatColor(state) {
+			//设置颜色
+			let stateColor = '',
+				stateColorObject = {
+					1: '#FEAC20',
+					2: '#4cd964',
+					3: '#34CC8C',
+					4: '#F94B4B',
+					5: '#007aff'
+				}
+			Object.keys(stateColorObject).forEach(function(key) {
+				if (key == state) {
+					stateColor = stateColorObject[key]
+				}
+			})
+			return stateColor
+		},
+		toNoSms(url) {
+			this.$api.navigateTo(url)
+		}
+	},
+	onPageScroll(e) {
+		//实时获取到滚动的值
+		if (e.scrollTop > 30) {
+			this.isCmcustomClass = 'fiexd'
+		} else {
+			this.isCmcustomClass = 'left'
+		}
+		if (e.scrollTop > 180) {
+			this.isShowHeader = true
+		} else {
+			this.isShowHeader = false
+		}
+	},
+	onReachBottom() {
+		if (this.hasNextPage) {
+			this.loadding = true
+			this.pullUpOn = true
+			this.getOnReachBottomData()
+		}
+	},
+	onPullDownRefresh() {
+		setTimeout(() => {
+			this.listQuery.pageNum = 1
+			this.currents = 0
+			// this.getOrderDatainit(this.currents)
+			uni.stopPullDownRefresh()
+		}, 200)
+	},
+	onShareAppMessage(res) {
+		//分享购买优惠券
+		const payment = res.target.dataset.payment
+		console.log('payment', payment)
+		if (res.from === 'button') {
+			// console.log('来自页面内转发按钮')
+			return {
+				title: `【待确认】收款金额${payment.receiptAmount.toFixed(2)}元,收款时间:${payment.receiptDate}`,
+				path: `pages/seller/cart/coupon-share?payment=${payment.id}`,
+				imageUrl: 'https://static.caimei365.com/app/img/icon/icon-shareCoupon@2x.png'
+			}
+		}
+	},
+	onShow() {
+		this.getOrderReceiptRebateOrders()
+	}
+}
+</script>
+
+<style lang="scss">
+@import '@/uni.scss';
+
+page {
+	background: #f7f7f7;
+}
+
+.tui-header-box {
+	width: 100%;
+	background: #ffffff;
+	z-index: 999;
+	position: fixed;
+	top: 0;
+	left: 0;
+	background-size: cover;
+	background-image: url(https://static.caimei365.com/app/crm/image/statistic_bg2.png);
+
+	&.fiexd {
+	}
+
+	&.first {
+	}
+}
+.header-top {
+	width: 100%;
+	font-size: 16px;
+	font-weight: 500;
+	height: 32px;
+	display: flex;
+	align-items: center;
+	justify-content: center;
+	position: relative;
+	padding: 0 40rpx;
+}
+
+.header-sit {
+	width: 100%;
+	box-sizing: border-box;
+	height: 80rpx;
+	line-height: 80rpx;
+	box-sizing: border-box;
+	color: #ffffff;
+	.header-sit-text {
+		text-align: left;
+		font-size: $font-size-40;
+		font-weight: 600;
+		font-family: '正楷';
+	}
+	.icon-fanhui {
+		display: block;
+		width: 80rpx;
+		height: 80rpx;
+		float: left;
+		text-align: center;
+		line-height: 80rpx;
+		font-size: 42rpx;
+	}
+}
+
+.tui-header-tabs {
+	width: 100%;
+	height: auto;
+	margin-bottom: 40rpx;
+	padding: 20rpx 24rpx;
+	background: #ffffff;
+	box-sizing: border-box;
+	position: fixed;
+	z-index: 999;
+	box-shadow: 0 10rpx 10rpx 0 rgba(86, 119, 252, 0.2);
+	.tui-header-tabmain {
+		width: 100%;
+		height: 70rpx;
+		float: left;
+		position: relative;
+		.input {
+			width: 100%;
+			height: 70rpx;
+			box-sizing: border-box;
+			padding: 0 20rpx;
+			padding-left: 70rpx;
+			background: #f7f7f7;
+			border-radius: 8rpx;
+		}
+		.icon-sousuo {
+			width: 80rpx;
+			height: 70rpx;
+			display: block;
+			line-height: 70rpx;
+			text-align: center;
+			color: #999999;
+			font-size: $font-size-40;
+			position: absolute;
+			left: 0;
+			top: 0;
+		}
+	}
+	.button-content {
+		width: 100%;
+		height: auto;
+		float: left;
+		position: relative;
+		.btn {
+			height: 64rpx;
+			padding: 0 20rpx;
+			margin: 10rpx 0 0 0;
+			line-height: 64rpx;
+			font-size: $font-size-26;
+			text-align: center;
+			border-radius: 6rpx;
+			float: right;
+		}
+		.btn-confirm {
+			background-color: #ff5000;
+			color: #ffffff;
+		}
+	}
+}
+
+.distinguish-button {
+	width: 100%;
+	position: fixed;
+	bottom: 0;
+	left: 0;
+	background-color: #ffffff;
+	padding: 0 50rpx;
+	padding-top: 20rpx;
+	.button {
+		width: 100%;
+		height: 80rpx;
+		background: $btn-confirm;
+		border-radius: 40rpx;
+		text-align: center;
+		color: #ffffff;
+		line-height: 80rpx;
+		font-size: $font-size-28;
+		box-shadow: 0 10rpx 14rpx 0 rgba(86, 119, 252, 0.2);
+	}
+}
+
+.user-section {
+	position: absolute;
+	width: 100%;
+}
+
+.header-content {
+	width: 100%;
+	height: auto;
+	position: relative;
+	background-color: #f7f7f7;
+}
+
+.tui-order-list {
+	margin-top: 24rpx;
+	width: 100%;
+	position: relative;
+	box-sizing: border-box;
+	padding: 0 20rpx;
+}
+
+.tui-order-content {
+	width: 100%;
+	height: auto;
+}
+
+.tui-order-item {
+	display: flex;
+	flex-direction: column;
+	width: 100%;
+	padding: 20rpx 20rpx;
+	background: #fff;
+	margin-bottom: 24rpx;
+	border-radius: 8rpx;
+	position: relative;
+	.list-checked {
+		width: 80rpx;
+		height: 80rpx;
+		line-height: 80rpx;
+		text-align: center;
+		position: absolute;
+		right: 0;
+		top: 0;
+		.iconfont {
+			font-size: 38rpx;
+			color: $color-system;
+		}
+	}
+	.list-detail {
+		width: 80rpx;
+		height: 280rpx;
+		line-height: 280rpx;
+		text-align: center;
+		position: absolute;
+		right: 0;
+		top: 80rpx;
+		.iconfont {
+			font-size: $font-size-30;
+			color: #999999;
+		}
+	}
+}
+
+.list-title {
+	width: 100%;
+	height: auto;
+
+	.list-title-t {
+		width: 100%;
+		height: 50rpx;
+		float: left;
+		font-size: $font-size-24;
+		padding-bottom: 10rpx;
+		.list-title-tip {
+			float: left;
+			.badges {
+				display: block;
+				float: left;
+				padding: 0 15rpx;
+				height: 40rpx;
+				line-height: 40rpx;
+				border-radius: 20rpx;
+				background: rgba(248, 204, 148, 0.5);
+				font-size: $font-size-24;
+				text-align: center;
+				color: #666666;
+			}
+		}
+		.list-title-num {
+			float: left;
+			text-align: left;
+			color: #e15616;
+			line-height: 40rpx;
+			margin-left: 20rpx;
+		}
+	}
+	.list-title-a {
+		width: 100%;
+		height: auto;
+		float: left;
+		padding: 5rpx 8rpx;
+		border-radius: 4rpx;
+		background-color: rgba(247, 247, 247, 1);
+		margin-bottom: 10rpx;
+		.text{
+			color: #999999;
+		}
+		.list-title-a-text {
+			width: 100%;
+			height: 40rpx;
+			float: left;
+			font-size: $font-size-24;
+			line-height: 40rpx;
+			color: #666666;
+			text-align: left;
+		}
+	}
+	.list-title-b {
+		width: 100%;
+		height: 40rpx;
+		float: left;
+		font-size: $font-size-24;
+		line-height: 40rpx;
+		color: #666666;
+		text-align: left;
+		.text{
+			color: #999999;
+		}
+		.list-title-b-item {
+			width: 50%;
+			height: 100%;
+			float: left;
+		}
+		&.sms {
+			height: auto;
+		}
+	}
+}
+.tui-prompt-title{
+	line-height: 44rpx;
+	text-align: center;
+}
+.tui-prompt-input{
+	width: 100%;
+	height: 80rpx;
+	box-sizing: border-box;
+	background: #f7f7f7;
+	border-radius: 8rpx;
+	padding:15rpx 20rpx;
+	margin: 20rpx 0;
+	.input {
+		width: 100%;
+		height: 100%;
+		line-height: 80rpx;
+		font-size: $font-size-26;
+		color: $color-system;
+	}
+}
+.tui-prompt-flex{
+	width: 100%;
+	height: 70rpx;
+	display: flex;
+	margin-top: 20rpx;
+	.btn{
+		flex: 1;
+		line-height: 70rpx;
+		font-size: $font-size-26;
+		text-align: center;
+		color: #FFFFFF;
+		border-radius: 33rpx;
+		margin: 0 24rpx;
+		&.btn-cancel{
+			background: #F7F7F7;
+			color: #999999;
+		}
+		&.btn-confirm{
+			background: $color-system;
+		}
+	}
+	
+}
+.tui-prompt-text{
+	line-height: 44rpx;
+	font-size: $font-size-26;
+	color: #333333;
+	.text{
+		color: $color-system;
+	}
+}
+</style>

+ 2 - 2
services/config.env.js

@@ -3,8 +3,8 @@ if(process.env.NODE_ENV === 'development'){
     // 开发环境
     // URL_CONFIG = 'http://192.168.2.67:18014'	 //智捷联调地址
     // URL_CONFIG = 'http://192.168.2.68:18014'	 //涛涛联调地址
-    URL_CONFIG = 'http://192.168.2.75:18014'	 //超超联调地址
-    // URL_CONFIG = 'https://core-b.caimei365.com'
+    // URL_CONFIG = 'http://192.168.2.75:18014'	 //超超联调地址
+    URL_CONFIG = 'https://core-b.caimei365.com'
     // URL_CONFIG = 'https://core.caimei365.com'
 }else{
     // 生产环境

+ 69 - 0
services/order.service.js

@@ -126,4 +126,73 @@ export default class OrderService {
             loadText: '请稍候...' 
         })
     }
+    /**
+	 *关联普通款
+	 * @param id 收款Id
+	 * @param confirmType 确认订单类型:1小额抹平确认,2大额抹平确认,3大额退款余额,4确认关联
+	 * @param orderIds 订单Id
+	/**/
+    orderReceiptConfirm(data = {}) {
+        return this.AjaxService.post({ 
+            url:'/order/receipt/confirm', 
+            data, 
+            isLoading: true ,
+            loadText: '处理中...' 
+        })
+    }
+    /**
+	 *审核普通款项
+	 * @param id 收款Id
+	 * @param receiptStatus 收款状态:1待确认、2已确认(待审核)、3审核通过、4审核未通过、5收款撤销【线上支付成功为审核通过】
+	 * @param reviewReason 不通过说明
+	/**/
+    orderReceiptAudit(data = {}) {
+        return this.AjaxService.post({ 
+            url:'/order/receipt/audit', 
+            data, 
+            isLoading: true ,
+            loadText: '处理中...' 
+        })
+    }
+    /**
+	 *收款订单详情
+	 * @param orderId 订单Id
+	/**/
+    orderReceiptOrdersInfo(data = {}) {
+        return this.AjaxService.get({ 
+            url:'/order/receipt/detail/orders/info', 
+            data, 
+            isLoading: true 
+        })
+    }
+    /**
+	 *返佣关联子订单列表
+	 * @param id 收款Id
+	 * @param confirmedType 0待确认,2已确认子订单
+	 * @param keyword 搜索关键词(供应商名称/订单号)
+	 * @param pageNum 页码
+	 * @param pageSize 条数
+	/**/
+    orderReceiptRebateOrders(data = {}) {
+        return this.AjaxService.get({ 
+            url:'/order/receipt/rebate/orders', 
+            data, 
+            isLoading: true ,
+            loadText: '请稍候...' 
+        })
+    }
+    /**
+	 *口头返佣关联
+	 * @param shopOrderId 子订单Id
+	 * @param verbalAmount 口头返佣佣金
+	 * @param rebateRemarks 备注
+	/**/
+    orderReceiptConfirmRebateVerbal(data = {}) {
+        return this.AjaxService.get({ 
+            url:'/order/receipt/confirm/rebate/verbal', 
+            data, 
+            isLoading: true ,
+            loadText: '处理中...' 
+        })
+    }
 }

+ 4 - 0
store/index.js

@@ -49,6 +49,10 @@ const store = new Vuex.Store({
             state.userInfo = provider
             state.openid = provider.openid
             console.log('用户微信openid', state.openid)
+            uni.setStorage({ //缓存用户openid
+			    key: 'openid',
+			    data: provider.openid
+            })
             uni.setStorage({ //缓存用户登陆状态
                 key: 'userInfo',
                 data: provider

Một số tệp đã không được hiển thị bởi vì quá nhiều tập tin thay đổi trong này khác