fix:出版社被市场搜索历史数据二次覆盖的问题
This commit is contained in:
parent
6670b0c59a
commit
03102f1739
@ -1927,16 +1927,16 @@ export default {
|
|||||||
this.noIsbnCategoryIndex = 0
|
this.noIsbnCategoryIndex = 0
|
||||||
this.noIsbnSelectedCategoryValue = ''
|
this.noIsbnSelectedCategoryValue = ''
|
||||||
}
|
}
|
||||||
// 更新出版社
|
// 更新出版社(最多20条)
|
||||||
if (pressList.length > 0) {
|
if (pressList.length > 0) {
|
||||||
this.noIsbnPublisherOptions = pressList.map(function(item) { return item.showName })
|
this.noIsbnPublisherOptions = pressList.map(function(item) { return item.showName }).slice(0, 20)
|
||||||
this.noIsbnPublisherDropdownVisible = true
|
this.noIsbnPublisherDropdownVisible = true
|
||||||
} else {
|
} else {
|
||||||
this.noIsbnPublisherOptions = []
|
this.noIsbnPublisherOptions = []
|
||||||
}
|
}
|
||||||
// 更新作者
|
// 更新作者(最多20条)
|
||||||
if (authorList.length > 0) {
|
if (authorList.length > 0) {
|
||||||
this.noIsbnAuthorOptions = authorList.map(function(item) { return item.showName })
|
this.noIsbnAuthorOptions = authorList.map(function(item) { return item.showName }).slice(0, 20)
|
||||||
this.noIsbnAuthorDropdownVisible = true
|
this.noIsbnAuthorDropdownVisible = true
|
||||||
} else {
|
} else {
|
||||||
this.noIsbnAuthorOptions = []
|
this.noIsbnAuthorOptions = []
|
||||||
@ -3230,9 +3230,13 @@ export default {
|
|||||||
new: onSaleFacet ? onSaleFacet.newCount : 0,
|
new: onSaleFacet ? onSaleFacet.newCount : 0,
|
||||||
sold: soldFacet ? (soldFacet.oldCount + soldFacet.newCount) : 0
|
sold: soldFacet ? (soldFacet.oldCount + soldFacet.newCount) : 0
|
||||||
}
|
}
|
||||||
// 填充下拉选项
|
// 填充下拉选项(仅当孔网API未拉取时使用历史数据兜底)
|
||||||
|
if (that.noIsbnAuthorOptions.length === 0) {
|
||||||
that.noIsbnAuthorOptions = Array.from(authorSet).filter(Boolean).slice(0, 10)
|
that.noIsbnAuthorOptions = Array.from(authorSet).filter(Boolean).slice(0, 10)
|
||||||
|
}
|
||||||
|
if (that.noIsbnPublisherOptions.length === 0) {
|
||||||
that.noIsbnPublisherOptions = Array.from(publisherSet).filter(Boolean).slice(0, 10)
|
that.noIsbnPublisherOptions = Array.from(publisherSet).filter(Boolean).slice(0, 10)
|
||||||
|
}
|
||||||
// 自动计算并填入售价
|
// 自动计算并填入售价
|
||||||
that.$nextTick(() => {
|
that.$nextTick(() => {
|
||||||
if (that.calculatedNoIsbnPrice > 0) {
|
if (that.calculatedNoIsbnPrice > 0) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user