吉安感知网项目-前端
chenyao
2026-02-27 4af871597f94631e18cc03a35bedea2679e14d9f
applications/mobile-web-view/src/appPages/work/workDetail/index.vue
@@ -2,7 +2,7 @@
   <div class="workDetailContainer">
      <div class="detailTop">
         <div class="image-container">
            <van-swipe class="detailSwipe" :autoplay="3000" indicator-color="#4C85FF">
            <van-swipe :autoplay="3000" indicator-color="#4C85FF">
            <van-swipe-item v-for="(img, index) in getImageList" :key="index">
               <van-image class="detailImage" :src="img" fit="cover" width="100%" height="235px"
                  @click="openPreview(index)" preview-visible="false" />
@@ -55,10 +55,11 @@
</template>
<script setup>
import {getSharingDetailsApi} from '@/api/work/index'
import { showToast, showNotify, showImagePreview } from 'vant'
import { getShowImg, getSmallImg } from '@/utils/util'
import { useRoute,useRouter } from 'vue-router'
const keyword = ref('')
const route = useRoute()
const router = useRouter()
@@ -93,7 +94,14 @@
}
onMounted(async () => {
workDetailData.value = JSON.parse(route.query.workDetailData)
   keyword.value = JSON.parse(route.query.workDetailData)
   try {
      const res = await getSharingDetailsApi({ cacheKey: keyword.value })
      workDetailData.value = res.data.data
   } catch (error) {
      showToast('分享链接失效')
   }
})
</script>
<style lang="scss" scoped>
@@ -102,8 +110,6 @@
      .image-container {
         position: relative;
         width: 100%;
         // height: 205px;
         .detailImage {
            width: 100%;
            height: 100%;
@@ -115,7 +121,7 @@
   .worderContainer {
      padding: 0 12px;
      padding-bottom: 2px;
      // padding-bottom: 2px;
      background: #f6f6f6;
   }
@@ -123,7 +129,7 @@
      margin-top: 15px;
      background-color: #fff;
      border-radius: 6px;
      padding: 10px;
      padding: 8px 10px;
      margin-bottom: 17px;
      .workOrderTitle {