董国庆
2025-06-06 d0f4c2d4bb7a72b32fb9945de8908e1d4ab6509c
H5/pages/dispatchWorkOrder/dispatchWorkOrder.vue
@@ -7,13 +7,13 @@
         </view>
         <view class="address">
            <view class="adr">{{detail.detailedAddress || ''}}</view>
            <view class="adr">{{detail.location || ''}}</view>
            <image src="/static/position@2x.png" class="w-31 h-31" mode="aspectFill"></image>
         </view>
         <view class="table-head">
            <view class="type flex1">问题类型</view>
            <view class="person flex1">群众</view>
            <view class="person flex1">群众姓名</view>
            <view class="phone flex1">联系电话</view>
         </view>
@@ -25,7 +25,12 @@
                  </view>
               </view>
               <view class="person-item flex1">{{detail.name}}</view>
               <view class="phone-item flex1">{{detail.contactNumber}}</view>
               <view class="flex a-center">
                  <view class="phone-item flex1">{{detail.contactNumber}}</view>
                  <image @click.stop="callPhone(detail.contactNumber)" src="../../static/tell.png"
                     class="w-58 h-58 shrink0 " />
               </view>
            </view>
         </view>
      </view>
@@ -40,16 +45,15 @@
      <view class="notice-tip flex a-center ">
         <image src="/static/warnng@2x.png" class="w-31 h-31 mr-15" mode="aspectFill"></image>
         提交后会由上级部门进行审核,请留意审核结果
         提交后会由下级部门处理当前诉求
      </view>
      <view class="btn" @click="dispatch">下派至下级部门</view>
      <u-popup round="19rpx" :show="showPop" mode="center" @close="close" @open="open">
         <view class="popup-content">
            <view class="title-pop">请选择下派单位</view>
            <view class="pop-label">社区:</view>
            <uni-data-select :disabled="false" v-model="value" :localdata="range"
               @change="change"></uni-data-select>
            <view class="pop-label">{{['','区县','街道','社区'][accountLevel]}}:</view>
            <uni-data-select :disabled="false" v-model="value" :localdata="range"></uni-data-select>
            <view class="botton-btn">
               <view class="cancle" @tap="close">取消</view>
@@ -74,10 +78,14 @@
            showPop: false,
            value: '',
            range: [],
            accountLevel: 1, //1、市级 2、区县 3、街道 4、社区
         };
      },
      onShow() {
         this.accountLevel = uni.getStorageSync('userInfo').levelId || 1
      },
      onLoad(option) {
         option.id = 1
         // option.id = 1
         if (option.id) {
            this.id = option.id
            getDetail({
@@ -90,8 +98,11 @@
         }
      },
      methods: {
         change(e) {
            console.log("e:", e);
         callPhone(phoneNumber) {
            uni.makePhoneCall({
               phoneNumber
            });
         },
         close() {
            this.showPop = false
@@ -120,17 +131,26 @@
               })
               return
            }
            uni.showLoading({
               mask: true
            })
            saveDispatch({
               complaintId: this.id,
               comment: this.content,
               dispatchId: this.value
            }).then(res => {
               this.showPop = false
               uni.hideLoading()
               if (res.code == 200) {
                  uni.showToast({
                     icon: 'none',
                     title: '下派成功'
                  })
                  uni.navigateBack()
                  setTimeout(() => {
                     uni.navigateBack({
                        delta: 2
                     })
                  }, 1500)
               }
            })
         }