京东下架

master
fanfan 6 months ago
parent 4027cdb1d7
commit 1c817fc470
  1. 24
      src/views/goods/Create.vue
  2. 34
      src/views/goods/Index.vue
  3. 2
      src/views/store/shop/Index.vue

@ -87,8 +87,8 @@
</a-form-item> </a-form-item>
<a-form-item label="商品编码" :labelCol="labelCol" :wrapperCol="wrapperCol"> <a-form-item label="商品编码" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-input placeholder="请输入商品编码" v-decorator="['goods_no']" /> <a-input placeholder="请输入商品编码" v-decorator="['goods_no']" />
</a-form-item> </a-form-item>
<a-form-item label="所属分类排行(0表示不参加排行)" :labelCol="labelCol" :wrapperCol="wrapperCol"> <a-form-item label="所属分类排行(0表示不参加排行)" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-input placeholder="所属分类排行" v-decorator="['paihang']" /> <a-input placeholder="所属分类排行" v-decorator="['paihang']" />
@ -418,14 +418,14 @@ export default {
this.isLoading = false this.isLoading = false
}) })
}, },
methods: { methods: {
handInfo(){ handInfo() {
let obj={ let obj = {
goods_name:'测试', goods_name: '测试',
goods_price:123 goods_price: 123
} }
this.form.setFieldsValue(obj) this.form.setFieldsValue(obj)
}, },
// //
onForceUpdate(bool = false) { onForceUpdate(bool = false) {
this.$forceUpdate() this.$forceUpdate()
@ -621,7 +621,7 @@ export default {
} }
} }
} }
.action-item{ .action-item {
margin-left: 20px; margin-left: 20px;
} }
</style> </style>

@ -53,6 +53,13 @@
<a-input style="margin-left: 5px" v-decorator="['profit_rate_max']" placeholder="请输入" /> <a-input style="margin-left: 5px" v-decorator="['profit_rate_max']" placeholder="请输入" />
</div> </div>
</a-form-item> </a-form-item>
<a-form-item label="京东下架">
<a-select @change="getGoodsJingDong" style="width: 120px" placeholder="请选择">
<a-select-option :value="item.val" v-for="item in isYesNo" :key="item.val">
{{ item.name }}
</a-select-option>
</a-select>
</a-form-item>
<a-form-item class="search-btn"> <a-form-item class="search-btn">
<a-button type="primary" icon="search" html-type="submit">搜索</a-button> <a-button type="primary" icon="search" html-type="submit">搜索</a-button>
</a-form-item> </a-form-item>
@ -120,6 +127,15 @@
:color="text == 10 ? 'green' : 'red'" :color="text == 10 ? 'green' : 'red'"
@click="handleUpdateStatus([item.goods_id], text != 10)" @click="handleUpdateStatus([item.goods_id], text != 10)"
>{{ text == 10 ? '上架' : '下架' }}</a-tag> >{{ text == 10 ? '上架' : '下架' }}</a-tag>
</span>
<!-- 京东下架 -->
<span slot="is_jd_remove" slot-scope="text">
<p
style="width: 40px;text-align: center;"
:style="{ color: text == 0 ? 'red' : 'green'}"
>
{{ text == 0 ? '是' : '否' }}
</p>
</span> </span>
<!-- 商品池 --> <!-- 商品池 -->
<span slot="is_pool" slot-scope="text"> <span slot="is_pool" slot-scope="text">
@ -238,6 +254,12 @@ const columns = [
dataIndex: 'status', dataIndex: 'status',
scopedSlots: { customRender: 'status' }, scopedSlots: { customRender: 'status' },
}, },
{
title: '京东下架',
width: '60px',
dataIndex: 'is_jd_remove',
scopedSlots: { customRender: 'is_jd_remove' },
},
{ {
title: '商品池', title: '商品池',
width: '60px', width: '60px',
@ -281,7 +303,8 @@ export default {
listType: 'all', listType: 'all',
spec_type: '', spec_type: '',
channel: '', channel: '',
merchant_id: '' merchant_id: '',
is_jd_remove:''
}, },
// //
isLoading: false, isLoading: false,
@ -315,6 +338,10 @@ export default {
{ name: '单规格', val: 10 }, { name: '单规格', val: 10 },
{ name: '多规格', val: 20 }, { name: '多规格', val: 20 },
], ],
isYesNo: [
{ name: '是', val: 1 },
{ name: '否', val: 0 },
],
checkList: [], checkList: [],
merchantList: [] merchantList: []
} }
@ -344,6 +371,9 @@ export default {
} }
}, },
methods: { methods: {
getGoodsJingDong(val){
this.queryParam.is_jd_remove = val
},
// //
handleModify() { handleModify() {
this.$router.push('/goods/modify') this.$router.push('/goods/modify')
@ -368,6 +398,8 @@ export default {
(formData.profit_rate_min || '') + (formData.profit_rate_min || '') +
'&categoryId=' + '&categoryId=' +
(this.queryParam.categoryId || '') + (this.queryParam.categoryId || '') +
'&is_jd_remove=' +
(this.queryParam.is_jd_remove || '') +
'&channel=' + '&channel=' +
this.queryParam.channel + this.queryParam.channel +
'&merchant_id=' + '&merchant_id=' +

@ -27,7 +27,7 @@
</div> </div>
<s-table <s-table
ref="table" ref="table"
rowKey="shop_id" rowKey="id"
:loading="isLoading" :loading="isLoading"
:columns="columns" :columns="columns"
:data="loadData" :data="loadData"

Loading…
Cancel
Save