MrShi
2024-04-07 9a819fa35464df79a1a8a56e132b3463fac520a7
wx/pages/report_details/report_details.vue
@@ -99,6 +99,9 @@
                        <image :src="item.fileurlFull" mode="widthFix" v-if="item.type == 0"></image>
                        <video :src="item.fileurlFull" v-if="item.type == 1" />
                     </view>
                     <view class="info_list_item_tu_up">
                        <u-icon name="plus" color="#222222" size="20"></u-icon>
                     </view>
                     <view class="info_list_item_tu_zw"></view>
                     <view class="info_list_item_tu_zw"></view>
                     <view class="info_list_item_tu_zw"></view>
@@ -111,6 +114,9 @@
                        <image :src="item.fileurlFull" mode="widthFix" v-if="item.type === 0"></image>
                        <video :src="item.fileurlFull" v-if="item.type === 1"></video>
                     </view> 
                     <view class="info_list_item_tu_up">
                        <u-icon name="plus" color="#222222" size="20"></u-icon>
                     </view>
                     <view class="info_list_item_tu_zw"></view>
                     <view class="info_list_item_tu_zw"></view>
                     <view class="info_list_item_tu_zw"></view>
@@ -122,6 +128,9 @@
                     <view class="info_list_item_tu_img" v-for="(item, index) in info.compensationFileList" :key="index">
                        <image :src="item.fileurlFull" mode="widthFix" v-if="item.type === 0"></image>
                        <video :src="item.fileurlFull" v-if="item.type === 0"></video>
                     </view>
                     <view class="info_list_item_tu_up">
                        <u-icon name="plus" color="#222222" size="20"></u-icon>
                     </view>
                     <view class="info_list_item_tu_zw"></view>
                     <view class="info_list_item_tu_zw"></view>
@@ -166,9 +175,21 @@
         </view>
         <view style="width: 100%; height: calc(env(safe-area-inset-bottom) + 100rpx);" v-if="info.status == 0 || info.status == 2 || info.status == 3"></view>
         <view class="details_footer" v-if="info.status == 0 || info.status == 2 || info.status == 3">
            <u-button type="primary" shape="circle" color="#437CB3" text="补充说明" @click="openBC"></u-button>
            <view style="width: 30rpx; height: 100%;"></view>
            <u-button type="primary" shape="circle" color="#437CB3" text="编辑" @click="edit"></u-button>
         </view>
      </view>
      <u-modal
         title="补充资料"
         :show="show"
         :showCancelButton="true"
         closeOnClickOverlay
         @cancel="show = false"
         @confirm="confirm"
      >
         <u--textarea v-model="value" placeholder="请输入"></u--textarea>
      </u-modal>
   </view>
</template>
@@ -178,9 +199,11 @@
         return {
            id: null,
            info: null,
            show: false,
            height: 'auto',
            height1: 'auto',
            height2: 'auto'
            height2: 'auto',
            value: ''
         };
      },
      onLoad(option) {
@@ -188,6 +211,26 @@
         this.getDetails()
      },
      methods: {
         openBC() {
            this.value = ''
            this.show = true
         },
         confirm() {
            if (!this.value) return uni.showToast({
               title: '请输入内容',
               icon: 'none'
            })
            this.$u.api.supplement({
               id: this.id,
               objType: 0,
               supplement: this.value
            }).then(res => {
               if (res.code === 200) {
                  this.show = false
                  this.getDetails()
               }
            })
         },
         edit() {
            uni.navigateTo({
               url: `/pages/new_report/new_report?id=${this.info.id}`
@@ -455,10 +498,21 @@
                        width: 140rpx;
                        height: 0;
                     }
                     .info_list_item_tu_up {
                        width: 140rpx;
                        height: 140rpx;
                        border-radius: 15rpx;
                        margin-bottom: 20rpx;
                        display: flex;
                        align-items: center;
                        justify-content: center;
                        border: 1rpx solid #999999;
                     }
                     .info_list_item_tu_img {
                        width: 140rpx;
                        height: 140rpx;
                        border-radius: 15rpx;
                        margin-bottom: 20rpx;
                        display: flex;
                        align-items: center;
                        justify-content: center;