|
@@ -1944,20 +1944,20 @@
|
|
|
try {
|
|
|
var isUserNext = oCookie != {{session "userId"}}
|
|
|
if (isUserNext) {
|
|
|
- localStorage.removeItem('home_top_search_ent_history_2021')
|
|
|
- localStorage.removeItem('home_top_search_buyer_history_2021')
|
|
|
+ localStorage.removeItem('home_top_search_ent_history_202109')
|
|
|
+ localStorage.removeItem('home_top_search_buyer_history_202109')
|
|
|
}
|
|
|
} catch (e) {
|
|
|
console.log('cookie 获取失败02')
|
|
|
}
|
|
|
} else {
|
|
|
- localStorage.removeItem('home_top_search_ent_history_2021')
|
|
|
- localStorage.removeItem('home_top_search_buyer_history_2021')
|
|
|
+ localStorage.removeItem('home_top_search_ent_history_202109')
|
|
|
+ localStorage.removeItem('home_top_search_buyer_history_202109')
|
|
|
}
|
|
|
}
|
|
|
|
|
|
function saveSearchHistory (type, insetStr, entId) {
|
|
|
- var saveOnlyKey = 'home_top_search_' + type + '_history_2021'
|
|
|
+ var saveOnlyKey = 'home_top_search_' + type + '_history_202109'
|
|
|
var oldArr = JSON.parse(localStorage.getItem(saveOnlyKey) || '[]')
|
|
|
var oldIds = JSON.parse(localStorage.getItem(saveOnlyKey + '_ids') || '[]')
|
|
|
// 检查原数组中是否存有本次查询字符串
|
|
@@ -1983,7 +1983,7 @@
|
|
|
}
|
|
|
|
|
|
function clearSearchHistory (type) {
|
|
|
- var saveOnlyKey = 'home_top_search_' + type + '_history_2021'
|
|
|
+ var saveOnlyKey = 'home_top_search_' + type + '_history_202109'
|
|
|
localStorage.removeItem(saveOnlyKey)
|
|
|
localStorage.removeItem(saveOnlyKey + '_ids')
|
|
|
var domNode = $('.del_' + type + '_history')
|
|
@@ -1996,7 +1996,7 @@
|
|
|
function getSearchHistory (type, setDom) {
|
|
|
clearOtherUserLocalStorage()
|
|
|
console.log('tyoe', type)
|
|
|
- var saveOnlyKey = 'home_top_search_' + type + '_history_2021'
|
|
|
+ var saveOnlyKey = 'home_top_search_' + type + '_history_202109'
|
|
|
var oldArr = JSON.parse(localStorage.getItem(saveOnlyKey) || '[]')
|
|
|
var oldIds = JSON.parse(localStorage.getItem(saveOnlyKey + '_ids') || '[]')
|
|
|
if (setDom) {
|
|
@@ -2037,4 +2037,4 @@
|
|
|
})
|
|
|
})
|
|
|
</script>
|
|
|
-<!--E-脚本-->
|
|
|
+<!--E-脚本-->
|