|
|
|
@ -97,9 +97,11 @@ Page({ |
|
|
|
util.showToast('请输入要搜索的关键字') |
|
|
|
return |
|
|
|
} |
|
|
|
if(!util.isEmpty(this.data.form.searchKey) && rearchStringList.indexOf(this.data.form.searchKey) < 0){ |
|
|
|
rearchStringList.splice(0, 0, this.data.form.searchKey) |
|
|
|
var index = rearchStringList.indexOf(this.data.form.searchKey) |
|
|
|
if(index >= 0){ |
|
|
|
rearchStringList.splice(index, 1) |
|
|
|
} |
|
|
|
rearchStringList.unshift(this.data.form.searchKey) |
|
|
|
if(rearchStringList.length > 24){ |
|
|
|
rearchStringList.slice(0, 24) |
|
|
|
} |
|
|
|
|