对比新文件 |
| | |
| | | import request from '@/utils/request'; |
| | | import {getTokenAndVerify} from "@/api/sgyhpczl/auth"; |
| | | |
| | | //下载文件 |
| | | export function downloadFile(params) { |
| | | return request({ |
| | | headers: { |
| | | 'token': getTokenAndVerify().token, |
| | | 'verify': getTokenAndVerify().verify |
| | | }, |
| | | url: '/taboi/file/dowloand_do', |
| | | method: 'GET', |
| | | contentType: "multipart/form-data", |
| | | responseType:'blob', |
| | | params:params?params:{} |
| | | }); |
| | | } |
| | |
| | | data |
| | | }); |
| | | } |
| | | //下载文件 |
| | | export function dowloand_do(params) { |
| | | return request({ |
| | | headers: { |
| | | 'token': getTokenAndVerify().token, |
| | | 'verify': getTokenAndVerify().verify |
| | | }, |
| | | url: '/taboi/file/dowloand_do', |
| | | method: 'GET', |
| | | contentType: "multipart/form-data", |
| | | responseType:'blob', |
| | | params:params?params:{} |
| | | }); |
| | | } |
| | | //新增/编辑 |
| | | export function addOrEdit(data) { |
| | | return request({ |
| | |
| | | > |
| | | <template slot-scope="scope"> |
| | | <span size="medium">{{ scope.row.content }}</span> |
| | | <a v-for="item in scope.row.realFileName" |
| | | :href="scope.row.url+'/'+item"> |
| | | {{ item.split("fileName=")[1] }} |
| | | </a> |
| | | <span v-for="item in scope.row.realFileName"> |
| | | <el-link type="primary" @click="downloadFile(subFile(item))"> |
| | | {{subFile(item)}} |
| | | </el-link> |
| | | </span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | |
| | | import {getDangerDetails, getWfRecordList} from "@/api/sgyhpczl/recheckCancellationNumber"; |
| | | import {company_next_step_do} from "@/api/sgyhpczl/Issuedbysuperiors"; |
| | | import {getUserInfo} from "@/api/sgyhpczl/hiddenDangerManagement"; |
| | | |
| | | import {downloadFile} from "@/api/sgyhpczl/fileUtils"; |
| | | |
| | | export default { |
| | | components: {Titlename}, |
| | |
| | | this.$router.push({ |
| | | path: "/recheckCancellationNumber" |
| | | }) |
| | | }, |
| | | subFile(fileName){ |
| | | return fileName.substring(fileName.indexOf("fileName=")+9) |
| | | }, |
| | | downloadFile(path){ |
| | | let params = { |
| | | type: 0, |
| | | fileName: path, |
| | | }; |
| | | downloadFile(params).then((res) => { |
| | | if(res.data.type=='text/json'){ |
| | | const reader = new FileReader(); |
| | | reader.readAsText(res.data, 'utf-8'); |
| | | reader.onload = e => { |
| | | this.$message({ |
| | | type: "error", |
| | | message: JSON.parse(reader.result).msg, |
| | | duration: 3000, |
| | | }); |
| | | } |
| | | } else { |
| | | let blob = new Blob([res.data], {type: 'application/octet-stream'}) |
| | | console.log(blob) |
| | | let blobUrl = window.URL.createObjectURL(blob) |
| | | let downloadElement = document.createElement('a') |
| | | downloadElement.href = blobUrl |
| | | downloadElement.download = path |
| | | document.body.appendChild(downloadElement) |
| | | downloadElement.click() |
| | | document.body.removeChild(downloadElement) |
| | | window.URL.revokeObjectURL(blobUrl) |
| | | } |
| | | }); |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | |
| | | </el-row> |
| | | <el-table :data="tableData" style="width: 100%" @selection-change="handleSelectionChange" v-loading="listLoading"> |
| | | <el-table-column type="selection" width="55" align="center"></el-table-column> |
| | | <el-table-column prop="number" label="编号" align="center" width="120"></el-table-column> |
| | | <el-table-column prop="number" label="编号" align="center" width="120"> |
| | | <template slot-scope="scope"> |
| | | <div class="blue-font-color" @click="showDetails(scope.row)">{{ scope.row.number }}</div> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="check_branch" label="检查部门" align="center" width="120"></el-table-column> |
| | | <el-table-column prop="check_man" label="检查人" align="center" width="120"></el-table-column> |
| | | <el-table-column prop="checktype" label="检查类别" align="center"></el-table-column> |
| | |
| | | } |
| | | }) |
| | | }, |
| | | showDetails(row){ |
| | | this.$router.push({ |
| | | path: "/dangerDetails", |
| | | query:{"id":row.id} |
| | | }) |
| | | }, |
| | | typeChange(val){ |
| | | this.listQuery.type = val; |
| | | if (val == 1){ |
| | |
| | | > |
| | | <template slot-scope="scope"> |
| | | <span size="medium">{{ scope.row.content }}</span> |
| | | <a v-for="item in scope.row.realFileName" |
| | | :href="scope.row.url+'/'+item"> |
| | | {{ item.split("fileName=")[1] }} |
| | | </a> |
| | | <span v-for="item in scope.row.realFileName"> |
| | | <el-link type="primary" @click="downloadFile(subFile(item))"> |
| | | {{subFile(item)}} |
| | | </el-link> |
| | | </span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | |
| | | <script> |
| | | import Titlename from "../../components/Titlename/index.vue"; |
| | | import {sendDangerNext, getDangerDetails, getWfRecordList} from "@/api/sgyhpczl/recheckCancellationNumber"; |
| | | import {downloadFile} from "@/api/sgyhpczl/fileUtils"; |
| | | |
| | | export default { |
| | | components: {Titlename}, |
| | |
| | | path:"/hiddenDangerRectification" |
| | | }) |
| | | } |
| | | }, |
| | | subFile(fileName){ |
| | | return fileName.substring(fileName.indexOf("fileName=")+9) |
| | | }, |
| | | downloadFile(path){ |
| | | let params = { |
| | | type: 0, |
| | | fileName: path, |
| | | }; |
| | | downloadFile(params).then((res) => { |
| | | if(res.data.type=='text/json'){ |
| | | const reader = new FileReader(); |
| | | reader.readAsText(res.data, 'utf-8'); |
| | | reader.onload = e => { |
| | | this.$message({ |
| | | type: "error", |
| | | message: JSON.parse(reader.result).msg, |
| | | duration: 3000, |
| | | }); |
| | | } |
| | | } else { |
| | | let blob = new Blob([res.data], {type: 'application/octet-stream'}) |
| | | console.log(blob) |
| | | let blobUrl = window.URL.createObjectURL(blob) |
| | | let downloadElement = document.createElement('a') |
| | | downloadElement.href = blobUrl |
| | | downloadElement.download = path |
| | | document.body.appendChild(downloadElement) |
| | | downloadElement.click() |
| | | document.body.removeChild(downloadElement) |
| | | window.URL.revokeObjectURL(blobUrl) |
| | | } |
| | | }); |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | |
| | | > |
| | | <template slot-scope="scope"> |
| | | <span size="medium">{{ scope.row.content }}</span> |
| | | <a v-for="item in scope.row.realFileName" |
| | | :href="scope.row.url+'/'+item"> |
| | | {{ item.split("fileName=")[1] }} |
| | | </a> |
| | | <span v-for="item in scope.row.realFileName"> |
| | | <el-link type="primary" @click="downloadFile(subFile(item))"> |
| | | {{subFile(item)}} |
| | | </el-link> |
| | | </span> |
| | | <!-- <a v-for="item in scope.row.realFileName"--> |
| | | <!-- :href="scope.row.url+'/'+item">--> |
| | | <!-- {{ item.split("fileName=")[1] }}--> |
| | | <!-- </a>--> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | |
| | | </el-form> |
| | | <el-form :model="sendData" :rules="rules" ref="sendData" label-width="150px" class="demo-ruleForm" |
| | | style="margin: 0 14% 0 16%;"> |
| | | > |
| | | |
| | | <el-row> |
| | | <el-col :span="22"> |
| | | <el-form-item label="发送流程" prop="name"> |
| | |
| | | <script> |
| | | import Titlename from "../../components/Titlename/index.vue"; |
| | | import {sendDangerNext, getDangerDetails, getWfRecordList} from "@/api/sgyhpczl/recheckCancellationNumber"; |
| | | import {downloadFile} from "@/api/sgyhpczl/fileUtils"; |
| | | |
| | | export default { |
| | | components: {Titlename}, |
| | |
| | | this.$router.push({ |
| | | path: "/delayHiddenDangerRectification" |
| | | }) |
| | | }, |
| | | subFile(fileName){ |
| | | return fileName.substring(fileName.indexOf("fileName=")+9) |
| | | }, |
| | | downloadFile(path){ |
| | | let params = { |
| | | type: 0, |
| | | fileName: path, |
| | | }; |
| | | downloadFile(params).then((res) => { |
| | | if(res.data.type=='text/json'){ |
| | | const reader = new FileReader(); |
| | | reader.readAsText(res.data, 'utf-8'); |
| | | reader.onload = e => { |
| | | this.$message({ |
| | | type: "error", |
| | | message: JSON.parse(reader.result).msg, |
| | | duration: 3000, |
| | | }); |
| | | } |
| | | } else { |
| | | let blob = new Blob([res.data], {type: 'application/octet-stream'}) |
| | | console.log(blob) |
| | | let blobUrl = window.URL.createObjectURL(blob) |
| | | let downloadElement = document.createElement('a') |
| | | downloadElement.href = blobUrl |
| | | downloadElement.download = path |
| | | document.body.appendChild(downloadElement) |
| | | downloadElement.click() |
| | | document.body.removeChild(downloadElement) |
| | | window.URL.revokeObjectURL(blobUrl) |
| | | } |
| | | }); |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | |
| | | width="260"> |
| | | <template slot-scope="scope"> |
| | | <span size="medium">{{ scope.row.content }}</span> |
| | | <a v-for="item in scope.row.realFileName" |
| | | :href="scope.row.url+'/'+item"> |
| | | {{ item.split("fileName=")[1] }} |
| | | </a> |
| | | <span v-for="item in scope.row.realFileName"> |
| | | <el-link type="primary" @click="downloadFile(subFile(item))"> |
| | | {{subFile(item)}} |
| | | </el-link> |
| | | </span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | |
| | | <script> |
| | | import Titlename from "../../components/Titlename/index.vue"; |
| | | import {sendDangerNext, getDangerDetails, getWfRecordList} from "@/api/sgyhpczl/recheckCancellationNumber"; |
| | | import {downloadFile} from "@/api/sgyhpczl/fileUtils"; |
| | | |
| | | export default { |
| | | components: {Titlename}, |
| | |
| | | this.$router.push({ |
| | | path:"/hiddenDangerRectification" |
| | | }) |
| | | }, |
| | | subFile(fileName){ |
| | | return fileName.substring(fileName.indexOf("fileName=")+9) |
| | | }, |
| | | downloadFile(path){ |
| | | let params = { |
| | | type: 0, |
| | | fileName: path, |
| | | }; |
| | | downloadFile(params).then((res) => { |
| | | if(res.data.type=='text/json'){ |
| | | const reader = new FileReader(); |
| | | reader.readAsText(res.data, 'utf-8'); |
| | | reader.onload = e => { |
| | | this.$message({ |
| | | type: "error", |
| | | message: JSON.parse(reader.result).msg, |
| | | duration: 3000, |
| | | }); |
| | | } |
| | | } else { |
| | | let blob = new Blob([res.data], {type: 'application/octet-stream'}) |
| | | console.log(blob) |
| | | let blobUrl = window.URL.createObjectURL(blob) |
| | | let downloadElement = document.createElement('a') |
| | | downloadElement.href = blobUrl |
| | | downloadElement.download = path |
| | | document.body.appendChild(downloadElement) |
| | | downloadElement.click() |
| | | document.body.removeChild(downloadElement) |
| | | window.URL.revokeObjectURL(blobUrl) |
| | | } |
| | | }); |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | |
| | | width="260"> |
| | | <template slot-scope="scope"> |
| | | <span size="medium">{{ scope.row.content }}</span> |
| | | <a v-for="item in scope.row.realFileName" |
| | | :href="scope.row.url+'/'+item"> |
| | | {{ item.split("fileName=")[1] }} |
| | | </a> |
| | | <span v-for="item in scope.row.realFileName"> |
| | | <el-link type="primary" @click="downloadFile(subFile(item))"> |
| | | {{subFile(item)}} |
| | | </el-link> |
| | | </span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | |
| | | <script> |
| | | import Titlename from "../../components/Titlename/index.vue"; |
| | | import {sendDangerNext, getDangerDetails, getWfRecordList} from "@/api/sgyhpczl/recheckCancellationNumber"; |
| | | import {downloadFile} from "@/api/sgyhpczl/fileUtils"; |
| | | |
| | | export default { |
| | | components: {Titlename}, |
| | |
| | | this.$router.push({ |
| | | path: "/recheckCancellationNumber" |
| | | }) |
| | | }, |
| | | subFile(fileName){ |
| | | return fileName.substring(fileName.indexOf("fileName=")+9) |
| | | }, |
| | | downloadFile(path){ |
| | | let params = { |
| | | type: 0, |
| | | fileName: path, |
| | | }; |
| | | downloadFile(params).then((res) => { |
| | | if(res.data.type=='text/json'){ |
| | | const reader = new FileReader(); |
| | | reader.readAsText(res.data, 'utf-8'); |
| | | reader.onload = e => { |
| | | this.$message({ |
| | | type: "error", |
| | | message: JSON.parse(reader.result).msg, |
| | | duration: 3000, |
| | | }); |
| | | } |
| | | } else { |
| | | let blob = new Blob([res.data], {type: 'application/octet-stream'}) |
| | | console.log(blob) |
| | | let blobUrl = window.URL.createObjectURL(blob) |
| | | let downloadElement = document.createElement('a') |
| | | downloadElement.href = blobUrl |
| | | downloadElement.download = path |
| | | document.body.appendChild(downloadElement) |
| | | downloadElement.click() |
| | | document.body.removeChild(downloadElement) |
| | | window.URL.revokeObjectURL(blobUrl) |
| | | } |
| | | }); |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | |
| | | import {getPageList, dowloand_do, addOrEdit, del, revoke, put} from "@/api/sgyhpczl/troubleshooting"; |
| | | import {uploadFile} from "@/api/sgyhpczl/hiddenDangerRectification"; |
| | | import {deepClone} from '@/utils' |
| | | import {downloadFile} from "@/api/sgyhpczl/fileUtils"; |
| | | |
| | | import { |
| | | initYHLX, |