Browse Source

update:1.商品列表修改细节

xuruhua 1 year ago
parent
commit
9772069f93

+ 0 - 2
src/views/mall/product/spu/form/InfoForm.vue

@@ -56,7 +56,6 @@
 		name: '', // 商品名称
 		categoryId: undefined, // 商品分类
 		keyword: '', // 关键字
-		picUrl: '', // 商品封面图
 		sliderPicUrls: [], // 商品轮播图
 		introduction: '', // 商品简介
 		brandId: undefined // 商品品牌
@@ -66,7 +65,6 @@
 		categoryId: [required],
 		keyword: [required],
 		introduction: [required],
-		picUrl: [required],
 		sliderPicUrls: [required],
 		brandId: [required]
 	})

+ 5 - 4
src/views/mall/product/spu/form/index.vue

@@ -35,8 +35,8 @@
 				<el-form-item style="float: right">
 					<el-button @click="dialogVisible = false">返回</el-button>
 					<!-- 不在回收站的才可以停用 -->
-					<el-button v-if="!isDetail && parentTabType!=4" :loading="formLoading" type="danger" plain
-						@click="handleStatus02Change(ProductSpuStatusEnum.RECYCLE.status)">
+					<el-button v-if="!isDetail && parentTabType!=4 && openType != 'create'" :loading="formLoading"
+						type="danger" plain @click="handleStatus02Change(ProductSpuStatusEnum.RECYCLE.status)">
 						停用
 					</el-button>
 					<!-- 在回收站的可以选择恢复或者删除 -->
@@ -49,7 +49,8 @@
 						@click="handleStatus02Change(ProductSpuStatusEnum.DISABLE.status)">
 						恢复
 					</el-button>
-					<el-button v-if="!isDetail" :loading="formLoading" type="primary" @click="handleStatusChange">
+					<el-button v-if="!isDetail && openType != 'create'" :loading="formLoading" type="primary"
+						@click="handleStatusChange">
 						{{parentRow.status == 0 ?"上架":"下架"}}
 					</el-button>
 
@@ -375,7 +376,7 @@
 	::v-deep .child-tabs .el-tabs__item {}
 
 	.right {
-		padding: 10px 0;
+		padding: 10px 0 60px;
 		border-left: 2px solid #e4e7ee;
 		margin-left: -2px;
 		float: left;

+ 10 - 3
src/views/mall/product/spu/index.vue

@@ -71,7 +71,7 @@
 						</p>
 						<div @click.stop="openForm('update',o,ProductSpuStatusEnum.RECYCLE.status,queryParams.tabType)"
 							v-show="o.showSetting" class="setting">
-							<el-icon size="20">
+							<el-icon size="20" color="rgb(220 223 231)">
 								<Setting />
 							</el-icon>
 						</div>
@@ -83,7 +83,7 @@
 							style="width: 100px;height: 100px;margin-right:10px;border:1px solid rgb(220 223 231);border-radius: 5px;"
 							@error="handleError" />
 						<div style='line-height: 25px;'>
-							<p>¥{{o.price}}</p>
+							<p>¥{{ fenToYuan(o.price) }}</p>
 							<p>销量:{{o.salesCount}}</p>
 							<p>库存:{{o.stock}}</p>
 							<p>状态:{{o.status == 1?"上架":"下架"}}</p>
@@ -506,12 +506,19 @@
 
 		.setting {
 			width: 30px;
-			top: 5px;
+			top: 0px;
 			right: 0px;
 			position: absolute;
 			height: 30px;
 			line-height: 30px;
 			text-align: center;
+			display: flex;
+			align-items: center;
+			justify-content: center;
+		}
+
+		.setting:hover {
+			background: #666
 		}
 
 		p,