baijunde 1 год назад
Родитель
Сommit
b3f48557f3

+ 1 - 1
pages/evaluate/evaluate.vue

@@ -201,7 +201,6 @@
 				})
 			},
 			replyUser(item){
-				console.log(item)
 				let data = {
 					commentContent:item.reply,
 					commentId:item.commentId
@@ -217,6 +216,7 @@
 							num: 1,
 							size: 10
 						}
+							this.appraiseList = []
 						this.getcommentList(page)
 					}
 					

+ 156 - 27
pages/order/details.vue

@@ -11,15 +11,23 @@
 		<view class="content">
 			<view class="status">
 				<view class="status_title">
-					{{product.state}}
-					<span>¥{{product.costPrice}}</span>
+					{{product.state}} <span v-if="product.differenceMinutes>0">,剩余</span> 
+					<u-count-down :timestamp="product.differenceMinutes*60" :show-days="false" font-size="36rpx" @end="getDetail"
+						v-if="product.differenceMinutes>0"></u-count-down>
+
+					<!-- <span>¥{{product.costPrice}}</span> -->
+				</view>
+				<view class="span" v-if="product.state == '待支付'">
+					顾客于{{product.buyTime}}下单
+				</view>
+				<view class="span" v-if="product.state == '待使用'">
+					顾客于{{product.buyTime}}下单
 				</view>
-				<view class="span">{{product.buyTime}}</view>
 			</view>
 			<view class="refund" @click="cutPopup" v-if="product.refundType == 1">
 				退款去向详情
 			</view>
-			<view class="product">
+			<view class="product" v-if="product.categoryId != 1945013773786701826">
 				<view class="title">
 					商品信息
 				</view>
@@ -36,10 +44,51 @@
 					</view>
 				</view>
 			</view>
+			<view class="product" v-if="product.categoryId == 1945013773786701826">
+				<view class="title" v-if="product.categoryId != 1945013773786701826">
+					商品信息
+				</view>
+				<view class="center"
+					v-for="(specitem, specIndex) in product.productsLinkCategorySpecItems.slice(0,isShow ? product.productsLinkCategorySpecItems.length : 2)"
+					:key="specIndex">
+					<view class="img">
+						<image :src="product.productImage" mode=""></image>
+					</view>
+					<view class="spec_item">
+						<view class="top">
+							{{product.productName}}
+						</view>
+						<view class="spec_content">
+							<view class="left">
+								<view class="cventer">
+									{{specitem.partName}} {{specitem.positionName}}
+								</view>
+								<view class="foot">
+									{{specitem.craftName}}
+								</view>
+							</view>
+							<view class="right">
+								<span style="font-size: 22rpx;color: #FD4912;">¥{{specitem.soldPrice}}</span>
+								<span style="text-decoration: line-through;font-size: 18rpx;color: #999999;">¥{{specitem.price}}</span>
+							</view>
+						</view>
+					</view>
+				</view>
+				<view class="is_show" @click.stop="unfold" v-if="product.productsLinkCategorySpecItems.length > 2">
+					{{isShow?'收起查看':'展开查看'}}
+					<image src="/static/order/hidden.png" mode="" v-if="isShow"></image>
+					<image src="/static/order/show.png" mode="" v-else></image>
+				</view>
+				<view class="all_price" v-if="product.categoryId == 1945013773786701826">
+					<span style="font-size: 22rpx;color: #FD4912;margin-right: 10rpx;">¥已优惠{{product.couponPrice}}</span>
+					<span style="font-size: 26rpx;color: #FD4912;"><text
+							style="font-size: 22rpx;">¥</text>{{product.orderPrice}}</span>
+				</view>
+			</view>
 			<view class="product">
 				<view class="title negotiate" v-if="product.auditType">
 					协商历史
-					<view class="look" @click="goRecord" >
+					<view class="look" @click="goRecord">
 						查看详情
 					</view>
 				</view>
@@ -47,31 +96,31 @@
 					订单信息
 				</view>
 				<view class="data">
-					<span>订单号</span>
+					<span>订单号</span>
 					{{product.orderId}}
 				</view>
 				<view class="data">
-					<span>支付流水号</span>
+					<span>支付流水号</span>
 					{{product.tradeId}}
 				</view>
 				<view class="data">
-					<span>提交人</span>
+					<span>提交人</span>
 					{{product.linkName}}
 				</view>
 				<view class="data">
-					<span>联系电话</span>
+					<span>联系电话</span>
 					{{product.phone}}
 				</view>
 				<view class="data">
-					<span>下单时间</span>
+					<span>下单时间</span>
 					{{product.buyTime}}
 				</view>
 				<view class="data">
-					<span>付款时间</span>
+					<span>付款时间</span>
 					{{product.payTime}}
 				</view>
 				<view class="data">
-					<span>使用时间</span>
+					<span>使用时间</span>
 					{{product.useTime}}
 				</view>
 			</view>
@@ -113,10 +162,10 @@
 		data() {
 			return {
 				orderId: '',
-				product: {
-
-				},
-				isDetail:false
+				product: {},
+				isDetail: false,
+				timestamp: 10000,
+				isShow: false
 			}
 		},
 		methods: {
@@ -134,19 +183,24 @@
 					}
 				})
 			},
+			//展开/收起查看钣金喷漆子选项
+			unfold(index) {
+				this.isShow = !this.isShow
+				this.$forceUpdate();
+			},
 			goRecord() {
 				uni.navigateTo({
 					url: '/pages/order/record?orderId=' + this.product.orderId
 				})
 			},
-			cutPopup(){
+			cutPopup() {
 				this.isDetail = !this.isDetail
 			},
-			refundDetail(){
+			refundDetail() {
 				this.isDetail = true
 			},
 			//获取退款去向
-			getRefund(){
+			getRefund() {
 				this.$http.get("/app/order/locaOrder/refundDestination?reOrderId=" + this.orderNo).then(res => {
 					if (res.data.code == 200) {
 						console.log(res)
@@ -169,6 +223,9 @@
 		width: 100vw;
 		height: 100vh;
 		background: #F7F8FC;
+		display: flex;
+		flex-direction: column;
+		overflow: hidden;
 
 		/*#ifdef APP-PLUS*/
 		.top {
@@ -184,7 +241,7 @@
 			padding: 20rpx;
 			display: flex;
 			align-items: center;
-			background: linear-gradient( 87deg, #E2F4F8 0%, #A3CDFF 100%), linear-gradient( 360deg, #FFFFFF 0%, rgba(255,255,255,0) 100%);
+			background: linear-gradient(87deg, #E2F4F8 0%, #A3CDFF 100%), linear-gradient(360deg, #FFFFFF 0%, rgba(255, 255, 255, 0) 100%);
 			position: relative;
 
 			.cuIcon-back {
@@ -203,6 +260,8 @@
 
 		.content {
 			padding: 24rpx;
+			flex: 1;
+			overflow-y: auto;
 
 			.status {
 				font-size: 44rpx;
@@ -211,15 +270,18 @@
 
 				.status_title {
 					display: flex;
-					justify-content: space-between;
+					align-items: end;
+					// justify-content: space-between;
 					margin-bottom: 15rpx;
+					font-size: 36rpx;
+					font-weight: 600;
 				}
 
 				.span {
 					font-size: 28rpx;
-					color: #666666;
+					color: #999999;
 					line-height: 33rpx;
-					font-size: 32rpx;
+					font-size: 24rpx;
 					color: #333333;
 					font-weight: 500;
 
@@ -271,9 +333,10 @@
 				}
 
 				.center {
+					width: 100%;
 					display: flex;
 					border-radius: 16rpx;
-					margin-top: 16rpx;
+					margin-bottom: 20rpx;
 
 					.img {
 						width: 132rpx;
@@ -310,6 +373,44 @@
 							}
 						}
 					}
+
+					.spec_item {
+						flex: 1;
+						margin-left: 20rpx;
+						display: flex;
+						flex-direction: column;
+						justify-content: space-between;
+
+						.top {
+							font-size: 26rpx;
+							height: 38rpx;
+							color: #000000;
+							margin-bottom: 6rpx;
+						}
+					}
+
+					.spec_content {
+						width: 100%;
+						flex: 1;
+						display: flex;
+						justify-content: space-between;
+						padding-top: 15rpx;
+
+						.left {
+							display: flex;
+							flex-direction: column;
+							justify-content: space-between;
+							font-size: 22rpx;
+							color: #333333;
+						}
+
+						.right {
+							text-align: right;
+							display: flex;
+							flex-direction: column;
+							justify-content: space-between;
+						}
+					}
 				}
 
 				.data {
@@ -317,19 +418,47 @@
 					height: 38rpx;
 					display: flex;
 					align-items: center;
-					justify-content: space-between;
+					// justify-content: space-between;
 					margin-top: 20rpx;
-					font-size: 28rpx;
+					margin-bottom: 12rpx;
+					font-size: 26rpx;
 					color: #333333;
 
 					span {
+						display: block;
+						width: 156rpx;
+						height: 38rpx;
 						font-size: 26rpx;
-						color: #8A91A8;
+						color: #666666;
+						margin-right: 16rpx;
 					}
 				}
 			}
 		}
 
+		.is_show {
+			display: flex;
+			align-items: center;
+			justify-content: center;
+			font-size: 24rpx;
+			color: #2D88F4;
+
+			image {
+				width: 20rpx;
+				height: 20rpx;
+				margin-left: 10rpx;
+			}
+		}
+
+		.all_price {
+			display: flex;
+			align-items: center;
+			justify-content: end;
+			padding-top: 20rpx;
+			border-top: 1px solid #EEEEEE;
+			margin-top: 20rpx;
+		}
+
 		.popup {
 			width: 100vw;
 			height: 100vh;

+ 110 - 5
pages/order/index.vue

@@ -61,7 +61,8 @@
 						已使用
 					</view>
 				</view>
-				<view class="order_product">
+				<!-- 普通订单 -->
+				<view class="order_product" v-if="item.categoryId != 1945013773786701826">
 					<view class="img">
 						<image :src="item.productImage" mode=""></image>
 					</view>
@@ -73,6 +74,41 @@
 						<image src="/static/product/ticket.png" mode=""></image>
 					</view>
 				</view>
+				<!-- 钣金喷漆订单 -->
+				<view class="spec" v-if="item.categoryId == 1945013773786701826">
+					<view class="order_product"
+						 v-for="(specitem, specIndex) in item.orderLinkCategorySpecItems.slice(0, item.isShow ? item.orderLinkCategorySpecItems.length : 2)"
+						:key="specIndex">
+						<view class="img">
+							<image :src="item.productImage" mode=""></image>
+						</view>
+						<view class="spec_item">
+							<view class="top">
+								{{item.productName}}
+							</view>
+							<view class="content">
+								<view class="left">
+									<view class="cventer">
+										{{specitem.partName}} {{specitem.positionName}}
+									</view>
+									<view class="foot">
+										{{specitem.craftName}}
+									</view>
+								</view>
+								<view class="right">
+									<span style="font-size: 22rpx;color: #333333;">¥{{specitem.soldPrice}}</span>
+									<span
+										style="text-decoration: line-through;font-size: 18rpx;color: #999999;">¥{{specitem.price}}</span>
+								</view>
+							</view>
+						</view>
+					</view>
+					<view class="is_show" @click.stop="unfold(index)" v-if="item.orderLinkCategorySpecItems.length > 2">
+						{{item.isShow?'收起查看':'展开查看'}}
+						<image src="/static/order/hidden.png" mode="" v-if="item.isShow"></image>
+						<image src="/static/order/show.png" mode="" v-else></image>
+					</view>
+				</view>
 				<view class="time">
 					<view class="time_left">
 						顾客于{{item.buyTime}}
@@ -80,6 +116,10 @@
 					<view class="time_right" @click.stop="goRecord(item)" v-if="item.auditType =='0'">
 						去处理
 					</view>
+					<view class="all_price"  v-if="item.categoryId == 1945013773786701826">
+						<span style="font-size: 22rpx;color: #FD4912;margin-right: 10rpx;">¥已优惠{{item.couponPrice}}</span>
+						<span style="font-size: 26rpx;color: #FD4912;"><text style="font-size: 22rpx;">¥</text>{{item.orderPrice}}</span>
+					</view>
 				</view>
 			</view>
 		</mescroll-uni>
@@ -106,7 +146,7 @@
 				</view>
 				<view class="time">
 					<span>{{item.date}}</span>
-					<span> <text>¥</text> {{item.price}}</span>
+					<span> <text>¥</text> {{item.rightsId?0:item.price}}</span>
 				</view>
 				<view class="btn_box">
 					<view class="btn" @click.stop="goLive(item)">
@@ -190,7 +230,8 @@
 					<span>添加收费服务</span>
 				</view>
 				<!-- 救援 -->
-				<view class="add_service" @click.stop="addService(item)" v-if="item.checkType>20&&(item.flowStatus== '06'||item.flowStatus== '07'||item.flowStatus== '08') ">
+				<view class="add_service" @click.stop="addService(item)"
+					v-if="item.checkType>20&&(item.flowStatus== '06'||item.flowStatus== '07'||item.flowStatus== '08') ">
 					<span>添加收费服务</span>
 				</view>
 				<view class="child_order">
@@ -328,6 +369,12 @@
 		},
 		methods: {
 
+			//展开/收起查看钣金喷漆子选项
+			unfold(index) {
+				this.orderList[index].isShow = !this.orderList[index].isShow;
+				 this.$forceUpdate();
+			},
+
 			//联系客户
 			callUser(item) {
 				uni.makePhoneCall({
@@ -380,7 +427,7 @@
 				this.buyEndTime = val.endDate
 				if (this.tabIndex == 0) {
 					this.orderList = []
-					
+
 					let page = {
 						num: 1,
 						size: 10
@@ -458,7 +505,7 @@
 			//跳转至服务订单详情页
 			goDetail(item) {
 				uni.navigateTo({
-					url: '/pages/order/serviceOrder/orderDetail?taskId=' + item.taskId + '&checkType=' + item.checkType
+					url: '/pages/order/serviceOrder/orderDetail?taskId=' + item.taskId + '&checkType=' + item.checkType +'&rightsId='+item.rightsId
 				})
 			},
 			getList(page) {
@@ -473,6 +520,11 @@
 				}
 				this.$http.post("/app/order/locaOrder/list", data).then(res => {
 					this.orderList = this.orderList.concat(res.data.result.records)
+					// 展开/收起
+					this.orderList.forEach(item => {
+						item.isShow = false
+					})
+					console.log(this.orderList)
 					this.mescroll.endSuccess(res.data.result.records.length, res.data.result.total);
 					uni.showTabBar()
 				}).catch(() => {
@@ -1016,6 +1068,7 @@
 					height: 132rpx;
 					display: flex;
 					margin: 10rpx 0px;
+					margin-bottom: 20rpx;
 
 					.img {
 						width: 132rpx;
@@ -1055,6 +1108,58 @@
 					.schedule {
 						width: 15%;
 					}
+
+					.spec_item {
+						flex: 1;
+						margin-left: 20rpx;
+						display: flex;
+						flex-direction: column;
+						justify-content: space-between;
+
+						.top {
+							font-size: 26rpx;
+							height: 38rpx;
+							color: #000000;
+							margin-bottom: 6rpx;
+						}
+
+						.content {
+							width: 100%;
+							flex: 1;
+							display: flex;
+							justify-content: space-between;
+							padding-top: 15rpx;
+
+							.left {
+								display: flex;
+								flex-direction: column;
+								justify-content: space-between;
+								font-size: 22rpx;
+								color: #333333;
+							}
+
+							.right {
+								text-align: right;
+								display: flex;
+								flex-direction: column;
+								justify-content: space-between;
+							}
+						}
+					}
+				}
+
+				.is_show {
+					display: flex;
+					align-items: center;
+					justify-content: center;
+					font-size: 24rpx;
+					color: #2D88F4;
+
+					image {
+						width: 20rpx;
+						height: 20rpx;
+						margin-left: 10rpx;
+					}
 				}
 
 				.time {

+ 3 - 1
pages/order/serviceOrder/orderDetail.vue

@@ -95,7 +95,7 @@
 					</view>
 					<view class="product_name">
 						{{form.productName}}
-						<span><text>¥</text>{{form.price}}</span>
+						<span><text>¥</text>{{rightsId?0:form.price}}</span>
 					</view>
 				</view>
 				<view class="sun_product">
@@ -378,6 +378,7 @@
 				paramState: null,
 				titleCheckType: null, //接单提示区分
 				serveType: '', //服务类型
+				rightsId:''
 			}
 		},
 		methods: {
@@ -701,6 +702,7 @@
 		onLoad(options) {
 			this.taskId = options.taskId
 			this.checkType = options.checkType
+			this.rightsId = options.rightsId
 		}
 	}
 </script>

+ 194 - 37
pages/product/creatProduct.vue

@@ -58,7 +58,7 @@
 					<u-upload v-else ref="dUpload" :action="action" :file-list="xqImage" @on-success="detailsSuccess"
 						@on-remove="detailsRemove" max-count="20" width="140rpx" height="140rpx"></u-upload>
 				</view>
-				<view class="item">
+				<view class="item" v-if="form.categoryId != '1945013773786701826'">
 					<view class="label">
 						原价<span>*</span>
 					</view>
@@ -69,7 +69,7 @@
 					</view>
 				</view>
-				<view class="item">
+				<view class="item" v-if="form.categoryId != '1945013773786701826'">
 					<view class="label">
 						实际售价<span>*</span>
 					</view>
@@ -80,7 +80,7 @@
 					</view>
 				</view>
-				<view class="item">
+				<view class="item" v-if="form.categoryId != '1945013773786701826'">
 					<view class="label">
 						组合套餐
 					</view>
@@ -89,6 +89,44 @@
 						<u-icon name="arrow-right" style="margin-left: 17rpx;"></u-icon>
 					</view>
 				</view>
+				<!-- 钣金喷漆 -->
+				<view class="spray" v-if="form.categoryId == '1945013773786701826'">
+					<view class="label" style="width: 100%;display: flex;justify-content: space-between;align-items: center;">
+						商品规格
+						<view class="change">
+							<span @click="allSelect">
+								<image src="/static/product/select.png" mode="" v-if="all"></image>
+								<image src="/static/product/round.png" mode="" v-else></image>
+								全选
+							</span>
+							<span @click="reverseSelsct">
+								<image src="/static/product/select.png" mode="" v-if="reverse"></image>
+								<image src="/static/product/round.png" mode="" v-else></image>
+								反选
+							</span>
+						</view>
+					</view>
+					<view class="spray_items">
+						<view class="spra" v-for="(item,index) in form.specItems" :key="item.craftId">
+							<view class="square" @click="select(item)">
+								<image src="/static/product/square_select.png" mode="" v-if="item.replaced == true"></image>
+								<image src="/static/product/square.png" mode="" v-else></image>
+							</view>
+							<view class="right">
+								<view class="name">
+									<!-- {{item.craftId}} -->
+									{{item.partName}} {{item.positionName}} {{item.craftName}}
+								</view>
+								<view class="price">
+									<view class="option">原价<input v-model="item.price" placeholder="输入商品原价" style="height: 49rpx;" />
+									</view>
+									<view class="option">参考售价<input v-model="item.soldPrice" placeholder="输入商品参考售价" /></view>
+								</view>
+							</view>
+
+						</view>
+					</view>
+				</view>
 			</view>
 			<view v-show="schedule == 2">
 				<view class="form" style="margin-bottom: 24rpx;">
@@ -262,6 +300,9 @@
 	import refund from '@/components/product/refund.vue'
 
 	import configService from '../../common/service/config.service'
+	import {
+		nextTick
+	} from "vue"
 	export default {
 		components: {
 			rangTime,
@@ -311,9 +352,40 @@
 				productId: '',
 				jindouChecked: false,
 				jifenChecked: false,
+				selectVaule: 0, //钣金喷漆选择
+				all: false, //是否全选
+				reverse: false, //是否反选
 			}
 		},
 		methods: {
+			//全选
+			allSelect() {
+				this.all = true
+				this.reverse = false
+				this.form.specItems.forEach(item => {
+					item.replaced = true
+				})
+			},
+			//反选
+			reverseSelsct() {
+				this.reverse = true
+				this.all = false
+				this.form.specItems.forEach(item => {
+					item.replaced = !item.replaced
+				})
+			},
+			//选中
+			select(item) {
+				item.replaced = !item.replaced
+				// const index = this.form.specItems.findIndex(i => i.id === item.id);
+				// if (index !== -1) {
+				// 	this.form.specItems.splice(index, 1, {
+				// 		...item,
+				// 		replaced: !item.replaced
+				// 	});
+				// }
+			},
+
 			// 上传封面图成功回调
 			handleSuccess(res, index, lists) {
 				this.form.productImage = this.imageHttp + res.message
@@ -326,45 +398,40 @@
 			//上传详情图
 			detailsSuccess(res, index, lists) {
 				console.log(lists)
-				 this.processImageList(lists);
+				this.processImageList(lists);
 				this.xqImage = lists
 			},
 			detailsRemove(index, lists) {
 				this.xqImage = lists
-				 this.processImageList(lists);
+				this.processImageList(lists);
+			},
+			// 处理图片列表,生成URL字符串
+			processImageList(lists) {
+				let temp = [];
+				lists.forEach(item => {
+					if (item.response && item.response.message) {
+						temp.push(this.imageHttp + item.response.message);
+					} else if (item.url) {
+						// 处理已存在的图片
+						temp.push(item.url);
+					}
+				});
+				this.form.detailImages = temp.join(',');
+				console.log('当前图片URL字符串:', this.form.detailImages);
 			},
-			  // 处理图片列表,生成URL字符串
-			    processImageList(lists) {
-			      let temp = [];
-			      lists.forEach(item => {
-			        if (item.response && item.response.message) {
-			          temp.push(this.imageHttp + item.response.message);
-			        } else if (item.url) {
-			          // 处理已存在的图片
-			          temp.push(item.url);
-			        }
-			      });
-			      this.form.detailImages = temp.join(',');
-			      console.log('当前图片URL字符串:', this.form.detailImages);
-			    },
 			//下一步
 			next() {
-				console.log(this.xqImage);
-
 				let temp = []
-				// if (this.xqImage.length > 0) {
-				// 	this.xqImage.forEach((item => {
-				// 		// temp.push(item.url)
-				// 		if (item.response.message) {
-
-				// 			temp.push({
-				// 				url: this.imageHttp + item.response.message
-				// 			})
-				// 		}
-				// 	}))
-
-				// }
-				// this.form.detailImages = temp.join(',')
+				if(this.form.specItems){
+					this.form.specItems.forEach(item => {
+						// item.replaced = true
+						if(item.replaced){
+							temp.push(item)
+						}
+					})
+					this.form.specItems = temp
+				}
+				
 				//基础信息必填提示
 				if (!this.form.categoryId) {
 					uni.showToast({
@@ -394,19 +461,24 @@
 					});
 					return
 				}
-				if (!this.form.price) {
+				if (!this.form.price && !this.form.categoryId == '1945013773786701826') {
 					uni.showToast({
 						title: '请输入商品原价',
 						icon: 'none'
 					});
 					return
 				}
-				if (!this.form.soldPrice) {
+				if (!this.form.soldPrice && !this.form.categoryId == '1945013773786701826') {
 					uni.showToast({
 						title: '请输入商品售价',
 						icon: 'none'
 					});
 					return
+				} else if (this.form.categoryId == '1945013773786701826' && temp.length ==0) {
+					uni.showToast({
+						title: '请选择最少一个配置',
+						icon: 'none'
+					});
 				} else {
 					this.schedule += 1
 				}
@@ -576,7 +648,8 @@
 						icon: 'none'
 					});
 					return
-				} else if (this.form.refundConfirmName == '' || this.form.refundLabelName == '') {
+				// } else if (this.tabIndex != 1 && (this.form.refundConfirmName == null || this.form.refundLabelName == null)) {
+					} else if (this.tabIndex != 1 && (this.form.refundConfirm == null || this.form.refundLabel == null)) {
 					uni.showToast({
 						title: '请选择退款标签',
 						icon: 'none'
@@ -638,6 +711,7 @@
 				this.$http.get("/app/product/queryById?id=" + this.productId, {}).then(res => {
 					if (res.data.code == 200) {
 						this.form = res.data.result
+
 						this.jifenChecked = res.data.result.integralAward ? true : false
 						this.jindouChecked = res.data.result.goldAward ? true : false
 						this.showText = res.data.result.productCategory
@@ -670,6 +744,7 @@
 						}
 
 						console.log(this.showRule)
+
 						uni.setStorage({
 							key: 'group',
 							data: res.data.result.productGroups
@@ -841,6 +916,88 @@
 					}
 				}
 
+				.spray {
+					.label {
+						height: 57rpx;
+						margin-right: 20rpx;
+						font-weight: 600;
+						font-size: 28rpx;
+						min-width: 126rpx;
+						margin-bottom: 16rpx;
+
+						.change {
+							display: flex;
+							align-items: center;
+							font-weight: 400;
+
+							span {
+								display: flex;
+								align-items: center;
+								margin-left: 30rpx;
+
+							}
+
+							image {
+								width: 36rpx;
+								height: 36rpx;
+								font-size: 28rpx;
+								margin-right: 4rpx;
+							}
+						}
+					}
+
+					.spray_items {
+						.spra {
+							height: 106rpx;
+							margin-bottom: 32rpx;
+							display: flex;
+							align-items: start;
+
+							.square {
+								margin-right: 12rpx;
+
+								image {
+									width: 30rpx;
+									height: 40rpx;
+								}
+							}
+
+							.name {
+								display: flex;
+								font-size: 28rpx;
+								margin-bottom: 16rpx;
+							}
+
+							.price {
+								height: 49rpx;
+								display: flex;
+								justify-content: space-between;
+
+								.option {
+									display: flex;
+									align-items: center;
+									font-size: 26rpx;
+									color: #666666;
+
+									input {
+										height: 49rpx;
+										width: 160rpx;
+										background: #F7F8FC;
+										border-radius: 4rpx;
+										margin-left: 10rpx;
+										text-align: center;
+										font-size: 26rpx;
+										color: #666666;
+									}
+								}
+
+							}
+						}
+
+
+					}
+				}
+
 				.upload {
 					display: block;
 					height: auto;

+ 67 - 14
pages/product/details.vue

@@ -31,22 +31,22 @@
 				</view>
 				<view class="img_box" v-if="detailImages">
 					<span class="line">商品详情图</span>
-					<view class="img_list" >
+					<view class="img_list">
 						<view class="img" v-for="(item,index) in detailImages" :key="index">
 							<image :src="item" mode=""></image>
 						</view>
 					</view>
 				</view>
-					<rich-text :nodes="form.richText" v-if="form.richText"></rich-text>
+				<rich-text :nodes="form.richText" v-if="form.richText"></rich-text>
 
-				<view class="data">
+				<view class="data"  v-if="form.categoryId != '1945013773786701826'">
 					<span class="span">原价</span>{{form.price}}
 				</view>
-				<view class="data">
+				<view class="data" v-if="form.categoryId != '1945013773786701826'">
 					<span class="span">实际售价</span>{{form.soldPrice}}
 				</view>
 
-				<view class="particulars">
+				<view class="particulars" v-if="form.categoryId != '1945013773786701826'">
 					组合套餐
 					<view class="content">
 						<view class="item" v-for="(item,index) in form.productGroups" :key="item.groupId">
@@ -63,6 +63,24 @@
 					</view>
 				</view>
 			</view>
+			
+			<view class="box" v-if="form.categoryId == '1945013773786701826'">
+				<view class="span">
+					商品规格
+				</view>
+				<view class="spec">
+					<view class="spec_item" v-for="(item,index) in specItems" :key="item.id">
+						<view class="name">
+							{{item.partName}} {{item.positionName}} {{item.craftName}}
+						</view>	
+						<view class="price">
+							原价<span>{{item.price}}</span>参考售价 <span>{{item.soldPrice}}</span> 
+						</view>
+							
+					</view>
+				</view>
+				
+			</view>
 			<view class="box rule">
 				<view class="title">
 					售卖/使用信息
@@ -91,7 +109,7 @@
 						<view class="item">
 							{{form.refundLabelName}}
 						</view>
-						<view class="item">   
+						<view class="item">
 							{{form.refundConfirmName}}
 						</view>
 					</view>
@@ -118,7 +136,8 @@
 				price: 280,
 				ruleList: [],
 				productId: '',
-				imageHttp: 'http://192.168.0.36:8080/jeecg-boot/'
+				imageHttp: 'http://192.168.0.36:8080/jeecg-boot/',
+				specItems:[]
 			}
 		},
 		methods: {
@@ -132,11 +151,20 @@
 		onLoad(options) {
 			this.productId = options.productId
 			this.$http.get("/app/product/queryById?id=" + this.productId, {}).then(res => {
-				console.log(res)
+				
 				if (res.data.code == 200) {
 					this.form = res.data.result
+					console.log(this.form)
 					this.detailImages = res.data.result.detailImages.split(',')
-					console.log(this.detailImages)
+					if(this.form.specItems){
+						 this.form.specItems.forEach(item => {
+							if(item.replaced){
+								this.specItems.push(item)
+							}
+						})
+					}
+					
+					console.log(this.specItems)
 				}
 			})
 		}
@@ -151,13 +179,14 @@
 		flex-direction: column;
 		overflow: hidden;
 		background: #F7F8FC;
+
 		/*#ifdef APP-PLUS*/
 		.top {
 			width: 100%;
 			height: var(--status-bar-height);
-				background-color: #fff;
+			background-color: #fff;
 		}
-		
+
 		/*#endif*/
 
 		.head {
@@ -193,6 +222,28 @@
 				padding: 16rpx;
 				background-color: #fff;
 				border-radius: 16rpx;
+				.spec{
+					background: #FBFCFF;
+					border-radius: 8rpx;
+					padding: 16rpx;
+					margin-top: 16rpx;
+					.spec_item{
+						margin-bottom: 32rpx;
+						.name{
+							font-size: 28rpx;
+							margin-bottom: 16rpx;
+						}
+						.price{
+							font-size: 26rpx;
+							color: #666666;
+							span{
+								color: #333333;
+								margin-left: 20rpx;
+								margin-right: 30rpx;
+							}
+						}
+					}
+				}
 			}
 		}
 
@@ -218,10 +269,12 @@
 				font-size: 28rpx;
 				color: #666666;
 			}
-			.ruler{
+
+			.ruler {
 				display: flex;
 				align-items: center;
-				.item{
+
+				.item {
 					width: auto;
 					height: 44rpx;
 					padding: 0rpx 16rpx;
@@ -230,7 +283,7 @@
 					justify-content: center;
 					line-height: 28rpx;
 					color: #2983EC;
-					background: rgba(68,154,255,0.1);
+					background: rgba(68, 154, 255, 0.1);
 					border-radius: 4rpx;
 					border: 1px solid #449AFF;
 					margin-right: 20rpx;

+ 61 - 51
pages/product/index.vue

@@ -16,8 +16,10 @@
 			</view>
 
 			<div class="tab-container">
-				<div class="tab-item" :class="tabIndex == 1?'active':''" @click="tabIndex=1;productName='';productStatus=0;getProductList();getStatus()">品牌标品</div>
-				<div class="tab-item" :class="tabIndex == 0?'active':''" @click="tabIndex=0;productName='';productStatus=0;getProductList();getStatus()">自有商品</div>
+				<div class="tab-item" :class="tabIndex == 1?'active':''"
+					@click="tabIndex=1;productName='';productStatus=0;getProductList();getStatus()">品牌标品</div>
+				<div class="tab-item" :class="tabIndex == 0?'active':''"
+					@click="tabIndex=0;productName='';productStatus=0;getProductList();getStatus()">自有商品</div>
 			</div>
 
 			<view class="search">
@@ -67,7 +69,9 @@
 						<view class="repertory">库存:{{item.stockQuantity}} <span></span> 销量:{{item.soldQuantity}}</view>
 						<view class="price">
 							<span style="font-size: 22rpx;margin: 0px;">¥</span>{{item.soldPrice}}
-							<span style="color:#999 ;font-size: 22rpx; text-decoration: line-through;">¥{{item.price}}</span>
+							<span v-if="item.categoryId == 1945013773786701826 ">~</span>
+							<span style="font-size: 22rpx;font-size: 30rpx;font-weight: 600;" v-if="item.categoryId == 1945013773786701826 ">¥{{item.price}}</span>
+							<span style="color:#999 ;font-size: 22rpx; text-decoration: line-through;" v-else>¥{{item.price}}</span>
 						</view>
 						<image src="/static/product/ticket.png" mode="" class="ticket" v-if="item.isRights == 1"></image>
 					</view>
@@ -82,7 +86,8 @@
 					<view class="delist" @click.stop="sell(item)" v-if="item.productStatus==0">
 						上架
 					</view>
-					<view class="delist select" @click.stop="goSelect(item)" style="margin-left: 20rpx;" v-if="item.categoryId.includes('1909434886438043649')">
+					<view class="delist select" @click.stop="goSelect(item)" style="margin-left: 20rpx;"
+						v-if="item.categoryId.includes('1909434886438043649')">
 						选择检测站
 					</view>
 					<view class="delist" @click.stop="delist(item)" v-if="item.productStatus==1">
@@ -172,7 +177,7 @@
 				productList: [],
 				merchantId: '',
 				productHandleList: [],
-				tabIndex:1
+				tabIndex: 1
 			}
 		},
 		methods: {
@@ -224,12 +229,12 @@
 				uni.navigateTo({
 					url: '/pages/product/creatStandard'
 				})
-				
+
 			},
 			//编辑
 			edit(item) {
 				uni.navigateTo({
-					url: '/pages/product/creatProduct?productId=' + item.productId+'&tabIndex='+this.tabIndex
+					url: '/pages/product/creatProduct?productId=' + item.productId + '&tabIndex=' + this.tabIndex
 				})
 			},
 			select(item) {
@@ -240,18 +245,18 @@
 			deletes(status) {
 				let shelves = []
 				this.productList.forEach(item => {
-					if(item.select){
+					if (item.select) {
 						shelves.push({
 							productId: item.productId,
 							productStatus: status
 						})
 					}
-					
+
 				})
 
 				let that = this
 				uni.showModal({
-					title: this.productStatus==0?'确定上架商品?':'确定下架商品?',
+					title: this.productStatus == 0 ? '确定上架商品?' : '确定下架商品?',
 					success: function(res) {
 						if (res.confirm) {
 
@@ -259,7 +264,7 @@
 								.then(res => {
 									if (res.data.code == 200) {
 										uni.showToast({
-											title: status==0?'下架成功':'上架成功',
+											title: status == 0 ? '下架成功' : '上架成功',
 											duration: 2000,
 											icon: 'none'
 										});
@@ -325,7 +330,7 @@
 			},
 			getProductList() {
 				this.$http.get("/app/product/list?merchantId=" + this.merchantId + "&productStatus=" + this.productStatus +
-						'&productName=' + this.productName +'&isPlatform='+this.tabIndex, )
+						'&productName=' + this.productName + '&isPlatform=' + this.tabIndex, )
 					.then(res => {
 						if (res.data.code == 200) {
 							res.data.result.records.forEach((item) => {
@@ -410,17 +415,18 @@
 				});
 			},
 			//跳转至选择检测站
-			goSelect(item){
+			goSelect(item) {
 				uni.navigateTo({
-					url:'/pages/product/checkMap'
+					url: '/pages/product/checkMap'
 				})
 			},
 			getStatus() {
-				this.$http.get("/app/product/statusCount?merchantId=" + this.merchantId+'&isPlatform='+this.tabIndex ).then(res => {
-					if (res.data.code == 200) {
-						this.typeList = res.data.result
-					}
-				})
+				this.$http.get("/app/product/statusCount?merchantId=" + this.merchantId + '&isPlatform=' + this.tabIndex).then(
+					res => {
+						if (res.data.code == 200) {
+							this.typeList = res.data.result
+						}
+					})
 			}
 		},
 		mounted() {
@@ -711,6 +717,7 @@
 						font-weight: 600;
 						font-style: 28rpx;
 						position: relative;
+
 						.repertory {
 							font-size: 24rpx;
 							display: flex;
@@ -740,7 +747,8 @@
 
 							}
 						}
-						image{
+
+						image {
 							position: absolute;
 							top: 50%;
 							right: 50rpx;
@@ -783,10 +791,11 @@
 						font-size: 26rpx;
 						color: #666666;
 					}
-					.select{
+
+					.select {
 						width: 178rpx;
 						height: 50rpx;
-						background: rgba(68,154,255,0.05);
+						background: rgba(68, 154, 255, 0.05);
 						border-radius: 8rpx;
 						border: 1px solid #449AFF;
 						font-size: 26rpx;
@@ -961,33 +970,34 @@
 			}
 		}
 	}
-.tab-container {
-  display: flex;
-  justify-content: space-around;
-
-.tab-item {
-  position: relative;
-  padding: 18rpx 0;
-  cursor: pointer;
-  color: #333;
-  font-weight: 400;
-  font-size: 28rpx;
-}
-
-.tab-item.active {
-	color: #449AFF;
-	font-weight: 600;
-}
-
-.tab-item.active::after {
-  content: '';
-  position: absolute;
-  bottom: -28px;
-  left: 35%;
-  width: 38rpx;
-  height: 100%;
-  background: url(/static/product/tab-act.png) no-repeat;
-  background-size: contain;
-}
-}
+
+	.tab-container {
+		display: flex;
+		justify-content: space-around;
+
+		.tab-item {
+			position: relative;
+			padding: 18rpx 0;
+			cursor: pointer;
+			color: #333;
+			font-weight: 400;
+			font-size: 28rpx;
+		}
+
+		.tab-item.active {
+			color: #449AFF;
+			font-weight: 600;
+		}
+
+		.tab-item.active::after {
+			content: '';
+			position: absolute;
+			bottom: -28px;
+			left: 35%;
+			width: 38rpx;
+			height: 100%;
+			background: url(/static/product/tab-act.png) no-repeat;
+			background-size: contain;
+		}
+	}
 </style>

BIN
static/order/hidden.png


BIN
static/order/show.png


BIN
static/product/square.png


BIN
static/product/square_select.png