商品列表

main
fanfan 11 months ago
parent 72a012fe58
commit 412a6dd1f1
  1. 24
      src/views/dataCenter/goods/Index.vue

@ -27,10 +27,15 @@
</a-form-item>
<a-form-item label="商品分类">
<a-tree-select
:treeData="categoryListTree"
style="min-width: 180px"
placeholder="请选择商品分类"
:dropdownStyle="{ maxHeight: '500px', overflow: 'auto' }"
:treeData="categoryListTree"
treeCheckable
treeCheckStrictly
allowClear
v-decorator="['categoryId', { initialValue: 0 }]"
:max-tag-count="1"
@change="onSearchCategory"
></a-tree-select>
</a-form-item>
<a-form-item label="类型">
@ -143,7 +148,11 @@
</span>
<!-- 商品池 -->
<span slot="is_pool" slot-scope="text">
<p class="twoline-hide" style="width: 40px" :style="{color:text == 0 ? 'red' : text == 1 ? 'green' : 'gray'}">
<p
class="twoline-hide"
style="width: 40px"
:style="{ color: text == 0 ? 'red' : text == 1 ? 'green' : 'gray' }"
>
{{ text == 0 ? '待处理' : text == 1 ? '已入池' : '未入池' }}
</p>
</span>
@ -258,6 +267,7 @@ export default {
is_self: '',
is_pool: '',
data_type: '',
categoryId: '',
},
//
isLoading: false,
@ -385,6 +395,13 @@ export default {
getSale(val) {
this.is_sale = val
},
onSearchCategory(list) {
let categoryId = []
list.forEach((item) => {
categoryId.push(item.value)
})
this.queryParam.categoryId=categoryId.join(',')
},
//
getCategoryList() {
this.isLoading = true
@ -397,7 +414,6 @@ export default {
// ()
handleUpdateStatus(goodsIds, is_pool) {
console.log(goodsIds, is_pool)
this.isLoading = true
GoodsApi.state({ goodsIds, is_pool })
.then((result) => {

Loading…
Cancel
Save