ticketDetail
This commit is contained in:
parent
7d732d68c2
commit
ed771eab5b
|
|
@ -31,7 +31,7 @@
|
|||
<el-col :md="12" :sm="12" :xs="24">
|
||||
<el-form-item label="关联作业">
|
||||
<el-input
|
||||
v-model="operationId"
|
||||
v-model="form.name"
|
||||
type="text"
|
||||
:disabled="true"
|
||||
></el-input>
|
||||
|
|
@ -118,59 +118,6 @@
|
|||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<!--
|
||||
临时用电
|
||||
|
||||
<el-col :md="12" :sm="12" :xs="24">
|
||||
<el-form-item label="安装/拆除">
|
||||
<el-input v-model="work_type" type="text" clearable></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="12" :xs="24">
|
||||
<el-form-item label="安装/拆除时间">
|
||||
<el-input v-model="work_time" type="text" clearable></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col :md="12" :sm="12" :xs="24">
|
||||
<el-form-item label="验收时间">
|
||||
<el-input v-model="accept_time" type="text" clearable></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="12" :xs="24">
|
||||
<el-form-item label="用电地点">
|
||||
<el-input v-model="power_to" type="text" clearable></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="12" :xs="24">
|
||||
<el-form-item label="电源接入点">
|
||||
<el-input v-model="power_from" type="text" clearable></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="12" :xs="24">
|
||||
<el-form-item label="用电开始">
|
||||
<el-input
|
||||
v-model="power_start_time"
|
||||
type="text"
|
||||
clearable
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="12" :xs="24">
|
||||
<el-form-item label="用电截至">
|
||||
<el-input
|
||||
v-model="power_end_time"
|
||||
type="text"
|
||||
clearable
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :md="12" :sm="12" :xs="24">
|
||||
<el-form-item label="计划用电天数">
|
||||
<el-input v-model="power_days" type="text" clearable></el-input>
|
||||
</el-form-item>
|
||||
</el-col> !-->
|
||||
|
||||
<el-col :md="24" :sm="12" :xs="24">
|
||||
<el-form-item label="风险选择">
|
||||
<el-checkbox-group v-model="form.risks_checked">
|
||||
|
|
@ -178,7 +125,8 @@
|
|||
v-for="(item, index) in risklist"
|
||||
:key="index"
|
||||
:label="item.id"
|
||||
>{{ item.name }}</el-checkbox
|
||||
>{{ item.name }}
|
||||
</el-checkbox
|
||||
>
|
||||
</el-checkbox-group>
|
||||
</el-form-item>
|
||||
|
|
@ -192,14 +140,6 @@
|
|||
></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<!--
|
||||
<el-col :md="12" :sm="12" :xs="24">
|
||||
<el-form-item label="逃生路径">
|
||||
<el-input v-model="escape_route" type="text" clearable></el-input>
|
||||
</el-form-item>
|
||||
</el-col> !-->
|
||||
|
||||
<el-col :md="24" :sm="12" :xs="24">
|
||||
<el-form-item label="措施选择">
|
||||
<el-checkbox-group v-model="form.measures_checked">
|
||||
|
|
@ -207,12 +147,12 @@
|
|||
v-for="(item, index) in measurelist"
|
||||
:key="index"
|
||||
:label="item.id"
|
||||
>{{ item.name }}</el-checkbox
|
||||
>{{ item.name }}
|
||||
</el-checkbox
|
||||
>
|
||||
</el-checkbox-group>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col :md="24" :sm="12" :xs="24">
|
||||
<el-card class="box-card">
|
||||
<div class="clearfix">
|
||||
|
|
@ -234,21 +174,13 @@
|
|||
></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<!--
|
||||
<el-col :md="12" :sm="12" :xs="24">
|
||||
<el-form-item label="作业审批照片">
|
||||
<el-input v-model="create_imgs" type="text" clearable></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
!-->
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :md="24" :sm="12" :xs="24">
|
||||
<el-form-item>
|
||||
<el-button style="margin-top: 12px" @click="handleNextStep"
|
||||
>下一步</el-button
|
||||
>
|
||||
<el-button style="margin-top: 12px" type="primary" plain @click="handleNextStep"
|
||||
>下一步
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
|
@ -270,6 +202,8 @@
|
|||
row-key="id"
|
||||
hidePagination
|
||||
stripe
|
||||
hideDo
|
||||
style="height: calc(100% - 60px);"
|
||||
>
|
||||
<el-table-column
|
||||
label="#"
|
||||
|
|
@ -289,7 +223,8 @@
|
|||
<el-tag v-for="item in scope.row.certificates_"
|
||||
:key="item.number"
|
||||
:label="item.name"
|
||||
:value="item.number">{{item.name}}</el-tag>
|
||||
:value="item.number">{{item.name}}
|
||||
</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
|
|
@ -380,12 +315,11 @@
|
|||
</template>
|
||||
</sc-dialog>
|
||||
<el-button style="margin-top: 12px" @click="handleLastStep"
|
||||
>上一步</el-button
|
||||
>
|
||||
<el-button style="margin-top: 12px" @click="handleNextStep"
|
||||
>下一步</el-button
|
||||
>
|
||||
|
||||
>上一步
|
||||
</el-button>
|
||||
<el-button style="margin-top: 12px" type="primary" plain @click="handleNextStep"
|
||||
>下一步
|
||||
</el-button>
|
||||
</el-main>
|
||||
<!--气体检测记录!-->
|
||||
<el-main class="nopadding" v-show="active === 2">
|
||||
|
|
@ -430,16 +364,20 @@
|
|||
label="检验结论"
|
||||
prop="is_ok"
|
||||
width="150"
|
||||
> <template #default="scope">
|
||||
>
|
||||
<template #default="scope">
|
||||
{{ is_ok_[scope.row.is_ok] }}
|
||||
</template></el-table-column>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
label="检测人"
|
||||
prop="checker"
|
||||
width="150"
|
||||
> <template #default="scope">
|
||||
>
|
||||
<template #default="scope">
|
||||
{{ scope.row.checker_.name }}
|
||||
</template></el-table-column>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
label="创建时间"
|
||||
prop="create_time"
|
||||
|
|
@ -458,8 +396,6 @@
|
|||
</el-popconfirm>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
|
||||
</scTable>
|
||||
<sc-dialog v-model="gasdialog" draggable title="气体检测记录">
|
||||
<el-form
|
||||
|
|
@ -544,10 +480,15 @@
|
|||
<el-button type="primary" @click="submitgas">确 定</el-button>
|
||||
</template>
|
||||
</sc-dialog>
|
||||
<el-button style="margin-top: 12px" @click="handleLastStep"
|
||||
>上一步</el-button
|
||||
>
|
||||
<el-button style="margin-top: 12px" @click="submitOut">退出</el-button>
|
||||
<el-button @click="handleLastStep">上一步</el-button>
|
||||
<el-button
|
||||
v-for=" item in initForm.transitions"
|
||||
:key="item.id"
|
||||
type="primary"
|
||||
@click="submitTicketCreate(item.id)"
|
||||
>{{item.name}}
|
||||
</el-button>
|
||||
<el-button @click="submitOut">退出</el-button>
|
||||
</el-main>
|
||||
</el-container>
|
||||
</template>
|
||||
|
|
@ -559,18 +500,22 @@
|
|||
.box-card p {
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
.content {
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
.stepSuc:hover {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.stepErr:hover {
|
||||
cursor: not-allowed;
|
||||
}
|
||||
</style>
|
||||
<script>
|
||||
import {genTree} from "@/utils/verificate";
|
||||
|
||||
const defaultformworker = {
|
||||
id: "",
|
||||
worker: null,
|
||||
|
|
@ -588,7 +533,6 @@ export default {
|
|||
components: {},
|
||||
data() {
|
||||
return {
|
||||
|
||||
active: 0,
|
||||
stepSuc: [0],
|
||||
stepTitle: ["基本信息", "作业人员", "气体检测记录"],
|
||||
|
|
@ -606,9 +550,10 @@ export default {
|
|||
cate: "",
|
||||
risks_checked: [],
|
||||
},
|
||||
|
||||
initForm: {},
|
||||
operationId: "",
|
||||
oplcateId: "",
|
||||
oplcateCode: "",
|
||||
oplId: "",
|
||||
leveloptions: [
|
||||
{id: 10, name: "特殊动火"},
|
||||
|
|
@ -620,7 +565,6 @@ export default {
|
|||
risklist: [],
|
||||
measurelist: [],
|
||||
pagtitle: "",
|
||||
|
||||
dutyOptions: [
|
||||
{value: 10, label: "作业人员"},
|
||||
{value: 20, label: "起重司机"},
|
||||
|
|
@ -646,13 +590,11 @@ export default {
|
|||
this.oplcateId = this.$route.query.oplcateId; //作业许可证种类ID
|
||||
this.oplId = this.$route.query.oplId; //许可证ID
|
||||
this.getoplData();
|
||||
|
||||
this.getInit();
|
||||
this.getDept();
|
||||
this.getUser();
|
||||
},
|
||||
methods: {
|
||||
|
||||
|
||||
getoplData() {
|
||||
if (this.oplId == "") {
|
||||
this.getOperation();
|
||||
|
|
@ -678,6 +620,7 @@ export default {
|
|||
this.$API.opm.operation.read.req(this.operationId).then((res) => {
|
||||
this.form.start_time = res.start_time; //作业开始时间
|
||||
this.form.end_time = res.end_time; //作业结束时间
|
||||
this.form.name = res.name; //作业结束时间
|
||||
|
||||
console.log(res);
|
||||
});
|
||||
|
|
@ -697,11 +640,12 @@ export default {
|
|||
},
|
||||
//作业
|
||||
|
||||
//根据作业许可证ID获取,风险、措施
|
||||
//根据作业许可证类别ID获取,风险、措施===>作业许可证类别详情
|
||||
getOplcates() {
|
||||
this.$API.opm.oplcate.read.req(this.oplcateId).then((res) => {
|
||||
console.log(res); //
|
||||
this.pagtitle = res.name;
|
||||
this.oplcateCode = res.code;
|
||||
this.risklist = res.risk_options_; //风险缝隙
|
||||
this.measurelist = res.measure_options_; //控制措施
|
||||
});
|
||||
|
|
@ -813,22 +757,21 @@ export default {
|
|||
this.$message.success("创建作业人员成功");
|
||||
this.$refs.workerTable.refresh();
|
||||
this.workerdialog = false;
|
||||
|
||||
})
|
||||
.catch((err) => {
|
||||
return err;
|
||||
});
|
||||
|
||||
});
|
||||
},
|
||||
//气体检测记录列表
|
||||
|
||||
//气体检测记录列表
|
||||
getgasList(id) {
|
||||
this.$API.opm.gas.list.req({opl: id, page: 0}).then((res) => {
|
||||
this.apigasObj = res;
|
||||
console.log(res);
|
||||
});
|
||||
},
|
||||
|
||||
//创建气体检测记录,显示Form
|
||||
addgas() {
|
||||
this.gasdialog = true;
|
||||
|
|
@ -854,6 +797,7 @@ export default {
|
|||
|
||||
});
|
||||
},
|
||||
|
||||
//删除气体检测记录
|
||||
delgas(row) {
|
||||
this.$API.opm.gas.delete
|
||||
|
|
@ -867,6 +811,30 @@ export default {
|
|||
return err;
|
||||
});
|
||||
},
|
||||
|
||||
//渲染工单提交按钮
|
||||
getInit() {
|
||||
this.$API.wf.workflow.initkey.req('Fire').then((res) => {
|
||||
this.initForm = res;
|
||||
});
|
||||
},
|
||||
|
||||
//提交,创建工单
|
||||
submitTicketCreate(id) {
|
||||
let ticket = {};
|
||||
ticket.workflow = this.initForm.workflow;
|
||||
ticket.ticket_data = {opl: this.oplId};
|
||||
ticket.transition = id;
|
||||
ticket.title = this.form.name + this.pagtitle + '申请';
|
||||
this.$API.wf.ticket.create.req(ticket).then((res) => {
|
||||
this.$message.success("提交成功");
|
||||
this.$router.push({
|
||||
name: "opl",
|
||||
query: {},
|
||||
});
|
||||
});
|
||||
},
|
||||
|
||||
//退出界面
|
||||
submitOut() {
|
||||
this.$router.push({
|
||||
|
|
|
|||
|
|
@ -134,7 +134,7 @@ export default {
|
|||
|
||||
//工作流
|
||||
getWorkflow() {
|
||||
this.$API.system.dept.list.req({ page: 0 }).then((res) => {
|
||||
this.$API.wf.workflow.list.req({ page: 0 }).then((res) => {
|
||||
this.workflowoptions = res;
|
||||
});
|
||||
},
|
||||
|
|
|
|||
|
|
@ -83,19 +83,21 @@
|
|||
},
|
||||
handleShow(row) {
|
||||
let workflowKey = row.workflow_.key;
|
||||
let catetype = '';
|
||||
let cateType = '',projectId='';
|
||||
if(workflowKey==='visit'){
|
||||
catetype = row.workflow_.key
|
||||
cateType = row.workflow_.key;
|
||||
projectId = row.ticket_data.visit;
|
||||
}else if(workflowKey==='rparty'){
|
||||
catetype = row.workflow_.key
|
||||
cateType = row.workflow_.key;
|
||||
projectId = row.ticket_data.rpj;
|
||||
}else{}
|
||||
this.$router.push({
|
||||
name: "visitdetail",
|
||||
query: {
|
||||
id: row.id,
|
||||
type: 'show',
|
||||
projectId: row.ticket_data.visit,
|
||||
catetype:catetype
|
||||
projectId: projectId,
|
||||
catetype:cateType
|
||||
},
|
||||
});
|
||||
},
|
||||
|
|
|
|||
|
|
@ -16,18 +16,13 @@
|
|||
</el-table-column>
|
||||
<el-table-column label="进行状态" min-width="100">
|
||||
<template #default="scope">
|
||||
<span v-if="scope.row.state_.type == 0"
|
||||
>{{ scope.row.state_.name }}中</span
|
||||
>
|
||||
<span v-else>已{{ scope.row.state_.name }}</span>
|
||||
<span>{{ scope.row.state_.name }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作人" min-width="100">
|
||||
<template #default="scope">
|
||||
<el-span v-if="scope.row.participant_">{{
|
||||
scope.row.participant_.name
|
||||
}}
|
||||
</el-span>
|
||||
<el-span v-if="scope.row.participant_">{{scope.row.participant_.name }}</el-span>
|
||||
<el-span v-if="scope.row.participant_str">{{scope.row.participant_str }}</el-span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
></el-button>
|
||||
</div>
|
||||
</el-header>
|
||||
<el-main class="nopadding">
|
||||
<el-main class="nopadding" style="height: 100%;">
|
||||
<scTable
|
||||
ref="table"
|
||||
:data="list"
|
||||
|
|
@ -18,6 +18,7 @@
|
|||
highlightCurrentRow
|
||||
hidePagination
|
||||
>
|
||||
<el-table-column label="#" type="index"></el-table-column>
|
||||
<el-table-column label="ID" prop="id"></el-table-column>
|
||||
<el-table-column label="名称" prop="name"></el-table-column>
|
||||
<el-table-column label="是否隐藏">
|
||||
|
|
|
|||
|
|
@ -44,37 +44,39 @@
|
|||
</el-descriptions>
|
||||
</el-card>
|
||||
<el-card style="margin-left: 10px; margin-bottom: 10px" v-if="cateType==='rparty'">
|
||||
<el-descriptions title="来访信息" :column="3">
|
||||
<el-descriptions title="入厂项目" :column="3">
|
||||
<el-descriptions-item label="工单流水号:">
|
||||
{{ticketDetail.sn }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="相关方:">
|
||||
{{rpjDetail.name }}
|
||||
{{rpjDetail.rparty_name}}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="入厂项目:">
|
||||
<!--{{rpjDetail.company }}-->
|
||||
{{rpjDetail.name }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="项目类型:">
|
||||
<!--<el-tag size="small">{{ rpjDetail.count_people }}人</el-tag>-->
|
||||
<el-tag size="small">{{rpjType_[rpjDetail.type]}}</el-tag>
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="合同编号:">
|
||||
<!--<el-tag v-for="item in rpjDetail.visitors_" :key='item.id' size="small">
|
||||
<!–{{ item.visitor_.name }}–>
|
||||
</el-tag>-->
|
||||
{{rpjDetail.contract_number }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="状态:">
|
||||
<!--{{state_[rpjDetail.state] }}-->
|
||||
{{state_[rpjDetail.state] }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="进厂时间:">
|
||||
<!--{{rpjDetail.visit_time }}-->
|
||||
{{rpjDetail.come_time }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="离厂时间:">
|
||||
<!--{{rpjDetail.leave_time }}-->
|
||||
{{rpjDetail.leave_time }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="所属部门:">
|
||||
<!--{{purpose_[rpjDetail.purpose] }}-->
|
||||
{{rpjDetail.belong_dept_name }}
|
||||
</el-descriptions-item>
|
||||
</el-descriptions>
|
||||
<div style="text-align: center">
|
||||
<el-link type="primary" @click="showMore"> 更多信息 </el-link>
|
||||
</div>
|
||||
<show-dialog v-if="rpjShow" ref="showDialog"></show-dialog>
|
||||
</el-card>
|
||||
<el-card style="margin-left: 10px; margin-bottom: 10px" v-if="type!=='show'">
|
||||
<scTitle title="处理"></scTitle>
|
||||
|
|
@ -137,13 +139,15 @@
|
|||
<script>
|
||||
import workDetails from "./details.vue";
|
||||
import workStep from "./steps.vue";
|
||||
import showDialog from "./../rpm/rpj_show.vue";
|
||||
import selectUser from '@/layout/components/userselect'
|
||||
|
||||
export default {
|
||||
components: {
|
||||
workDetails,
|
||||
workStep,
|
||||
selectUser
|
||||
selectUser,
|
||||
showDialog
|
||||
},
|
||||
name: "visitdetail",
|
||||
data() {
|
||||
|
|
@ -167,6 +171,7 @@
|
|||
suggestion:'',
|
||||
target_user:'',
|
||||
},
|
||||
rpjShow:false,
|
||||
limitedAdd:false,
|
||||
limitedDeliver:false,
|
||||
limitedUserSelect:false,
|
||||
|
|
@ -176,6 +181,12 @@
|
|||
30: "面试",
|
||||
40: "开会"
|
||||
},
|
||||
rpjType_: {
|
||||
10: "建筑施工",
|
||||
20: "设备设施检维修",
|
||||
30: "保安保洁服务",
|
||||
40: "其他",
|
||||
},
|
||||
state_: {
|
||||
10: "创建中",
|
||||
20: "审批中",
|
||||
|
|
@ -186,27 +197,28 @@
|
|||
};
|
||||
},
|
||||
created(){
|
||||
this.ticketId = this.$route.query.id;
|
||||
this.type = this.$route.query.type;
|
||||
this.cateType = this.$route.query.catetype;
|
||||
},
|
||||
mounted() {
|
||||
this.ticketId = this.$route.query.id;
|
||||
this.type = this.$route.query.type;
|
||||
this.projectId = this.$route.query.projectId;
|
||||
this.cateType = this.$route.query.catetype;
|
||||
|
||||
},
|
||||
mounted() {
|
||||
if(this.cateType==='visit'){
|
||||
this.getVisit();
|
||||
}else if(this.cateType==='rparty'){
|
||||
this.getVisit();
|
||||
this.getRpj();
|
||||
}
|
||||
this.getticketItem();
|
||||
|
||||
this.getBtns();
|
||||
this.getRpj();
|
||||
|
||||
},
|
||||
methods: {
|
||||
showMore(){
|
||||
this.rpjShow = true;
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.showDialog.open().setData({id:this.projectId});
|
||||
})
|
||||
},
|
||||
//工单详情
|
||||
getticketItem() {
|
||||
this.$API.wf.ticket.ticketItem.req(this.ticketId).then((res) => {
|
||||
|
|
@ -229,7 +241,8 @@
|
|||
|
||||
//入厂项目详情
|
||||
getRpj(){
|
||||
this.$API.rpmrpj.item.req(this.projectId).then((res) => {
|
||||
this.$API.rpm.rpj.item.req(this.projectId).then((res) => {
|
||||
debugger;
|
||||
this.rpjDetail = res;
|
||||
});
|
||||
},
|
||||
|
|
|
|||
|
|
@ -28,13 +28,13 @@
|
|||
<el-table-column label="创建时间" prop="create_time" min-width="150"></el-table-column>
|
||||
<el-table-column label="操作" fixed="right" align="center" width="220">
|
||||
<template #default="scope">
|
||||
<el-button link size="small" @click="workflowShow(scope.row)">配置</el-button>
|
||||
<el-button link size="small" type="primary" @click="workflowShow(scope.row)">配置</el-button>
|
||||
<el-divider direction="vertical"></el-divider>
|
||||
<el-button link size="small" @click="workflowEdit(scope.row)">编辑</el-button>
|
||||
<el-button link size="small" type="primary" @click="workflowEdit(scope.row)">编辑</el-button>
|
||||
<el-divider direction="vertical"></el-divider>
|
||||
<el-popconfirm title="确定删除吗?" @confirm="workflowDel(scope.row)">
|
||||
<template #reference>
|
||||
<el-button link size="small">删除</el-button>
|
||||
<el-button link size="small" type="danger">删除</el-button>
|
||||
</template>
|
||||
</el-popconfirm>
|
||||
</template>
|
||||
|
|
|
|||
Loading…
Reference in New Issue