|
|
@@ -27,14 +27,21 @@
|
|
|
<el-tabs style="padding: 0 20px 40px 20px;" v-model="activeName" @tab-click="handleClick">
|
|
|
<el-tab-pane label="积分兑换" name="goodsNotice">
|
|
|
<el-input clearable style="width: 200px;" size="small" v-model="goodsName" placeholder="物品名称"></el-input>
|
|
|
- <el-select clearable style="width: 200px; margin-left: 30px;" size="small" v-model="productAttribute"
|
|
|
+ <!-- <el-select clearable style="width: 200px; margin-left: 30px;" size="small" v-model="productAttribute"
|
|
|
placeholder="物品类型">
|
|
|
<el-option v-for="item in options" :key="item.dictValue" :label="item.dictLabel" :value="item.dictValue">
|
|
|
</el-option>
|
|
|
- </el-select>
|
|
|
+ </el-select> -->
|
|
|
+ <el-button size="small" style="margin-left: 30px;" type="primary" @click="getList('goodsNotice')">查询</el-button>
|
|
|
<el-button size="small" style="margin-left: 30px;" type="primary" round @click="changeOrderByClause('asc')" icon="el-icon-top">积分</el-button>
|
|
|
<el-button size="small" style="margin-left: 30px;" type="primary" round @click="changeOrderByClause('desc')" icon="el-icon-bottom">积分</el-button>
|
|
|
- <el-button size="small" style="margin-left: 30px;" type="primary" @click="getList('goodsNotice')">查询</el-button>
|
|
|
+
|
|
|
+ <div class="tab-list" style="margin-top: 10px;">
|
|
|
+ <div :class="{ 'tab': true, 'checked': item.checked }" v-for="(item) in options" :key="item.dictValue"
|
|
|
+ @click="choseProductAttributeType(item)">
|
|
|
+ {{ item.dictLabel }}
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
<div class="list-container">
|
|
|
<el-empty v-if="goodsList.length==0" :image-size="200"></el-empty>
|
|
|
<div v-else class="prize-list">
|
|
|
@@ -137,7 +144,24 @@ export default {
|
|
|
},
|
|
|
getIntegralTypes(){
|
|
|
integralTypes({dictType:'mall_sku_attribute'}).then(response=>{
|
|
|
- this.options = response.data.data;
|
|
|
+ console.log(response.data.data);
|
|
|
+ const dataList = response.data.data;
|
|
|
+ const data = {
|
|
|
+ dictValue:'',
|
|
|
+ dictLabel:'全部'
|
|
|
+ }
|
|
|
+ dataList.unshift(data);
|
|
|
+ if(dataList.length>0){
|
|
|
+ dataList.forEach((item,index) => {
|
|
|
+ if(index==0){
|
|
|
+ item.checked = true;
|
|
|
+ }else{
|
|
|
+ item.checked = false;
|
|
|
+ }
|
|
|
+
|
|
|
+ });
|
|
|
+ this.options = dataList;
|
|
|
+ }
|
|
|
})
|
|
|
},
|
|
|
getWelfareList() {
|
|
|
@@ -161,6 +185,14 @@ export default {
|
|
|
this.goodsList = []
|
|
|
})
|
|
|
},
|
|
|
+ choseProductAttributeType(item) {
|
|
|
+ this.options.forEach((element) => {
|
|
|
+ element.checked = false;
|
|
|
+ });
|
|
|
+ item.checked = true;
|
|
|
+ this.productAttribute = item.dictValue;
|
|
|
+ this.getList('goodsNotice');
|
|
|
+ },
|
|
|
choseType(item) {
|
|
|
this.choseList.forEach((element) => {
|
|
|
element.checked = false;
|
|
|
@@ -415,11 +447,10 @@ button {
|
|
|
/* margin-top: 0.2rem;
|
|
|
margin-left: 2.5rem; */
|
|
|
font-size: 0.4rem;
|
|
|
- /* line-height: 0.5rem;
|
|
|
- white-space: pre-line; */
|
|
|
+ /* line-height: 1.3rem; */
|
|
|
+ /* white-space: pre-line; */
|
|
|
color: #515767;
|
|
|
}
|
|
|
-
|
|
|
.tab-list{
|
|
|
display: flex;
|
|
|
flex-wrap: wrap;
|
|
|
@@ -431,11 +462,11 @@ button {
|
|
|
display: flex;
|
|
|
justify-content: center;
|
|
|
align-items: center;
|
|
|
- height: 2rem;
|
|
|
+ height: 1.8rem;
|
|
|
background-color: #fff;
|
|
|
border-radius: 1rem;
|
|
|
- font-size: 1rem;
|
|
|
- line-height: 2rem;
|
|
|
+ font-size: 0.5rem;
|
|
|
+ line-height: 1.8rem;
|
|
|
color: #8a9aa9;
|
|
|
padding: 0 0.83rem;
|
|
|
margin-right: 1rem;
|