【新增】模板库
This commit is contained in:
@@ -56,11 +56,18 @@
|
||||
@clear="getList">
|
||||
</el-input>
|
||||
</div>
|
||||
<div class="search-item" style="margin-bottom: 0;">
|
||||
<label style="width: 100px;">仅显示未填写:</label>
|
||||
<el-select v-model="search.isShowWhite" placeholder="请选择" clearable size="small">
|
||||
<el-option label="是" value="1"></el-option>
|
||||
<el-option label="否" value="0"></el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
<el-button style="margin-left: 10px;" @click="getList" size="small" :loading="pageShow">查询</el-button>
|
||||
</template>
|
||||
</ai-search-bar>
|
||||
<ai-table
|
||||
:tableData="skuList"
|
||||
:tableData="list"
|
||||
:col-configs="colConfigs"
|
||||
style="margin-top: 8px;"
|
||||
@getList="getList"
|
||||
@@ -207,7 +214,8 @@
|
||||
current: 1,
|
||||
size: -1,
|
||||
productSkuId: '',
|
||||
productSkcId: ''
|
||||
productSkcId: '',
|
||||
isShowWhite: ''
|
||||
},
|
||||
lableSearch: {
|
||||
current: 1,
|
||||
@@ -262,6 +270,19 @@
|
||||
},
|
||||
|
||||
computed: {
|
||||
list () {
|
||||
if (!this.skuList.length) {
|
||||
return []
|
||||
}
|
||||
|
||||
if (this.search.isShowWhite !== '1') {
|
||||
return this.skuList
|
||||
}
|
||||
|
||||
const keys = this.relationList.map(v => v.field)
|
||||
return this.skuList.filter(v => keys.some(e => !v[e]))
|
||||
},
|
||||
|
||||
currMall () {
|
||||
if (!this.$store.state.mallList.length) {
|
||||
return {}
|
||||
@@ -324,9 +345,8 @@
|
||||
},
|
||||
|
||||
readXLSX(file) {
|
||||
return new Promise((resolve, reject) => {
|
||||
return new Promise(resolve => {
|
||||
const reader = new FileReader()
|
||||
|
||||
reader.readAsBinaryString(file)
|
||||
reader.onload = evt => {
|
||||
const data = evt.target.result
|
||||
@@ -380,7 +400,7 @@
|
||||
mallId: this.lableSearch.mallId,
|
||||
anti: true,
|
||||
data: {
|
||||
page: page,
|
||||
page,
|
||||
pageSize: 200,
|
||||
catIds: catIds
|
||||
}
|
||||
@@ -388,7 +408,7 @@
|
||||
if (res.errorCode == 1000000) {
|
||||
resolve({
|
||||
list: res.result.pageItems.map(v => v.productSkcId),
|
||||
isHasNext: res.result.pageItems.length < 200
|
||||
isHasNext: res.result.total && res.result.pageItems.length && (res.result.pageItems.length < 200 && res.result.total > 200)
|
||||
})
|
||||
} else {
|
||||
resolve({ list: [], isHasNext: false })
|
||||
|
||||
Reference in New Issue
Block a user