{"ast":null,"code":"import { getInspectionList } from '@/api';\nexport default {\n name: 'InspectionList',\n data() {\n return {\n total: 0,\n list: [],\n scrollTimer: null\n };\n },\n async mounted() {\n const res = await getInspectionList();\n this.total = res.data.total;\n this.list = res.data.list;\n this.$nextTick(() => this.startScroll());\n },\n beforeDestroy() {\n clearInterval(this.scrollTimer);\n },\n methods: {\n levelText(level) {\n const map = {\n high: '高',\n medium: '中',\n low: '低'\n };\n return map[level] || level;\n },\n // 自动滚动\n startScroll() {\n const wrapper = this.$refs.listWrapper;\n if (!wrapper) return;\n this.scrollTimer = setInterval(() => {\n if (wrapper.scrollTop + wrapper.clientHeight >= wrapper.scrollHeight - 2) {\n wrapper.scrollTop = 0;\n } else {\n wrapper.scrollTop += 1;\n }\n }, 50);\n }\n }\n};","map":{"version":3,"names":["getInspectionList","name","data","total","list","scrollTimer","mounted","res","$nextTick","startScroll","beforeDestroy","clearInterval","methods","levelText","level","map","high","medium","low","wrapper","$refs","listWrapper","setInterval","scrollTop","clientHeight","scrollHeight"],"sources":["src/components/LabStats/InspectionList.vue"],"sourcesContent":["\n \n \n 实验室安全检查情况\n {{ total }}\n \n \n \n \n \n {{ item.id }}\n \n {{ item.lab }}\n {{ item.issue }}\n \n \n {{ levelText(item.level) }}\n \n \n {{ item.status }}\n \n {{ item.date }}\n \n \n \n \n \n\n\n\n\n\n"],"mappings":"AAkCA,SAAAA,iBAAA;AAEA;EACAC,IAAA;EACAC,KAAA;IACA;MACAC,KAAA;MACAC,IAAA;MACAC,WAAA;IACA;EACA;EACA,MAAAC,QAAA;IACA,MAAAC,GAAA,SAAAP,iBAAA;IACA,KAAAG,KAAA,GAAAI,GAAA,CAAAL,IAAA,CAAAC,KAAA;IACA,KAAAC,IAAA,GAAAG,GAAA,CAAAL,IAAA,CAAAE,IAAA;IACA,KAAAI,SAAA,YAAAC,WAAA;EACA;EACAC,cAAA;IACAC,aAAA,MAAAN,WAAA;EACA;EACAO,OAAA;IACAC,UAAAC,KAAA;MACA,MAAAC,GAAA;QAAAC,IAAA;QAAAC,MAAA;QAAAC,GAAA;MAAA;MACA,OAAAH,GAAA,CAAAD,KAAA,KAAAA,KAAA;IACA;IACA;IACAL,YAAA;MACA,MAAAU,OAAA,QAAAC,KAAA,CAAAC,WAAA;MACA,KAAAF,OAAA;MACA,KAAAd,WAAA,GAAAiB,WAAA;QACA,IAAAH,OAAA,CAAAI,SAAA,GAAAJ,OAAA,CAAAK,YAAA,IAAAL,OAAA,CAAAM,YAAA;UACAN,OAAA,CAAAI,SAAA;QACA;UACAJ,OAAA,CAAAI,SAAA;QACA;MACA;IACA;EACA;AACA","ignoreList":[]},"metadata":{},"sourceType":"module","externalDependencies":[]}