2023-11-07 09:43:46 +08:00
|
|
|
|
<template>
|
|
|
|
|
<view>
|
|
|
|
|
<cu-custom bgColor="bg-gradual-blueness" :isBack="true">
|
|
|
|
|
<block slot="backText">返回</block>
|
|
|
|
|
<block slot="content">动火作业申请</block>
|
|
|
|
|
</cu-custom>
|
|
|
|
|
<view class="form">
|
|
|
|
|
<view class="wui-form-list">
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">申请单位:</view>
|
|
|
|
|
{{ form.APPLY_DEPARTMENT_NAME }}
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">申请办理人:</view>
|
|
|
|
|
{{ form.APPLY_USER_NAME }}
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">作业编号:</view>
|
|
|
|
|
<input :disabled="forbidEdit" v-model="form.JOB_NUMBER" placeholder="请输入编号"></input>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">申请日期:</view>
|
|
|
|
|
<ruiDatePicker v-if="!forbidEdit" :start="todayDate" fields="minute"
|
|
|
|
|
:value="form.APPLICATION_DATE || '请选择'"
|
|
|
|
|
@change="changeApplicationDate"></ruiDatePicker>
|
|
|
|
|
<text v-else>{{ form.APPLICATION_DATE }}</text>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">作业类型:</view>
|
|
|
|
|
<picker @change="jobTypeChange" :disabled="forbidEdit" :value="form.JOB_TYPE_INDEX"
|
|
|
|
|
:range="jobTypeList"
|
|
|
|
|
range-key="name">
|
|
|
|
|
<view class="picker">
|
|
|
|
|
{{ form.JOB_TYPE_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</picker>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">动火部位:</view>
|
|
|
|
|
<input :disabled="forbidEdit" v-model="form.HOT_WORK_POSITION" placeholder="请输入动火部位"></input>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">动火方法:</view>
|
|
|
|
|
<picker @change="hotWorkMethodChange" :disabled="forbidEdit" :value="form.HOT_WORK_METHOD_INDEX"
|
|
|
|
|
:range="hotWorkMethodList" range-key="NAME">
|
|
|
|
|
<view class="picker">
|
|
|
|
|
{{ form.HOT_WORK_METHOD_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</picker>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">动火作业级别:</view>
|
|
|
|
|
<picker @change="hotWorkLevelChange" :disabled="forbidEdit" :value="form.HOT_WORK_LEVEL_INDEX"
|
|
|
|
|
:range="hotWorkLevelList" range-key="name">
|
|
|
|
|
<view class="picker">
|
|
|
|
|
{{ form.HOT_WORK_LEVEL_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</picker>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.HOT_WORK_LEVEL_INDEX =='0'">
|
|
|
|
|
<view class="title">动火负责人确认部门:</view>
|
|
|
|
|
<block v-if="!forbidEdit">
|
|
|
|
|
<view class="picker-tree-box">
|
|
|
|
|
<view class="picker-tree" @tap="showZgTree('tkiTree30')">
|
|
|
|
|
{{ form.CHARGECONFIRM_DEPT_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<tki-tree ref="tkiTree30" :selectParent=true :range="treeNode" rangeKey="name"
|
|
|
|
|
@confirm="zgtreeConfirm($event,'chargeConfirmList')"
|
|
|
|
|
@cancel="zgtreeCancel"></tki-tree>
|
|
|
|
|
</block>
|
|
|
|
|
<block v-else>{{ form.CHARGECONFIRM_DEPT_NAME }}</block>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.CHARGECONFIRM_DEPT_NAME">
|
|
|
|
|
<view class="title">动火负责人确认负责人:</view>
|
|
|
|
|
<picker @change="chargeConfirmChange" :disabled="forbidEdit" :value="form.CHARGECONFIRM_INDEX"
|
|
|
|
|
:range="chargeConfirmList" range-key="NAME">
|
|
|
|
|
<view class="picker">
|
|
|
|
|
{{ form.CHARGECONFIRM_USER_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</picker>
|
|
|
|
|
</view>
|
|
|
|
|
|
|
|
|
|
<!-- <view class="cu-form-group">
|
|
|
|
|
<view class="title">动火时间:</view>
|
|
|
|
|
<ruiDatePicker v-if="!forbidEdit" :start="todayDate" fields="minute"
|
|
|
|
|
:value="form.HOT_WORK_TIME || '请选择'"
|
|
|
|
|
@change="changehotWorkTime"></ruiDatePicker>
|
|
|
|
|
<text v-else>{{ form.HOT_WORK_TIME }}</text>
|
|
|
|
|
</view> -->
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">动火开始时间:</view>
|
|
|
|
|
<text>{{ form.HOT_WORK_TIME_START }}</text>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">动火结束时间:</view>
|
|
|
|
|
<text>{{ form.HOT_WORK_TIME_END }}</text>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">作业地点:</view>
|
|
|
|
|
<button class="cu-btn shadow bg-blue" @click="chooseLocation" v-if="!forbidEdit">地图选择</button>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.WORK_LONGITUDE">
|
|
|
|
|
<view class="title">经度:</view>
|
|
|
|
|
<view>{{form.WORK_LONGITUDE}}</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.WORK_LATITUDE">
|
|
|
|
|
<view class="title">纬度:</view>
|
|
|
|
|
<view>{{form.WORK_LATITUDE}}</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">作业内容:</view>
|
|
|
|
|
<input :disabled="forbidEdit" v-model="form.JOB_CONTENT" placeholder="请输入作业内容"></input>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="!forbidEdit">
|
|
|
|
|
<view class="title">动火操作人:</view>
|
|
|
|
|
<view class="add_pard_b">
|
|
|
|
|
<button class="cu-btn round bg-blue" @click="addOther">添加</button>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="add_pard_box" v-if="showAddOther">
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<button class="cu-btn round bg-blue" @click="hotWorkOperatorSelectShow">特种作业人员</button>
|
|
|
|
|
<button class="cu-btn round bg-blue" @click="addSpecialInputAdd">临时人员</button>
|
|
|
|
|
<button class="cu-btn round bg-blue" @click="addOtherInputAdd">其他</button>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="add_pard_item" v-for="(item,index) of other">
|
|
|
|
|
<view class="add_pard_del" @click="removeOther(index)">
|
|
|
|
|
<text class="cuIcon-roundclosefill text-red f40"></text>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<picker @change="PickerYsr($event,index)" :value="other[index].index"
|
|
|
|
|
@click="haveUser(otherUserList[index])"
|
|
|
|
|
:disabled="otherUserList[index] ==null || otherUserList[index].length==0"
|
|
|
|
|
:range="otherUserList[index]" range-key="NAME">
|
|
|
|
|
<view class="picker">
|
|
|
|
|
{{other[index].USER_NAME?other[index].USER_NAME:'请选择'}}
|
|
|
|
|
</view>
|
|
|
|
|
</picker>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="forbidEdit">
|
|
|
|
|
<view class="title">动火操作人:</view>
|
|
|
|
|
<uni-table border stripe emptyText="暂无更多数据" style="flex:1;margin: 20upx 0">
|
|
|
|
|
<uni-tr></uni-tr>
|
|
|
|
|
<uni-tr v-for="item in form.HOT_WORK_OPERATOR_NAME" :key="item">
|
|
|
|
|
<uni-td>{{ item }}</uni-td>
|
|
|
|
|
</uni-tr>
|
|
|
|
|
</uni-table>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">动火单位监护人员:</view>
|
|
|
|
|
<input :disabled="forbidEdit" v-model="form.SUPERVISOR_OF_HOT_WORK_UNIT"
|
|
|
|
|
placeholder="请输入动火单位监护人员"></input>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
|
|
|
|
|
<!-- 动火单位负责人 1-->
|
|
|
|
|
<view class="wui-form-list">
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">动火确认部门:</view>
|
|
|
|
|
<block v-if="!forbidEdit">
|
|
|
|
|
<view class="picker-tree-box">
|
|
|
|
|
<view class="picker-tree" @tap="showZgTree('tkiTree1')">
|
|
|
|
|
{{ form.HOT_WORK_DEPARTMENT_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<tki-tree ref="tkiTree1" :selectParent=true :range="treeNode" rangeKey="name"
|
|
|
|
|
@confirm="zgtreeConfirm($event,'hotWorkUserList')"
|
|
|
|
|
@cancel="zgtreeCancel"></tki-tree>
|
|
|
|
|
</block>
|
|
|
|
|
<block v-else>{{ form.HOT_WORK_DEPARTMENT_NAME }}</block>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.HOT_WORK_DEPARTMENT_NAME">
|
|
|
|
|
<view class="title">动火确认负责人:</view>
|
|
|
|
|
<picker @change="hotWorkChange" :disabled="forbidEdit" :value="form.HOT_WORK_PERSONNEL_INDEX"
|
|
|
|
|
:range="hotWorkUserList" range-key="NAME">
|
|
|
|
|
<view class="picker">
|
|
|
|
|
{{ form.HOT_WORK_USER_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</picker>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.HOT_WORK_USER_PHONE">
|
|
|
|
|
<view class="title">动火单位负责人电话:</view>
|
|
|
|
|
{{ form.HOT_WORK_USER_PHONE }}
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<!-- 项目发包人2 v-if="form.JOB_TYPE_INDEX == '1'" -->
|
|
|
|
|
<view class="wui-form-list" v-if="form.JOB_TYPE_ID == '1'">
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">项目发包单位负责人部门:</view>
|
|
|
|
|
<block v-if="!forbidEdit">
|
|
|
|
|
<view class="picker-tree-box">
|
|
|
|
|
<view class="picker-tree" @tap="showZgTree('tkiTree2')">
|
|
|
|
|
{{ form.PROJECT_UNIT_LEADER_DEPARTMENT_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<tki-tree ref="tkiTree2" :selectParent=true :range="treeNode" rangeKey="name"
|
|
|
|
|
@confirm="zgtreeConfirm($event,'projectUnitLeaderList')"
|
|
|
|
|
@cancel="zgtreeCancel"></tki-tree>
|
|
|
|
|
</block>
|
|
|
|
|
<block v-else>{{ form.PROJECT_UNIT_LEADER_DEPARTMENT_NAME }}</block>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.PROJECT_UNIT_LEADER_DEPARTMENT_NAME">
|
|
|
|
|
<view class="title">项目发包单位负责人:</view>
|
|
|
|
|
<picker @change="projectUnitLeaderChange" :disabled="forbidEdit"
|
|
|
|
|
:value="form.PROJECT_UNIT_LEADER_INDEX"
|
|
|
|
|
:range="projectUnitLeaderList" range-key="NAME">
|
|
|
|
|
<view class="picker">
|
|
|
|
|
{{ form.PROJECT_UNIT_LEADER_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</picker>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.PROJECT_UNIT_LEADER_PHONE">
|
|
|
|
|
<view class="title">项目发包单位负责人电话:</view>
|
|
|
|
|
{{ form.PROJECT_UNIT_LEADER_PHONE }}
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<!-- 现场负责人 3 现场管辖单位负责人 -->
|
|
|
|
|
<view class="wui-form-list">
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">现场负责人部门:</view>
|
|
|
|
|
<block v-if="!forbidEdit">
|
|
|
|
|
<view class="picker-tree-box">
|
|
|
|
|
<view class="picker-tree" @tap="showZgTree('tkiTree3')">
|
|
|
|
|
{{ form.SITE_LEADER_DEPARTMENT_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<tki-tree ref="tkiTree3" :selectParent=true :range="treeNode" rangeKey="name"
|
|
|
|
|
@confirm="zgtreeConfirm($event,'siteLeaderList')"
|
|
|
|
|
@cancel="zgtreeCancel"></tki-tree>
|
|
|
|
|
</block>
|
|
|
|
|
<block v-else>{{ form.SITE_LEADER_DEPARTMENT_NAME }}</block>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.SITE_LEADER_DEPARTMENT_NAME">
|
|
|
|
|
<view class="title">现场负责人:</view>
|
|
|
|
|
<picker @change="siteLeaderChange" :disabled="forbidEdit" :value="form.SITE_LEADER_INDEX"
|
|
|
|
|
:range="siteLeaderList" range-key="NAME">
|
|
|
|
|
<view class="picker">
|
|
|
|
|
{{ form.SITE_LEADER_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</picker>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.SITE_LEADER_PHONE">
|
|
|
|
|
<view class="title">现场负责人电话:</view>
|
|
|
|
|
{{ form.SITE_LEADER_PHONE }}
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<!-- 现场管辖单位负责人 4 -->
|
|
|
|
|
<view class="wui-form-list">
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">现场管辖负责人部门:</view>
|
|
|
|
|
<block v-if="!forbidEdit">
|
|
|
|
|
<view class="picker-tree-box">
|
|
|
|
|
<view class="picker-tree" @tap="showZgTree('tkiTree7')">
|
|
|
|
|
{{ form.UNIT_LEADER_DEPARTMENT_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<tki-tree ref="tkiTree7" :selectParent=true :range="treeNode" rangeKey="name"
|
|
|
|
|
@confirm="zgtreeConfirm($event,'unitLeaderList')"
|
|
|
|
|
@cancel="zgtreeCancel"></tki-tree>
|
|
|
|
|
</block>
|
|
|
|
|
<block v-else>{{ form.UNIT_LEADER_DEPARTMENT_NAME }}</block>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.UNIT_LEADER_DEPARTMENT_NAME">
|
|
|
|
|
<view class="title">现场管辖负责人:</view>
|
|
|
|
|
<picker @change="unitLeaderChange" :disabled="forbidEdit" :value="form.UNIT_LEADER_INDEX"
|
|
|
|
|
:range="unitLeaderList" range-key="NAME">
|
|
|
|
|
<view class="picker">
|
|
|
|
|
{{ form.UNIT_LEADER_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</picker>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.UNIT_LEADER_PHONE">
|
|
|
|
|
<view class="title">现场管辖负责人电话:</view>
|
|
|
|
|
{{ form.UNIT_LEADER_PHONE }}
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<!-- 动火许可证签发单位5 -->
|
|
|
|
|
<view class="wui-form-list">
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">动火许可证签发单位:</view>
|
|
|
|
|
<block v-if="!forbidEdit">
|
|
|
|
|
<view class="picker-tree-box">
|
|
|
|
|
<view class="picker-tree" @tap="showZgTree('tkiTree4')">
|
|
|
|
|
{{ form.ISSUING_DEPARTMENT_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<tki-tree ref="tkiTree4" :selectParent=true :range="treeNode" rangeKey="name"
|
|
|
|
|
@confirm="zgtreeConfirm($event,'issunigUserList')"
|
|
|
|
|
@cancel="zgtreeCancel"></tki-tree>
|
|
|
|
|
</block>
|
|
|
|
|
<block v-else>{{ form.ISSUING_DEPARTMENT_NAME }}</block>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.ISSUING_DEPARTMENT_NAME">
|
|
|
|
|
<view class="title">动火许可证签发负责人:</view>
|
|
|
|
|
<picker @change="issungChange" :disabled="forbidEdit" :value="form.ISSUING_INDEX"
|
|
|
|
|
:range="issunigUserList" range-key="NAME">
|
|
|
|
|
<view class="picker">
|
|
|
|
|
{{ form.ISSUING_USER_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</picker>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.ISSUING_USER_PHONE">
|
|
|
|
|
<view class="title">动火许可证签发负责人电话:</view>
|
|
|
|
|
{{ form.ISSUING_USER_PHONE }}
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<!-- 是否安全总监审批6 -->
|
|
|
|
|
<view class="wui-form-list">
|
|
|
|
|
<view class="cu-form-group ">
|
|
|
|
|
<view class="title text-hui">是否安全总监审批</view>
|
|
|
|
|
<radio-group class="selected" @change="radioType" :disabled="forbidEdit">
|
|
|
|
|
<view class="group mr20">
|
|
|
|
|
<radio class='radio' :disabled="forbidEdit" value="1"
|
|
|
|
|
:checked="form.IS_SAFETY_DIRECTOR==1"></radio>
|
|
|
|
|
<text>是</text>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="group">
|
|
|
|
|
<radio class='radio' :disabled="forbidEdit" value="0"
|
|
|
|
|
:checked="form.IS_SAFETY_DIRECTOR==0"></radio>
|
|
|
|
|
<text>否</text>
|
|
|
|
|
</view>
|
|
|
|
|
</radio-group>
|
|
|
|
|
</view>
|
|
|
|
|
<div v-if="form.IS_SAFETY_DIRECTOR =='1'">
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">安全总监单位:</view>
|
|
|
|
|
<block v-if="!forbidEdit">
|
|
|
|
|
<view class="picker-tree-box">
|
|
|
|
|
<view class="picker-tree" @tap="showZgTree('tkiTree5')">
|
|
|
|
|
{{ form.SAFETY_DIRECTOR_DEPARTMENT_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<tki-tree ref="tkiTree5" :selectParent=true :range="treeNode" rangeKey="name"
|
|
|
|
|
@confirm="zgtreeConfirm($event,'safetyDirectorList')"
|
|
|
|
|
@cancel="zgtreeCancel"></tki-tree>
|
|
|
|
|
</block>
|
|
|
|
|
<block v-else>{{ form.SAFETY_DIRECTOR_DEPARTMENT_NAME }}</block>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.SAFETY_DIRECTOR_DEPARTMENT_NAME">
|
|
|
|
|
<view class="title">安全总监:</view>
|
|
|
|
|
<picker @change="safetyDirectorChange" :disabled="forbidEdit"
|
|
|
|
|
:value="form.SAFETY_DIRECTOR_INDEX"
|
|
|
|
|
:range="safetyDirectorList" range-key="NAME">
|
|
|
|
|
<view class="picker">
|
|
|
|
|
{{ form.SAFETY_DIRECTOR_USER_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</picker>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.SAFETY_DIRECTOR_PHONE">
|
|
|
|
|
<view class="title">安全总监电话:</view>
|
|
|
|
|
{{ form.SAFETY_DIRECTOR_PHONE }}
|
|
|
|
|
</view>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</view>
|
|
|
|
|
<!-- 是否 需要气体检测 7 -->
|
|
|
|
|
<view class="wui-form-list">
|
|
|
|
|
<view class="cu-form-group ">
|
|
|
|
|
<view class="title text-hui">是否需要气体检测</view>
|
|
|
|
|
<radio-group class="selected" @change="radioType2" :disabled="forbidEdit">
|
|
|
|
|
<view class="group mr20">
|
|
|
|
|
<radio class='radio' :disabled="forbidEdit" value="1"
|
|
|
|
|
:checked="form.IS_GAS_TESTING==1"></radio>
|
|
|
|
|
<text>是</text>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="group">
|
|
|
|
|
<radio class='radio' :disabled="forbidEdit" value="0"
|
|
|
|
|
:checked="form.IS_GAS_TESTING==0"></radio>
|
|
|
|
|
<text>否</text>
|
|
|
|
|
</view>
|
|
|
|
|
</radio-group>
|
|
|
|
|
</view>
|
|
|
|
|
<div v-if="form.IS_GAS_TESTING =='1'">
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">气体检测人员单位:</view>
|
|
|
|
|
<block v-if="!forbidEdit">
|
|
|
|
|
<view class="picker-tree-box">
|
|
|
|
|
<view class="picker-tree" @tap="showZgTree('tkiTree6')">
|
|
|
|
|
{{ form.GAS_TESTING_DEPARTMENT_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<tki-tree ref="tkiTree6" :selectParent=true :range="treeNode" rangeKey="name"
|
|
|
|
|
@confirm="zgtreeConfirm($event,'gasTestingList')"
|
|
|
|
|
@cancel="zgtreeCancel"></tki-tree>
|
|
|
|
|
</block>
|
|
|
|
|
<block v-else>{{ form.GAS_TESTING_DEPARTMENT_NAME }}</block>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.GAS_TESTING_DEPARTMENT_NAME">
|
|
|
|
|
<view class="title">气体检测人员:</view>
|
|
|
|
|
<picker @change="gasTestingChange" :disabled="forbidEdit" :value="form.GAS_TESTING_INDEX"
|
|
|
|
|
:range="gasTestingList" range-key="NAME">
|
|
|
|
|
<view class="picker">
|
|
|
|
|
{{ form.GAS_TESTING_USER_NAME || '请选择' }}
|
|
|
|
|
</view>
|
|
|
|
|
</picker>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group" v-if="form.GAS_TESTING_USER_PHONE">
|
|
|
|
|
<view class="title">气体检测人员电话:</view>
|
|
|
|
|
{{ form.GAS_TESTING_USER_PHONE }}
|
|
|
|
|
</view>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</view>
|
|
|
|
|
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-bar btn-group" style="margin-top: 30upx;">
|
|
|
|
|
<button v-if="!forbidEdit" class="cu-btn bg-blue margin-tb-sm lg" @click="$noMultipleClicks(goSubmit,'1')">
|
|
|
|
|
提交
|
|
|
|
|
</button>
|
|
|
|
|
<button v-if="forbidEdit" class="cu-btn bg-green margin-tb-sm lg" @click="$noMultipleClicks(goback)">返回
|
|
|
|
|
</button>
|
|
|
|
|
</view>
|
|
|
|
|
|
|
|
|
|
<view class="padding flex flex-direction"></view>
|
|
|
|
|
<uni-popup ref="cityMore" type="bottom" :maskClick="false">
|
|
|
|
|
<more-select
|
|
|
|
|
title="选择特种操作人"
|
|
|
|
|
:cityData="hotWorkOperatorDepartmentList"
|
|
|
|
|
@closeCity="hotWorkOperatorSelectHide('close')"
|
|
|
|
|
@queryCity="hotWorkOperatorSelectHide('query')"
|
|
|
|
|
@switchCity="switchCity"
|
|
|
|
|
@chooseCity="chooseCity"
|
|
|
|
|
:cityIndex="cityIndex"
|
|
|
|
|
:cityIdArr="form.HOT_WORK_OPERATOR_ID"
|
|
|
|
|
:maxCount="99"
|
|
|
|
|
></more-select>
|
|
|
|
|
</uni-popup>
|
|
|
|
|
|
|
|
|
|
<view :class="['cu-modal',{'show':addModal}]">
|
|
|
|
|
<view class="cu-dialog">
|
|
|
|
|
<view class="cu-bar bg-white justify-end">
|
|
|
|
|
<view class="content">添加动火操作人</view>
|
|
|
|
|
<view class="action" @tap="addModal = false">
|
|
|
|
|
<text class="cuIcon-close text-red"></text>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view>
|
|
|
|
|
<view class="wrapper">
|
|
|
|
|
<view class="handCenter">
|
|
|
|
|
<view class="form">
|
|
|
|
|
<view class="wui-form-list">
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">人员姓名:</view>
|
|
|
|
|
<input v-model="addOtherInput.USERNAME" placeholder="请输入人员姓名"></input>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-bar bg-white justify-end">
|
|
|
|
|
<view class="action">
|
|
|
|
|
<button class="cu-btn bg-green margin-left" @click="addOtherInputSubmit">确认</button>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
|
|
|
|
|
<view :class="['cu-modal',{'show':addSpecial}]">
|
|
|
|
|
<view class="cu-dialog">
|
|
|
|
|
<view class="cu-bar bg-white justify-end">
|
|
|
|
|
<view class="content">添加动火操作人</view>
|
|
|
|
|
<view class="action" @tap="addSpecial = false">
|
|
|
|
|
<text class="cuIcon-close text-red"></text>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view>
|
|
|
|
|
<view class="wrapper">
|
|
|
|
|
<view class="handCenter">
|
|
|
|
|
<view class="form">
|
|
|
|
|
<view class="wui-form-list">
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">人员单位:</view>
|
|
|
|
|
<input v-model="addSpecialInput.DEPTNAME" placeholder="请输入人员单位"></input>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">人员姓名:</view>
|
|
|
|
|
<input v-model="addSpecialInput.USERNAME" placeholder="请输入人员姓名"></input>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">人员照片:</view>
|
|
|
|
|
<button class="cu-btn bg-blue margin-tb-sm sm" @click="ChooseImageUser"
|
|
|
|
|
v-if="addSpecialInput.userImgList.length === 0">点击上传
|
|
|
|
|
</button>
|
|
|
|
|
<block v-else>
|
|
|
|
|
<view class="bg-img" v-for="(item,index) in addSpecialInput.userImgList"
|
|
|
|
|
:key="index" @tap="ViewImageUser" :data-url="item">
|
|
|
|
|
<image :src="item" style="width: 500px"></image>
|
|
|
|
|
<view class="cu-tag bg-red" @tap.stop="DelImgUser" :data-index="index">
|
|
|
|
|
<text class='cuIcon-close'></text>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</block>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-form-group">
|
|
|
|
|
<view class="title">证件照片:</view>
|
|
|
|
|
<button class="cu-btn bg-blue margin-tb-sm sm" @click="ChooseImageCard"
|
|
|
|
|
v-if="addSpecialInput.cardImgList.length === 0">点击上传
|
|
|
|
|
</button>
|
|
|
|
|
<block v-else>
|
|
|
|
|
<view class="bg-img" v-for="(item,index) in addSpecialInput.cardImgList"
|
|
|
|
|
:key="index" @tap="ViewImageCard" :data-url="item">
|
|
|
|
|
<image :src="item" style="width: 500px"></image>
|
|
|
|
|
<view class="cu-tag bg-red" @tap.stop="DelImgCard" :data-index="index">
|
|
|
|
|
<text class='cuIcon-close'></text>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</block>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="cu-bar bg-white justify-end">
|
|
|
|
|
<view class="action">
|
|
|
|
|
<button class="cu-btn bg-green margin-left" @click="addSpecialInputSubmit">确认</button>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
import {
|
|
|
|
|
basePath,
|
|
|
|
|
corpinfoId,
|
|
|
|
|
loginUser,
|
|
|
|
|
loginSession,
|
|
|
|
|
formatDate,
|
|
|
|
|
loginUserId
|
|
|
|
|
} from '@/common/tool.js';
|
|
|
|
|
import tkiTree from "@/components/select-tree/select-tree.vue"
|
|
|
|
|
import ruiDatePicker from '@/components/rattenking-dtpicker/rattenking-dtpicker.vue';
|
|
|
|
|
import moreSelect from '@/components/more-select/more-select.vue';
|
|
|
|
|
import uniPopup from '@/components/more-select/uni-popup/uni-popup.vue';
|
|
|
|
|
|
|
|
|
|
export default {
|
|
|
|
|
components: {
|
|
|
|
|
tkiTree,
|
|
|
|
|
ruiDatePicker,
|
|
|
|
|
moreSelect,
|
|
|
|
|
uniPopup
|
|
|
|
|
},
|
|
|
|
|
data() {
|
|
|
|
|
return {
|
|
|
|
|
msg: 'add',
|
|
|
|
|
noClick: true,
|
|
|
|
|
form: {
|
|
|
|
|
HOTWORKAPPLICATION_ID: '',
|
|
|
|
|
APPLY_DEPARTMENT_ID: '',
|
|
|
|
|
APPLY_DEPARTMENT_NAME: '',
|
|
|
|
|
APPLY_USER_ID: '',
|
|
|
|
|
APPLY_USER_NAME: '',
|
|
|
|
|
JOB_NUMBER: '',
|
|
|
|
|
APPLICATION_DATE: '',
|
|
|
|
|
JOB_TYPE_INDEX: '',
|
|
|
|
|
JOB_TYPE_ID: '',
|
|
|
|
|
JOB_TYPE_NAME: '',
|
|
|
|
|
HOT_WORK_POSITION: '',
|
|
|
|
|
HOT_WORK_METHOD_INDEX: '',
|
|
|
|
|
HOT_WORK_METHOD_ID: '',
|
|
|
|
|
HOT_WORK_METHOD_NAME: '',
|
|
|
|
|
HOT_WORK_LEVEL_INDEX: '',
|
|
|
|
|
HOT_WORK_LEVEL_ID: '',
|
|
|
|
|
HOT_WORK_LEVEL_NAME: '',
|
|
|
|
|
HOT_WORK_APPLICATION_DEPARTMENT_ID: '',
|
|
|
|
|
HOT_WORK_APPLICATION_DEPARTMENT_NAME: '',
|
|
|
|
|
DEPARTMENT_PERSONNEL_INDEX: '',
|
|
|
|
|
DEPARTMENT_PERSONNEL_ID: '',
|
|
|
|
|
DEPARTMENT_PERSONNEL_NAME: '',
|
|
|
|
|
JOB_CONTENT: '',
|
|
|
|
|
SITE_LEADER_DEPARTMENT_ID: '',
|
|
|
|
|
SITE_LEADER_DEPARTMENT_NAME: '',
|
|
|
|
|
SITE_LEADER_INDEX: '',
|
|
|
|
|
SITE_LEADER_ID: '',
|
|
|
|
|
SITE_LEADER_NAME: '',
|
|
|
|
|
SITE_LEADER_PHONE: '',
|
|
|
|
|
SUPERVISOR_OF_HOT_WORK_UNIT: '',
|
|
|
|
|
HOT_WORK_TIME: '',
|
|
|
|
|
WORK_LONGITUDE: '',
|
|
|
|
|
WORK_LATITUDE: '',
|
|
|
|
|
HOT_WORK_UNIT_LEADER_DEPARTMENT_ID: '',
|
|
|
|
|
HOT_WORK_UNIT_LEADER_DEPARTMENT_NAME: '',
|
|
|
|
|
HOT_WORK_UNIT_LEADER_INDEX: '',
|
|
|
|
|
HOT_WORK_UNIT_LEADER_ID: '',
|
|
|
|
|
HOT_WORK_UNIT_LEADER_NAME: '',
|
|
|
|
|
HOT_WORK_UNIT_LEADER_PHONE: '',
|
|
|
|
|
UNIT_LEADER_DEPARTMENT_ID: '',
|
|
|
|
|
UNIT_LEADER_DEPARTMENT_NAME: '',
|
|
|
|
|
UNIT_LEADER_INDEX: '',
|
|
|
|
|
UNIT_LEADER_ID: '',
|
|
|
|
|
UNIT_LEADER_NAME: '',
|
|
|
|
|
UNIT_LEADER_PHONE: '',
|
|
|
|
|
PROJECT_UNIT_LEADER_DEPARTMENT_ID: '',
|
|
|
|
|
PROJECT_UNIT_LEADER_DEPARTMENT_NAME: '',
|
|
|
|
|
PROJECT_UNIT_LEADER_INDEX: '',
|
|
|
|
|
PROJECT_UNIT_LEADER_ID: '',
|
|
|
|
|
PROJECT_UNIT_LEADER_NAME: '',
|
|
|
|
|
PROJECT_UNIT_LEADER_PHONE: '',
|
|
|
|
|
HOT_WORK_PERMIT_ISSUING_UNIT: '',
|
|
|
|
|
HOT_WORK_OPERATOR_ID: [],
|
|
|
|
|
HOT_WORK_OPERATOR_NAME: [],
|
|
|
|
|
LEADER_DEPARTMENT_ID: '',
|
|
|
|
|
LEADER_DEPARTMENT_NAME: '',
|
|
|
|
|
LEADER_USER_ID: '',
|
|
|
|
|
LEADER_USER_NAME: '',
|
|
|
|
|
LEADER_USER_PHONE: '',
|
|
|
|
|
LEADER_USER_INDEX: '',
|
|
|
|
|
HOT_WORK_DEPARTMENT_ID: '',
|
|
|
|
|
HOT_WORK_DEPARTMENT_NAME: '',
|
|
|
|
|
HOT_WORK_PERSONNEL_INDEX: '',
|
|
|
|
|
HOT_WORK_USER_ID: '',
|
|
|
|
|
HOT_WORK_USER_NAME: '',
|
|
|
|
|
IS_SAFETY_DIRECTOR: '0',
|
|
|
|
|
SAFETY_DIRECTOR_DEPARTMENT_ID: '',
|
|
|
|
|
SAFETY_DIRECTOR_DEPARTMENT_NAME: '',
|
|
|
|
|
SAFETY_DIRECTOR_INDEX: '',
|
|
|
|
|
SAFETY_DIRECTOR_USER_ID: '',
|
|
|
|
|
SAFETY_DIRECTOR_USER_NAME: '',
|
|
|
|
|
SAFETY_DIRECTOR_PHONE: '',
|
|
|
|
|
IS_GAS_TESTING: '0',
|
|
|
|
|
GAS_TESTING_DEPARTMENT_ID: '',
|
|
|
|
|
GAS_TESTING_DEPARTMENT_NAME: '',
|
|
|
|
|
GAS_TESTING_INDEX: '',
|
|
|
|
|
GAS_TESTING_USER_ID: '',
|
|
|
|
|
GAS_TESTING_USER_NAME: '',
|
|
|
|
|
GAS_TESTING_USER_PHONE: '',
|
|
|
|
|
ISSUING_DEPARTMENT_ID: '',
|
|
|
|
|
ISSUING_DEPARTMENT_NAME: '',
|
|
|
|
|
ISSUING_INDEX: '',
|
|
|
|
|
ISSUING_USER_ID: '',
|
|
|
|
|
ISSUING_USER_NAME: '',
|
|
|
|
|
ISSUING_USER_PHONE: '',
|
|
|
|
|
CHARGECONFIRM_DEPT_ID: '',
|
|
|
|
|
CHARGECONFIRM_DEPT_NAME: '',
|
|
|
|
|
CHARGECONFIRM_USER_NAME: '',
|
|
|
|
|
CHARGECONFIRM_USER_ID: '',
|
|
|
|
|
CHARGECONFIRM_INDEX: '',
|
|
|
|
|
CHARGECONFIRM_PHONE: '',
|
|
|
|
|
},
|
|
|
|
|
rules: [
|
|
|
|
|
{name: 'APPLY_DEPARTMENT_NAME', message: '请输入申请单位'},
|
|
|
|
|
{name: 'APPLY_USER_NAME', message: '请输入申请办理人'},
|
|
|
|
|
{name: 'JOB_NUMBER', message: '请输入作业编号'},
|
|
|
|
|
{name: 'APPLICATION_DATE', message: '请选择申请日期'},
|
|
|
|
|
{name: 'JOB_TYPE_ID', message: '请选择作业类型'},
|
|
|
|
|
{name: 'HOT_WORK_POSITION', message: '请输入动火部位'},
|
|
|
|
|
{name: 'HOT_WORK_METHOD_ID', message: '请选择动火方法'},
|
|
|
|
|
{name: 'HOT_WORK_LEVEL_ID', message: '请选择动火作业级别'},
|
|
|
|
|
{name: 'JOB_CONTENT', message: '请输入作业内容'},
|
|
|
|
|
{name: 'HOT_WORK_TIME', message: '请选择动火时间'},
|
|
|
|
|
],
|
|
|
|
|
treeNode: [],
|
|
|
|
|
forbidEdit: false,
|
|
|
|
|
todayDate: formatDate(new Date(), 'yyyy-MM-dd hh:mm'),
|
|
|
|
|
jobTypeList: [
|
|
|
|
|
{id: '0', name: '内部作业'},
|
|
|
|
|
{id: '1', name: '单项发包作业'},
|
|
|
|
|
],
|
|
|
|
|
hotWorkMethodList: [],
|
|
|
|
|
hotWorkLevelList: [
|
|
|
|
|
{id: '0', name: '特级'},
|
|
|
|
|
{id: '1', name: '一级'},
|
|
|
|
|
{id: '2', name: '二级'},
|
|
|
|
|
{id: '3', name: '三级'},
|
|
|
|
|
],
|
|
|
|
|
hotWorkUserList: [],
|
|
|
|
|
departmentPersonnelList: [],
|
|
|
|
|
siteLeaderList: [],
|
|
|
|
|
hotWorkUnitLeaderList: [],
|
|
|
|
|
unitLeaderList: [],
|
|
|
|
|
hotWorkLssuedLisr: [],
|
|
|
|
|
projectUnitLeaderList: [],
|
|
|
|
|
chargeConfirmList: [],
|
|
|
|
|
issunigUserList: [],
|
|
|
|
|
hotWorkOperatorDepartmentList: [],
|
|
|
|
|
safetyDirectorList: [],
|
|
|
|
|
gasTestingList: [],
|
|
|
|
|
cityIndex: 0,
|
|
|
|
|
showAddOther: false,
|
|
|
|
|
other: [],
|
|
|
|
|
otherUserList: [],
|
|
|
|
|
addModal: false,
|
|
|
|
|
addOtherInput: {
|
|
|
|
|
DEPTNAME: '',
|
|
|
|
|
USERNAME: '',
|
|
|
|
|
userImgList: [],
|
|
|
|
|
cardImgList: []
|
|
|
|
|
},
|
|
|
|
|
addSpecial: false,
|
|
|
|
|
addSpecialInput: {
|
|
|
|
|
DEPTNAME: '',
|
|
|
|
|
USERNAME: '',
|
|
|
|
|
userImgList: [],
|
|
|
|
|
cardImgList: []
|
|
|
|
|
},
|
|
|
|
|
temID: ''
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
onLoad(event) {
|
|
|
|
|
if (event.id) {
|
|
|
|
|
this.form.HOTWORKAPPLICATION_ID = event.id
|
|
|
|
|
this.getData();
|
|
|
|
|
} else {
|
|
|
|
|
// 初始化作业负责人
|
|
|
|
|
this.form.APPLY_DEPARTMENT_ID = loginUser.DEPARTMENT_ID;
|
|
|
|
|
this.form.APPLY_DEPARTMENT_NAME = loginUser.DEPARTMENT_NAME;
|
|
|
|
|
this.form.APPLY_USER_ID = loginUser.USER_ID;
|
|
|
|
|
this.form.APPLY_USER_NAME = loginUser.NAME;
|
|
|
|
|
// this.form.SITE_LEADER_PHONE = loginUser.USERNAME;
|
|
|
|
|
}
|
|
|
|
|
loginSession();
|
|
|
|
|
this.getDept()
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
getData() {
|
|
|
|
|
var _this = this;
|
|
|
|
|
uni.showLoading({
|
|
|
|
|
title: '请稍候'
|
|
|
|
|
})
|
|
|
|
|
uni.request({
|
|
|
|
|
url: basePath + '/app/hotworkapplication/goEdit',
|
|
|
|
|
method: 'POST',
|
|
|
|
|
header: {
|
|
|
|
|
'Content-type': 'application/x-www-form-urlencoded'
|
|
|
|
|
},
|
|
|
|
|
data: {
|
|
|
|
|
HOTWORKAPPLICATION_ID: _this.form.HOTWORKAPPLICATION_ID,
|
|
|
|
|
},
|
|
|
|
|
success: (res) => {
|
|
|
|
|
if ("success" == res.data.result) {
|
|
|
|
|
this.form = res.data.pd;
|
|
|
|
|
let HOT_WORK_OPERATOR_NAME = res.data.pd.HOT_WORK_OPERATOR_NAME
|
|
|
|
|
this.form.HOT_WORK_OPERATOR_NAME = HOT_WORK_OPERATOR_NAME.substring(0, HOT_WORK_OPERATOR_NAME.length - 1).split(',');
|
|
|
|
|
// this.msg = 'edit';
|
|
|
|
|
this.forbidEdit = true;
|
|
|
|
|
uni.hideLoading();
|
|
|
|
|
} else if ("exception" == res.data.result) {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
title: '错误',
|
|
|
|
|
duration: 2000
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
goSubmit(STATUS) {
|
|
|
|
|
var _this = this;
|
|
|
|
|
let required = true
|
|
|
|
|
if (STATUS == 1) {
|
|
|
|
|
this.rules.map(({name, message}) => {
|
|
|
|
|
if (!this.form[name]) {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
icon: 'none',
|
|
|
|
|
title: message,
|
|
|
|
|
duration: 1500
|
|
|
|
|
});
|
|
|
|
|
required = false
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
if (this.form.hotWorkLevelID == '0') {
|
|
|
|
|
if (!this.form.HOT_WORK_APPLICATION_DEPARTMENT_ID) {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
icon: 'none',
|
|
|
|
|
title: '请选择动火申请部门',
|
|
|
|
|
duration: 1500
|
|
|
|
|
});
|
|
|
|
|
required = false
|
|
|
|
|
}
|
|
|
|
|
if (!this.form.DEPARTMENT_PERSONNEL_ID) {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
icon: 'none',
|
|
|
|
|
title: '请选择部门人员',
|
|
|
|
|
duration: 1500
|
|
|
|
|
});
|
|
|
|
|
required = false
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
if (this.form.JOB_TYPE_ID == '1' && !this.form.PROJECT_UNIT_LEADER_ID) {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
icon: 'none',
|
|
|
|
|
title: '请选择项目发包单位负责人',
|
|
|
|
|
duration: 1500
|
|
|
|
|
});
|
|
|
|
|
required = false
|
|
|
|
|
}
|
|
|
|
|
if (this.form.HOT_WORK_OPERATOR_ID.length === 0) {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
icon: 'none',
|
|
|
|
|
title: '请选择动火操作人',
|
|
|
|
|
duration: 1500
|
|
|
|
|
});
|
|
|
|
|
required = false
|
|
|
|
|
}
|
|
|
|
|
if (this.form.HOT_WORK_METHOD_NAME == '电焊') {
|
|
|
|
|
if (this.form.HOT_WORK_OPERATOR_ID.length === 0) {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
icon: 'none',
|
|
|
|
|
title: '请选择特种作业动火操作人',
|
|
|
|
|
duration: 1500
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
if (!required) {
|
|
|
|
|
return
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
var operatorUser = ''
|
|
|
|
|
_this.other.forEach((item) => {
|
|
|
|
|
operatorUser += item.USER_ID + ';'
|
|
|
|
|
// operatorUser += item.
|
|
|
|
|
})
|
|
|
|
|
uni.showLoading({
|
|
|
|
|
title: '请稍候'
|
|
|
|
|
})
|
|
|
|
|
uni.request({
|
|
|
|
|
url: basePath + "/app/hotworkapplication/" + _this.msg,
|
|
|
|
|
method: 'POST',
|
|
|
|
|
dataType: 'json',
|
|
|
|
|
header: {
|
|
|
|
|
'Content-type': 'application/x-www-form-urlencoded'
|
|
|
|
|
},
|
|
|
|
|
// mode.forEach((item) => {
|
|
|
|
|
// modestr += (item + '-' + type + ',')
|
|
|
|
|
// })
|
|
|
|
|
|
|
|
|
|
data: {
|
|
|
|
|
...this.form,
|
|
|
|
|
STATUS,
|
|
|
|
|
CORPINFO_ID: corpinfoId,
|
|
|
|
|
operatorUser: operatorUser
|
|
|
|
|
},
|
|
|
|
|
success: (res) => {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
icon: 'none',
|
|
|
|
|
title: '保存成功',
|
|
|
|
|
duration: 2000
|
|
|
|
|
});
|
|
|
|
|
_this.goback()
|
|
|
|
|
},
|
|
|
|
|
fail: (err) => {
|
|
|
|
|
uni.hideLoading();
|
|
|
|
|
uni.showModal({
|
|
|
|
|
content: err.errMsg,
|
|
|
|
|
showCancel: false
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
hotWorkChange(e) {
|
|
|
|
|
console.info(e)
|
|
|
|
|
|
|
|
|
|
console.info(this.hotWorkUserList[e.detail.value])
|
|
|
|
|
this.form.HOT_WORK_PERSONNEL_INDEX = e.detail.value
|
|
|
|
|
this.form.HOT_WORK_USER_NAME = this.hotWorkUserList[e.detail.value].NAME
|
|
|
|
|
this.form.HOT_WORK_USER_ID = this.hotWorkUserList[e.detail.value].USER_ID
|
|
|
|
|
this.form.HOT_WORK_USER_PHONE = this.hotWorkUserList[e.detail.value].USERNAME
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
jobTypeChange(e) {
|
|
|
|
|
this.form.JOB_TYPE_INDEX = e.detail.value
|
|
|
|
|
this.form.JOB_TYPE_NAME = this.jobTypeList[e.detail.value].name
|
|
|
|
|
this.form.JOB_TYPE_ID = this.jobTypeList[e.detail.value].id
|
|
|
|
|
},
|
|
|
|
|
hotWorkMethodChange(e) {
|
|
|
|
|
this.form.HOT_WORK_METHOD_INDEX = e.detail.value
|
|
|
|
|
this.form.HOT_WORK_METHOD_NAME = this.hotWorkMethodList[e.detail.value].NAME
|
|
|
|
|
this.form.HOT_WORK_METHOD_ID = this.hotWorkMethodList[e.detail.value].DICTIONARIES_ID
|
|
|
|
|
},
|
|
|
|
|
hotWorkLevelChange(e) {
|
|
|
|
|
this.form.HOT_WORK_LEVEL_INDEX = e.detail.value
|
|
|
|
|
this.form.HOT_WORK_LEVEL_NAME = this.hotWorkLevelList[e.detail.value].name
|
|
|
|
|
this.form.HOT_WORK_LEVEL_ID = this.hotWorkLevelList[e.detail.value].id
|
|
|
|
|
},
|
|
|
|
|
departmentPersonnelChange(e) {
|
|
|
|
|
this.form.DEPARTMENT_PERSONNEL_INDEX = e.detail.value;
|
|
|
|
|
this.form.DEPARTMENT_PERSONNEL_ID = this.departmentPersonnelList[e.detail.value].USER_ID;
|
|
|
|
|
this.form.DEPARTMENT_PERSONNEL_NAME = this.departmentPersonnelList[e.detail.value].NAME;
|
|
|
|
|
},
|
|
|
|
|
siteLeaderChange(e) {
|
|
|
|
|
this.form.SITE_LEADER_INDEX = e.detail.value;
|
|
|
|
|
this.form.SITE_LEADER_ID = this.siteLeaderList[e.detail.value].USER_ID;
|
|
|
|
|
this.form.SITE_LEADER_NAME = this.siteLeaderList[e.detail.value].NAME;
|
|
|
|
|
this.form.SITE_LEADER_PHONE = this.siteLeaderList[e.detail.value].USERNAME;
|
|
|
|
|
},
|
|
|
|
|
hotWorkUnitLeaderChange(e) {
|
|
|
|
|
this.form.HOT_WORK_UNIT_LEADER_INDEX = e.detail.value;
|
|
|
|
|
this.form.HOT_WORK_UNIT_LEADER_ID = this.hotWorkUnitLeaderList[e.detail.value].USER_ID;
|
|
|
|
|
this.form.HOT_WORK_UNIT_LEADER_NAME = this.hotWorkUnitLeaderList[e.detail.value].NAME;
|
|
|
|
|
this.form.HOT_WORK_UNIT_LEADER_PHONE = this.hotWorkUnitLeaderList[e.detail.value].USERNAME;
|
|
|
|
|
},
|
|
|
|
|
unitLeaderChange(e) {
|
|
|
|
|
this.form.UNIT_LEADER_INDEX = e.detail.value;
|
|
|
|
|
this.form.UNIT_LEADER_ID = this.unitLeaderList[e.detail.value].USER_ID;
|
|
|
|
|
this.form.UNIT_LEADER_NAME = this.unitLeaderList[e.detail.value].NAME;
|
|
|
|
|
this.form.UNIT_LEADER_PHONE = this.unitLeaderList[e.detail.value].USERNAME;
|
|
|
|
|
},
|
|
|
|
|
hotWorkLeaderLeaderChange(e) {
|
|
|
|
|
this.form.HOT_WORK_UNIT_LEADER_INDEX = e.detail.value;
|
|
|
|
|
this.form.LEADER_USER_ID = this.hotWorkLssuedLisr[e.detail.value].USER_ID;
|
|
|
|
|
this.form.LEADER_USER_NAME = this.hotWorkLssuedLisr[e.detail.value].NAME;
|
|
|
|
|
this.form.HOT_WORK_DEPARTMENT_PHONE = this.hotWorkLssuedLisr[e.detail.value].USERNAME;
|
|
|
|
|
},
|
|
|
|
|
projectUnitLeaderChange(e) {
|
|
|
|
|
this.form.PROJECT_UNIT_LEADER_INDEX = e.detail.value;
|
|
|
|
|
this.form.PROJECT_UNIT_LEADER_ID = this.projectUnitLeaderList[e.detail.value].USER_ID;
|
|
|
|
|
this.form.PROJECT_UNIT_LEADER_NAME = this.projectUnitLeaderList[e.detail.value].NAME;
|
|
|
|
|
this.form.PROJECT_UNIT_LEADER_PHONE = this.projectUnitLeaderList[e.detail.value].USERNAME;
|
|
|
|
|
},
|
|
|
|
|
safetyDirectorChange(e) {
|
|
|
|
|
this.form.SAFETY_DIRECTOR_INDEX = e.detail.value;
|
|
|
|
|
this.form.SAFETY_DIRECTOR_USER_ID = this.safetyDirectorList[e.detail.value].USER_ID;
|
|
|
|
|
this.form.SAFETY_DIRECTOR_USER_NAME = this.safetyDirectorList[e.detail.value].NAME;
|
|
|
|
|
this.form.SAFETY_DIRECTOR_PHONE = this.safetyDirectorList[e.detail.value].USERNAME;
|
|
|
|
|
},
|
|
|
|
|
gasTestingChange(e) {
|
|
|
|
|
this.form.GAS_TESTING_INDEX = e.detail.value;
|
|
|
|
|
this.form.GAS_TESTING_USER_ID = this.gasTestingList[e.detail.value].USER_ID;
|
|
|
|
|
this.form.GAS_TESTING_USER_NAME = this.gasTestingList[e.detail.value].NAME;
|
|
|
|
|
this.form.GAS_TESTING_USER_PHONE = this.gasTestingList[e.detail.value].USERNAME;
|
|
|
|
|
},
|
|
|
|
|
issungChange(e) {
|
|
|
|
|
this.form.ISSUING_INDEX = e.detail.value;
|
|
|
|
|
this.form.ISSUING_USER_ID = this.issunigUserList[e.detail.value].USER_ID;
|
|
|
|
|
this.form.ISSUING_USER_NAME = this.issunigUserList[e.detail.value].NAME;
|
|
|
|
|
this.form.ISSUING_USER_PHONE = this.issunigUserList[e.detail.value].USERNAME;
|
|
|
|
|
},
|
|
|
|
|
chargeConfirmChange(e) {
|
|
|
|
|
this.form.CHARGECONFIRM_INDEX = e.detail.value;
|
|
|
|
|
this.form.CHARGECONFIRM_USER_ID = this.chargeConfirmList[e.detail.value].USER_ID;
|
|
|
|
|
this.form.CHARGECONFIRM_USER_NAME = this.chargeConfirmList[e.detail.value].NAME;
|
|
|
|
|
this.form.CHARGECONFIRM_PHONE = this.chargeConfirmList[e.detail.value].USERNAME;
|
|
|
|
|
},
|
|
|
|
|
hotWorkOperatorSelectShow() {
|
|
|
|
|
|
|
|
|
|
this.$refs.cityMore.open();
|
|
|
|
|
},
|
|
|
|
|
hotWorkOperatorSelectHide(type) {
|
|
|
|
|
var _this = this
|
|
|
|
|
var copyother = _this.other
|
|
|
|
|
_this.other = []
|
|
|
|
|
for (let i = 0; i < copyother.length; i++) {
|
|
|
|
|
if (copyother[i].TYPE != '1') {
|
|
|
|
|
_this.other.push(copyother[i]);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
for (let i = 0; i < _this.form.HOT_WORK_OPERATOR_ID.length; i++) {
|
|
|
|
|
let o = {
|
|
|
|
|
"STATE": '1',
|
|
|
|
|
"USER_ID": this.form.HOT_WORK_OPERATOR_ID[i],
|
|
|
|
|
"USER_NAME": this.form.HOT_WORK_OPERATOR_NAME[i]
|
|
|
|
|
};
|
|
|
|
|
_this.other.push(o);
|
|
|
|
|
}
|
|
|
|
|
this.$refs.cityMore.close();
|
|
|
|
|
},
|
|
|
|
|
switchCity(index) {
|
|
|
|
|
this.cityIndex = index
|
|
|
|
|
},
|
|
|
|
|
chooseCity(item) { // 点击选择特种作业人员
|
|
|
|
|
console.info(item)
|
|
|
|
|
if (this.form.HOT_WORK_OPERATOR_ID.indexOf(item.id) == -1) { // 如果没有找到匹配的字符串则返回 -1。
|
|
|
|
|
this.form.HOT_WORK_OPERATOR_ID.push(item.id)
|
|
|
|
|
this.form.HOT_WORK_OPERATOR_NAME.push(item.name)
|
|
|
|
|
} else {
|
|
|
|
|
this.form.HOT_WORK_OPERATOR_ID.splice(this.form.HOT_WORK_OPERATOR_ID.indexOf(item.id), 1)
|
|
|
|
|
this.form.HOT_WORK_OPERATOR_NAME.splice(this.form.HOT_WORK_OPERATOR_NAME.indexOf(item.name), 1)
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
changeApplicationDate(e) {
|
|
|
|
|
this.form.APPLICATION_DATE = e
|
|
|
|
|
},
|
|
|
|
|
changehotWorkTime(e) {
|
|
|
|
|
this.form.HOT_WORK_TIME = e
|
|
|
|
|
},
|
|
|
|
|
getDept() {
|
|
|
|
|
var _this = this;
|
|
|
|
|
uni.request({
|
|
|
|
|
url: basePath + '/app/sys/listTree', //部门下拉接口
|
|
|
|
|
method: 'POST',
|
|
|
|
|
dataType: 'json',
|
|
|
|
|
header: {
|
|
|
|
|
'Content-type': 'application/x-www-form-urlencoded'
|
|
|
|
|
},
|
|
|
|
|
data: {
|
|
|
|
|
CORPINFO_ID: corpinfoId,
|
|
|
|
|
},
|
|
|
|
|
success: (res) => {
|
|
|
|
|
if ("success" == res.data.result) {
|
|
|
|
|
_this.treeNode = eval(res.data.zTreeNodes);
|
|
|
|
|
} else {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
title: res.data.message,
|
|
|
|
|
duration: 2000
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
uni.request({
|
|
|
|
|
url: basePath + '/app/relevantunit/listAllTree',
|
|
|
|
|
method: 'POST',
|
|
|
|
|
dataType: 'json',
|
|
|
|
|
header: {
|
|
|
|
|
'Content-type': 'application/x-www-form-urlencoded'
|
|
|
|
|
},
|
|
|
|
|
data: {
|
|
|
|
|
CORPINFO_ID: corpinfoId,
|
|
|
|
|
},
|
|
|
|
|
success: (res) => {
|
|
|
|
|
if ("success" === res.data.result) {
|
|
|
|
|
_this.hotWorkOperatorDepartmentList = JSON.parse(res.data.varList);
|
|
|
|
|
} else {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
title: res.data.message,
|
|
|
|
|
duration: 2000
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
uni.request({
|
|
|
|
|
url: basePath + '/dictionaries/getLevels',
|
|
|
|
|
method: 'POST',
|
|
|
|
|
dataType: 'json',
|
|
|
|
|
header: {
|
|
|
|
|
'Content-type': 'application/x-www-form-urlencoded'
|
|
|
|
|
},
|
|
|
|
|
data: {
|
|
|
|
|
DICTIONARIES_ID: "63cf39931a89467594efc441bf67f6dd",
|
|
|
|
|
},
|
|
|
|
|
success: (res) => {
|
|
|
|
|
if ("success" === res.data.result) {
|
|
|
|
|
_this.hotWorkMethodList = res.data.list
|
|
|
|
|
} else {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
title: res.data.message,
|
|
|
|
|
duration: 2000
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
showZgTree(ref) {
|
|
|
|
|
this.$refs[ref]._show();
|
|
|
|
|
},
|
|
|
|
|
zgtreeConfirm(e, list) {
|
|
|
|
|
if (list === "hotWorkUserList") {
|
|
|
|
|
this.form.HOT_WORK_DEPARTMENT_ID = e[0].id;
|
|
|
|
|
this.form.HOT_WORK_DEPARTMENT_NAME = e[0].name;
|
|
|
|
|
this.form.HOT_WORK_PERSONNEL_INDEX = '';
|
|
|
|
|
this.form.HOT_WORK_USER_ID = '';
|
|
|
|
|
this.form.HOT_WORK_USER_NAME = '';
|
|
|
|
|
}
|
|
|
|
|
if (list === "projectUnitLeaderList") {
|
|
|
|
|
this.form.PROJECT_UNIT_LEADER_DEPARTMENT_ID = e[0].id;
|
|
|
|
|
this.form.PROJECT_UNIT_LEADER_DEPARTMENT_NAME = e[0].name;
|
|
|
|
|
this.form.PROJECT_UNIT_LEADER_INDEX = '';
|
|
|
|
|
this.form.PROJECT_UNIT_LEADER_ID = '';
|
|
|
|
|
this.form.PROJECT_UNIT_LEADER_NAME = '';
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
if (list === "safetyDirectorList") {
|
|
|
|
|
this.form.SAFETY_DIRECTOR_DEPARTMENT_ID = e[0].id;
|
|
|
|
|
this.form.SAFETY_DIRECTOR_DEPARTMENT_NAME = e[0].name;
|
|
|
|
|
this.form.SAFETY_DIRECTOR_INDEX = '';
|
|
|
|
|
this.form.SAFETY_DIRECTOR_USER_ID = '';
|
|
|
|
|
this.form.SAFETY_DIRECTOR_USER_NAME = '';
|
|
|
|
|
}
|
|
|
|
|
if (list === "gasTestingList") {
|
|
|
|
|
this.form.GAS_TESTING_DEPARTMENT_ID = e[0].id;
|
|
|
|
|
this.form.GAS_TESTING_DEPARTMENT_NAME = e[0].name;
|
|
|
|
|
this.form.GAS_TESTING_INDEX = '';
|
|
|
|
|
this.form.GAS_TESTING_USER_ID = '';
|
|
|
|
|
this.form.GAS_TESTING_USER_NAME = '';
|
|
|
|
|
}
|
|
|
|
|
if (list === "issunigUserList") {
|
|
|
|
|
this.form.ISSUING_DEPARTMENT_ID = e[0].id;
|
|
|
|
|
this.form.ISSUING_DEPARTMENT_NAME = e[0].name;
|
|
|
|
|
this.form.ISSUING_INDEX = '';
|
|
|
|
|
this.form.ISSUING_USER_ID = '';
|
|
|
|
|
this.form.ISSUING_USER_NAME = '';
|
|
|
|
|
}
|
|
|
|
|
// ===================
|
|
|
|
|
if (list === "departmentPersonnelList") {
|
|
|
|
|
this.form.HOT_WORK_APPLICATION_DEPARTMENT_ID = e[0].id;
|
|
|
|
|
this.form.HOT_WORK_APPLICATION_DEPARTMENT_NAME = e[0].name;
|
|
|
|
|
this.form.DEPARTMENT_PERSONNEL_INDEX = '';
|
|
|
|
|
this.form.DEPARTMENT_PERSONNEL_ID = '';
|
|
|
|
|
this.form.DEPARTMENT_PERSONNEL_NAME = '';
|
|
|
|
|
}
|
|
|
|
|
if (list === "siteLeaderList") {
|
|
|
|
|
this.form.SITE_LEADER_DEPARTMENT_ID = e[0].id;
|
|
|
|
|
this.form.SITE_LEADER_DEPARTMENT_NAME = e[0].name;
|
|
|
|
|
this.form.SITE_LEADER_INDEX = '';
|
|
|
|
|
this.form.SITE_LEADER_ID = '';
|
|
|
|
|
this.form.SITE_LEADER_NAME = '';
|
|
|
|
|
}
|
|
|
|
|
if (list === "hotWorkUnitLeaderList") {
|
|
|
|
|
this.form.HOT_WORK_UNIT_LEADER_DEPARTMENT_ID = e[0].id;
|
|
|
|
|
this.form.HOT_WORK_UNIT_LEADER_DEPARTMENT_NAME = e[0].name;
|
|
|
|
|
this.form.HOT_WORK_UNIT_LEADER_INDEX = '';
|
|
|
|
|
this.form.HOT_WORK_UNIT_LEADER_ID = '';
|
|
|
|
|
this.form.HOT_WORK_UNIT_LEADER_NAME = '';
|
|
|
|
|
}
|
|
|
|
|
if (list === "unitLeaderList") {
|
|
|
|
|
this.form.UNIT_LEADER_DEPARTMENT_ID = e[0].id;
|
|
|
|
|
this.form.UNIT_LEADER_DEPARTMENT_NAME = e[0].name;
|
|
|
|
|
this.form.UNIT_LEADER_INDEX = '';
|
|
|
|
|
this.form.UNIT_LEADER_ID = '';
|
|
|
|
|
this.form.UNIT_LEADER_NAME = '';
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (list === "hotWorkLssuedLisr") {
|
|
|
|
|
this.form.LEADER_DEPARTMENT_ID = e[0].id;
|
|
|
|
|
this.form.LEADER_DEPARTMENT_NAME = e[0].name;
|
|
|
|
|
this.form.LEADER_USER_ID = '';
|
|
|
|
|
this.form.LEADER_USER_NAME = '';
|
|
|
|
|
}
|
|
|
|
|
if (list === "chargeConfirmList") {
|
|
|
|
|
this.form.CHARGECONFIRM_DEPT_ID = e[0].id;
|
|
|
|
|
this.form.CHARGECONFIRM_DEPT_NAME = e[0].name;
|
|
|
|
|
this.form.CHARGECONFIRM_USER_ID = '';
|
|
|
|
|
this.form.CHARGECONFIRM_USER_NAME = '';
|
|
|
|
|
this.form.CHARGECONFIRM_INDEX = '';
|
|
|
|
|
}
|
|
|
|
|
this.getUserList(list, e[0].id);
|
|
|
|
|
},
|
|
|
|
|
getUserList(list, DEPARTMENT_ID) {
|
|
|
|
|
//发送 post 请求
|
|
|
|
|
var _this = this;
|
|
|
|
|
uni.request({
|
|
|
|
|
method: 'POST',
|
|
|
|
|
dataType: 'json',
|
|
|
|
|
header: {
|
|
|
|
|
'Content-type': 'application/x-www-form-urlencoded'
|
|
|
|
|
},
|
|
|
|
|
url: basePath + '/app/sys/listUser',
|
|
|
|
|
data: {
|
|
|
|
|
DEPARTMENT_ID, NOMAIN: '1',
|
|
|
|
|
tm: new Date().getTime()
|
|
|
|
|
},
|
|
|
|
|
success: function (res) {
|
|
|
|
|
if ("success" == res.data.result) {
|
|
|
|
|
_this[list] = res.data.userList;
|
|
|
|
|
} else {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
title: res.data.message,
|
|
|
|
|
duration: 2000
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
zgtreeCancel(e) {
|
|
|
|
|
this.isUps = false;
|
|
|
|
|
},
|
|
|
|
|
chooseLocation() {
|
|
|
|
|
var _this = this
|
|
|
|
|
uni.navigateTo({
|
2023-12-11 17:15:23 +08:00
|
|
|
|
url: '/pages/map/mapPro',
|
2023-11-07 09:43:46 +08:00
|
|
|
|
events: {
|
|
|
|
|
// 为指定事件添加一个监听器,获取被打开页面传送到当前页面的数据
|
|
|
|
|
acceptDataFromOpenedPage: function (e) {
|
|
|
|
|
_this.form.WORK_LONGITUDE = e.data.longitue;
|
|
|
|
|
_this.form.WORK_LATITUDE = e.data.latitude;
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
goback() {
|
|
|
|
|
uni.navigateBack({
|
|
|
|
|
delta: 1
|
|
|
|
|
});
|
|
|
|
|
uni.hideLoading();
|
|
|
|
|
},
|
|
|
|
|
addOther() {
|
|
|
|
|
this.showAddOther = true
|
|
|
|
|
},
|
|
|
|
|
removeOther(index) {
|
|
|
|
|
var item = this.other [index]
|
|
|
|
|
if (item.TYPE === '1') {
|
|
|
|
|
this.form.HOT_WORK_OPERATOR_ID.splice(this.form.HOT_WORK_OPERATOR_ID.indexOf(item.USER_ID), 1)
|
|
|
|
|
this.form.HOT_WORK_OPERATOR_NAME.splice(this.form.HOT_WORK_OPERATOR_NAME.indexOf(item.USER_NAME), 1)
|
|
|
|
|
} else { //删除临时人员
|
|
|
|
|
uni.request({
|
|
|
|
|
url: basePath + '/app/hotworkapplication/deleteTem',
|
|
|
|
|
method: 'POST',
|
|
|
|
|
dataType: 'json',
|
|
|
|
|
header: {
|
|
|
|
|
'Content-type': 'application/x-www-form-urlencoded'
|
|
|
|
|
},
|
|
|
|
|
data: {
|
|
|
|
|
"SPECIALUSER_ID": item.USER_ID,
|
|
|
|
|
"FOREIGN_KEY": item.USER_ID
|
|
|
|
|
},
|
|
|
|
|
success: (res) => {
|
|
|
|
|
if ("success" === res.data.result) {
|
|
|
|
|
} else {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
title: res.data.message,
|
|
|
|
|
duration: 2000
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
this.other.splice(index, 1);
|
|
|
|
|
this.otherUserList.splice(index, 1);
|
|
|
|
|
},
|
|
|
|
|
addOtherInputAdd() {
|
|
|
|
|
this.addModal = true
|
|
|
|
|
this.addOtherInput = {}
|
|
|
|
|
},
|
|
|
|
|
addOtherInputSubmit() {
|
|
|
|
|
if (this.addOtherInput.USERNAME == '' || undefined == this.addOtherInput.USERNAME) {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
icon: 'none',
|
|
|
|
|
title: '请输入姓名',
|
|
|
|
|
duration: 2000
|
|
|
|
|
});
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
uni.request({
|
|
|
|
|
url: basePath + '/app/hotworkapplication/addTemUser',
|
|
|
|
|
method: 'POST',
|
|
|
|
|
dataType: 'json',
|
|
|
|
|
header: {
|
|
|
|
|
'Content-type': 'application/x-www-form-urlencoded'
|
|
|
|
|
},
|
|
|
|
|
data: {
|
|
|
|
|
"USER_TYPE": '4',
|
|
|
|
|
"USER_ID": '',
|
|
|
|
|
"TEM_USER_NAME": this.addOtherInput.USERNAME,
|
|
|
|
|
loginUserId: loginUserId,
|
|
|
|
|
},
|
|
|
|
|
success: (res) => {
|
|
|
|
|
if ("success" === res.data.result) {
|
|
|
|
|
let o = {
|
|
|
|
|
"SPECIALUSER_ID": res.data.pd.SPECIALUSER_ID,
|
|
|
|
|
"USER_TYPE": '4',
|
|
|
|
|
"USER_ID": res.data.pd.SPECIALUSER_ID,
|
|
|
|
|
"USER_NAME": this.addOtherInput.USERNAME
|
|
|
|
|
};
|
|
|
|
|
this.other.push(o);
|
|
|
|
|
} else {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
title: res.data.message,
|
|
|
|
|
duration: 2000
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
this.addModal = false
|
|
|
|
|
},
|
|
|
|
|
addSpecialInputAdd() {
|
|
|
|
|
this.addSpecial = true
|
|
|
|
|
this.addSpecialInput = {
|
|
|
|
|
DEPTNAME: '',
|
|
|
|
|
USERNAME: '',
|
|
|
|
|
userImgList: [],
|
|
|
|
|
cardImgList: []
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
addSpecialInputSubmit() {
|
|
|
|
|
if (this.addSpecialInput.DEPTNAME == '' || undefined == this.addSpecialInput.DEPTNAME) {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
icon: 'none',
|
|
|
|
|
title: '请输入人员单位',
|
|
|
|
|
duration: 2000
|
|
|
|
|
});
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if (this.addSpecialInput.USERNAME == '' || undefined == this.addSpecialInput.USERNAME) {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
icon: 'none',
|
|
|
|
|
title: '请输入人员姓名',
|
|
|
|
|
duration: 2000
|
|
|
|
|
});
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if (this.addSpecialInput.userImgList.length === 0) {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
icon: 'none',
|
|
|
|
|
title: '请上传人员照片',
|
|
|
|
|
duration: 2000
|
|
|
|
|
});
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if (this.addSpecialInput.cardImgList.length === 0) {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
icon: 'none',
|
|
|
|
|
title: '请上传证件照片',
|
|
|
|
|
duration: 2000
|
|
|
|
|
});
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
//先上传人员信息
|
|
|
|
|
uni.request({
|
|
|
|
|
url: basePath + '/app/hotworkapplication/addTemUser',
|
|
|
|
|
method: 'POST',
|
|
|
|
|
dataType: 'json',
|
|
|
|
|
header: {
|
|
|
|
|
'Content-type': 'application/x-www-form-urlencoded'
|
|
|
|
|
},
|
|
|
|
|
data: {
|
|
|
|
|
"USER_TYPE": '3',
|
|
|
|
|
"USER_ID": '',
|
|
|
|
|
"TEM_USER_NAME": this.addSpecialInput.USERNAME,
|
|
|
|
|
"TEM_USER_DEPT_NAME": this.addSpecialInput.DEPTNAME,
|
|
|
|
|
loginUserId: loginUserId,
|
|
|
|
|
},
|
|
|
|
|
success: (res) => {
|
|
|
|
|
if ("success" === res.data.result) {
|
|
|
|
|
//上传照片
|
|
|
|
|
this.uploadImg(this.addSpecialInput.userImgList, '201', res.data.pd.SPECIALUSER_ID)
|
|
|
|
|
this.uploadImg(this.addSpecialInput.cardImgList, '202', res.data.pd.SPECIALUSER_ID)
|
|
|
|
|
let o = {
|
|
|
|
|
"USER_TYPE": '3',
|
|
|
|
|
"USER_ID": res.data.pd.SPECIALUSER_ID,
|
|
|
|
|
"USER_NAME": this.addSpecialInput.USERNAME,
|
|
|
|
|
"SPECIALUSER_ID": res.data.pd.SPECIALUSER_ID
|
|
|
|
|
};
|
|
|
|
|
this.other.push(o);
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
title: res.data.message,
|
|
|
|
|
duration: 2000
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
this.addSpecial = false
|
|
|
|
|
},
|
|
|
|
|
ChooseImageUser() {
|
|
|
|
|
var _this = this;
|
|
|
|
|
uni.chooseImage({
|
|
|
|
|
count: 1, //默认9
|
|
|
|
|
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
|
|
|
|
sourceType: ['camera', 'album'], //从相册选择
|
|
|
|
|
success: (res) => {
|
|
|
|
|
if (this.addSpecialInput.userImgList.length != 0) {
|
|
|
|
|
this.addSpecialInput.userImgList = this.addSpecialInput.userImgList.concat(res.tempFilePaths)
|
|
|
|
|
} else {
|
|
|
|
|
this.addSpecialInput.userImgList = res.tempFilePaths
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
ViewImageUser(e) {
|
|
|
|
|
uni.previewImage({
|
|
|
|
|
urls: this.addSpecialInput.userImgList,
|
|
|
|
|
current: e.currentTarget.dataset.url
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
DelImgUser(e) {
|
|
|
|
|
uni.showModal({
|
|
|
|
|
title: '双控平台',
|
|
|
|
|
content: '确定要删除这张图片吗?',
|
|
|
|
|
cancelColor: "#000000",
|
|
|
|
|
cancelText: '取消',
|
|
|
|
|
confirmText: '确定',
|
|
|
|
|
success: res => {
|
|
|
|
|
if (res.confirm) {
|
|
|
|
|
this.addSpecialInput.userImgList.splice(e.currentTarget.dataset.index, 1)
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
ChooseImageCard() {
|
|
|
|
|
var _this = this;
|
|
|
|
|
uni.chooseImage({
|
|
|
|
|
count: 1, //默认9
|
|
|
|
|
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
|
|
|
|
sourceType: ['camera', 'album'], //从相册选择
|
|
|
|
|
success: (res) => {
|
|
|
|
|
if (this.addSpecialInput.cardImgList.length != 0) {
|
|
|
|
|
this.addSpecialInput.cardImgList = this.addSpecialInput.cardImgList.concat(res.tempFilePaths)
|
|
|
|
|
} else {
|
|
|
|
|
this.addSpecialInput.cardImgList = res.tempFilePaths
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
ViewImageCard(e) {
|
|
|
|
|
uni.previewImage({
|
|
|
|
|
urls: this.addSpecialInput.cardImgList,
|
|
|
|
|
current: e.currentTarget.dataset.url
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
DelImgCard(e) {
|
|
|
|
|
uni.showModal({
|
|
|
|
|
title: '双控平台',
|
|
|
|
|
content: '确定要删除这张图片吗?',
|
|
|
|
|
cancelColor: "#000000",
|
|
|
|
|
cancelText: '取消',
|
|
|
|
|
confirmText: '确定',
|
|
|
|
|
success: res => {
|
|
|
|
|
if (res.confirm) {
|
|
|
|
|
this.addSpecialInput.cardImgList.splice(e.currentTarget.dataset.index, 1)
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
radioType(e) {
|
|
|
|
|
this.form.IS_SAFETY_DIRECTOR = e.detail.value
|
|
|
|
|
},
|
|
|
|
|
radioType2(e) {
|
|
|
|
|
this.form.IS_GAS_TESTING = e.detail.value
|
|
|
|
|
},
|
|
|
|
|
uploadImg(tempFilePaths, type, key) {
|
|
|
|
|
return new Promise((resolve, reject) => {
|
|
|
|
|
var _this = this;
|
|
|
|
|
if (tempFilePaths.length == 0) {
|
|
|
|
|
resolve();
|
|
|
|
|
}
|
|
|
|
|
uni.showLoading({
|
|
|
|
|
title: '上传中'
|
|
|
|
|
})
|
|
|
|
|
uni.uploadFile({
|
|
|
|
|
url: basePath + '/app/imgfiles/add',
|
|
|
|
|
filePath: tempFilePaths[0],
|
|
|
|
|
name: 'FFILE',
|
|
|
|
|
formData: {
|
|
|
|
|
'TYPE': type,
|
|
|
|
|
'FOREIGN_KEY': key
|
|
|
|
|
},
|
|
|
|
|
success: (res) => {
|
|
|
|
|
uni.hideLoading();
|
|
|
|
|
resolve();
|
|
|
|
|
},
|
|
|
|
|
fail: (err) => {
|
|
|
|
|
uni.hideLoading();
|
|
|
|
|
uni.showModal({
|
|
|
|
|
content: err.errMsg,
|
|
|
|
|
showCancel: false
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
<style>
|
|
|
|
|
.right_icon {
|
|
|
|
|
position: relative;
|
|
|
|
|
padding-right: 36 upx;
|
|
|
|
|
width: 200 upx;
|
|
|
|
|
text-align: right;
|
|
|
|
|
overflow: hidden;
|
|
|
|
|
white-space: nowrap;
|
|
|
|
|
text-overflow: ellipsis;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.right_icon ::after {
|
|
|
|
|
font-family: cuIcon;
|
|
|
|
|
display: block;
|
|
|
|
|
content: "\e6a3";
|
|
|
|
|
position: absolute;
|
|
|
|
|
font-size: 17px;
|
|
|
|
|
color: #8799a3;
|
|
|
|
|
line-height: 50px;
|
|
|
|
|
width: 30px;
|
|
|
|
|
text-align: center;
|
|
|
|
|
top: -28 upx;
|
|
|
|
|
bottom: 0;
|
|
|
|
|
right: -22 upx;
|
|
|
|
|
margin: auto;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.modal_content {
|
|
|
|
|
display: flex;
|
|
|
|
|
text-align: left;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.modal_left {
|
|
|
|
|
flex-basis: 50%;
|
|
|
|
|
padding: 50 upx 20 upx;
|
|
|
|
|
border-right: 1px solid #000000;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.modal_right {
|
|
|
|
|
flex-basis: 50%;
|
|
|
|
|
padding: 50 upx;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.modal_left_title, .modal_right_title {
|
|
|
|
|
font-size: 16px;
|
|
|
|
|
color: #000000;
|
|
|
|
|
font-weight: 700;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.checkbox-item {
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
padding: 0 30 upx;
|
|
|
|
|
min-height: 100 upx;
|
|
|
|
|
background-color: #ffffff;
|
|
|
|
|
border-bottom: 1 upx solid #ddd;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.checkbox-item:last-child {
|
|
|
|
|
border-bottom: none;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.selected {
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
height: 100 upx;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.selected .radio {
|
|
|
|
|
transform: scale(0.8);
|
|
|
|
|
margin-right: 10 upx;
|
|
|
|
|
}
|
|
|
|
|
</style>
|