|
@@ -81,15 +81,14 @@ export default (state = initSearchList, action) => {
|
|
|
if (action.type == SET_TIP) {
|
|
|
const newState = Object.assign({}, state);
|
|
|
let tempArr = newState.labelListBig;
|
|
|
- let tempArrs = newState.labelListSmall;
|
|
|
let tmpLis = action.item
|
|
|
- tempArrs = tempArrs.filter((item)=>{
|
|
|
- if(item.time == tmpLis.time){
|
|
|
- item.value = action.value
|
|
|
+
|
|
|
+ for(let i= 0;i < tempArr.length;i++){
|
|
|
+ if(tmpLis.time == tempArr[i].time){
|
|
|
+ tempArr[i].value = action.value
|
|
|
}
|
|
|
- return item
|
|
|
- })
|
|
|
- newState.labelListSmall = [...tempArrs]
|
|
|
+ }
|
|
|
+ newState.labelListBig = [...tempArr]
|
|
|
return newState;
|
|
|
}
|
|
|
if (action.type == SEARCH_TYPE_NEW) {
|