소스 검색

增加类型显示

htc 11 달 전
부모
커밋
e5edec94df
1개의 변경된 파일24개의 추가작업 그리고 8개의 파일을 삭제
  1. 24 8
      pagesHouse/HotelMerchandise/index.vue

+ 24 - 8
pagesHouse/HotelMerchandise/index.vue

@@ -1,5 +1,5 @@
 <template>
-	<view class="pages" :style="{'min-height':h+'px','padding-top':(mt)+'px'}">
+	<view class="pages" :style="{'min-height':h+'px','padding-top':(mt)+'px','padding-botom':(Selected?100:0)+'px','box-sizing':(Selected?'content-box':'border-box')}">
 		<c-nav-bar title="商品管理"></c-nav-bar>
 		<view class="tb">
 			<view class="tabs">
@@ -87,6 +87,7 @@
 				<view class="right">
 					<view class="right-left">
 						<image :src="item.coverImg" mode=""></image>
+						<view class="rl_type" v-if="typecfg[item.goodsType]">{{typecfg[item.goodsType]}}</view>
 					</view>
 					<view class="right-right">
 						<view class="top">
@@ -340,7 +341,8 @@
 					page: 1,
 					sortType: '', //选择条件:1创建时间 2销量从高到低 3价格从高到低 4价格从低到高
 					status: 0, //状态:0上架1下架
-				}
+				},
+				typecfg:{1:'特价船',2:'包船'}
 			}
 		},
 		onLoad(option) {
@@ -710,16 +712,14 @@
 
 			},
 			yujialedata() {
-				this.$api.get('/scenic/goods/page', this.fromData).then(res => {
-					console.log(res.data.data.list);
-					this.roomType = res.data.data.list;
+				this.$api.get('/scenic/api/goods/page', this.fromData).then(res => {
+					this.roomType = res.data.data.list.filter(d=>d.goodsType!=3);
 					this.mytotal = res.data.data.total;
 				})
 			},
 
 			getRepast() {
 				this.$api.get('/api/merchant/food/product/page', this.fromData).then(res => {
-					console.log(res.data.data.list);
 					this.roomType = res.data.data.list;
 					this.mytotal = res.data.data.total;
 				})
@@ -1305,12 +1305,28 @@
 				height: 172rpx;
 				border-radius: 16rpx;
 				margin-right: 22rpx;
+				position: relative;
 
 				image {
 					width: 100%;
 					height: 100%;
 					border-radius: 16rpx;
 				}
+				.rl_type{
+					width: 80rpx;
+					height: 34rpx;
+					background: #FEB000;
+					border-radius: 16rpx 0 18rpx 0;
+					line-height: 34rpx;
+					text-align: center;
+					font-family: PingFangSC, PingFang SC;
+					font-weight: 400;
+					font-size: 20rpx;
+					color: #FFFFFF;
+					position: absolute;
+					left: 0;
+					top: 0;
+				}
 			}
 
 			.right-right {}
@@ -1395,13 +1411,13 @@
 			.right {
 				width: 75%;
 				display: flex;
-				justify-content: space-evenly;
+				justify-content: flex-end;
 
 				.right-btn {
 					width: 148rpx;
 					height: 80rpx;
 					line-height: 80rpx;
-					background-color: #1372FF;
+					background-color: #007A69;
 					border-radius: 16rpx;
 					font-size: 26rpx;
 					color: #fff;