yunxing 3 rokov pred
rodič
commit
fd2c613925

+ 2 - 1
src/components/equipmentFacilities/MSwiper.vue

@@ -85,6 +85,7 @@ export default {
     },
     created() {
         swiperVm = this
+        this.list.forEach((v,index) => v.index = index)
         this.swiperList = cloneDeep(this.list)
         let swiperData = []
         swiperData = this.group(this.swiperList, 15)
@@ -99,7 +100,7 @@ export default {
             let currentInfo = {}
             this.swiperList.map((item, index) => {
                 item.active = false
-                if (detail.drawernum === item.drawernum) {
+                if (detail.drawernum === item.drawernum && detail.index === item.index ) {
                     item.active = true
                     currentInfo = cloneDeep(item)
                 }