Lou
2024-02-02 97483e557f956a66429016189a4355d1150fbb6f
更新
10 files modified
2 files added
1072 ■■■■■ changed files
api/place/place.js 20 ●●●●● patch | view | raw | blame | history
pages.json 9 ●●●●● patch | view | raw | blame | history
pages/user/test.vue 121 ●●●● patch | view | raw | blame | history
subPackage/house/houseNumber/index.vue 43 ●●●● patch | view | raw | blame | history
subPackage/house/houseNumber/lineItem.vue 24 ●●●● patch | view | raw | blame | history
subPackage/house/houseNumber/siteInspect.vue 11 ●●●●● patch | view | raw | blame | history
subPackage/workbench/components/cateSelector.vue 269 ●●●●● patch | view | raw | blame | history
subPackage/workbench/views/audit.vue 8 ●●●● patch | view | raw | blame | history
subPackage/workbench/views/auditList.vue 2 ●●●●● patch | view | raw | blame | history
subPackage/workbench/views/checkReform.vue 205 ●●●● patch | view | raw | blame | history
subPackage/workbench/views/cscj.vue 65 ●●●●● patch | view | raw | blame | history
subPackage/workbench/views/reformList.vue 295 ●●●●● patch | view | raw | blame | history
api/place/place.js
@@ -75,4 +75,24 @@
        method: 'GET',
        params
    })
}
//场所整改提交
export const addPlaceCheckReform = (data) => {
    return http.request({
        url: '/blade-taskPlaceRectification/taskPlaceRectification/updateRectification',
        method: 'POST',
        data: data
    })
}
//审核场所整改
export const auditPlaceCheckReform = (data) => {
    return http.request({
        url: '/blade-taskPlaceRectification/taskPlaceRectification/applyRectification',
        method: 'POST',
        data: data
    })
}
pages.json
@@ -590,6 +590,15 @@
                        "navigationBarBackgroundColor": "#fff",
                        "navigationBarTextStyle": "black"
                    }
                },
                {
                    "path": "views/reformList",
                    "style": {
                        "navigationBarTitleText": "场所整改",
                        "enablePullDownRefresh": false,
                        "navigationBarBackgroundColor": "#fff",
                        "navigationBarTextStyle": "black"
                    }
                }
            ]
        },
pages/user/test.vue
@@ -4,18 +4,16 @@
            <text class="f-28">选择标签</text>
            <u-icon name="arrow-right"></u-icon>
        </view>
        <view class="mt-20 p-20 bgc-ff" v-if="selectedCate">
        <view class="mt-20 p-20 bgc-ff" v-if="selectedItem.parentName">
            <view class="f-28">已选标签</view>
            <view class="p-20 flex flex-wrap">
                <view class="mr-20">
                    <u-tag size="mini" :text="selectedCate"></u-tag>
                    <text v-if="selectedItem.parentName">{{selectedItem.parentName}}</text>
                    <text v-if="selectedItem.childrenName">、{{selectedItem.childrenName}}</text>
                    <!-- <u-tag size="mini" :text="selectedCate"></u-tag> -->
                </view>
            </view>
        </view>
        <u-popup :show="isShow" @close="closePopup" :safeAreaInsetTop="true" mode="bottom" :closeable="true" round="12">
            <view class="popup-title fw f-30">九小场所类型</view>
@@ -23,7 +21,7 @@
            <view class="popup-list flex a-i-c">
                <scroll-view scroll-y="true" class="scroll">
                    <view class="popup-box">
                        <view :class="['box-item','f-28',item.id == selectedFId?'c-main fw':'']"
                        <view :class="['box-item','f-28',item.id == selectedTemp.parentId?'c-main fw':'']"
                            v-for="(item,index)  in  categoryList" :key="index" @click="handleSelect(item,index)">
                            {{item.title}}
                        </view>
@@ -37,7 +35,7 @@
                            {{item.title}}
                        </view> -->
                        <view :class="['box-item','f-28',item.id == selectedCId?'c-main fw':'']"
                        <view :class="['box-item','f-28',item.id == selectedTemp.childrenId?'c-main fw':'']"
                            v-for="(item,index)  in  childList" :key="index" @click="handleSelectChild(item,index)">
                            {{item.title}}
                        </view>
@@ -49,7 +47,15 @@
                <view class="popup-btn c-main" @click="closePopup">
                    取消
                </view>
                <view class="popup-btn bgc-main c-ff">
                <view
                    v-if="(childList.length && !selectedTemp.childrenId) || (!childList.length && !selectedTemp.parentId)"
                    class="popup-btn bgc-gray c-ff" @click="comfirmPopup">
                    确定
                </view>
                <view v-else class="popup-btn bgc-main c-ff" @click="comfirmPopup">
                    确定
                </view>
            </view>
@@ -75,17 +81,28 @@
                fIndex: null,
                cId: null,
                showLabelList: [],
                selectedItem: [],
                selectedCate: "",
                selectedFId: "",
                selectedCId: "",
                selectedId: ""
                selectedItem: {
                    parentId: "",
                    childrenId: "",
                    parentName: "",
                    childrenName: ""
                },
                selectedTemp: {
                    parentId: "",
                    childrenId: "",
                    parentName: "",
                    childrenName: ""
                },
                categoryId: "1752893561027239937",
                index: "",
                tempIndex: ""
            }
        },
        onLoad() {
            // this.getCategory(1);
            this.getNineTypeList()
            // this.showDefault()
        },
        methods: {
@@ -96,6 +113,7 @@
                }).then(res => {
                    console.log(res.data);
                    this.categoryList = res.data;
                    this.showDefault(res.data)
                })
            },
@@ -123,25 +141,22 @@
                })
            },
            handleSelect(item, index) {
                if (index == this.fIndex) return;
                this.fIndex = index;
                this.selectedCate = item.title;
                this.selectedFId = item.id;
                if (index == this.tempIndex) return;
                this.tempIndex = index;
                this.$set(this.selectedTemp, "parentId", item.id);
                this.$set(this.selectedTemp, "parentName", item.title);
                this.$set(this.selectedTemp, "childrenId", "");
                this.$set(this.selectedTemp, "childrenName", "");
                if (item.hasChildren) {
                    this.childList = item.children;
                } else {
                    this.childList = [];
                }
                // this.getCategory(2, item.categoryNo);
                console.table("选择父级=>", this.selectedItem)
            },
            handleSelectChild(item, index) {
                // this.childList[index].isSelect = !this.childList[index].isSelect;
                this.selectedCate = item.title;
                this.selectedCId = item.id;
                // this.getSelected()
                this.$set(this.selectedTemp, "childrenId", item.id);
                this.$set(this.selectedTemp, "childrenName", item.title);
            },
            getSelected() {
@@ -152,7 +167,6 @@
                    }
                }
                this.selectedItem = arr;
                console.table("选择子级=>", this.selectedItem);
            },
            showSelected() {
@@ -165,18 +179,59 @@
                }
            },
            closePopup() {
                this.$set(this.selectedTemp, "parentId", this.selectedItem.parentId);
                this.$set(this.selectedTemp, "parentName", this.selectedItem.parentName);
                this.$set(this.selectedTemp, "childrenId", this.selectedItem.childrenId);
                this.$set(this.selectedTemp, "childrenName", this.selectedItem.childrenName);
                this.tempIndex = this.index;
                this.childList = this.categoryList[this.index].children;
                this.isShow = false;
            },
            delTag(index) {
                this.selectedItem.splice(index, 1);
            },
            comfirmPopup() {
                this.$set(this.selectedItem, "parentId", this.selectedTemp.parentId);
                this.$set(this.selectedItem, "parentName", this.selectedTemp.parentName);
                this.$set(this.selectedItem, "childrenId", this.selectedTemp.childrenId);
                this.$set(this.selectedItem, "childrenName", this.selectedTemp.childrenName);
                this.index = this.tempIndex;
                this.isShow = false;
            },
            showDefault(data) {
                for (let i = 0, ii = data.length; i < ii; i++) {
                    console.log(2);
                    if (data[i].hasChildren) {
                        for (let k = 0, kk = data[i].children.length; k < kk; k++) {
                            if (this.categoryId == data[i].children[k].id) {
                                this.index = i;
                                this.tempIndex = i;
                                this.childList = data[i].children;
                                this.$set(this.selectedItem, "parentId", data[i].id)
                                this.$set(this.selectedItem, "parentName", data[i].title)
                                this.$set(this.selectedItem, "childrenId", data[i].children[k].id)
                                this.$set(this.selectedItem, "childrenName", data[i].children[k].title)
                                this.$set(this.selectedTemp, "parentId", data[i].id)
                                this.$set(this.selectedTemp, "parentName", data[i].title)
                                this.$set(this.selectedTemp, "childrenId", data[i].children[k].id)
                                this.$set(this.selectedTemp, "childrenName", data[i].children[k].title)
                            }
                        }
                    } else {
                        if (this.categoryId == data.id) {
                            this.$set(this.selectedItem, "parentId", data[i].id)
                            this.$set(this.selectedItem, "parentName", data[i].title)
                            this.$set(this.selectedTemp, "parentId", data[i].id)
                            this.$set(this.selectedTemp, "parentName", data[i].title)
                        }
                    }
                }
            }
        }
    }
</script>
@@ -256,4 +311,8 @@
            border: 1px solid currentColor;
        }
    }
    .bgc-gray {
        background-color: darkgray;
    }
</style>
subPackage/house/houseNumber/index.vue
@@ -146,7 +146,8 @@
    } from "@/api/place/place.js"
    import uploadMixin from "@/mixin/uploadMixin";
    import {
        bizDictionary
        bizDictionary,
        bizDictionaryTree
    } from '@/api/system/dict.js'
    export default {
        mixins: [uploadMixin],
@@ -204,7 +205,7 @@
                        value: '未完善'
                    },
                    {
                        title: '场所简介',
                        title: '备注',
                        name: 'remark',
                        value: '未完善'
                    },
@@ -360,6 +361,11 @@
                this.eventType = option.eventType;
            }
            this.getBuildingDetail()
            uni.$on("refresh", () => {
                this.getBuildingDetail()
            })
        },
        watch: {
@@ -381,6 +387,15 @@
                })
            },
            getBizDictTree(callback) {
                bizDictionaryTree({
                    code: "nineType"
                }).then(res => {
                    if (res.code == 200) {
                        callback(res.data)
                    }
                })
            },
            async getBuildingDetail() {
                // this.$nextTick(() => {
@@ -434,11 +449,27 @@
                        //     this.houseNumberData.splice(index,1)
                        // }
                        if (data.isNine == 1 && item.name == "nineType") {
                            this.getBizDict('nineType', (list) => {
                                item.value = this.$getIndex(list, data.nineType, 'dictKey',
                                    'dictValue').name
                            // this.getBizDict('nineType', (list) => {
                            //     item.value = this.$getIndex(list, data.nineType, 'dictKey',
                            //         'dictValue').name
                            // })
                            this.getBizDictTree(list => {
                                for (let i = 0, ii = list.length; i < ii; i++) {
                                    if (list[i].hasChildren) {
                                        for (let k = 0, kk = list[i].children.length; k < kk; k++) {
                                            if (data.nineType == list[i].children[k].key) {
                                                item.value = list[i].children[k].title;
                                            }
                                        }
                                    } else {
                                        if (data.nineType == list[i].key) {
                                            item.value = list[i].title;
                                        }
                                    }
                                }
                            })
                        }
                        if (item.name == 'isFront') {
                            item.value = data.isFront == 1 ? "是" : "否"
@@ -583,7 +614,7 @@
            navToInspect() {
                uni.navigateTo({
                    url: `/subPackage/house/houseNumber/siteInspect?code=${this.stdId}`
                    url: `/subPackage/house/houseNumber/siteInspect?code=${this.stdId}&name=${this.placeName}`
                })
            }
subPackage/house/houseNumber/lineItem.vue
@@ -5,11 +5,11 @@
                <view class="title">{{ item.title }}</view>
                <view class="value" v-if="!item.isUseSlot">{{ item.value }}</view>
            </view>
            <view class="pic">
            <view class="pic">
                <slot name="pic" :sdate="item"></slot>
            </view>
            <view class="other">
                <slot name="other" :sdate="item"></slot>
            </view>
            <view class="other">
                <slot name="other" :sdate="item"></slot>
            </view>
        </view>
    </view>
@@ -41,18 +41,19 @@
                display: flex;
                justify-content: space-between;
                padding: 25rpx 0;
                font-size: 32rpx;
                font-size: 30rpx;
                background-color: #fff;
                border-bottom: 1rpx solid #f6f6f6;
                .title {
                    flex-shrink: 0;
                    flex-shrink: 0;
                    width: 200rpx;
                }
                .value {
                    color: #989898;
                    width: 50%;
                    // width: 50%;
                    width: calc(100% - 200rpx);
                    word-wrap: break-word;
                    margin-left: 20rpx;
                    text-align: right;
@@ -62,10 +63,11 @@
                    border: 0;
                }
            }
            .pic {
                display: flex;
                flex-wrap: wrap;
            }
            .pic {
                display: flex;
                flex-wrap: wrap;
            }
        }
    }
</style>
subPackage/house/houseNumber/siteInspect.vue
@@ -91,7 +91,7 @@
                </view>
            </view>
            <view class="flex j-c-s-b a-i-c mb-20" v-if="info.punishFlag == 1">
            <view class="flex j-c-s-b a-i-c mb-20" v-if="info.punishFlag == 2">
                <view class="f-28" style="width:160rpx;">处罚说明</view>
                <u-textarea v-model="info.punishRemark" placeholder="请输入处罚说明内容"
                    placeholderClass="c-99 f-26"></u-textarea>
@@ -171,11 +171,11 @@
                count: 0,
                statusList: [{
                        name: "是",
                        id: 1
                        id: 2
                    },
                    {
                        name: "否",
                        id: 2
                        id: 1
                    }
                ],
                time: Number(new Date()),
@@ -186,6 +186,7 @@
        },
        onLoad(option) {
            this.info.houseCode = option.code;
            this.info.placeName = option.name;
            this.getItem();
        },
@@ -265,7 +266,9 @@
            },
            async afterReadImgs(event, item, fIndex, cIndex) {
                this.showLoading()
                uni.showLoading({
                    title: "上传中..."
                })
                let children = this.questionList[fIndex];
                let lists = [].concat(event.file)
                let fileListLen = item.urls.length;
subPackage/workbench/components/cateSelector.vue
New file
@@ -0,0 +1,269 @@
<template>
    <view class="">
        <!-- <view class="cell  flex j-c-s-b a-i-c  bgc-ff" @click="isShow = true">
            <text class="f-28">选择标签</text>
            <u-icon name="arrow-right"></u-icon>
        </view>
        <view class="mt-20 p-20 bgc-ff" v-if="selectedItem.parentName">
            <view class="f-28">已选标签</view>
            <view class="p-20 flex flex-wrap">
                <view class="mr-20">
                    <text v-if="selectedItem.parentName">{{selectedItem.parentName}}</text>
                    <text v-if="selectedItem.childrenName">、{{selectedItem.childrenName}}</text>
                </view>
            </view>
        </view> -->
        <u-popup :show="isShow" @close="closePopup" :safeAreaInsetTop="true" mode="bottom" :closeable="true" round="12">
            <view class="popup-title fw f-30">九小场所类型</view>
            <view class="popup-list flex a-i-c">
                <scroll-view scroll-y="true" class="scroll">
                    <view class="popup-box">
                        <view :class="['box-item','f-28',item.key == selectedTemp.parentId?'c-main fw':'']"
                            v-for="(item,index)  in  categoryList" :key="index" @click="handleSelect(item,index)">
                            {{item.title}}
                        </view>
                    </view>
                </scroll-view>
                <u-line direction="col" length="300rpx" v-if="childList.length"></u-line>
                <scroll-view scroll-y="true" class="scroll" v-if="childList.length">
                    <view class="popup-box">
                        <view :class="['box-item','f-28',item.key == selectedTemp.childrenId?'c-main fw':'']"
                            v-for="(item,index)  in  childList" :key="index" @click="handleSelectChild(item,index)">
                            {{item.title}}
                        </view>
                    </view>
                </scroll-view>
            </view>
            <view class="popup-footer flex j-c-s-b a-i-c">
                <view class="popup-btn c-main" @click="closePopup">
                    取消
                </view>
                <view
                    v-if="(childList.length && !selectedTemp.childrenId) || (!childList.length && !selectedTemp.parentId)"
                    class="popup-btn bgc-gray c-ff" @click="comfirmPopup">
                    确定
                </view>
                <view v-else class="popup-btn bgc-main c-ff" @click="comfirmPopup">
                    确定
                </view>
            </view>
        </u-popup>
    </view>
</template>
<script>
    import {
        bizDictionaryTree
    } from '@/api/system/dict.js'
    export default {
        name: "cateSelector",
        data() {
            return {
                isShow: false,
                categoryList: [],
                childList: [],
                selectedItem: {
                    parentId: "",
                    childrenId: "",
                    parentName: "",
                    childrenName: ""
                },
                selectedTemp: {
                    parentId: "",
                    childrenId: "",
                    parentName: "",
                    childrenName: ""
                },
                index: "",
                tempIndex: ""
            }
        },
        created() {
            this.getCateList()
        },
        methods: {
            open() {
                this.isShow = true;
            },
            close() {
                this.isShow = false;
            },
            getCateList() {
                bizDictionaryTree({
                    code: "nineType"
                }).then(res => {
                    if (res.code == 200) {
                        this.categoryList = res.data;
                    }
                })
            },
            handleSelect(item, index) {
                if (index == this.tempIndex) return;
                this.tempIndex = index;
                this.$set(this.selectedTemp, "parentId", item.key);
                this.$set(this.selectedTemp, "parentName", item.title);
                this.$set(this.selectedTemp, "childrenId", "");
                this.$set(this.selectedTemp, "childrenName", "");
                if (item.hasChildren) {
                    this.childList = item.children;
                } else {
                    this.childList = [];
                }
            },
            handleSelectChild(item, index) {
                this.$set(this.selectedTemp, "childrenId", item.key);
                this.$set(this.selectedTemp, "childrenName", item.title);
            },
            closePopup() {
                if (this.selectedTemp.parentId) {
                    this.$set(this.selectedTemp, "parentId", this.selectedItem.parentId);
                    this.$set(this.selectedTemp, "parentName", this.selectedItem.parentName);
                    this.$set(this.selectedTemp, "childrenId", this.selectedItem.childrenId);
                    this.$set(this.selectedTemp, "childrenName", this.selectedItem.childrenName);
                    this.tempIndex = this.index;
                    if (this.index != "" && this.categoryList[this.index].hasChildren) {
                        this.childList = this.categoryList[this.index].children;
                    }
                    if (this.index == "") {
                        this.childList = [];
                    }
                }
                this.isShow = false;
            },
            comfirmPopup() {
                this.$set(this.selectedItem, "parentId", this.selectedTemp.parentId);
                this.$set(this.selectedItem, "parentName", this.selectedTemp.parentName);
                this.$set(this.selectedItem, "childrenId", this.selectedTemp.childrenId);
                this.$set(this.selectedItem, "childrenName", this.selectedTemp.childrenName);
                this.index = this.tempIndex;
                this.isShow = false;
                this.$emit("comfirm", this.selectedItem);
            },
            showDefault(id) {
                for (let i = 0, ii = this.categoryList.length; i < ii; i++) {
                    if (this.categoryList[i].hasChildren) {
                        for (let k = 0, kk = this.categoryList[i].children.length; k < kk; k++) {
                            if (id == this.categoryList[i].children[k].key) {
                                this.index = i;
                                this.tempIndex = i;
                                this.childList = this.categoryList[i].children;
                                this.$set(this.selectedItem, "parentId", this.categoryList[i].key)
                                this.$set(this.selectedItem, "parentName", this.categoryList[i].title)
                                this.$set(this.selectedItem, "childrenId", this.categoryList[i].children[k].key)
                                this.$set(this.selectedItem, "childrenName", this.categoryList[i].children[k].title)
                                this.$set(this.selectedTemp, "parentId", this.categoryList[i].key)
                                this.$set(this.selectedTemp, "parentName", this.categoryList[i].title)
                                this.$set(this.selectedTemp, "childrenId", this.categoryList[i].children[k].key)
                                this.$set(this.selectedTemp, "childrenName", this.categoryList[i].children[k].title)
                            }
                        }
                    } else {
                        if (id == this.categoryList[i].key) {
                            this.index = i;
                            this.tempIndex = i;
                            this.$set(this.selectedItem, "parentId", this.categoryList[i].key)
                            this.$set(this.selectedItem, "parentName", this.categoryList[i].title)
                            this.$set(this.selectedTemp, "parentId", this.categoryList[i].key)
                            this.$set(this.selectedTemp, "parentName", this.categoryList[i].title)
                        }
                    }
                }
            }
        }
    }
</script>
<style lang="scss">
    page {
        background-color: #F5F5F5;
    }
    .cell {
        padding: 20rpx;
    }
    .popup-title {
        padding: 20rpx 0;
        text-align: center;
    }
    .scroll {
        flex: 1;
        height: 700rpx;
        transition: all .2s;
    }
    // .scroll:first-child {
    //     flex:1;
    //     .box-item{
    //         border-bottom:1px solid #F5F5F5;
    //     }
    // }
    // .scroll:last-child {
    //     flex:2;
    // }
    .p-20 {
        padding: 20rpx;
    }
    .popup-list {
        width: 100%;
        height: 700rpx;
        padding: 10rpx 0;
        box-sizing: border-box;
        .bgc-f4 {
            background-color: #f4f4f4;
        }
        .popup-box {
            width: 100%;
            height: 700rpx;
            .box-item {
                width: 100%;
                padding: 30rpx;
                box-sizing: border-box;
                text-align: center;
            }
        }
    }
    .popup-footer {
        padding: 20rpx;
        box-shadow: 0rpx 0rpx 10rpx 1rpx rgba(0, 0, 0, 0.1);
        .popup-btn {
            width: 45%;
            height: 78rpx;
            line-height: 78rpx;
            border-radius: 10rpx;
            text-align: center;
            font-size: 28rpx;
        }
        .popup-btn:nth-child(1) {
            border: 1px solid currentColor;
        }
    }
    .bgc-gray {
        background-color: darkgray;
    }
</style>
subPackage/workbench/views/audit.vue
@@ -112,16 +112,20 @@
            if (option.code) {
                this.houseCode = option.code;
            }
            // this.getList()
        },
        onShow() {
            this.resetParams();
            this.getList()
        },
        onReachBottom() {
            this.currentPage++
            this.getList()
        },
        methods: {
            searchConfirm() {
                this.resetParams()
                this.getList()
subPackage/workbench/views/auditList.vue
@@ -271,6 +271,8 @@
                    this.$u.func.globalNavigator(`labelReportDetail?id=${id}`)
                } else if (reportType == 6) {
                    this.$u.func.globalNavigator(`schoolReportDetail?id=${id}`)
                } else {
                    this.$u.func.globalNavigator(`checkReform?id=${id}`)
                }
            },
subPackage/workbench/views/checkReform.vue
@@ -33,11 +33,11 @@
            <text>其它隐患问题</text>
            <text class="item-content">{{info.remark}}</text>
        </view>
        <view class="item-row flex j-c-s-b a-i-c" v-if="info.rectificationNoticeFlag == 1">
        <view class="item-row flex j-c-s-b a-i-c" v-if="info.rectificationNoticeFlag == 2">
            <text>下发整改通知</text>
            <text class="item-content">是</text>
        </view>
        <view class="item-row flex j-c-s-b a-i-c" v-if="info.punishFlag == 1">
        <view class="item-row flex j-c-s-b a-i-c" v-if="info.punishFlag == 2">
            <text>是否处罚</text>
            <text class="item-content">是</text>
        </view>
@@ -49,7 +49,7 @@
            <text>整改截至时间</text>
            <text class="item-content">{{info.rectificationEndTime}}</text>
        </view>
        <view class="item-row flex j-c-s-b a-i-c" v-if="inof.remark">
        <view class="item-row flex j-c-s-b a-i-c" v-if="info.remark">
            <text>其它隐患问题</text>
            <text class="item-content">{{info.remark}}</text>
        </view>
@@ -74,6 +74,18 @@
                <u-image :src="i" width="100rpx" height="100rpx"></u-image>
            </view>
        </view>
        <view class="item-row flex j-c-s-b a-i-c">
            <text>状态</text>
            <text v-if="info.status == 1">待审核</text>
            <text v-if="info.status == 2">审核成功</text>
            <text v-if="info.status == 3">审核驳回</text>
        </view>
        <view class="item-row flex j-c-s-b a-i-c" v-if="info.status == 3 && info.reasonFailure">
            <text>驳回原因</text>
            <text class="item-content">{{info.reasonFailure}}</text>
        </view>
        <view class="mt-20 bgc-ff">
            <block v-for="(item,index) in itemList">
                <block v-for="(i,k) in item.children">
@@ -84,32 +96,49 @@
                        </view>
                        <u-collapse ref="collapse" v-if="i.id == n.itemId && n.state == 0">
                            <u-collapse-item :name="index" :title="i.title" value="存在">
                                <view class="mb-20" v-if="n.remark">
                                    <view class="f-26 mb-10" style="color:#000">隐患描述</view>
                                    <view class="f-28" style="color:#000">
                                        {{n.remark}}
                                    </view>
                                </view>
                                <view class="mb-20" v-if="n.imageUrls">
                                    <view class="f-26 mb-10" style="color:#000">隐患照片</view>
                                    <view class="f-26 mb-10 c-00">隐患照片</view>
                                    <view class="flex flex-wrap">
                                        <view class="mr-20" v-for="r in ($setImageUrl(n.imageUrls))">
                                            <u-image :src="r" width="100rpx" height="100rpx"
                                            <u-image :src="r" width="140rpx" height="140rpx"
                                                @click="previewImage($setImageUrl(n.imageUrls),i)"></u-image>
                                        </view>
                                    </view>
                                </view>
                                <view class="">
                                    <view class="f-26 mb-10">整改后照片</view>
                                    <u-upload :fileList="form.images" :previewFullImage="uploadConfig.previewFullImage"
                                <view class="mb-20" v-if="n.remark">
                                    <view class="f-26 mb-10 c-00">隐患描述</view>
                                    <view class="f-28 c-00">
                                        {{n.remark}}
                                    </view>
                                </view>
                                <view class="mb-20" v-if="roleType == 2 || (roleType == 1 && n.rectificationImageUrls)">
                                    <view class="f-26 mb-10 c-00">整改后照片</view>
                                    <u-upload v-if="roleType == 2" :fileList="n.urls"
                                        :previewFullImage="uploadConfig.previewFullImage"
                                        :accept="uploadConfig.acceptImg" :multiple="uploadConfig.multiple"
                                        :maxCount="uploadConfig.maxCount" :capture="uploadConfig.capture"
                                        @afterRead="afterReadImg" @delete="deletePic">
                                        @afterRead="afterReadImgs($event,n,m)" @delete="deleteImages($event,m)">
                                        <view class="upload-item upload-icon flex_base">
                                            <u-icon name="/static/icon/upload.png" width="60rpx"
                                                height="60rpx"></u-icon>
                                        </view>
                                    </u-upload>
                                    <view class="flex flex-wrap" v-if="roleType == 1 && n.rectificationImageUrls">
                                        <view class="mr-20" v-for="r in ($setImageUrl(n.rectificationImageUrls))">
                                            <u-image :src="r" width="140rpx" height="140rpx"
                                                @click="previewImage($setImageUrl(n.rectificationImageUrls),i)"></u-image>
                                        </view>
                                    </view>
                                </view>
                                <view class="" v-if="roleType == 2 || (roleType == 1 && n.rectificationRemark)">
                                    <view class="f-26 mb-10 c-00">整改后描述</view>
                                    <u-textarea v-model="n.rectificationRemark" placeholder="请输入处罚说明内容"
                                        placeholderClass="c-99 f-26" :disabled="roleType == 1?true:false"></u-textarea>
                                </view>
                            </u-collapse-item>
                        </u-collapse>
@@ -118,8 +147,9 @@
            </block>
        </view>
        <footer-btn />
        <view class="blank"></view>
        <footer-btn @click="submitInfo" v-if="roleType == 2 && (info.status == 1 || info.status == 3)" />
        <audit-action v-if="roleType == 1 && info.status == 1" @handle="submitAudit" />
    </view>
</template>
@@ -127,21 +157,37 @@
    import uploadMixin from "@/mixin/uploadMixin";
    import {
        getPlaceCheckItem,
        getPlaceCheckDetail,
        getPlaceCheckReformDetail
        getPlaceCheckReformDetail,
        addPlaceCheckReform,
        auditPlaceCheckReform
    } from '@/api/place/place.js'
    import auditAction from '../components/actionBtn.vue'
    export default {
        mixins: [uploadMixin],
        components: {
            auditAction
        },
        data() {
            return {
                info: {},
                images: [],
                signatureUrl: [],
                label: "",
                itemList: []
                itemList: [],
                roleType: '' //1.民警/系统管理员   2.场所负责人
            }
        },
        async onLoad(option) {
            let {
                roleName
            } = uni.getStorageSync("activeRole")
            if (roleName == "居民") {
                this.roleType = 2;
            }
            if (roleName == "民警" || roleName == "系统管理员") {
                this.roleType = 1;
            }
            await this.getItem();
            this.getDetail(option.id);
        },
@@ -150,15 +196,24 @@
                getPlaceCheckReformDetail({
                    taskId: id
                }).then(res => {
                    this.info = res.data;
                    let data = res.data;
                    // this.info = res.data;
                    this.images = this.$setImageUrl(res.data.imageUrls);
                    this.signatureUrl = this.$setImageUrl(res.data.signaturePath);
                    if (res.data.placePoiLabelVOList.length) {
                        this.label = res.data.placePoiLabelVOList[res.data.placePoiLabelVOList.length - 1]
                            .labelName;
                    }
                    // this.label = res.data.
                    for (let i of data.patrolRecordVOList) {
                        if ((data.status == 1 || data.status == 3) && this.roleType == 2) {
                            if (i.rectificationImageUrls) {
                                i.urls = this.$setImageUrl(i.rectificationImageUrls, 2);
                            } else {
                                i.urls = [];
                            }
                        }
                    }
                    this.info = data;
                })
            },
@@ -171,9 +226,49 @@
                })
            },
            async afterReadImgs(event, item, fIndex) {
                uni.showLoading({
                    title: "上传中..."
                })
                let children = this.info.patrolRecordVOList;
                let lists = [].concat(event.file)
                let fileListLen = item.urls.length;
                lists.map((item) => {
                    children[fIndex].urls.push({
                        ...item,
                        status: 'uploading',
                        message: '上传中'
                    })
                    this.$set(this.info, "patrolRecordVOList", children)
                })
                for (let i = 0; i < lists.length; i++) {
                    const result = await this.uploadFilePromise(lists[i].url)
                    children[fIndex].urls.splice(fileListLen, 1, Object.assign({}, {
                        url: result.data.link,
                        name: result.data.name
                    }))
                    this.$set(this.info, "patrolRecordVOList", children)
                    fileListLen++
                }
                this.loadingClose()
            },
            setUrl(src) {
                return this.$setImageUrl(url)
            deleteImages(event, index) {
                let children = this.info.patrolRecordVOList;
                children[index].urls.splice(event.index, 1);
                this.$set(this.info, "patrolRecordVOList", children)
            },
            setImages(key) {
                if (!key) {
                    return ""
                } else {
                    let urls = [];
                    for (let i of key) {
                        urls.push(i.name);
                    }
                    return urls.join(",")
                }
            },
            previewImage(urls, current) {
@@ -181,8 +276,57 @@
                    urls,
                    current
                })
            }
            },
            //整改提交
            submitInfo() {
                uni.showLoading({
                    title: "加载中..."
                })
                let data = this.info;
                for (let i of data.patrolRecordVOList) {
                    if (i.urls) {
                        i.rectificationImageUrls = this.setImages(i.urls)
                    }
                    delete i.urls;
                }
                if (data.status == 3) {
                    data.status = 1;
                }
                addPlaceCheckReform(data).then(res => {
                    uni.hideLoading()
                    if (res.code == 200) {
                        this.$showTips("操作成功", "success");
                        setTimeout(() => {
                            uni.navigateBack()
                        }, 300)
                    }
                })
            },
            //审核
            submitAudit(val) {
                uni.showLoading({
                    title: "加载中..."
                })
                auditPlaceCheckReform({
                    id: this.info.id,
                    taskId: this.info.taskId,
                    status: val.type,
                    rectificationFlag: val.type == 3 ? 1 : 2,
                    reasonFailure: val.remark
                }).then(res => {
                    uni.hideLoading()
                    if (res.code == 200) {
                        this.$showTips("操作成功");
                        setTimeout(() => {
                            uni.navigateBack()
                        }, 300)
                    }
                })
            }
        }
    }
</script>
@@ -239,4 +383,13 @@
        height: 140rpx;
        border: 1px solid #EEEEEE;
    }
    .blank {
        width: 100%;
        height: 140rpx;
    }
    .c-00 {
        color: #000;
    }
</style>
subPackage/workbench/views/cscj.vue
@@ -38,7 +38,7 @@
                            {{form.isNine == 1?"是":"否"}}
                        </view>
                    </u-form-item>
                    <u-form-item v-if="form.isNine == 1" @click="showNineTypePicker = true" class="form-item"
                    <u-form-item v-if="form.isNine == 1" @click="showNineTypeSelector" class="form-item"
                        labelWidth="100" label="九小场所类型:" :required="isRequired" :disabled="isDisabled" prop="nineType">
                        <u-input border="none" v-model="nineTypeValue" disabled disabledColor="#ffffff"
                            placeholder="请选择">
@@ -214,12 +214,10 @@
            :loading="pickerLoading" :columns="[frontTypeList]" @confirm="confirmFrontTypePicker"
            @cancel="showFrontTypePicker = false"></u-picker>
        <u-picker :show="isShowCatePicker" :defaultIndex="categoryIndex" ref="catePicker" keyName="categoryName"
            :columns="categoryList" @confirm="confirmCategory" @change="changeCategory"
            @cancel="isShowCatePicker = false"></u-picker>
        <cate-selector ref="selector" @comfirm="comfirmNineType" />
    </view>
</template>
@@ -250,11 +248,15 @@
        bizDictionary,
        bizDictionaryTree
    } from '@/api/system/dict.js'
    import cateSelector from "../components/cateSelector.vue"
    export default {
        mixins: [uploadMixin],
        components: {
            lineItem,
            boxTitle
            boxTitle,
            cateSelector
        },
        data() {
            return {
@@ -506,7 +508,8 @@
        async onLoad(option) {
            await this.getCategory();
            await this.getAllBizDict();
            this.getNineTypeList();
            // this.getNineTypeList();
            const {
                type
            } = option
@@ -555,12 +558,6 @@
        onReady() {
            this.$refs.form.setRules(this.rules)
        },
        onUnload() {
        },
        methods: {
            // getBuildingDetail(params = {}) {
@@ -638,6 +635,9 @@
                })
            },
            showNineTypeSelector() {
                this.$refs.selector.open();
            },
            navTo(type) {
                if (type == 1) {
@@ -781,12 +781,22 @@
                        }
                        if (key == "isNine") {
                            let {
                                index,
                                name
                            } = this.$getIndex(this.nineTypeList, data.nineType, "value", "name");
                            this.nineTypeIndex = index;
                            this.nineTypeValue = name;
                            // let {
                            //     index,
                            //     name
                            // } = this.$getIndex(this.nineTypeList, data.nineType, "value", "name");
                            // this.nineTypeIndex = index;
                            // this.nineTypeValue = name;
                            this.$refs.selector.showDefault(data.nineType)
                            setTimeout(() => {
                                if (this.$refs.selector.selectedItem.childrenId) {
                                    this.nineTypeValue = this.$refs.selector.selectedItem
                                        .childrenName
                                } else {
                                    this.nineTypeValue = this.$refs.selector.selectedItem
                                        .parentName;
                                }
                            }, 200)
                        }
                        if (key == "isFront") {
@@ -843,6 +853,17 @@
                })
            },
            //选择九小场所类型
            comfirmNineType(val) {
                if (val.childrenId) {
                    this.form.nineType = val.childrenId;
                    this.nineTypeValue = val.childrenName;
                } else {
                    this.form.nineType = val.parentId;
                    this.nineTypeValue = val.parentName;
                }
            },
            //表单提交
            submit() {
                const that = this
@@ -872,9 +893,11 @@
                                title: '提交成功',
                                success() {
                                    setTimeout(() => {
                                        that.$u.func.globalNavigator(
                                            "/pages/home/index", "switchTab")
                                    }, 1000)
                                        uni.$emit("refresh")
                                        uni.navigateBack()
                                        // that.$u.func.globalNavigator(
                                        //     "/pages/home/index", "switchTab")
                                    }, 300)
                                }
                            })
                        })
subPackage/workbench/views/reformList.vue
New file
@@ -0,0 +1,295 @@
<template>
    <view>
        <u-sticky>
            <view class="bgc-ff">
                <view class="tab">
                    <u-tabs :list="tabList" :current="tabIndex" @click="changeTab" :inactiveStyle="{color:'#999999'}"
                        :activeStyle="{color:'#017BFC'}">
                    </u-tabs>
                    <view class="search flex j-c-s-b a-i-c">
                        <view class="tab-filter flex j-c-c a-i-c" @click="showDateModal">
                            <text class="f-28">时间筛选</text>
                            <u-icon name="arrow-down"></u-icon>
                        </view>
                        <u-search placeholder="请输入需要查询信息的名称" v-model="keyWord" :clearabled="true" :showAction="true"
                            :animation="true" @search="searchConfirm" @clear="clearConfirm"></u-search>
                    </view>
                </view>
            </view>
        </u-sticky>
        <view class="list">
            <view class="list-item bgc-ff mb-20" v-for="(i,k) in list" :key="k"
                @click="navTo(i.id,i.reportType,i.status,i.type)">
                <view class="item-title flex a-i-c j-c-s-b mb-20">
                    <text class="f-32 fw">{{i.name}}</text>
                    <u-tag v-if="i.status == 4" text="待接收" type="warning" plain plainFill></u-tag>
                    <u-tag v-if="i.status == 1" text="待审批" type="warning" plain plainFill></u-tag>
                    <u-tag v-if="i.status == 2" text="审核通过" type="success" plain plainFill></u-tag>
                    <u-tag v-if="i.status == 3" text="审核拒绝" type="error" plain plainFill></u-tag>
                </view>
                <view class="item-row flex a-i-c j-c-s-b">
                    <text class="f-28">时间</text>
                    <text class="f-28 c-66">{{i.createTime}}</text>
                </view>
                <view class="item-row flex a-i-c j-c-s-b">
                    <text class="f-28">地址</text>
                    <text class="address f-28 c-66">{{i.addressName || ""}}</text>
                </view>
            </view>
        </view>
        <u-toast ref="uToast"></u-toast>
        <u-loadmore :status="loadingStatus" loadmoreText="开始加载" loadingText="数据加载中" nomoreText="没有更多了" line />
        <date-range-modal ref="dateRane" @comfirm="handleComfirmDate" @rest="handleRestDate" />
    </view>
</template>
<script>
    import {
        getAuditReportingList
    } from "@/api/reporting/reporting"
    import dateRangeModal from '@/components/dateRangeModal/modal.vue';
    export default {
        components: {
            dateRangeModal
        },
        data() {
            return {
                tabList: [
                    {
                        name: "全部",
                        status: "",
                    },
                    {
                        name: "待接收",
                        status: 4,
                    },
                    {
                        name: "待审核",
                        status: 1
                    },
                    {
                        name: "审核通过",
                        status: 2
                    },
                    {
                        name: "已拒绝",
                        status: 3
                    }
                ],
                tabIndex: 0,
                currentStatus: "",
                list: [],
                loadingStatus: 'nomore',
                currentPage: 1,
                frequency: '',
                reportType: "",
                selectDate: [],
                houseCode: "",
                keyword: ""
            }
        },
        onLoad(option) {
            console.log(option);
            if (option.reportType) {
                this.reportType = option.reportType;
                uni.setNavigationBarTitle({
                    title: "取保候审"
                })
            }
            if (option.from == "index") {
                uni.setNavigationBarTitle({
                    title: "场所任务"
                })
            }
            if (option.from == "task") {
                this.tabIndex = 1;
                this.currentStatus = 1;
            }
            if (option.code) {
                this.houseCode = option.code;
            }
            // this.getList()
        },
        onShow() {
            this.resetParams();
            this.getList()
        },
        onReachBottom() {
            this.currentPage++
            this.getList()
        },
        methods: {
            searchConfirm() {
                this.resetParams()
                this.getList()
            },
            clearConfirm() {
                this.keyWord = ''
                this.searchConfirm()
            },
            changeTab(e) {
                this.tabIndex = e.index;
                this.currentStatus = e.status;
                this.resetParams();
                this.getList();
            },
            resetParams() {
                this.list = [];
                this.currentPage = 1;
            },
            getList() {
                this.$nextTick(() => {
                    this.loadingStatus = 'loadingmore'
                    this.$refs.uToast.show({
                        type: 'loading',
                        message: '正在加载',
                        duration: 9999999
                    })
                })
                let params = {
                    page: this.currentPage,
                    size: 20,
                    status: this.currentStatus,
                    frequency: this.frequency
                }
                if (this.selectDate.length) {
                    params.startTime = this.selectDate[0]
                    params.endTime = this.selectDate[1]
                }
                if (this.houseCode) {
                    params.houseCode = this.houseCode;
                }
                if (this.reportType) {
                    params.reportType = this.reportType
                }
                if (this.keyword) {
                    params.name = this.keyword;
                }
                getAuditReportingList(params).then(res => {
                    if (res.code != 200) {
                        uni.showToast({
                            title: '数据请求失败',
                            icon: 'error'
                        })
                        return
                    }
                    let records = res.data.records;
                    this.list = [...this.list, ...records]
                    this.$nextTick(() => {
                        this.$refs.uToast.isShow = false
                    })
                    this.loadingStatus = 'nomore'
                })
            },
            navTo(id, reportType, status, type) {
                if (status == 4) {
                    if (uni.getStorageSync("activeRole").roleName == "民警") {
                        this.navToDetail(reportType, id, type)
                    } else {
                        this.navToEdit(reportType, id, type);
                    }
                } else {
                    this.navToDetail(reportType, id, type)
                }
            },
            navToEdit(reportType, id, type) {
                if (reportType == 1) {
                    this.$u.func.globalNavigator(`/subPackage/label/bail?id=${id}`)
                } else if (reportType == 2 || type == 7) {
                    this.$u.func.globalNavigator(`/subPackage/label/hotel?id=${id}`)
                } else if (reportType == 3 || reportType == 4 || reportType == 5) {
                    this.$u.func.globalNavigator(`/subPackage/label/form?id=${id}`)
                } else if (reportType == 6) {
                    this.$u.func.globalNavigator(`/subPackage/label/school?id=${id}`)
                }
            },
            navToDetail(reportType, id, type) {
                if (reportType == 1) {
                    this.$u.func.globalNavigator(`bailReportDetail?id=${id}`)
                } else if (reportType == 2 || type == 7) {
                    this.$u.func.globalNavigator(`hotelReportDetail?id=${id}`)
                } else if (reportType == 3 || reportType == 4 || reportType == 5) {
                    this.$u.func.globalNavigator(`labelReportDetail?id=${id}`)
                } else if (reportType == 6) {
                    this.$u.func.globalNavigator(`schoolReportDetail?id=${id}`)
                } else {
                    this.$u.func.globalNavigator(`checkReform?id=${id}`)
                }
            },
            showDateModal() {
                this.$refs.dateRane.open();
            },
            handleRestDate() {
                this.selectDate = [];
                this.resetParams();
                this.getList()
            },
            handleComfirmDate(val) {
                this.selectDate = val;
                this.resetParams();
                this.getList()
            }
        }
    }
</script>
<style lang="scss">
    page {
        background-color: #F5F5F5;
    }
    .tab {
        // width: 100%;
    }
    .search {
        padding: 20rpx 20rpx;
    }
    // .tab /deep/.u-tabs__wrapper__nav__item {
    //     flex: 1;
    // }
    .tab-filter {
        padding: 0 20rpx;
    }
    .list {
        margin: 20rpx 30rpx 0;
    }
    .list-item {
        padding: 0 30rpx 20rpx;
        border-radius: 8rpx;
        .item-title {
            padding: 30rpx 0;
            border-bottom: 1px solid #F5F5F5;
        }
        .item-row {
            padding: 10rpx 0;
            .address {
                width: 65%;
                text-align: right;
            }
        }
    }
</style>