| | |
| | | return http.get('/sccg/base_case/query_case', params); |
| | | }, |
| | | |
| | | // 获取处置结果详情 |
| | | getBaseCaseDetail: (id) => { |
| | | return http.get('/sccg/base_case/baseCaseDetail/' + id); |
| | | }, |
| | | |
| | | // 上传处置结果 |
| | | updateDisposeResult: (params) => { |
| | | return http.post('/sccg/dispatch_handle/addition_dispose_result', params); |
| | | } |
| | | } |
| | |
| | | <template> |
| | | <div class="my-upload"> |
| | | <el-upload |
| | | <div v-if="pictureList.length > 0" class="image-box"> |
| | | <div v-for="image in pictureList" class="image-box-item"> |
| | | <i @click="handleDeletePicture(image)" class="el-icon-delete image-delete-icon"></i> |
| | | <el-image :key="image" class="image-content" :src="image" ></el-image> |
| | | </div> |
| | | </div> |
| | | <el-upload |
| | | :file-list="fileList" |
| | | action="/sccg/file/medias" |
| | | :multiple="multiple" |
| | |
| | | :list-type="listType" |
| | | :on-remove="handleRemove" |
| | | :headers="getToken()"> |
| | | <div class="upload-btn"> |
| | | <i class="el-icon-plus"></i> |
| | | <span>上传图片</span> |
| | | </div> |
| | | <div class="upload-btn"> |
| | | <i class="el-icon-plus"></i> |
| | | <span>上传图片</span> |
| | | </div> |
| | | </el-upload> |
| | | </div> |
| | | </template> |
| | |
| | | // 文件列表 |
| | | fileList: [], |
| | | // 是否显示文件列表 |
| | | flag: true, |
| | | flag: false, |
| | | // 多选 |
| | | multiple: false, |
| | | // 限制 |
| | |
| | | // 移除文件 |
| | | handleRemove(file, fileList){ |
| | | this.$emit('delPictureUrl',{url:file.response.data.url1}); |
| | | }, |
| | | |
| | | handleDeletePicture(imageUrl) { |
| | | this.$emit('delPictureUrl', { url: imageUrl }); |
| | | } |
| | | }, |
| | | props: { |
| | |
| | | </script> |
| | | <style lang="scss" scoped> |
| | | .my-upload { |
| | | display: flex; |
| | | flex-wrap: nowrap; |
| | | justify-content: flex-start; |
| | | margin-right: 5px; |
| | | |
| | | .upload-btn { |
| | | display: flex; |
| | | flex-direction: column; |
| | | justify-content: center; |
| | | align-items: center; |
| | | border-radius: 4px; |
| | | width: 100px; |
| | | height: 100px; |
| | | |
| | | &:hover i{ |
| | | color: #409eff; |
| | | } |
| | | |
| | | i { |
| | | font-size: 30px; |
| | | font-weight: 650; |
| | | } |
| | | |
| | | span { |
| | | line-height: 22px; |
| | | } |
| | | } |
| | | .image-box { |
| | | display: flex; |
| | | height: 100px; |
| | | margin: 0 10px; |
| | | |
| | | .image-content { |
| | | width: 100px; |
| | | height: 100px; |
| | | } |
| | | .image-delete-icon { |
| | | position: relative; |
| | | bottom: calc(100% - 50px); |
| | | left: calc(100% - 50px); |
| | | opacity: 0; |
| | | } |
| | | |
| | | .image-box-item:hover { |
| | | color: #ffffff; |
| | | opacity: .5; |
| | | .image-delete-icon { |
| | | z-index: 2; |
| | | opacity: 1; |
| | | } |
| | | } |
| | | } |
| | | |
| | | :deep(.el-upload--picture-card) { |
| | | width: 100px; |
| | |
| | | :deep(.el-upload-list__item){ |
| | | width: 100px; |
| | | height: 100px; |
| | | } |
| | | //.file-list { |
| | | // display: flex; |
| | | // flex-wrap: nowrap; |
| | | //} |
| | | .upload-btn { |
| | | display: flex; |
| | | flex-direction: column; |
| | | justify-content: center; |
| | | align-items: center; |
| | | border-radius: 4px; |
| | | width: 100px; |
| | | height: 100px; |
| | | |
| | | &:hover i{ |
| | | color: #409eff; |
| | | } |
| | | |
| | | i { |
| | | font-size: 30px; |
| | | font-weight: 650; |
| | | } |
| | | |
| | | span { |
| | | line-height: 22px; |
| | | } |
| | | } |
| | | .uploaded-image { |
| | | width: 0; |
| | | height: 100px; |
| | | display: flex; |
| | | } |
| | | } |
| | | </style> |
| | |
| | | <!-- 上传页面 --> |
| | | <el-dialog :visible.sync="dialogUpload" width="80%" title="上传处置结果" v-if="dialogUpload" |
| | | :before-close="handleClose"> |
| | | <uploadVio v-if="mystatus === 1" :caseId="caseId" :mycode="caseCode" :vioData="vioData" @closeDialog="closeDialog"></uploadVio> |
| | | <uploadVio v-if="mystatus === 1" :imageResourceId="imageResourceId" :caseId="caseId" :mycode="caseCode" :vioData="vioData" @closeDialog="closeDialog"></uploadVio> |
| | | <uploadIll v-else :caseId="caseId" :mycode="caseCode" @closeDialog="closeDialog" :illData="illData"></uploadIll> |
| | | </el-dialog> |
| | | <!-- tools --> |
| | |
| | | data() { |
| | | return { |
| | | tableData: [], |
| | | imageResourceId: null, |
| | | context: "", |
| | | dialogUpload: false, |
| | | dialogView: false, |
| | |
| | | await casequery.getBaseCaseDetail(data.code) |
| | | .then(({ baseCase, currentSitVo, filesPictureVo, handlePassVo }) => { |
| | | this.vioData = currentSitVo; |
| | | this.imageResourceId = filesPictureVo.imageResources[0].id; |
| | | }) |
| | | .catch(err => this.$message.error(err)) |
| | | this.dialogUpload = true; |
| | |
| | | this.caseCode = data.code; |
| | | }, |
| | | // 关闭上传界面 |
| | | closeDialog({ flag }) { |
| | | this.dialogUpload = flag; |
| | | this.getUserList(); |
| | | closeDialog() { |
| | | this.dialogUpload = false; |
| | | this.getUserList(); |
| | | }, |
| | | // 处理时间 |
| | | filterTime(time) { |
| | |
| | | <el-form ref="arriveForm" label-width="160px" :model="arrive" :rules="arriveRules" autoComplete="on"> |
| | | <!-- 到达时间 --> |
| | | <el-form-item label="到达时间:" prop="arrivalTime"> |
| | | <el-date-picker v-model="arrive.arrivalTime" type="datetime" placeholder="选择到达时间"> |
| | | <el-date-picker v-model="arrive.arrivalTime" value-format="yyyy-MM-dd HH:mm:ss" type="datetime" placeholder="选择到达时间"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | <!-- 到达地址 --> |
| | |
| | | <!-- 现场情况照片 --> |
| | | <el-form-item label="现场情况照片:" prop="situationPic"> |
| | | <div class="upImg" > |
| | | <MyUpload @setPictureUrl="setPicUrl" @delPictureUrl="delPicUrl"></MyUpload> |
| | | <MyUpload :picture-list="arrive.situationPic" @setPictureUrl="setPicUrl" @delPictureUrl="delPicUrl"></MyUpload> |
| | | <div class="tip">{{ arrive.situationPic.length }} / 4</div> |
| | | </div> |
| | | </el-form-item> |
| | |
| | | </template> |
| | | <script> |
| | | import MyUpload from "@/components/myUpload" |
| | | import { deepClone } from "@/utils/helper"; |
| | | export default { |
| | | components: { |
| | | MyUpload |
| | |
| | | } |
| | | }, |
| | | created() { |
| | | this.arrive = this.arriveData; |
| | | this.arrive = deepClone(this.arriveData); |
| | | if (this.arriveData) { |
| | | this.arrive.situationPic = this.arriveData.situationPic.split(','); |
| | | } |
| | | }, |
| | | methods: { |
| | | handleSuccess(res, file, filelist) { |
| | |
| | | delPicUrl({url}){ |
| | | const baseUrl = 'http://140.143.152.226:8410/'; |
| | | this.arrive.situationPic.splice(this.arrive.situationPic.indexOf(baseUrl + url),1); |
| | | console.log(this.arrive.situationPic); |
| | | } |
| | | }, |
| | | watch: { |
| | | 'arrive.situationPic.length': { |
| | | handler(newLen, oldLen) { |
| | | if (newLen !== 0) { |
| | | this.$refs.arriveForm.validateField('situationPic'); |
| | | } |
| | | }, |
| | | deep: true, |
| | | } |
| | | } |
| | | } |
| | |
| | | </div> |
| | | <!-- 时间 --> |
| | | <el-form-item label="时间:" prop="investigationTime"> |
| | | <el-date-picker v-model="evidence.investigationTime" type="datetime" placeholder="选择时间"> |
| | | <el-date-picker v-model="evidence.investigationTime" value-format="yyyy-MM-dd HH:mm:ss" type="datetime" placeholder="选择时间"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | <!-- 地址 --> |
| | |
| | | <el-form ref="userForm" label-width="120px" :model="user" :rules="userRules" autoComplete="on"> |
| | | <!-- 类型 --> |
| | | <el-form-item label="类型:" prop="illegalType"> |
| | | <el-input v-model="basecase"></el-input> |
| | | <el-input v-model="user.illegalType"></el-input> |
| | | </el-form-item> |
| | | <!-- 姓名、手机号 --> |
| | | <div class="user-item"> |
| | |
| | | </div> |
| | | </template> |
| | | <script> |
| | | import { getTypeList } from '@/utils/helper' |
| | | import {validateName,validatePhone,validateCardId} from '@/utils/validate' |
| | | import { deepClone, getTypeList } from '@/utils/helper' |
| | | import { validateName, validatePhone, validateCardId } from '@/utils/validate' |
| | | import MyUpload from "@/components/myUpload" |
| | | export default { |
| | | components: { |
| | |
| | | await this.getCardTypeList(); |
| | | await this.getSchoolList(); |
| | | await this.getNationList(); |
| | | this.user.illegalType = JSON.parse(JSON.stringify(this.mytype)); |
| | | if (this.evienceData) { |
| | | this.evidence = this.evienceData; |
| | | this.evidence.pic = this.evidence.pic.split(','); |
| | | if (this.evidenceData) { |
| | | this.evidence = deepClone(this.evidenceData); |
| | | this.evidence.pic = this.evidenceData.pic.split(','); |
| | | this.user = this.evidence.partyInfo; |
| | | this.evidence.investigationTime = this.evidence.createTime; |
| | | this.evidence.userInfo = this.evidence.partyInfo.name; |
| | | this.user.illegalType = JSON.parse(JSON.stringify(this.mytype)); |
| | | } |
| | | }, |
| | | methods: { |
| | |
| | | }, |
| | | // 检验user |
| | | checkUser() { |
| | | debugger; |
| | | this.$refs.userForm.validate((valid) => { |
| | | if (valid) { |
| | | this.userFlag = false; |
| | |
| | | setPicUrl({ url }) { |
| | | const baseUrl = 'http://140.143.152.226:8410/'; |
| | | if (this.evidence.pic.length < 4) { |
| | | this.evidence.pic.push(baseUrl + url) |
| | | this.evidence.pic.push(baseUrl + url); |
| | | } |
| | | }, |
| | | //删除图片 |
| | |
| | | this.evidence.pic.splice(this.evidence.pic.indexOf(baseUrl + url),1); |
| | | } |
| | | }, |
| | | props:['mytype','mycode', 'evienceData'] |
| | | props:['mytype','mycode', 'evidenceData'] |
| | | } |
| | | </script> |
| | | <style lang="scss" scoped> |
| | |
| | | <!-- 到达现场情况 --> |
| | | <MyArrive ref="arrive" :arriveData="arriveData"></MyArrive> |
| | | <!-- 调查取证 --> |
| | | <MyEvidence ref="evidence" :evienceData="evienceData" :mytype="1" :mycode="mycode"></MyEvidence> |
| | | <MyEvidence ref="evidence" :evidenceData="evidenceData" :mytype="1" :mycode="mycode"></MyEvidence> |
| | | <!-- 底部按钮 --> |
| | | <div class="footer"> |
| | | <el-button @click="handleSubmit" type="primary">确定</el-button> |
| | |
| | | <script> |
| | | import MyArrive from '../components/arrive' |
| | | import MyEvidence from "../components/evidence" |
| | | import { parseTime } from '@/utils/index' |
| | | import casequery from "@/api/operate/casequery"; |
| | | |
| | | export default { |
| | | components: { |
| | |
| | | data() { |
| | | return { |
| | | arriveData: null, |
| | | evienceData: null |
| | | evidenceData: null |
| | | } |
| | | }, |
| | | props: ['caseId', 'closeDialog','mycode', 'vioData'], |
| | | props: ['caseId', 'closeDialog','mycode', 'vioData', 'imageResourceId'], |
| | | created() { |
| | | this.arriveData = this.vioData.arrivalSituation; |
| | | this.evienceData = this.vioData.investigation; |
| | | this.evidenceData = this.vioData.investigation; |
| | | }, |
| | | methods: { |
| | | handleSubmit() { |
| | |
| | | if (valid) { |
| | | evidenceForm.validate((flag) => { |
| | | if (flag) { |
| | | this.$axios({ |
| | | method: 'post', |
| | | url: `sccg/dispatch_handle/addition_dispose_result?caseId=`+this.caseId+'&type=1', |
| | | data:{ |
| | | arrivalAddress: arrive.arrive.arrivalAddress, |
| | | arrivalTime: parseTime(arrive.arrive.arrivalTime), |
| | | situationExplain: arrive.arrive.situationExplain, |
| | | replyExplain: arrive.arrive.replyExplain, |
| | | situationPic: `${arrive.arrive.situationPic}`, |
| | | // |
| | | undertaker: evidence.evidence.undertaker, |
| | | assistant: evidence.evidence.assistant, |
| | | investigationTime: parseTime(evidence.evidence.investigationTime), |
| | | address: evidence.evidence.address, |
| | | caseAction: evidence.evidence.caseAction, |
| | | description: evidence.evidence.description, |
| | | pic: `${evidence.evidence.pic}`, |
| | | // |
| | | name: evidence.user.name, |
| | | phoneCode: evidence.user.phoneCode, |
| | | certificateType: evidence.user.certificateType, |
| | | certificateCode: evidence.user.certificateCode, |
| | | educationDegree: evidence.user.educationDegree, |
| | | career: evidence.user.career, |
| | | work: evidence.user.work, |
| | | nation: evidence.user.nation, |
| | | nativePlace: evidence.user.nativePlace, |
| | | liveAddress: evidence.user.liveAddress, |
| | | registerAddress: evidence.user.registerAddress, |
| | | } |
| | | }) |
| | | .then(res => { |
| | | if (res.code === 200) { |
| | | this.$message({ |
| | | type: 'success', |
| | | message:'上传成功', |
| | | }) |
| | | this.$emit('closeDialog', { flag: false }); |
| | | }else{ |
| | | this.$message({ |
| | | type:'warning', |
| | | message:res.message |
| | | }) |
| | | } |
| | | }) |
| | | const arriveData = Object.assign({}, arrive.arrive); |
| | | const evidenceData = Object.assign({}, evidence.evidence); |
| | | const { partyInfo } = evidenceData; |
| | | const arrivalSituationId = arriveData.id; |
| | | const investigationId = evidenceData.id; |
| | | const partyInfoId = partyInfo.id; |
| | | const evidencePic = evidenceData.pic.join(','); |
| | | const situationPic = arriveData.situationPic.join(','); |
| | | delete evidenceData.id; |
| | | delete evidenceData.partyInfo; |
| | | delete evidenceData.pic; |
| | | delete arriveData.situationPic; |
| | | delete arriveData.id; |
| | | casequery.updateDisposeResult({ |
| | | caseId: this.caseId, |
| | | imageResourceId: this.imageResourceId, |
| | | pic: evidencePic, |
| | | arrivalSituationId, |
| | | situationPic, |
| | | partyInfoId, |
| | | investigationId, |
| | | ...arriveData, |
| | | ...evidenceData, |
| | | ...partyInfo |
| | | }) |
| | | .then(() => { |
| | | this.$message.success('操作成功'); |
| | | this.$emit('closeDialog'); |
| | | }) |
| | | .catch(err => { |
| | | this.$message.error(err); |
| | | }) |
| | | } else { |
| | | return false; |
| | | } |
| | |
| | | }; |
| | | |
| | | const validateStoreType = (rule, value, callback) => { |
| | | debugger; |
| | | if (value) { |
| | | callback(); |
| | | } else { |