| | |
| | | @size-change="sizeChange" |
| | | @refresh-change="refreshChange" |
| | | @on-load="onLoad" |
| | | @row-click="rowClick"> |
| | | |
| | | @row-click="rowClick" |
| | | > |
| | | <template slot="menuLeft"> |
| | | <el-button |
| | | type="danger" |
| | | |
| | | v-show="true" |
| | | size="mini" |
| | | icon="el-icon-delete" |
| | |
| | | <template slot-scope="{ row }" slot="jtype"> |
| | | <el-tag |
| | | >{{ |
| | | row.jtype == "0" || row.jtype == "" ? "未派发" : row.jtype == "1" && (row.securityId == null || row.securityId |
| | | == "") |
| | | ? "未接收" : row.jtype == "1" && (row.securityId != null || row.securityId != "") ? "已接收" : "已处置" |
| | | row.jtype == "0" || row.jtype == "" |
| | | ? "未派发" |
| | | : row.jtype == "1" && |
| | | (row.securityId == null || row.securityId == "") |
| | | ? "未接收" |
| | | : row.jtype == "1" && |
| | | (row.securityId != null || row.securityId != "") |
| | | ? "已接收" |
| | | : "已处置" |
| | | }} |
| | | </el-tag> |
| | | </template> |
| | |
| | | >派发 |
| | | </el-button> |
| | | </template> |
| | | |
| | | <template slot-scope="{type,disabled}" slot="xllxzsForm"> |
| | | <div class="mapClassMain" style="width: 860px;height: 400px"> |
| | | <Map ref="modalForm"/> |
| | | </div> |
| | | </template> |
| | | |
| | | |
| | | </avue-crud> |
| | | |
| | | |
| | | <real-popup ref="realPopupView"></real-popup> |
| | | <el-drawer title="电子地图" append-to-body="true" :visible.sync="showMap"> |
| | | <iframe |
| | |
| | | labelWidth: "100", |
| | | size: "mini", |
| | | border: false, |
| | | stripe: true, |
| | | menuWidth: 240, |
| | | //stripe:true, |
| | | menuWidth: 260, |
| | | dialogWidth: 950, |
| | | tip: false, |
| | | searchShow: true, |
| | |
| | | dialogClickModal: false, |
| | | column: [ |
| | | { |
| | | label: "警情类型", |
| | | label: "任务类型", |
| | | prop: "alarmType", |
| | | search: false, |
| | | searchSpan: 3, |
| | |
| | | //cascaderItem: ["city", "district"], |
| | | dicUrl: |
| | | "/api/blade-system/dict-biz/child-list?parentId=1356523651644043266", |
| | | control: (val, form) => { |
| | | // if (val) { |
| | | // } |
| | | return { |
| | | text2: { |
| | | display: true, |
| | | }, |
| | | text3: { |
| | | label: "内容3", |
| | | }, |
| | | }; |
| | | }, |
| | | }, |
| | | { |
| | | label: "报警时间", |
| | | label: "下发时间", |
| | | type: "datetime", |
| | | width: 160, |
| | | format: "yyyy-MM-dd HH:mm:ss", |
| | | valueFormat: "yyyy-MM-dd HH:mm:ss", |
| | | prop: "alarmTime", |
| | | rules: [{ |
| | | required: true, |
| | | message: "请选择报警时间", |
| | | trigger: "blur" |
| | | }], |
| | | rules: [ |
| | | { |
| | | required: true, |
| | | message: "请选择报警时间", |
| | | trigger: "blur", |
| | | }, |
| | | ], |
| | | }, |
| | | { |
| | | label: "报警时间", |
| | |
| | | trigger: "blur", |
| | | }, |
| | | ], |
| | | }, { |
| | | }, |
| | | { |
| | | label: "备注", |
| | | prop: "bz", |
| | | span: 24, |
| | |
| | | label: "地址", |
| | | prop: "place", |
| | | span: 10, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请选择地址", |
| | | trigger: "blur" |
| | | }], |
| | | rules: [ |
| | | { |
| | | required: true, |
| | | message: "请选择地址", |
| | | trigger: "blur", |
| | | }, |
| | | ], |
| | | }, |
| | | { |
| | | label: null, |
| | |
| | | width: "100", |
| | | labelWidth: "120", |
| | | formatter: (row, value, label, column) => { |
| | | return value = value.substring(0, 11); |
| | | return (value = value.substring(0, 11)); |
| | | }, |
| | | span: 7, |
| | | }, |
| | |
| | | hide: true, |
| | | prop: "wd", |
| | | formatter: (row, value, label, column) => { |
| | | return value = value.substring(0, 10); |
| | | return (value = value.substring(0, 10)); |
| | | }, |
| | | span: 5, |
| | | }, |
| | |
| | | label: "省份", |
| | | prop: "province", |
| | | search: true, |
| | | width: 100, |
| | | searchSpan: 2, |
| | | searchLabelWidth: 45, |
| | | placeholder: "省份", |
| | |
| | | label: "地市", |
| | | prop: "city", |
| | | type: "select", |
| | | width: 100, |
| | | searchPlaceholder: "地市", |
| | | placeholder: "地市", |
| | | searchLabelWidth: 1, |
| | |
| | | label: "区县", |
| | | searchSpan: 2, |
| | | searchLabelWidth: 1, |
| | | width: 100, |
| | | searchPlaceholder: "区县", |
| | | placeholder: "区县", |
| | | search: true, |
| | |
| | | width: 96, |
| | | search: true, |
| | | slot: true, |
| | | addDisplay: false, |
| | | value: "0", |
| | | searchPlaceholder: "请选择", |
| | | prop: "jtype", |
| | | type: "select", |
| | |
| | | }, |
| | | ], |
| | | }, |
| | | // { |
| | | // label: "派发人", |
| | | // prop: "alarmPeople", |
| | | // width: 90, |
| | | // addDisplay: false, |
| | | // editDisplay: false, |
| | | // }, |
| | | { |
| | | label: "派发人", |
| | | prop: "alarmPeople", |
| | | width: 90, |
| | | addDisplay: false, |
| | | editDisplay: false, |
| | | }, |
| | | { |
| | | label: "处警员", |
| | | label: "接收人", |
| | | prop: "securityArr", |
| | | type: "tree", |
| | | multiple: true, |
| | | dicUrl: "/api/catalogs/catalogs/getBigTree", |
| | | props: { |
| | | label: "title" |
| | | label: "title", |
| | | }, |
| | | width: 72, |
| | | hide: true, |
| | |
| | | addDisplay: true, |
| | | editDisplay: true, |
| | | viewDisplay: true, |
| | | } |
| | | }, |
| | | { |
| | | label: "巡逻路线", |
| | | prop: "xllx", |
| | | hide: true, |
| | | display: true, |
| | | type: "tree", |
| | | dicUrl: "/api/routeIn/routein/tree", |
| | | props: { |
| | | label: "title", |
| | | }, |
| | | }, |
| | | { |
| | | label: "路线展示", |
| | | labelWidth: "0", |
| | | prop: "xllxzs", |
| | | className: "mapClass", |
| | | hide: true, |
| | | display: true, |
| | | formslot: true, |
| | | }, |
| | | ], |
| | | }, |
| | | data: [], |
| | |
| | | //重新加载一次页面详情数据,解决新的省市区无法写入问题 |
| | | //判断是新增还是修改 |
| | | if (that.isEdit) { |
| | | getclient(this.form.id).then(res => { |
| | | getclient(this.form.id).then((res) => { |
| | | // that.province = res.data.data.province; |
| | | // that.city = res.data.data.city; |
| | | // that.district = res.data.data.district; |
| | |
| | | |
| | | var address = val.formattedAddress.toString(); |
| | | if (address.search("县") != -1) { |
| | | this.form.place = address.substring(address.indexOf("县") + 1, address.length); |
| | | this.form.place = address.substring( |
| | | address.indexOf("县") + 1, |
| | | address.length |
| | | ); |
| | | } |
| | | if (address.search("区") != -1) { |
| | | this.form.place = address.substring(address.indexOf("区") + 1, address.length); |
| | | this.form.place = address.substring( |
| | | address.indexOf("区") + 1, |
| | | address.length |
| | | ); |
| | | } |
| | | //写入新的省市区 |
| | | that.form.province = val.addressComponent.province; |
| | |
| | | } else { |
| | | that.form.map = { |
| | | formattedAddress: "", |
| | | latitude: 28.68235075592195, |
| | | longitude: 115.9021417169273, |
| | | latitude: 28.699957, |
| | | longitude: 115.862118, |
| | | }; |
| | | } |
| | | }, |
| | | immediate: true, |
| | | }, |
| | | //随意一个 |
| | | // 'form.deviceName'() { |
| | | // if (this.initFlag) { |
| | | // this.initData(); |
| | | // } |
| | | // } |
| | | "form.alarmType": { |
| | | handler(val) { |
| | | var xllx = this.findObject(this.option.column, "xllx"); |
| | | var xllxzs = this.findObject(this.option.column, "xllxzs"); |
| | | if (val === "巡逻任务") { |
| | | xllx.display = true; |
| | | xllxzs.display = true; |
| | | xllx.rules = [ |
| | | { |
| | | required: true, |
| | | message: "请选择巡逻路线", |
| | | trigger: "blur", |
| | | }, |
| | | ]; |
| | | } else { |
| | | xllx.display = false; |
| | | xllxzs.display = false; |
| | | xllx.rules = []; |
| | | } |
| | | }, |
| | | immediate: true, |
| | | }, |
| | | "form.xllx":{ |
| | | handler(val) { |
| | | if (val){ |
| | | this.getxllx(val) |
| | | } |
| | | |
| | | }, |
| | | immediate: true, |
| | | } |
| | | }, |
| | | computed: { |
| | | ...mapGetters(["permission", "flowRoutes"]), |
| | |
| | | created() { |
| | | this.dateTime = this.getDate(); |
| | | }, |
| | | mounted() { |
| | | var xb = JSON.parse(window.sessionStorage.getItem('sjsb')); |
| | | var data = this.$route.query; |
| | | if (xb == 1) { |
| | | this.form = data; |
| | | this.openAdd(); |
| | | window.sessionStorage.removeItem('sjsb'); |
| | | } |
| | | }, |
| | | methods: { |
| | | rowSave(row, done, loading) { |
| | | |
| | | if (typeof row.securityArr != "string") { |
| | | var security = ""; |
| | | row.securityArr.forEach((item) => { |
| | |
| | | row.securityArr = security.substring(0, security.length - 1); |
| | | } |
| | | var userId = JSON.parse( |
| | | window.localStorage.getItem("群防群控后台管理系统-userInfo") |
| | | ).content.real_name; |
| | | window.localStorage.getItem("洪城义警后台管理系统-userInfo") |
| | | ).content.nick_name; |
| | | |
| | | if (row.securityArr == "" || row.securityArr == null) { |
| | | row.jtype = "0"; |
| | | row.alarmPeople = ""; |
| | | }else { |
| | | row.jtype = "1"; |
| | | //已派发保安 |
| | | row.alarmPeople = userId; |
| | | if (row.jtype != "2") { |
| | | if (row.securityArr == "" || row.securityArr == null) { |
| | | row.jtype = "0"; |
| | | row.alarmPeople = ""; |
| | | } else { |
| | | row.jtype = "1"; |
| | | //已派发保安 |
| | | } |
| | | } |
| | | row.alarmPeople = userId; |
| | | |
| | | add(row).then( |
| | | () => { |
| | |
| | | } |
| | | ); |
| | | }, |
| | | getxllx(val){ |
| | | var that = this; |
| | | if (this.$refs.modalForm == undefined) { |
| | | setTimeout(function () { |
| | | that.$refs.modalForm.addLines(val); |
| | | }, 1500) |
| | | } else { |
| | | that.$refs.modalForm.addLines(val); |
| | | } |
| | | }, |
| | | rowUpdate(row, index, done, loading) { |
| | | |
| | | var userId = JSON.parse( |
| | | window.localStorage.getItem("群防群控后台管理系统-userInfo") |
| | | ).content.real_name; |
| | | |
| | | window.localStorage.getItem("洪城义警后台管理系统-userInfo") |
| | | ).content.nick_name; |
| | | if (typeof row.securityArr != "string") { |
| | | var security = ""; |
| | | row.securityArr.forEach((item) => { |
| | |
| | | }); |
| | | row.securityArr = security.substring(0, security.length - 1); |
| | | } |
| | | |
| | | if (row.securityArr == "" || row.securityArr == null) { |
| | | row.jtype = "0"; |
| | | row.alarmPeople = ""; |
| | | }else { |
| | | row.jtype = "1"; |
| | | //已派发保安 |
| | | row.alarmPeople = userId; |
| | | if (row.jtype != "2") { |
| | | if (row.securityArr == "" || row.securityArr == null) { |
| | | row.jtype = "0"; |
| | | row.alarmPeople = ""; |
| | | } else { |
| | | row.jtype = "1"; |
| | | //已派发保安 |
| | | } |
| | | } |
| | | |
| | | row.alarmPeople = userId; |
| | | row.coordinate = ""; |
| | | update(row).then( |
| | | () => { |
| | |
| | | }; |
| | | } |
| | | } |
| | | |
| | | if (releaseTimeRange) { |
| | | values = { |
| | | ...params, |
| | |
| | | endTime: this.showToDay(today) + " 23:59:59", |
| | | }; |
| | | //修改搜索框中的值 |
| | | this.search.releaseTimeRange = [this.showToDay(today) + " 00:00:00", this.showToDay(today) + " 23:59:59"] |
| | | this.search.releaseTimeRange = [ |
| | | this.showToDay(today) + " 00:00:00", |
| | | this.showToDay(today) + " 23:59:59", |
| | | ]; |
| | | } |
| | | if (e == 1) { |
| | | params = { |
| | |
| | | endTime: this.showToDay(today) + " 23:59:59", |
| | | }; |
| | | //修改搜索框中的值 |
| | | this.search.releaseTimeRange = [this.showWeekFirstDay(today) + " 00:00:00", this.showToDay(today) + " 23:59:59"] |
| | | this.search.releaseTimeRange = [ |
| | | this.showWeekFirstDay(today) + " 00:00:00", |
| | | this.showToDay(today) + " 23:59:59", |
| | | ]; |
| | | } |
| | | if (e == 2) { |
| | | params = { |
| | |
| | | endTime: this.showToDay(today) + " 23:59:59", |
| | | }; |
| | | //修改搜索框中的值 |
| | | this.search.releaseTimeRange = [this.showMonthFirstDay(today) + " 00:00:00", this.showToDay(today) + " 23:59:59"] |
| | | this.search.releaseTimeRange = [ |
| | | this.showMonthFirstDay(today) + " 00:00:00", |
| | | this.showToDay(today) + " 23:59:59", |
| | | ]; |
| | | } |
| | | this.query = params; |
| | | this.page.currentPage = 1; |
| | |
| | | |
| | | //本月第一天 |
| | | showMonthFirstDay(Nowdate) { |
| | | var MonthFirstDay = new Date(Nowdate.getFullYear(), Nowdate.getMonth(), 1); |
| | | var MonthFirstDay = new Date( |
| | | Nowdate.getFullYear(), |
| | | Nowdate.getMonth(), |
| | | 1 |
| | | ); |
| | | var M = Number(MonthFirstDay.getMonth()) + 1; |
| | | if (M < 10) { |
| | | M = "0" + M; |
| | | } |
| | | return MonthFirstDay.getFullYear() + "-" + M + "-" + "0" + MonthFirstDay.getDate(); |
| | | return ( |
| | | MonthFirstDay.getFullYear() + |
| | | "-" + |
| | | M + |
| | | "-" + |
| | | "0" + |
| | | MonthFirstDay.getDate() |
| | | ); |
| | | }, |
| | | getBZdata(e) { |
| | | this.activeClass = e; |
| | |
| | | this.showMap = true; |
| | | this.$nextTick(() => { |
| | | this.$refs.mapDiv.onload = () => { |
| | | window.frames[1].init("ClientManagement", {x: row.jd, y: row.wd, clientID: row.deviceNumber}); |
| | | window.frames[0].init("ClientManagement", { |
| | | x: row.jd, |
| | | y: row.wd, |
| | | clientID: row.deviceNumber, |
| | | }); |
| | | }; |
| | | }); |
| | | }, |
| | |
| | | }, |
| | | |
| | | PoliceTracking(row) { |
| | | var arr = []; |
| | | this.$store.state.tags.tagList.forEach((item) => { |
| | | if (item.label != "任务追踪") { |
| | | arr.push(item); |
| | | } |
| | | }); |
| | | this.$store.state.tags.tagList = arr; |
| | | //警情追踪 |
| | | this.$router.push({path: "/policeTracking/track", query: row}); |
| | | |
| | | }, |
| | | //打开新增窗体 |
| | | openAdd() { |
| | | this.$refs.crud.rowAdd(); |
| | | }, |
| | | |
| | | //数据导出 |
| | |
| | | ); |
| | | //window.open(`http://localhost:8108/ureport/excel?_u=blade-alarm.statis.ureport.xml&beginTime=${beginTime}&endTime=${endTime}&waringType=${waringType}&timeDesc=${timeDesc}`); |
| | | }, |
| | | rowClick(val) {//行点击事件 |
| | | rowClick(val) { |
| | | //行点击事件 |
| | | //警情追踪 |
| | | this.$router.push({path: "/policeTracking/track", query: val}); |
| | | } |
| | | this.PoliceTracking(val); |
| | | |
| | | }, |
| | | }, |
| | | }; |
| | | </script> |
| | |
| | | width: 12%; |
| | | } |
| | | |
| | | .mapClass div label { |
| | | display: none; |
| | | } |
| | | |
| | | .mapClassMain { |
| | | padding-left: 25px !important; |
| | | } |
| | | |
| | | .cityreal2 div label, |
| | | .cityreal3 div label { |
| | | display: none; |