<template> 
 | 
    <GlobalWindow 
 | 
        :title="title" 
 | 
        width="100%" 
 | 
        :visible.sync="visible" 
 | 
        :confirm-working="isWorking" 
 | 
        @confirm="confirm" 
 | 
    > 
 | 
        <div class="info"> 
 | 
          <div class="info_head"> 
 | 
            <span>所属企业:{{ form.companyName }} </span> 
 | 
            <el-button  type="primary" v-if=" form.unitStatus == 0" @click="$refs.dispatchReviewCheck.open('审核派遣单位',form)" >审核</el-button> 
 | 
            <el-button type="primary" v-else-if="form.unitStatus == 1 &&( form.worktypeStatus  == null || form.worktypeStatus == 0)" @click="$refs.dispatchReview.open('审核工种',form)">审核工种</el-button> 
 | 
          </div> 
 | 
            <div class="info_list"> 
 | 
                <div class="info_list_item"> 
 | 
                    <div class="info_list_item_label">派遣单位:</div> 
 | 
                    <div class="info_list_item_val">{{form.name}}</div> 
 | 
                </div> 
 | 
                <div class="info_list_item"> 
 | 
                    <div class="info_list_item_label">派遣单位信用代码:</div> 
 | 
                    <div class="info_list_item_val">{{form.code}}</div> 
 | 
                </div> 
 | 
                <div class="info_list_item"> 
 | 
                    <div class="info_list_item_label">派遣单位状态:</div> 
 | 
                    <div class="info_list_item_val" :class="'du-status'+form.unitStatus"  v-if="form.unitStatus === 0">待审核</div> 
 | 
                    <div class="info_list_item_val"    v-if="form.unitStatus === 1"> 
 | 
                      <span :class="'du-status'+form.worktypeStatus"  style="color:#2E68EC;" v-if="form.worktypeStatus  ==null||form.worktypeStatus === 0">工种待审</span> 
 | 
                      <span  :class="'du-status'+form.worktypeStatus"  v-if="form.worktypeStatus === 1">审核通过</span> 
 | 
                      <span :class="'du-status'+form.worktypeStatus"  v-if="form.worktypeStatus === 2">工种审核不通过</span> 
 | 
                     </div> 
 | 
                    <div class="info_list_item_val"  :class="'du-status'+form.unitStatus" v-if="form.unitStatus === 2">审核不通过</div> 
 | 
                </div> 
 | 
                <div class="info_list_item"> 
 | 
                    <div class="info_list_item_label">派遣单位详述:</div> 
 | 
                    <div class="info_list_item_val">{{form.content}}</div> 
 | 
                </div> 
 | 
            </div> 
 | 
            <div class="info_table"> 
 | 
                <div class="info_table_item" v-for="(item, index) in form.duSolutionList" :key="index"> 
 | 
                    <div class="info_table_item_label">保险方案:{{item.solutionName}}</div> 
 | 
                    <div class="info_table_item_content"> 
 | 
                        <el-table 
 | 
                            :data="item.duWorktypeList" 
 | 
                            border 
 | 
                            style="width: 100%"> 
 | 
                            <el-table-column label="序号" width="80px"> 
 | 
                                <template slot-scope="scope"> 
 | 
                                    <span>{{scope.$index + 1}}</span> 
 | 
                                </template> 
 | 
                            </el-table-column> 
 | 
                            <el-table-column 
 | 
                                prop="workTypeName" 
 | 
                                label="所属工种"> 
 | 
                            </el-table-column> 
 | 
                            <el-table-column 
 | 
                                prop="name" 
 | 
                                label="操作视频"> 
 | 
                                <template slot-scope="{row}"> 
 | 
                                    <video loop controls width="150px" height="150px" :src="row.videoUrlFull"></video> 
 | 
                                </template> 
 | 
                            </el-table-column> 
 | 
                            <el-table-column 
 | 
                                prop="checkDate" 
 | 
                                label="审核通过日期"> 
 | 
                            </el-table-column> 
 | 
                            <el-table-column 
 | 
                                label="状态"> 
 | 
                                <template slot-scope="{row}"> 
 | 
                                    <span :class="'du-status'+row.status"  v-if="row.status === 0">待审核</span> 
 | 
                                    <span :class="'du-status'+row.status"   v-if="row.status === 1">审核通过</span> 
 | 
                                    <span :class="'du-status'+row.status"  v-if="row.status === 2">审核不通过</span> 
 | 
                                </template> 
 | 
                            </el-table-column> 
 | 
<!--                            <el-table-column 
 | 
                                label="操作"> 
 | 
                                <template slot-scope="scope"> 
 | 
                                    <el-button type="text" style="color: red;" v-if="scope.row.status === 2" @click="dele(scope.row.id, index, scope.$index)">删除</el-button> 
 | 
                                </template> 
 | 
                            </el-table-column>--> 
 | 
                        </el-table> 
 | 
                    </div> 
 | 
                </div> 
 | 
            </div> 
 | 
            <div class="info_status"> 
 | 
                <div class="info_status_label">审核流程</div> 
 | 
                <div class="info_status_list"> 
 | 
                    <el-timeline :reverse="reverse"> 
 | 
                        <el-timeline-item 
 | 
                            v-for="(activity, index) in form.duLogList" 
 | 
                            :key="index"> 
 | 
                            <div style="display: flex; flex-direction: column;"> 
 | 
                                <span style="font-size: 16px; font-weight: 400; color: black;"> 
 | 
                                    {{activity.title}} 
 | 
                                    <span style="font-size: 16px; font-weight: 400; color: black; margin-left: 10px;" v-if="activity.objType === 5 || activity.objType === 6 || activity.objType === 1 || activity.objType === 2"> 
 | 
                                       {{activity.content}} 
 | 
                                    </span> 
 | 
                                </span> 
 | 
                                <span style="margin-top: 5px; font-size: 12px; font-weight: 400; color: #999999;"> 
 | 
                                    操作员-{{activity.creatorName}}({{activity.creatorType==1? activity.companyName: "平台端"}}){{activity.createDate}} 
 | 
                                </span> 
 | 
                            </div> 
 | 
                        </el-timeline-item> 
 | 
                    </el-timeline> 
 | 
                </div> 
 | 
            </div> 
 | 
        </div> 
 | 
  
 | 
        <!--    添加方案    --> 
 | 
        <addJobType ref="addJobType" @success="callback" /> 
 | 
        <!-- 编辑 --> 
 | 
      <OperaDispatchUnitWindow ref="OperaDispatchUnitWindow" @success="callback" /> 
 | 
      <dispatchReview ref="dispatchReview"  @success="callback" /> 
 | 
      <dispatchReviewCheck ref="dispatchReviewCheck" @success="callback" /> 
 | 
      <template v-slot:footer> 
 | 
        <el-button @click="visible=false">返回</el-button> 
 | 
      </template> 
 | 
    </GlobalWindow> 
 | 
</template> 
 | 
  
 | 
<script> 
 | 
  import BaseOpera from '@/components/base/BaseOpera' 
 | 
  import GlobalWindow from '@/components/common/GlobalWindow' 
 | 
  import addJobType from '@/components/enterprise/addJobType' 
 | 
  import dispatchReview from '@/components/business/dispatchReview' 
 | 
  import dispatchReviewCheck from '@/components/business/dispatchReviewCheck' 
 | 
  import OperaDispatchUnitWindow from '@/components/enterprise/OperaDispatchUnitWindow' 
 | 
  import { getById } from '@/api/business/dispatchUnit' 
 | 
  import { deleteById } from '@/api/business/duWorktype' 
 | 
  export default { 
 | 
    name: 'dispatchUnitDetailsPlat', 
 | 
    extends: BaseOpera, 
 | 
    components: { GlobalWindow, addJobType, OperaDispatchUnitWindow,dispatchReview ,dispatchReviewCheck}, 
 | 
    data () { 
 | 
      return { 
 | 
        // 表单数据 
 | 
        form: { 
 | 
          id: null, 
 | 
          name: '', 
 | 
          code: '', 
 | 
          content: '', 
 | 
          companyName:'', 
 | 
          unitStatus: '', 
 | 
          worktypeStatus: '', 
 | 
          duLogList: [], 
 | 
          duSolutionList: [], 
 | 
          saveDuSolutionDTOList: [ 
 | 
            { 
 | 
              id: '', 
 | 
              saveDuWorkTypeDTOList: [ 
 | 
                { 
 | 
                  videoUrl: '', 
 | 
                  workTypeId: '', 
 | 
                  file: { 
 | 
                    videourl: '', 
 | 
                    videourlfull: '' 
 | 
                  } 
 | 
                } 
 | 
              ], 
 | 
              typeWork: [], 
 | 
              solutionId: '' 
 | 
            } 
 | 
          ] 
 | 
        }, 
 | 
        tableData: [], 
 | 
        insuranceScheme: [], 
 | 
        reverse: false, 
 | 
        visible5:false, 
 | 
        activities: [] 
 | 
      } 
 | 
    }, 
 | 
    created () { 
 | 
      this.config({ 
 | 
        api: '/business/dispatchUnit', 
 | 
        'field.id': 'id' 
 | 
      }) 
 | 
    }, 
 | 
    methods: { 
 | 
      open (title, target) { 
 | 
        this.title = title 
 | 
        this.visible = true 
 | 
        this.form={ 
 | 
          id: null, 
 | 
          name: '', 
 | 
          code: '', 
 | 
          content: '', 
 | 
          unitStatus: '', 
 | 
          companyName:'', 
 | 
          worktypeStatus: '', 
 | 
          duLogList: [], 
 | 
          duSolutionList: [], 
 | 
          saveDuSolutionDTOList:[ ] 
 | 
        } 
 | 
        this.form.id = target.id 
 | 
        this.form.checkInfo='' 
 | 
        this.getDetails() 
 | 
      }, 
 | 
      async getDetails() { 
 | 
        let res = await getById(this.form.id) 
 | 
        for (const key in this.form) { 
 | 
          this.form[key] = res[key] 
 | 
        } 
 | 
      }, 
 | 
      callback() { 
 | 
          // this.visible = true 
 | 
          this.open (this.title, this.form) 
 | 
         this.$emit('success') 
 | 
      } 
 | 
    } 
 | 
  } 
 | 
</script> 
 | 
  
 | 
<style lang="scss" scoped> 
 | 
    .info { 
 | 
        width: 100%; 
 | 
        .info_list { 
 | 
            width: 100%; 
 | 
            display: flex; 
 | 
            align-items: center; 
 | 
            flex-wrap: wrap; 
 | 
            .info_list_item { 
 | 
                width: 33.3%; 
 | 
                display: flex; 
 | 
                align-items: center; 
 | 
                margin-bottom: 15px; 
 | 
                .info_list_item_label { 
 | 
                    flex-shrink: 0; 
 | 
                    //width: 150px; 
 | 
                    font-size: 14px; 
 | 
                    color: black; 
 | 
                } 
 | 
                .info_list_item_val { 
 | 
                    flex: 1; 
 | 
                    font-size: 14px; 
 | 
                    color: black; 
 | 
                } 
 | 
            } 
 | 
        } 
 | 
      .info_head { 
 | 
        width: 100%; 
 | 
        display: flex; 
 | 
        align-items: center; 
 | 
        justify-content: space-between; 
 | 
        margin-bottom: 15px; 
 | 
        span { 
 | 
          color: black; 
 | 
          font-size: 14px; 
 | 
        } 
 | 
      } 
 | 
        .info_btns { 
 | 
            width: 100%; 
 | 
            display: flex; 
 | 
            align-items: center; 
 | 
            margin-bottom: 15px; 
 | 
        } 
 | 
        .info_table { 
 | 
            width: 100%; 
 | 
            display: flex; 
 | 
            flex-direction: column; 
 | 
            margin-bottom: 15px; 
 | 
            .info_table_item { 
 | 
                width: 100%; 
 | 
                display: flex; 
 | 
                flex-direction: column; 
 | 
                margin-bottom: 15px; 
 | 
                &:last-child { 
 | 
                    margin: 0 !important; 
 | 
                } 
 | 
                .info_table_item_label { 
 | 
                    font-size: 14px; 
 | 
                    color: black; 
 | 
                    margin-bottom: 10px; 
 | 
                } 
 | 
                .info_table_item_content { 
 | 
                    width: 100%; 
 | 
                } 
 | 
            } 
 | 
        } 
 | 
        .info_status { 
 | 
            width: 100%; 
 | 
            .info_status_label { 
 | 
                width: 100%; 
 | 
                font-size: 18px; 
 | 
                font-weight: bold; 
 | 
                margin-bottom: 15px; 
 | 
            } 
 | 
        } 
 | 
    } 
 | 
</style> 
 |