wjt
2024-06-26 59f4dc012a2c42eebd31301444e0f8df9af088e0
qiye/complaint/details.vue
@@ -8,7 +8,9 @@
      <view class="donw-box"></view>
      <view class="page-main">
         <view class="title">
            已评价
            <template v-if="msg.orderStatus>2&&msg.isEva==0">已执法待评价</template>
            <template v-if="msg.orderStatus>2&&msg.isEva==1">已评价</template>
            <template v-if="msg.orderStatus==2">待执法</template>
         </view>
         <view class="wbox">
            <view class="item">
@@ -45,53 +47,53 @@
            </view>
         </view>
         <view style="height: 20rpx;"></view>
         <template v-if="orderId">
            <view class="wbox">
               <view class="item">
                  <view class="k">
                     执法主题
                  </view>
                  <view class="v">
                     {{details.enforceReason}}
                  </view>
               </view>
               <view class="item">
                  <view class="k">
                     执法过程
                  </view>
               </view>
               <view class="imgbox">
                  <img :src="baseUrl+item" v-for="(item,index) in orderDetailsMsg.regionImgs" :key="index" class="more" @click="imgclick(item)" alt="" />
               </view>
               <view class="item">
                  <view class="k">
                     执法结果
                  </view>
                  <view class="v" style="color: #EB4746;">
                     <!-- {{details.regionStatus == 0? "正常" : "停业整顿" }} -->
                     {{orderDetailsMsg.regionReason}}
                  </view>
               </view>
               <view class="item">
                  <view class="k">
                     执法时间
                  </view>
                  <view class="v">
                     {{details.executeTime}}
                  </view>
               </view>
            </view>
            <view style="height: 20rpx;"></view>
         <template v-if="orderId">
            <view class="wbox">
               <view class="item">
                  <view class="k">
                     执法主题
                  </view>
                  <view class="v">
                     {{details.enforceReason}}
                  </view>
               </view>
               <view class="item">
                  <view class="k">
                     执法过程
                  </view>
               </view>
               <view class="imgbox">
                  <img :src="baseUrl+item" v-for="(item,index) in orderDetailsMsg.regionImgs" :key="index" class="more" @click="imgclick(item)" alt="" />
               </view>
               <view class="item">
                  <view class="k">
                     执法结果
                  </view>
                  <view class="v" style="color: #EB4746;">
                     <!-- {{details.regionStatus == 0? "正常" : "停业整顿" }} -->
                     {{orderDetailsMsg.regionReason}}
                  </view>
               </view>
               <view class="item">
                  <view class="k">
                     执法时间
                  </view>
                  <view class="v">
                     {{details.executeTime}}
                  </view>
               </view>
            </view>
            <view style="height: 20rpx;"></view>
         </template>
         <view class="wbox2">
            <view class="t">
               投诉记录
            </view>
            <view class="jilu" :class="{start: item.nodeName == '发起投诉' || item.nodeName == '已办结', handler: item.nodeName == '处理中', nonde: index == nodeList.length - 1}" v-for="(item,index) in nodeList" :key="index">
               <image src="/static/policy/icon.png" class="img" alt="" mode="widthFix" v-if="item.nodeName == '发起投诉'"/>
               <image src="/static/guocheng.png" class="img" alt=""  mode="widthFix"  v-if="item.nodeName == '处理中'"/>
               <image src="/static/policy/refject.png" class="img"  mode="widthFix" alt="" v-if="item.nodeName == '已驳回'"/>
               <image src="/static/policy/icon.png" class="img" alt="" mode="widthFix" v-if="item.nodeName == '发起投诉'"/>
               <image src="/static/guocheng.png" class="img" alt=""  mode="widthFix"  v-if="item.nodeName == '处理中'"/>
               <image src="/static/policy/refject.png" class="img"  mode="widthFix" alt="" v-if="item.nodeName == '已驳回'"/>
               <image src="/static/policy/icon.png" class="img" alt=""  mode="widthFix" v-if="item.nodeName == '已办结'"/>
               <view class="font" style="width: calc(100% - 50rpx);">
                  <view class="h" >
@@ -110,12 +112,16 @@
                        <span>申诉主题:</span>
                        {{dictLabel1}}
                     </view>
                     <view class="p">
                     <view class="p" style="margin-bottom: 18rpx;">
                        <span>申诉内容:</span>
                        {{details.complaintReason}}
                     </view>
                     <view class="p"  v-if="item.nodeName == '已驳回'">
                        <span>驳回原因:</span>
                        {{item.nodeReason}}
                     </view>
                     <view class="p"  v-if="item.nodeName == '已驳回'">
                        <span>申诉内容:</span>
                     <view class="p"  v-if="item.nodeName == '已办结' && item.nodeReason">
                        <span>办结结果:</span>
                        {{item.nodeReason}}
                     </view>
                  </view>
@@ -126,7 +132,33 @@
               <view class="font">
                  <view class="h">
                     <view class="s">
                        已驳回
                        {{item.nodeName}}
                     </view>
                     <view class="time">
                        {{item.nodeTime}}
                     </view>
                  </view>
                  <view class="b">
                     <view class="name">
                        {{details.companyUser}}
                     </view>
                     <view class="p">
                        <span>申诉主题:</span>
                        {{dictLabel1}}
                     </view>
                     <view class="p">
                        <span>申诉内容:</span>
                        {{details.complaintReason}}
                     </view>
                  </view>
               </view>
            </view>
            <view class="jilu">
               <image src="/static/guocheng.png" class="img" alt=""  />
               <view class="font">
                  <view class="h">
                     <view class="s">
                        处理中
                     </view>
                     <view class="time">
                        2024-06-07 12:14
@@ -146,123 +178,97 @@
                     </view>
                  </view>
               </view>
            </view>
            <view class="jilu">
               <image src="/static/guocheng.png" class="img" alt=""  />
               <view class="font">
                  <view class="h">
                     <view class="s">
                        处理中
                     </view>
                     <view class="time">
                        2024-06-07 12:14
                     </view>
                  </view>
                  <view class="b">
                     <view class="name">
                        {{details.companyUser}}
                     </view>
                     <view class="p">
                        <span>申诉主题:</span>
                        {{dictLabel1}}
                     </view>
                     <view class="p">
                        <span>申诉内容:</span>
                        {{details.complaintReason}}
                     </view>
                  </view>
               </view>
            </view>
          -->
          -->
         </view>
      </view>
      
   </view>
</template>
<script>
   import { complaintDetails, orderNodeList, orderComplaintNodeList } from '@/api/qiye.js'
   import { orderDetails } from '@/api/policy.js'
   import { config } from '@/common/config.js'
<script>
   import { complaintDetails, orderNodeList, orderComplaintNodeList } from '@/api/qiye.js'
   import { orderDetails } from '@/api/policy.js'
   import { config } from '@/common/config.js'
   import { getDicts } from '@/api/data.js'
   export default {
      data() {
         return {
            details: {},
            orderId: "",
            orderDetailsMsg: {},
            baseUrl: config.baseUrl,
            dictLabel: "",
            dictLabel1: "",
            details: {},
            orderId: "",
            orderDetailsMsg: {},
            baseUrl: config.baseUrl,
            dictLabel: "",
            dictLabel1: "",
            nodeList: []
         }
      },
      onLoad(options) {
         this.complaint(options.id)
         if(options.orderId) {
            this.orderId = options.orderId
            this.orderDetails()
         } else {
            this.orderNodeList(options.id)
         }
      },
      methods: {
         orderNodeList(id) {
            orderNodeList({id}).then(val => {
               // console.log(val)
               this.nodeList = val.data.data
            })
         },
         // 获取投诉类型
         getComtype() {
            getDicts('complaint_type').then(val => {
               console.log(val)
               this.dictLabel1 = val.data.data.find(item => item.dictCode == this.details.complaintType).dictLabel
            })
         },
         enforceType() {
            getDicts('enforce_type').then(val => {
               console.log(val)
               this.dictLabel = val.data.data.find(item => item.dictCode == this.orderDetailsMsg.enforceType).dictLabel
            })
      onLoad(options) {
         this.complaint(options.id)
         if(options.orderId) {
            this.orderId = options.orderId
            this.orderDetails()
         } else {
            this.orderNodeList(options.id)
         }
      },
      methods: {
         orderNodeList(id) {
            orderNodeList({id}).then(val => {
               // console.log(val)
               this.nodeList = val.data.data
            })
         },
         imgclick(url) {
         // 获取投诉类型
         getComtype() {
            getDicts('complaint_type').then(val => {
               console.log(val)
               this.dictLabel1 = val.data.data.find(item => item.dictCode == this.details.complaintType).dictLabel
            })
         },
         enforceType() {
            getDicts('enforce_type').then(val => {
               console.log(val)
               this.dictLabel = val.data.data.find(item => item.dictCode == this.orderDetailsMsg.enforceType).dictLabel
            })
         },
         imgclick(url) {
            url = this.baseUrl + url
            uni.previewImage({
               urls: [url]
            })
         },
         complaint(details) {
            complaintDetails(details).then(val => {
               // console.log(val.data.data)
               this.details = val.data.data
               this.getComtype()
            })
         },
         orderDetails() {
            orderDetails({ orderId: this.orderId}).then(val => {
               // console.log(val.data.data)
               val.data.data.regionImgs = val.data.data.regionImgs.split(",")
               this.orderDetailsMsg = val.data.data
               this.orderComplaintNodeList()
               this.enforceType()
            })
         },
         orderComplaintNodeList() {
            orderComplaintNodeList({ orderId: this.orderId }).then(val => {
               console.log(val.data.data, 'val===')
               this.nodeList = val.data.data
            })
         },
         complaint(details) {
            complaintDetails(details).then(val => {
               // console.log(val.data.data)
               this.details = val.data.data
               this.getComtype()
            })
         },
         orderDetails() {
            orderDetails({ orderId: this.orderId}).then(val => {
               // console.log(val.data.data)
               val.data.data.regionImgs = val.data.data.regionImgs.split(",")
               this.orderDetailsMsg = val.data.data
               this.orderComplaintNodeList()
               this.enforceType()
            })
         },
         orderComplaintNodeList() {
            orderComplaintNodeList({ orderId: this.orderId }).then(val => {
               console.log(val.data.data, 'val===')
               this.nodeList = val.data.data
            })
         }
      }
   }
</script>
<style>
   page {
      background: #F4F4F4;
   page {
      background: #F4F4F4;
   }
</style>
<style lang="scss" scoped>
@@ -335,7 +341,8 @@
      border-radius: 5px;
      box-sizing: border-box;
      margin: 0 32rpx;
      position: relative;
      z-index: 10;
      .t {
         padding: 24rpx;
         border-bottom: 1px solid #EEEEEE;
@@ -344,33 +351,33 @@
         font-weight: bold;
      }
   
   }
   }
   .jilu{
      display: flex;
      justify-content: space-between;
      padding: 24rpx;
      position: relative;
      &::before{
         content: '';
         display: inline-block;
         width: 2rpx;
         height: 100%;
         background: #eb47460d;
         position: absolute;
         left: 44rpx;
         top: 30rpx;
         z-index: 99;
      }
      padding: 24rpx;
      position: relative;
      &::before{
         content: '';
         display: inline-block;
         width: 2rpx;
         height: 100%;
         background: #eb47460d;
         position: absolute;
         left: 44rpx;
         top: 30rpx;
         z-index: 99;
      }
      
      .img{
         width: 50rpx;
         height: 50rpx;
         margin-right: 24rpx;
         position: relative;
         margin-right: 24rpx;
         position: relative;
         z-index: 100;
      }
      .font{
      .font{
         width: calc(100% - 70rpx);
         .h{
            display: flex;
@@ -406,20 +413,20 @@
            }
         }
      }
   }
   .handler{
      &::before {
         background: #fe7b320d;
      }
   }
   .start{
      &::before{
         background: #E7F8F0;
      }
   }
   .nonde{
      &::before{
         background: none;
      }
   }
   }
   .handler{
      &::before {
         background: #fe7b320d;
      }
   }
   .start{
      &::before{
         background: #E7F8F0;
      }
   }
   .nonde{
      &::before{
         background: none;
      }
   }
</style>