ll
liukangdong
2025-02-27 88a34566f7c3f77d90daa3fd57fb0abca3e1b5e6
h5/pages/staff/snapshot.vue
@@ -18,7 +18,7 @@
               <text>*</text>
               <text>隐患区域</text>
            </view>
            <view class="value" @click="isShowArea = true">
            <view class="value" @click="openArea">
               <text class="mr6"
                  :style="{ color: param.areaName ? '#000000' : '#999999' }">{{ param.areaName ? param.areaName : "请选择" }}</text>
               <u-icon name="arrow-right" color="#CCCCCC" size="20"></u-icon>
@@ -56,8 +56,14 @@
               </view>
               <view class="adduser_list_item_ipt1_upload" v-for="(item, i) in submitFileList" :key="i">
                  <u-icon class="close" size="20" name="close-circle-fill" color="red" @click="fileDel(i)"></u-icon>
                  <image v-if="item.type == 0" :src="item.fileurlFull" mode="widthFix"></image><video v-if="item.type == 1"
                     :src="item.fileurlFull"></video>
                  <image v-if="item.type == 0" :src="item.fileurlFull" mode="widthFix"></image>
                  <!--                   <video v-if="item.type == 1"
                     :src="item.fileurlFull" :controls="false" :show-center-play-btn="false"></video> -->
                  <view v-if="item.type == 1" class="video_wrap">
                     <video :src="item.fileurlFull" :initial-time="0.01" :show-center-play-btn="false" :controls="false"
                        class="video" :enable-progress-gesture="false" muted />
                     <image src="@/static/play.png" class="play" mode=""></image>
                  </view>
               </view>
            </view>
         </view>
@@ -86,7 +92,7 @@
               <text></text>
               <text>联系电话</text>
            </view>
            <view class="value"><input type="text" disabled placeholder="请输入联系电话" v-model="param.memberPhone"
            <view class="value"><input type="tel" disabled placeholder="请输入联系电话" v-model="param.memberPhone"
                  placeholder-style="color: #999999;" /></view>
         </view>
         <view class="line">
@@ -114,7 +120,7 @@
      <u-picker keyName="name" :show="isShowType" closeOnClickOverlay :columns="areaType" @confirm="seletedType"
         @close="isShowType = false" @cancel="isShowType = false"></u-picker>
      <!--  -->
      <u-datetime-picker :show="isShowTime" :minDate="new Date().getTime()" mode="datetime" closeOnClickOverlay
      <u-datetime-picker :show="isShowTime" :formatter="formatter" :minDate="new Date().getTime()" mode="datetime" closeOnClickOverlay
         @cancel="isShowTime = false" @close="isShowTime = false" @confirm="seletedDate"></u-datetime-picker>
      <!--  -->
      <u-popup :show="showUpload" @close="showUpload = false" closeOnClickOverlay>
@@ -166,7 +172,25 @@
            this.$set(this.param, 'checkorName', option.name)
         })
      },
      methods: {
      methods: {
         formatter(type, value) {
            if (type === 'year') {
               return `${value}年`
            }
            if (type === 'month') {
               return `${value}月`
            }
            if (type === 'day') {
               return `${value}日`
            }
            if (type === 'hour') {
               return `${value}时`
            }
            if (type === 'minute') {
               return `${value}分`
            }
            return value
         },
         onSubmit() {
            const {
               param,
@@ -211,7 +235,10 @@
            this.$set(this.param, 'companyId', item.id)
            this.$set(this.param, 'companyName', item.name)
            this.$set(this.param, 'areaId', '')
            this.$set(this.param, 'areaName', '')
            this.$set(this.param, 'areaName', '')
            this.$set(this.param, 'checkUserId', '')
            this.$set(this.param, 'applyCheckUserId', '')
            this.$set(this.param, 'checkorName', '')
            DangerConfigType({
               type: '0',
               companyId: item.id
@@ -219,6 +246,10 @@
               this.areaOptions = [res.data]
            })
            this.isShowCompany = false
         },
         openArea() {
            if(!this.param.companyId) return this.showToast('请先选择责任部门')
            this.isShowArea = true
         },
         seletedArea(e) {
            const item = e.value[0]
@@ -251,7 +282,9 @@
            this.isShowTime = false
         },
         initConfig() {
            deptListPost({queryHiddenDanger: 1}).then(res => {
            deptListPost({
               queryHiddenDanger: 1
            }).then(res => {
               this.deptList = [res.data]
            })
            DangerConfigType({
@@ -422,7 +455,9 @@
            display: flex;
            flex-wrap: wrap;
         }
         textarea{
            width: 100%;
         }
         .adduser_list_item_ipt1_upload {
            margin-top: 24rpx;
            width: 156rpx;
@@ -437,9 +472,11 @@
            align-items: center;
            justify-content: center;
            position: relative;
            &:nth-of-type(4n){
               margin-right: 0;
            &:nth-of-type(4n) {
               margin-right: 0;
            }
            .close {
               position: absolute;
               right: -20rpx;
@@ -447,6 +484,23 @@
               z-index: 9999;
            }
            .video_wrap {
               position: relative;
               border: 1px solid;
               width: 156rpx;
               height: 156rpx;
               border-radius: 4rpx;
               .play {
                  width: 60rpx !important;
                  height: 60rpx !important;
                  position: absolute;
                  top: 50%;
                  left: 50%;
                  transform: translate(-50%, -50%);
               }
            }
            image {
               width: 100%;
               height: 100%;