123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878 |
- <!--
- *@description: 危险工程
- *@author: yh Fu
- *@date: 2024-01-03 14:17:43
- *@version: V1.0.5
- -->
- <template>
- <div class="app-container">
- <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="110px">
- <el-form-item label="作业基本信息" prop="basicInformation">
- <el-input
- v-model="queryParams.basicInformation"
- placeholder="请输入作业基本信息"
- clearable
- @keyup.enter.native="handleQuery"
- />
- </el-form-item>
- <el-form-item label="工程名称" prop="enginName">
- <el-input
- v-model="queryParams.enginName"
- placeholder="请输入工程名称"
- clearable
- @keyup.enter.native="handleQuery"
- />
- </el-form-item>
- <el-form-item label="工程地点" prop="enginAddre">
- <el-input
- v-model="queryParams.enginAddre"
- placeholder="请输入工程地点"
- clearable
- @keyup.enter.native="handleQuery"
- />
- </el-form-item>
- <el-form-item>
- <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
- <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
- </el-form-item>
- </el-form>
- <el-row :gutter="10" class="mb8">
- <el-col :span="1.5">
- <el-button
- type="primary"
- plain
- icon="el-icon-plus"
- size="mini"
- @click="handleAdd"
- v-hasPermi="['zdsz:engineeringDangerous:add']"
- >新增
- </el-button>
- </el-col>
- <el-col :span="1.5">
- <el-button
- type="success"
- plain
- icon="el-icon-edit"
- size="mini"
- :disabled="single"
- @click="handleUpdate"
- v-hasPermi="['zdsz:engineeringDangerous:edit']"
- >修改
- </el-button>
- </el-col>
- <el-col :span="1.5">
- <el-button
- type="danger"
- plain
- icon="el-icon-delete"
- size="mini"
- :disabled="multiple"
- @click="handleDelete"
- v-hasPermi="['zdsz:engineeringDangerous:remove']"
- >删除
- </el-button>
- </el-col>
- <!-- <el-col :span="1.5">
- <el-button
- type="warning"
- plain
- icon="el-icon-download"
- size="mini"
- @click="handleExport"
- v-hasPermi="['zdsz:engineeringDangerous:export']"
- >导出
- </el-button>
- </el-col>-->
- <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
- </el-row>
- <el-table v-loading="loading" :data="engineeringDangerousList" @selection-change="handleSelectionChange">
- <el-table-column type="selection" width="55" align="center"/>
- <!-- <el-table-column label="" align="center" prop="id" v-if="true"/>-->
- <el-table-column label="作业基本信息" align="center" prop="basicInformation"/>
- <el-table-column label="工程名称" align="center" prop="enginName"/>
- <el-table-column label="工程地点" align="center" prop="enginAddre"/>
- <el-table-column label="工程时间" align="center" prop="enginTime" width="180">
- <template slot-scope="scope">
- <span>{{ parseTime(scope.row.enginTime, '{y}-{m}-{d}') }}</span>
- </template>
- </el-table-column>
- <!-- <el-table-column label="管径" align="center" prop="pipeDiameter"/>
- <el-table-column label="管材" align="center" prop="tubularProduct"/>
- <el-table-column label="是否存在套管" align="center" prop="casingPresent"/>
- <el-table-column label="管道压力" align="center" prop="pipePressure"/>
- <el-table-column label="气源方向" align="center" prop="gasSourceDirection"/>
- <el-table-column label="作业位置" align="center" prop="taskPosition"/>
- <el-table-column label="与作业相关阀门位置" align="center" prop="valvePosition"/>
- <el-table-column label="压力报告" align="center" prop="stressReport"/>
- <el-table-column label="监理旁站记录" align="center" prop="supervision record"/>
- <el-table-column label="工作联系单" align="center" prop="workContactForm"/>
- <el-table-column label="巡线确认单" align="center" prop="linePatrolConfirmationForm"/>
- <el-table-column label="危险作业坑大小(长)" align="center" prop="hazardousWorkPitsLong"/>
- <el-table-column label="危险作业坑大小(宽)" align="center" prop="hazardousWorkPitsWide"/>
- <el-table-column label="危险作业坑大小(深)" align="center" prop="hazardousWorkPitsDeep"/>
- <el-table-column label="是否需要支护" align="center" prop="needSupport"/>
- <el-table-column label="作业坑内其他管道情况" align="center" prop="otherPipelineConditionsWorkPit"/>
- <el-table-column label="现场负责人" align="center" prop="siteHead"/>
- <el-table-column label="现场负责人电话" align="center" prop="siteHeadPhone"/>
- <el-table-column label="作业人员信息" align="center" prop="operatorInformation"/>
- <el-table-column label="检口" align="center" prop="inspectionPort"/>
- <el-table-column label="管道刷油" align="center" prop="pipelinePainting"/>
- <el-table-column label="管道支护" align="center" prop="pipelineSupport"/>
- <el-table-column label="管道防腐" align="center" prop="pipelineCorrosionProtection"/>
- <el-table-column label="砌筑阀门井" align="center" prop="masonryValveWell"/>
- <el-table-column label="保护井" align="center" prop="protectionWell"/>
- <el-table-column label="管件保护井砌筑" align="center" prop="pipeProtectionWelMasonry"/>
- <el-table-column label="回填" align="center" prop="backfill"/>
- <el-table-column label="夯实" align="center" prop="tamp"/>
- <el-table-column label="平整场地" align="center" prop="levelingTheSite"/>
- <el-table-column label="备注" align="center" prop="remark"/>-->
- <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
- <template slot-scope="scope">
- <el-button
- size="mini"
- type="text"
- icon="el-icon-edit"
- @click="handleUpdate(scope.row)"
- v-hasPermi="['zdsz:engineeringDangerous:edit']"
- >修改
- </el-button>
- <el-button
- size="mini"
- type="text"
- icon="el-icon-delete"
- @click="handleDelete(scope.row)"
- v-hasPermi="['zdsz:engineeringDangerous:remove']"
- >删除
- </el-button>
- <!-- <el-button-->
- <!-- size="mini"-->
- <!-- type="text"-->
- <!-- icon="el-icon-edit"-->
- <!-- @click="addNewPipe(scope.row)"-->
- <!-- >新增顶管工程-->
- <!-- </el-button>-->
- <!-- <el-button
- type="text"
- icon="el-icon-edit"
- size="mini"
- @click="viewSource(scope.row)"
- >历史
- </el-button>-->
- </template>
- </el-table-column>
- </el-table>
- <pagination
- v-show="total>0"
- :total="total"
- :page.sync="queryParams.pageNum"
- :limit.sync="queryParams.pageSize"
- @pagination="getList"
- />
- <!-- 添加或修改危险作业工程对话框 -->
- <el-dialog :title="title" :visible.sync="open" append-to-body customClass="appendElDialog">
- <el-form ref="form" :model="form" :rules="rules" label-width="110px">
- <el-row>
- <el-col :span="8">
- <el-form-item label="作业基本信息" prop="basicInformation">
- <el-input v-model="form.basicInformation" placeholder="请填写作业基本信息" maxlength="200"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="工程名称" prop="enginName">
- <el-input v-model="form.enginName" placeholder="请填写作业基本信息" maxlength="200"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="工程地点" prop="enginAddre">
- <el-input v-model="form.enginAddre" placeholder="请填写工程地点" maxlength="200"></el-input>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-col :span="6">
- <el-form-item label="工程时间" prop="enginTime">
- <el-date-picker
- v-model="form.enginTime"
- value-format="yyyy-MM-dd hh:mm:ss"
- type="datetime"
- placeholder="请选择工程时间">
- </el-date-picker>
- </el-form-item>
- </el-col>
- </el-col>
- <el-col :span="8">
- <el-form-item label="现场负责人" prop="siteHead">
- <el-input v-model="form.siteHead" placeholder="请填写现场负责人" maxlength="16"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="现场负责人电话" prop="siteHeadPhone">
- <el-input v-model="form.siteHeadPhone" placeholder="请填写现场负责人电话" maxlength="11"/>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="作业人员信息" prop="operatorInformation">
- <el-input v-model="form.operatorInformation" placeholder="请填写作业人员信息" maxlength="200"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="监理旁站记录" prop="supervisionRecord">
- <el-input v-model="form.supervisionRecord" placeholder="请填写监理旁站记录" maxlength="200"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="工作联系单" prop="workContactForm">
- <el-input v-model="form.workContactForm" placeholder="请填写工作联系单" maxlength="200"/>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="巡线确认单" prop="linePatrolConfirmationForm">
- <el-input v-model="form.linePatrolConfirmationForm" placeholder="请填写巡线确认单" maxlength="200"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="作业位置" prop="taskPosition">
- <el-input v-model="form.taskPosition" placeholder="请填写作业位置" maxlength="200"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="相关阀门位置" prop="valvePosition">
- <el-input v-model="form.valvePosition" placeholder="请填写与作业相关阀门位置" maxlength="200"/>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="是否存在套管" prop="casingPresent">
- <el-select v-model="form.casingPresent" placeholder="请选择是否存在套管">
- <el-option
- v-for="e in segmentedCompressionQualifiedOption"
- :key="e.value"
- :label="e.label"
- :value="e.value"
- ></el-option>
- </el-select>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="管径" prop="pipeDiameter">
- <el-input v-model="form.pipeDiameter" placeholder="请填写管径" maxlength="200"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="管材" prop="tubularProduct">
- <el-input v-model="form.tubularProduct" placeholder="请填写管材" maxlength="200"></el-input>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="管道压力" prop="pipePressure">
- <el-input v-model="form.pipePressure" placeholder="请填写管道压力" maxlength="200"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="压力报告" prop="stressReport">
- <el-input v-model="form.stressReport" placeholder="请填写压力报告" maxlength="200"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="气流方向" prop="gasSourceDirection">
- <el-input v-model="form.gasSourceDirection" placeholder="请填写气流方向" maxlength="200"/>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="是否需要支护" prop="casingPresent">
- <el-select v-model="form.needSupport" placeholder="请选择是否需要支护">
- <el-option
- v-for="e in segmentedCompressionQualifiedOption"
- :key="e.value"
- :label="e.label"
- :value="e.value"
- ></el-option>
- </el-select>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="管道支护" prop="pipelineSupport">
- <el-input v-model="form.pipelineSupport" placeholder="请填写管道支护" maxlength="200"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="检口" prop="inspectionPort">
- <el-input v-model="form.inspectionPort" placeholder="请填写检口" maxlength="200"/>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="管道刷油" prop="pipelinePainting">
- <el-input v-model="form.pipelinePainting" placeholder="请填写管道刷油" maxlength="200"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="管道防腐" prop="pipelineCorrosionProtection">
- <el-input v-model="form.pipelineCorrosionProtection" placeholder="请填写管道防腐" maxlength="200"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="其他管道情况" prop="otherPipelineConditionsWorkPit">
- <el-input v-model="form.otherPipelineConditionsWorkPit" placeholder="请填写其他管道情况" maxlength="200"/>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="保护井" prop="protectionWell">
- <el-input v-model="form.protectionWell" placeholder="请填写保护井" maxlength="200"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="管件保护井砌筑" prop="pipeProtectionWelMasonry">
- <el-input v-model="form.pipeProtectionWelMasonry" placeholder="请填写管件保护井砌筑" maxlength="200"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="砌筑阀门井" prop="masonryValveWell">
- <el-input v-model="form.masonryValveWell" placeholder="请填写砌筑阀门井" maxlength="200"/>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="作业坑(长)(米)" prop="hazardousWorkPitsLong">
- <el-input v-model="form.hazardousWorkPitsLong" placeholder="请填写危险作业坑大小(长)" maxlength="11"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="作业坑(宽)(米)" prop="hazardousWorkPitsWide">
- <el-input v-model="form.hazardousWorkPitsWide" placeholder="请填写危险作业坑大小(宽)" maxlength="11"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="作业坑(深)(米)" prop="hazardousWorkPitsDeep">
- <el-input v-model="form.hazardousWorkPitsDeep" placeholder="请填写危险作业坑大小(深)" maxlength="11"/>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="回填" prop="backfill">
- <el-input v-model="form.backfill" placeholder="请填写回填" maxlength="200"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="夯实" prop="tamp">
- <el-input v-model="form.tamp" placeholder="请填写夯实" maxlength="200"/>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="平整场地" prop="levelingTheSite">
- <el-input v-model="form.levelingTheSite" placeholder="请填写平整场地" maxlength="200"/>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="24">
- <el-form-item label="备注" prop="remark" style="width: 42.7%;">
- <el-input
- v-model="form.remark"
- type="textarea"
- placeholder="请输入内容"
- class="remark_input"
- maxlength="200"
- />
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="24">
- <el-form-item label="附件" prop="">
- <ObsFileUpload ref="obsFileUpload" :file-size="100"
- :file-type="['dwg','dwt','doc','docx','xls','xlsx','png', 'jpg', 'jpeg']" :limit="9999"
- :value="form.pics"
- ></ObsFileUpload>
- </el-form-item>
- </el-col>
- </el-row>
- </el-form>
- <div slot="footer" class="dialog-footer" style="margin-top: 20%;">
- <el-button :loading="buttonLoading" type="primary" @click="submitForm">提交</el-button>
- <el-button @click="cancel">取 消</el-button>
- </div>
- </el-dialog>
- </div>
- </template>
- <script>
- import {
- listEngineeringDangerous,
- getEngineeringDangerous,
- delEngineeringDangerous, queryEngineeringDangerous, updateEngineeringDangerous, addEngineeringDangerous,
- } from "@/api/zdsz/engineeringDangerous";
- import data from "@/views/system/dict/data.vue";
- import {validPhoneMobile, checkPositiveDecimal} from "@/api/rules";
- export default {
- name: "EngineeringDangerous",
- computed: {
- data() {
- return data
- }
- },
- components: {},
- data() {
- return {
- //备用
- // openNodeForm:false,
- //备用
- currentCollapses: [],
- nodeType: "危险作业工程",
- nodeDetailVisible: false,
- // 按钮loading
- buttonLoading: false,
- // 遮罩层
- loading: true,
- // 选中数组
- ids: [],
- // 非单个禁用
- single: true,
- // 非多个禁用
- multiple: true,
- // 显示搜索条件
- showSearch: true,
- // 总条数
- total: 0,
- // 危险工程表格数据
- engineeringDangerousList: [],
- // 弹出层标题
- title: "",
- // 是否显示弹出层
- open: false,
- // 查询参数
- queryParams: {
- pics: [],
- pageNum: 1,
- pageSize: 10,
- basicInformation: undefined,
- enginName: undefined,
- enginAddre: undefined,
- enginTime: undefined,
- pipeDiameter: undefined,
- tubularProduct: undefined,
- casingPresent: undefined,
- pipePressure: undefined,
- gasSourceDirection: undefined,
- taskPosition: undefined,
- valvePosition: undefined,
- stressReport: undefined,
- supervisionRecord: undefined,
- workContactForm: undefined,
- linePatrolConfirmationForm: undefined,
- hazardousWorkPitsLong: undefined,
- hazardousWorkPitsWide: undefined,
- hazardousWorkPitsDeep: undefined,
- needSupport: undefined,
- otherPipelineConditionsWorkPit: undefined,
- siteHead: undefined,
- siteHeadPhone: undefined,
- operatorInformation: undefined,
- inspectionPort: undefined,
- pipelinePainting: undefined,
- pipelineSupport: undefined,
- pipelineCorrosionProtection: undefined,
- masonryValveWell: undefined,
- protectionWell: undefined,
- pipeProtectionWelMasonry: undefined,
- backfill: undefined,
- tamp: undefined,
- levelingTheSite: undefined,
- /* zEngineeringNodeBo: {
- type: "危险作业工程",
- zEngineeringInfoBo: {} //节点信息
- }*/
- },
- zEngineeringInfoBo: {
- constructAddre: '', // 施工地址
- constructPhone: '', // 施工人电话
- constructUser: '', // 施工人
- headName: '', // 负责人
- headPhone: '', // 负责人电话
- constructAccordingDrawings: '', // 是否按图纸施工
- segmentedCompressionQualified: '', // 分段打压是否合格
- selfClosingValveType: '', // 自闭阀类型
- visitType: '', // 上门类型
- backfillTime: '', // 回填时间
- constructTime: '', // 施工时间
- zEngiineeringPhotoBoList: [] // 图片列表
- },
- constructAccordingDrawingsOption: [
- {
- value: '1',
- label: '是'
- },
- {
- value: '0',
- label: '否'
- }
- ],
- segmentedCompressionQualifiedOption: [
- {
- value: '1',
- label: '是'
- },
- {
- value: '0',
- label: '否'
- }
- ],
- // 表单参数
- form: {},
- // 表单校验
- rules: {
- basicInformation: [
- {required: true, message: "作业基本信息不能为空", trigger: "blur"}
- ],
- enginName: [
- {required: true, message: "工程名称不能为空", trigger: "blur"}
- ],
- enginAddre: [
- {required: true, message: "工程地点不能为空", trigger: "blur"}
- ],
- /* enginTime: [
- {required: true, message: "工程时间不能为空", trigger: "blur"}
- ],*/
- hazardousWorkPitsLong: [
- //{required: true, message: "危险作业坑大小(长)不能为空", trigger: "blur"},
- {validator: checkPositiveDecimal, trigger: 'blur'},
- ],
- hazardousWorkPitsWide: [
- //{required: true, message: "危险作业坑大小(宽)不能为空", trigger: "blur"},
- {validator: checkPositiveDecimal, trigger: 'blur'},
- ],
- hazardousWorkPitsDeep: [
- //{required: true, message: "危险作业坑大小(深)不能为空", trigger: "blur"},
- {validator: checkPositiveDecimal, trigger: 'blur'},
- ],
- siteHeadPhone: [
- // {required: true, message: "现场负责人电话不能为空", trigger: "blur"}
- {validator: validPhoneMobile, trigger: 'blur'},
- ],
- },
- //备用
- currentType: null, // 组件类型 put修改 add新增
- };
- },
- created() {
- this.getList();
- },
- methods: {
- submitForm() {
- this.$refs["form"].validate(valid => {
- if (valid) {
- this.buttonLoading = true;
- if (this.form.id != null) {
- this.form.pics = []
- for (let i = 0; i < this.$refs.obsFileUpload.fileList.length; i++) {
- console.log(this.$refs.obsFileUpload.fileList[i])
- this.form.pics.push({
- 'fileName': this.$refs.obsFileUpload.fileList[i].name,
- 'picUrl': this.$refs.obsFileUpload.fileList[i].url
- })
- }
- updateEngineeringDangerous(this.form).then(response => {
- this.$modal.msgSuccess("修改成功");
- this.open = false;
- this.getList();
- }).finally(() => {
- this.buttonLoading = false;
- });
- } else {
- this.form.pics = []
- for (let i = 0; i < this.$refs.obsFileUpload.fileList.length; i++) {
- console.log(this.$refs.obsFileUpload.fileList[i])
- this.form.pics.push({
- 'fileName': this.$refs.obsFileUpload.fileList[i].name,
- 'picUrl': this.$refs.obsFileUpload.fileList[i].url
- })
- }
- addEngineeringDangerous(this.form).then(response => {
- this.$modal.msgSuccess("新增成功");
- this.open = false;
- this.getList();
- }).finally(() => {
- this.buttonLoading = false;
- });
- }
- }
- });
- },
- //备用
- viewSource(e) {
- this.currentId = e.id
- this.$refs.ConstructionDetails.open(_, "危险作业工程")
- },
- viewNodeSource(e) {
- // todo: 获取数据
- queryEngineeringDangerous({
- id: this.currentId
- }).then(res => {
- try {
- this.currentCollapses = res.data.zEngineeringNodeBoList[0].zEngineeringInfoBoList
- } catch (error) {
- this.currentCollapses = [];
- }
- })
- },
- closeToSucceed() {
- this.open = false;
- this.getList()
- },
- toNodeDetail() {
- this.$refs["form"].validate(valid => {
- if (valid) {
- if (this.currentType === 'put') {
- this.form.pics = this.$refs.obsFileUpload.fileList
- this.$refs.childNode.open(this.form, 37, [{name: "危险作业工程"}])
- return
- }
- if (this.currentType === 'add') {
- this.form.pics = this.$refs.obsFileUpload.fileList
- this.$refs.childNode.open(this.form, 3, [{name: "危险作业工程"}])
- return
- }
- }
- })
- /* return
- this.$refs['form'].validate(e => {
- if (e) {
- this.nodeDetailVisible = true
- }
- })*/
- },
- // 新增顶管工程
- addNewPipe(data) {
- this.$refs.enginPipe.openDialog({
- id: data.id,
- type: "危险作业工程"
- }, 'add', data)
- },
- getUrl(url) {
- this.zEngineeringInfoBo.zEngiineeringPhotoBoList = this.$refs.obsImageUpload.fileList ? this.$refs.obsImageUpload.fileList.map(e => e.url) : [];
- },
- /** 查询危险工程列表 */
- /* getList() {
- this.loading = true;
- listEngineeringDangerous({
- basicInformation: this.queryParams.basicInformation,
- enginName: this.queryParams.enginName,
- enginAddre: this.queryParams.enginAddre,
- params: this.queryParams
- }).then(res => {
- this.engineeringDangerousList = res.rows;
- this.total = res.total;
- this.loading = false;
- });
- },*/
- getList() {
- this.loading = true;
- listEngineeringDangerous(this.queryParams).then(response => {
- this.engineeringDangerousList = response.rows;
- this.total = response.total;
- this.loading = false;
- });
- },
- // 取消按钮
- cancel() {
- this.open = false;
- this.reset();
- },
- // 表单重置
- reset() {
- this.form = {
- id: undefined,
- basicInformation: undefined,
- enginName: undefined,
- enginAddre: undefined,
- enginTime: undefined,
- pipeDiameter: undefined,
- tubularProduct: undefined,
- casingPresent: undefined,
- pipePressure: undefined,
- gasSourceDirection: undefined,
- taskPosition: undefined,
- valvePosition: undefined,
- stressReport: undefined,
- supervisionRecord: undefined,
- workContactForm: undefined,
- linePatrolConfirmationForm: undefined,
- hazardousWorkPitsLong: undefined,
- hazardousWorkPitsWide: undefined,
- hazardousWorkPitsDeep: undefined,
- needSupport: undefined,
- otherPipelineConditionsWorkPit: undefined,
- siteHead: undefined,
- siteHeadPhone: undefined,
- operatorInformation: undefined,
- inspectionPort: undefined,
- pipelinePainting: undefined,
- pipelineSupport: undefined,
- pipelineCorrosionProtection: undefined,
- masonryValveWell: undefined,
- protectionWell: undefined,
- pipeProtectionWelMasonry: undefined,
- backfill: undefined,
- tamp: undefined,
- levelingTheSite: undefined,
- version: undefined,
- remark: undefined,
- delFlag: undefined,
- createBy: undefined,
- createTime: undefined,
- updateBy: undefined,
- updateTime: undefined
- };
- this.resetForm("form");
- },
- /** 搜索按钮操作 */
- handleQuery() {
- this.queryParams.pageNum = 1;
- this.getList();
- },
- /** 重置按钮操作 */
- resetQuery() {
- this.resetForm("queryForm");
- this.handleQuery();
- },
- // 多选框选中数据
- handleSelectionChange(selection) {
- this.ids = selection.map(item => item.id)
- this.single = selection.length !== 1
- this.multiple = !selection.length
- },
- /** 新增按钮操作 */
- handleAdd() {
- this.reset();
- this.currentType = "add"
- this.open = true;
- this.title = "添加危险工程";
- },
- /** 修改按钮操作 */
- handleUpdate(row) {
- this.loading = true;
- this.reset();
- const id = row.id || this.ids
- getEngineeringDangerous(id).then(response => {
- this.loading = false;
- this.form = response.data;
- this.currentType = "put"
- this.open = true;
- this.title = "修改危险工程";
- });
- },
- /** 删除按钮操作 */
- handleDelete(row) {
- const ids = row.id || this.ids;
- this.$modal.confirm('是否确认删除所选的数据项?').then(() => {
- this.loading = true;
- return delEngineeringDangerous(ids);
- }).then(() => {
- this.loading = false;
- this.getList();
- this.$modal.msgSuccess("删除成功");
- }).catch(() => {
- }).finally(() => {
- this.loading = false;
- });
- },
- /** 导出按钮操作 */
- handleExport() {
- this.download('zdsz/engineeringDangerous/export', {
- ...this.queryParams
- }, `engineeringDangerous_${new Date().getTime()}.xlsx`)
- }
- }
- };
- </script>
- <style lang="scss" scoped>
- ::v-deep .appendElDialog {
- width: 70%;
- height: 80%;
- overflow: hidden;
- overflow-y: scroll;
- .el-dialog__body {
- height: 100%;
- }
- //.el-form-item {
- // margin-bottom: 22px;
- // width: 30%;
- // display: inline-block;
- //}
- // .el-form-item:nth-child(2n+2){
- // margin-left: 5%;
- // }
- .el-form-item:not(:nth-child(1):nth-child(2)) {
- margin-top: 0.5%;
- }
- .el-form-item__error {
- width: 200px;
- color: #ff4949;
- font-size: 12px;
- line-height: 1;
- padding-top: 4px;
- position: absolute;
- top: 100%;
- left: 0;
- }
- .remark_input {
- .el-textarea__inner {
- width: 238%;
- height: 190px;
- }
- }
- .otherSituation {
- width: 60%;
- .el-form-item__label {
- width: 170px;
- }
- .el-form-item__content {
- margin-left: 173px;
- }
- }
- .dialog-footer {
- }
- }
- </style>
|