| | |
| | | <el-button type="primary" @click="search">查询</el-button> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" @click="addDialogOpen">添加</el-button> |
| | | <el-button type="primary" @click="addAduitDialogVisible=true">添加</el-button> |
| | | </el-form-item> |
| | | |
| | | <el-form-item> |
| | | <el-upload name="multipartFile" class="upload-demo" action="/api/cause/upload " |
| | | :before-upload="beforeAvatarUpload" :on-preview="handlePreview" :on-success="respond" :limit="1"> |
| | | <el-upload name="multipartFile" class="upload-demo" action="/api/cause/upload " :show-file-list="false" |
| | | :before-upload="beforeAvatarUpload" :on-success="respond" :limit="1"> |
| | | <el-button type="primary">导入</el-button> |
| | | </el-upload> |
| | | </el-form-item> |
| | |
| | | <el-table-column prop="ctime" label="创建日期" width="160" header-align="center" align="center"> |
| | | </el-table-column> |
| | | <el-table-column label="操作" width="240" header-align="center" align="center"> |
| | | <template slot-scope="scope"> |
| | | <el-button type="text" size="medium" @click="handleAudit(scope.row)">编辑</el-button> |
| | | <el-button type="text" size="medium" @click="handleAudit(scope.row)">报案人员</el-button> |
| | | <el-button type="text" size="medium" @click="handleAudit(scope.row)">群公告</el-button> |
| | | <el-button type="text" size="medium" @click="handleAudit(scope.row)" style="color:#ff0000">删除</el-button> |
| | | <el-button type="text" size="medium" @click="removeCause(scope.row.id)" style="color:#ff0000">删除 |
| | | </el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | </template> |
| | | <el-pagination @current-change="handleCurrentChange" :current-page="queryInfo.current" :page-size="queryInfo.size" |
| | | layout="prev, pager, next" :total="total"></el-pagination> |
| | | </el-card> |
| | | |
| | | <!--添加人员弹窗--> |
| | | <el-dialog title="添加" :visible.sync="addAduitDialogVisible" width="50%" :before-close="addAduitClose"> |
| | | <el-row :gutter="15"> |
| | | <el-form ref="addAduitForm" :model="auditFrom" :rules="rules" size="medium" label-width="100px"> |
| | | <el-col :span="12"> |
| | | <el-form-item label="报案人 " prop="reporterName"> |
| | | <el-input v-model="auditFrom.reporterName" placeholder="请输入报案人 " clearable |
| | | :style="{ width: '100%' }"> |
| | | </el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="手机号码" prop="mobile"> |
| | | <el-input v-model="auditFrom.mobile" placeholder="请输入手机号码" clearable :style="{ width: '100%' }"> |
| | | </el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="身份证号" prop="idcard"> |
| | | <el-input v-model="auditFrom.idcard" placeholder="请输入身份证号" clearable :style="{ width: '100%' }"> |
| | | </el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="被骗时间" prop="cheatTime"> |
| | | <el-date-picker v-model="auditFrom.tmpTime" type="datetime" placeholder="选择日期时间" |
| | | :style="{ width: '100%' }" format="yyyy-MM-dd HH:mm:ss" :value-format="auditFrom.cheatTime"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="涉案金额" prop="amountInvolved"> |
| | | <el-input v-model="auditFrom.amountInvolved" placeholder="请输入涉案金额" clearable |
| | | :style="{ width: '100%' }"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="案件描述" prop="reportDescription"> |
| | | <el-input v-model="auditFrom.reportDescription" placeholder="请输入案件描述" clearable |
| | | :style="{ width: '100%' }"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="补充信息" prop="information"> |
| | | <el-input v-model="auditFrom.information" type="textarea" placeholder="请输入补充信息" |
| | | :autosize="{ minRows: 4, maxRows: 4 }" :style="{ width: '100%' }"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="关联案件" prop="causeId"> |
| | | <el-select v-model="auditFrom.causeId" placeholder="请选择下拉选择" clearable :style="{ width: '50%' }"> |
| | | <el-option v-for="item in causeOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-form> |
| | | </el-row> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="addAduitDialogVisible = false">取 消</el-button> |
| | | <el-button type="primary" @click="addAduit">确 定</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import { |
| | | casueList |
| | | casueList, |
| | | remove |
| | | } from '@/api/cause' |
| | | |
| | | export default { |
| | | name: "Entry", |
| | | data() { |
| | | return { |
| | | causeOptions: [], |
| | | auditFrom: { |
| | | reporterName: '', |
| | | mobile: '', |
| | | idcard: '', |
| | | cheatTime: '', |
| | | amountInvolved: '', |
| | | reportDescription: '', |
| | | information: '', |
| | | reportMaterials: "", |
| | | causeId: '', |
| | | fileList: [], |
| | | tmpTime: '', |
| | | }, |
| | | casueList: [], |
| | | queryInfo: { |
| | | cause: '', |
| | |
| | | } |
| | | ], |
| | | total: 0, |
| | | addAduitDialogVisible: false, |
| | | rules: { |
| | | reporterName: [{ |
| | | required: true, |
| | | message: '请输入报案人 ', |
| | | trigger: 'blur' |
| | | }], |
| | | mobile: [{ |
| | | required: true, |
| | | message: '请输入手机号码', |
| | | trigger: 'blur' |
| | | }], |
| | | idcard: [{ |
| | | required: true, |
| | | message: '请输入身份证号', |
| | | trigger: 'blur' |
| | | }], |
| | | tmpTime: [{ |
| | | required: true, |
| | | message: '请输入被骗时间', |
| | | trigger: 'blur' |
| | | }], |
| | | amountInvolved: [{ |
| | | required: true, |
| | | message: '请输入涉案金额', |
| | | trigger: 'blur' |
| | | }], |
| | | reportDescription: [{ |
| | | required: true, |
| | | message: '请输入案件描述', |
| | | trigger: 'blur' |
| | | }], |
| | | information: [{ |
| | | required: true, |
| | | message: '请输入补充信息', |
| | | trigger: 'blur' |
| | | }], |
| | | causeId: [{ |
| | | required: true, |
| | | message: '请选择下拉选择', |
| | | trigger: 'change' |
| | | }], |
| | | }, |
| | | } |
| | | }, |
| | | created() { |
| | |
| | | }, |
| | | methods: |
| | | { |
| | | addAduitClose() { |
| | | this.addAduitDialogVisible = false |
| | | this.$refs.addAduitForm.resetFields() |
| | | this.picShow = "" |
| | | }, |
| | | addAduit() { |
| | | this.$refs.addAduitForm.validate(async (vaild) => { |
| | | if (!vaild) return this.$message.error('输入有误') |
| | | this.auditFrom.reportMaterials = this.auditFrom.fileList.map(i => i.data).join(',') |
| | | report(this.auditFrom).then(res => { |
| | | this.$message.success('提交成功') |
| | | this.addAduitDialogVisible = false |
| | | this.getList() |
| | | }).catch(err => { |
| | | this.addAduitClose() |
| | | }) |
| | | }) |
| | | }, |
| | | respond(res) { |
| | | if (res.code == 200) { |
| | | this.$message({ |
| | |
| | | type: 'error' |
| | | }) |
| | | } |
| | | location.reload(); |
| | | }, |
| | | beforeAvatarUpload(file) { |
| | | let Xls = file.name.split('.'); |
| | |
| | | res => { |
| | | this.total = res.data.data.total |
| | | this.casueList = res.data.data.records |
| | | console.log(res.data.data.records); |
| | | } |
| | | ) |
| | | |
| | |
| | | handleCurrentChange(val) { |
| | | this.queryInfo.current = val; |
| | | this.getList(); |
| | | }, |
| | | removeCause(val) { |
| | | remove(val).then( |
| | | res => { |
| | | this.$message({ |
| | | message: '删除成功', |
| | | type: 'success' |
| | | }); |
| | | this.getList(); |
| | | } |
| | | ) |
| | | } |
| | | } |
| | | } |