1
This commit is contained in:
@@ -1819,29 +1819,17 @@ export default {
|
|||||||
return 'info' // 其他状态
|
return 'info' // 其他状态
|
||||||
},
|
},
|
||||||
|
|
||||||
/** 准备查询参数:去除空格并在关键词搜索时清空日期 */
|
/** 准备查询参数:仅去除空格,保留日期等所有搜索条件 */
|
||||||
prepareQueryParams() {
|
prepareQueryParams() {
|
||||||
const textKeys = ['remark', 'orderSearch', 'distributionMark', 'modelNumber', 'link', 'buyer', 'address', 'status']
|
const textKeys = ['remark', 'orderSearch', 'distributionMark', 'modelNumber', 'link', 'buyer', 'address', 'status']
|
||||||
let hasKeyword = false
|
|
||||||
|
|
||||||
textKeys.forEach(key => {
|
textKeys.forEach(key => {
|
||||||
const value = this.queryParams[key]
|
const value = this.queryParams[key]
|
||||||
if (typeof value === 'string') {
|
if (typeof value === 'string') {
|
||||||
const trimmed = value.trim()
|
const trimmed = value.trim()
|
||||||
if (trimmed) {
|
this.queryParams[key] = trimmed || undefined
|
||||||
this.queryParams[key] = trimmed
|
|
||||||
hasKeyword = true
|
|
||||||
} else {
|
|
||||||
this.queryParams[key] = undefined
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
if (hasKeyword) {
|
|
||||||
this.dateRange = []
|
|
||||||
this.queryParams.beginTime = null
|
|
||||||
this.queryParams.endTime = null
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
|
|
||||||
/** 退货复制 */
|
/** 退货复制 */
|
||||||
|
|||||||
Reference in New Issue
Block a user