|
@@ -81,9 +81,10 @@
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<el-form-item>
|
|
<el-form-item>
|
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="getList">搜索</el-button>
|
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="getList">搜索</el-button>
|
|
- <el-button type="primary" icon="el-icon-search" size="mini" :disabled="buttonDisabled" @click="getTrail">轨迹</el-button>
|
|
|
|
|
|
+<!-- <el-button type="primary" icon="el-icon-search" size="mini" :disabled="buttonDisabled" @click="getTrail">轨迹</el-button>-->
|
|
<el-button type="primary" icon="el-icon-refresh" size="mini">重置</el-button>
|
|
<el-button type="primary" icon="el-icon-refresh" size="mini">重置</el-button>
|
|
<el-button type="primary" icon="el-icon-refresh" size="mini" @click="exportQuery">导出</el-button>
|
|
<el-button type="primary" icon="el-icon-refresh" size="mini" @click="exportQuery">导出</el-button>
|
|
|
|
+ <el-button type="primary" icon="el-icon-refresh" size="mini" @click="exportMissQuery">漏打报表</el-button>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-form>
|
|
</el-form>
|
|
</div>
|
|
</div>
|
|
@@ -252,7 +253,7 @@ export default {
|
|
// this.getvideo()
|
|
// this.getvideo()
|
|
this.getTableHeight();
|
|
this.getTableHeight();
|
|
},
|
|
},
|
|
-
|
|
|
|
|
|
+
|
|
mounted(){
|
|
mounted(){
|
|
this.getTree();
|
|
this.getTree();
|
|
this.listLocation();
|
|
this.listLocation();
|
|
@@ -263,113 +264,120 @@ export default {
|
|
beforeDestroy(){
|
|
beforeDestroy(){
|
|
},
|
|
},
|
|
methods:{
|
|
methods:{
|
|
- exportQuery(){
|
|
|
|
- this.download('/qdtl/log/export', {
|
|
|
|
- ...this.queryForm
|
|
|
|
- }, `巡检监测_${new Date().getTime()}.xlsx`)
|
|
|
|
- },
|
|
|
|
- getTableHeight(){
|
|
|
|
- var h = document.body.clientHeight;
|
|
|
|
- this.tableHeight = h*0.6
|
|
|
|
- // console.log(1111111111);
|
|
|
|
- console.log(this.tableHeight);
|
|
|
|
- },
|
|
|
|
- getTrail(){
|
|
|
|
- var trail = {};
|
|
|
|
- trail.areaId = this.queryForm.areaId
|
|
|
|
- trail.patrolmanCard = this.queryForm.patrolmanCard
|
|
|
|
- trail.deviceCode = this.queryForm.deviceCode
|
|
|
|
- trail.checkpointCard = this.queryForm.checkpointCard
|
|
|
|
- trail.endTime = this.queryForm.endTime
|
|
|
|
- trail.beginTime = this.queryForm.beginTime
|
|
|
|
- getTrail(trail).then(response=>{
|
|
|
|
- console.log(response);
|
|
|
|
- this.trailData = response.data
|
|
|
|
- this.pointArry.data = this.trailData;
|
|
|
|
- this.pointArry.type = 8
|
|
|
|
- this.open = true
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
- getList(){
|
|
|
|
- console.log(this.queryForm);
|
|
|
|
- getLog(this.queryForm).then(response =>{
|
|
|
|
- console.log(response);
|
|
|
|
- this.logList = response.rows
|
|
|
|
- this.total = response.total
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
- openMap(){
|
|
|
|
- console.log(11111111)
|
|
|
|
- this.pointArry.data = this.trailData;
|
|
|
|
- this.pointArry.type = 8
|
|
|
|
- console.log(this.pointArry);
|
|
|
|
- },
|
|
|
|
- getTree(){
|
|
|
|
- var treeDate = {
|
|
|
|
- label:'所有',
|
|
|
|
- value:1
|
|
|
|
- }
|
|
|
|
- treeDate.children = this.dict.type.tl_xun_area
|
|
|
|
- this.areaData.push(treeDate);
|
|
|
|
- },
|
|
|
|
- listLocation(){
|
|
|
|
- listLocation().then(response =>{
|
|
|
|
- this.locationList = response.rows
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
- listDevice(){
|
|
|
|
- listDevice().then(response =>{
|
|
|
|
- this.deviceList = response.rows
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
- getPatrolman(){
|
|
|
|
- getPatrolman().then(response =>{
|
|
|
|
- this.patorlmanList = response.rows
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
- tableRowClassName({ row, rowIndex }) {
|
|
|
|
- if ((rowIndex + 1) % 2 === 0) {
|
|
|
|
- return "warning-row";
|
|
|
|
- } else {
|
|
|
|
- return "success-row";
|
|
|
|
- }
|
|
|
|
- },
|
|
|
|
- filterNode(value, data) {
|
|
|
|
- if (!value) return true;
|
|
|
|
- return data.label.indexOf(value) !== -1;
|
|
|
|
- },
|
|
|
|
- treeChange(data, node){
|
|
|
|
- let tree = this.$refs.tree;
|
|
|
|
- let array = tree.getCheckedNodes().concat(tree.getHalfCheckedNodes())
|
|
|
|
- var areaArray = []
|
|
|
|
- for(var index in array){
|
|
|
|
- if(array[index].value != 1){
|
|
|
|
- areaArray.push(array[index].value);
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- this.queryForm.areaId = areaArray.join(',')
|
|
|
|
- this.getList();
|
|
|
|
- // console.log(this.queryForm.areaId)
|
|
|
|
- },
|
|
|
|
- buttonChange(){
|
|
|
|
- console.log(this.queryForm.dateArry != null);
|
|
|
|
- console.log(this.queryForm.patrolmanCard != null);
|
|
|
|
- console.log(this.queryForm.patrolmanCard != '');
|
|
|
|
- if(this.queryForm.dateArry != null){
|
|
|
|
- var start = this.queryForm.dateArry[0];
|
|
|
|
- var end = this.queryForm.dateArry[1];
|
|
|
|
- this.queryForm.beginTime = start;
|
|
|
|
- this.queryForm.endTime = end;
|
|
|
|
- var startDay = new Date(start).setHours(0,0,0,0);;
|
|
|
|
- var endDay = new Date(end).setHours(0,0,0,0);;
|
|
|
|
- if(startDay == endDay && this.queryForm.patrolmanCard != null && this.queryForm.patrolmanCard != ''){
|
|
|
|
- this.buttonDisabled = false
|
|
|
|
- }else{
|
|
|
|
- this.buttonDisabled = true
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- console.log(this.buttonDisabled)
|
|
|
|
|
|
+ exportQuery() {
|
|
|
|
+ this.download('/qdtl/log/export', {
|
|
|
|
+ ...this.queryForm
|
|
|
|
+ }, `巡检监测_${new Date().getTime()}.xlsx`)
|
|
|
|
+ },
|
|
|
|
+ exportMissQuery() {
|
|
|
|
+ this.download('/qdtl/log/missExport', {
|
|
|
|
+ ...this.queryForm
|
|
|
|
+ }, `漏打巡检点报表_${new Date().getTime()}.xlsx`)
|
|
|
|
+ },
|
|
|
|
+ getTableHeight() {
|
|
|
|
+ var h = document.body.clientHeight;
|
|
|
|
+ this.tableHeight = h * 0.6
|
|
|
|
+ // console.log(1111111111);
|
|
|
|
+ console.log(this.tableHeight);
|
|
|
|
+ },
|
|
|
|
+ getTrail() {
|
|
|
|
+ var trail = {};
|
|
|
|
+ trail.areaId = this.queryForm.areaId
|
|
|
|
+ trail.patrolmanCard = this.queryForm.patrolmanCard
|
|
|
|
+ trail.deviceCode = this.queryForm.deviceCode
|
|
|
|
+ trail.checkpointCard = this.queryForm.checkpointCard
|
|
|
|
+ trail.endTime = this.queryForm.endTime
|
|
|
|
+ trail.beginTime = this.queryForm.beginTime
|
|
|
|
+ getTrail(trail).then(response => {
|
|
|
|
+ console.log(response);
|
|
|
|
+ this.trailData = response.data
|
|
|
|
+ this.pointArry.data = this.trailData;
|
|
|
|
+ this.pointArry.type = 8
|
|
|
|
+ this.open = true
|
|
|
|
+ })
|
|
|
|
+ },
|
|
|
|
+ getList() {
|
|
|
|
+ console.log(this.queryForm);
|
|
|
|
+ getLog(this.queryForm).then(response => {
|
|
|
|
+ console.log(response);
|
|
|
|
+ this.logList = response.rows
|
|
|
|
+ this.total = response.total
|
|
|
|
+ })
|
|
|
|
+ },
|
|
|
|
+ openMap() {
|
|
|
|
+ console.log(11111111)
|
|
|
|
+ this.pointArry.data = this.trailData;
|
|
|
|
+ this.pointArry.type = 8
|
|
|
|
+ console.log(this.pointArry);
|
|
|
|
+ },
|
|
|
|
+ getTree() {
|
|
|
|
+ var treeDate = {
|
|
|
|
+ label: '所有',
|
|
|
|
+ value: 1
|
|
|
|
+ }
|
|
|
|
+ treeDate.children = this.dict.type.tl_xun_area
|
|
|
|
+ this.areaData.push(treeDate);
|
|
|
|
+ },
|
|
|
|
+ listLocation() {
|
|
|
|
+ listLocation().then(response => {
|
|
|
|
+ this.locationList = response.rows
|
|
|
|
+ })
|
|
|
|
+ },
|
|
|
|
+ listDevice() {
|
|
|
|
+ listDevice().then(response => {
|
|
|
|
+ this.deviceList = response.rows
|
|
|
|
+ })
|
|
|
|
+ },
|
|
|
|
+ getPatrolman() {
|
|
|
|
+ getPatrolman().then(response => {
|
|
|
|
+ this.patorlmanList = response.rows
|
|
|
|
+ })
|
|
|
|
+ },
|
|
|
|
+ tableRowClassName({row, rowIndex}) {
|
|
|
|
+ if ((rowIndex + 1) % 2 === 0) {
|
|
|
|
+ return "warning-row";
|
|
|
|
+ } else {
|
|
|
|
+ return "success-row";
|
|
}
|
|
}
|
|
|
|
+ },
|
|
|
|
+ filterNode(value, data) {
|
|
|
|
+ if (!value) return true;
|
|
|
|
+ return data.label.indexOf(value) !== -1;
|
|
|
|
+ },
|
|
|
|
+ treeChange(data, node) {
|
|
|
|
+ let tree = this.$refs.tree;
|
|
|
|
+ let array = tree.getCheckedNodes().concat(tree.getHalfCheckedNodes())
|
|
|
|
+ var areaArray = []
|
|
|
|
+ for (var index in array) {
|
|
|
|
+ if (array[index].value != 1) {
|
|
|
|
+ areaArray.push(array[index].value);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ this.queryForm.areaId = areaArray.join(',')
|
|
|
|
+ this.getList();
|
|
|
|
+ // console.log(this.queryForm.areaId)
|
|
|
|
+ },
|
|
|
|
+ buttonChange() {
|
|
|
|
+ console.log(this.queryForm.dateArry != null);
|
|
|
|
+ console.log(this.queryForm.patrolmanCard != null);
|
|
|
|
+ console.log(this.queryForm.patrolmanCard != '');
|
|
|
|
+ if (this.queryForm.dateArry != null) {
|
|
|
|
+ var start = this.queryForm.dateArry[0];
|
|
|
|
+ var end = this.queryForm.dateArry[1];
|
|
|
|
+ this.queryForm.beginTime = start;
|
|
|
|
+ this.queryForm.endTime = end;
|
|
|
|
+ var startDay = new Date(start).setHours(0, 0, 0, 0);
|
|
|
|
+ ;
|
|
|
|
+ var endDay = new Date(end).setHours(0, 0, 0, 0);
|
|
|
|
+ ;
|
|
|
|
+ if (startDay == endDay && this.queryForm.patrolmanCard != null && this.queryForm.patrolmanCard != '') {
|
|
|
|
+ this.buttonDisabled = false
|
|
|
|
+ } else {
|
|
|
|
+ this.buttonDisabled = true
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ console.log(this.buttonDisabled)
|
|
|
|
+ }
|
|
}
|
|
}
|
|
};
|
|
};
|
|
</script>
|
|
</script>
|