luobisheng
2022-11-22 35c30ecf074b292e955d96df7a713a2166daff0e
src/views/operate/disposal/casepool/dispatch/index.vue
@@ -81,14 +81,14 @@
                <!-- 详情页展示 -->
                <el-dialog :visible.sync="dialogView" width="80%" title="基础信息(人工)" v-if="dialogView"
                    :before-close="handleClose">
                    <MyDetail :info=info v-if="mystatus==1 ? true:false"></MyDetail>
                    <MyDetail :info=info v-if="mystatus===1"></MyDetail>
                    <MyIllDetail :info=info v-else></MyIllDetail>
                </el-dialog>
                <!-- 上传页面 -->
                <el-dialog :visible.sync="dialogUpload" width="80%" title="上传处置结果" v-if="dialogUpload"
                    :before-close="handleClose">
                    <uploadVio v-if="mystatus === 1" :caseId="caseId" :mycode="caseCode"  @closeDialog="closeDialog"></uploadVio>
                    <uploadIll v-else :caseId="caseId" :mycode="caseCode" @closeDialog="closeDialog"></uploadIll>
                    <uploadVio v-if="mystatus === 1" :caseId="caseId" :mycode="caseCode" :vioData="vioData"  @closeDialog="closeDialog"></uploadVio>
                    <uploadIll v-else :caseId="caseId" :mycode="caseCode" @closeDialog="closeDialog" :illData="illData"></uploadIll>
                </el-dialog>
                <!-- tools -->
                <div class="tools">
@@ -109,8 +109,7 @@
                    </div>
                    <div class="pagination">
                        <el-pagination background :current-page="currentPage" layout="prev, pager, next"
                            :total="totalNum" :page-size="pageSize" @current-change="changeCurrentPage"
                            @prev-click="handlePrev" @next-click="handleNext">
                            :total="totalNum" :page-size="pageSize" @current-change="changeCurrentPage">
                        </el-pagination>
                    </div>
                </div>
@@ -123,10 +122,10 @@
import uploadIll from "./updateUser/uploadResult/ill"
import MyDetail from '@/components/detail'
import MyIllDetail from '@/components/illdetail'
import casequery from "@/api/operate/casequery";
import helper from '@/utils/mydate'
export default {
    components: {
        // updateUser,
        uploadVio, uploadIll, MyDetail,MyIllDetail
    },
    data() {
@@ -134,7 +133,6 @@
            tableData: [],
            context: "",
            dialogUpload: false,
            // dialogUpdate: false,
            dialogView: false,
            info: {},
            totalNum: null,
@@ -179,7 +177,9 @@
            statusArr: [],
            mystatus: 1,
            caseId: '',
            caseCode:null,
            caseCode: null,
            vioData: null,
            illData: null
        }
    },
    created() {
@@ -194,14 +194,12 @@
    methods: {
        // 顶部下拉框
        setMystatus(value) {
            console.log(value);
            this.statusArr[1] = value;
            this.changeTypeChecked(value - 1);
            this.getUserList();
        },
        // 批量删除
        mulDelete(idArr) {
            console.log(idArr);
            this.$axios({
                method: 'delete',
                url: 'sccg/violations/batch_delete?ids=' + idArr,
@@ -215,7 +213,6 @@
        },
        // 执行下拉框操作
        selectChange(list) {
            console.log(this.tempList);
            if (this.tempList.length !== 0) {
                if (list === 3) {
                    this.preMyIdx = list;
@@ -235,11 +232,7 @@
            list.forEach(item => {
                this.tempList.push(item.code);
            })
            if (list.length === this.tableData.length) {
                this.all = true;
            } else {
                this.all = false
            }
            this.all = list.length === this.tableData.length;
        },
        // 全选
        selectAll() {
@@ -253,10 +246,8 @@
        },
        // 删除单条数据
        handleDelete({ number }) {
            console.log(number);
            this.$confirm('确认删除?')
                .then(_ => {
                    console.log(1);
                    this.$axios({
                        method: 'delete',
                        url: `sccg/violations/delete?id=${number}`,
@@ -286,38 +277,22 @@
        // 更改违规/违建
        changeTypeChecked(idx) {
            this.typeList.forEach((item, index) => {
                if (index === idx) {
                    item.checked = true;
                } else {
                    item.checked = false;
                }
                item.checked = index === idx;
            })
            this.mystatus = idx + 1;
            console.log(this.mystatus);
            this.statusArr[1] = this.typeList[idx].value;
            this.getUserList();
        },
        // 设置表格斑马纹
        tableRowClassName({ row, rowIndex }) {
            if ((rowIndex + 1) % 2 == 0) {
            if ((rowIndex + 1) % 2 === 0) {
                return 'warning-row';
            } else {
                return 'success-row';
            }
            return '';
        },
        // 当前页改变触发事件
        changeCurrentPage(page) {
            this.currentPage = page;
            this.getUserList();
        },
        // 上一页点击事件
        handlePrev(page) {
            this.currentPage = page;
            this.getUserList();
        },
        // 下一页点击事件
        handleNext(page) {
            this.currentPage = page;
            this.getUserList();
        },
@@ -325,7 +300,6 @@
            this.$confirm('确认关闭?')
                .then(_ => {
                    this.dialogUpload = false;
                    // this.dialogUpdate = false;
                    done();
                })
                .catch(_ => { });
@@ -344,11 +318,15 @@
                    this.dialogView = true;
                })
        },
        opernDialog(data) {
            this.dialogUpload = true;
            this.caseId = data.id;
            this.caseCode = data.code
            // console.log(data);
        async opernDialog(data) {
            await casequery.getBaseCaseDetail(data.code)
                .then(({ baseCase, currentSitVo, filesPictureVo, handlePassVo }) => {
                  this.vioData = currentSitVo;
                })
                .catch(err => this.$message.error(err))
          this.dialogUpload = true;
          this.caseId = data.id;
          this.caseCode = data.code;
        },
        // 关闭上传界面
        closeDialog({ flag }) {
@@ -370,7 +348,6 @@
    header {
        background-color: #09152f;
        border: 1pox solid #fff;
        .headerContent {
            padding: 0 40px;
@@ -430,7 +407,6 @@
        background-color: #09152f;
        margin-top: 20px;
        padding-bottom: 50px;
        border: 1pox solid #fff;
        .btn span:hover {
            cursor: pointer;