wangfei vor 6 Jahren
Ursprung
Commit
3575d95e9b
1 geänderte Dateien mit 10 neuen und 0 gelöschten Zeilen
  1. 10
    0
      src/store/book/index.js

+ 10
- 0
src/store/book/index.js Datei anzeigen

@@ -32,6 +32,16 @@ export default {
32 32
         }
33 33
         return x
34 34
       })}
35
+      // let list = state.recommends.list
36
+      // list = list.map(x => {
37
+      //   if(x.BookId == bookid){
38
+      //     x.LeftNum = x.LeftNum - 1
39
+      //     return x
40
+      //   }
41
+      //   return x
42
+      // })
43
+      // list.splice(list.findIndex(item => item.LeftNum < 1), 1)
44
+      // state.recommends = {...state.recommends, list}
35 45
     },
36 46
     updateBookLeftNum(state, bookid) {
37 47
       state.books = {...state.books, list: state.books.list.map(x => {