safecheck-client 3.0.30-9 → 3.0.30-90
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/examples/SafePlan-liaoyuan/App.vue +3 -1
- package/package.json +4 -3
- package/src/App.vue +2 -2
- package/src/components/DefectDealMain/DefectListNew.vue +5 -5
- package/src/components/Util.js +15 -0
- package/src/components/android/AddPlanItem.vue +5 -2
- package/src/components/android/AreaPlan.vue +2 -2
- package/src/components/android/CurrentCreate.vue +3 -2
- package/src/components/android/CurrentCreate_new.vue +563 -559
- package/src/components/android/PaperFeedback.vue +4 -2
- package/src/components/android/SafecheckOrderV.vue +2 -2
- package/src/components/android/UploadPage.vue +13 -123
- package/src/components/paper/PaperList.vue +9 -2
- package/src/components/paper/PlanChooser.vue +8 -6
- package/src/components/pc/Edit.vue +126 -0
- package/src/components/pc/LodopFuncs.js +159 -0
- package/src/components/pc/NewCheckpaper.vue +9 -5
- package/src/components/pc/PaperEdit.vue +151 -0
- package/src/components/pc/PrintData.vue +243 -0
- package/src/components/pc/PrintTable.vue +241 -0
- package/src/components/pc/SelectCheckPlanAndNoPLan.vue +3 -0
- package/src/components/report/NoCheckplanSafecheck.vue +0 -2
- package/src/components/rongcheng/CheckCurrentCreate.vue +8 -0
- package/src/components/rongcheng/PaperStatem.vue +42 -1
- package/src/components/rongcheng/PhoneUpUserinfo.vue +149 -199
- package/src/components/rongcheng/SafecheckOrderV.vue +8 -0
- package/src/components/rongcheng/SafecheckUserInfo.vue +419 -0
- package/src/components/rongcheng/report/CheckPlanAreaList.vue +21 -3
- package/src/filiale/ankangyihua/pc/checkUserList.vue +1 -0
- package/src/filiale/bayan/android/CurrentCreate.vue +1 -1
- package/src/filiale/bayan/android/Edit.vue +132 -0
- package/src/filiale/bayan/android/SafecheckOrderV.vue +2 -2
- package/src/filiale/bayan/android/SafecheckUserInfo.vue +6 -1
- package/src/filiale/bayan/android.js +2 -1
- package/src/filiale/fugou/android/AddPlanItem.vue +413 -0
- package/src/filiale/fugou/android.js +10 -0
- package/src/filiale/fugou/pc/DefectMainNew.vue +63 -0
- package/src/filiale/fugou/pc/DefectPaperNew.vue +1081 -0
- package/src/filiale/fugou/pc/PaperDefectMain.vue +890 -0
- package/src/filiale/fugou/pc/PaperList.vue +46 -0
- package/src/filiale/fugou/pc/checkUserList.vue +824 -0
- package/src/filiale/fugou/pc.js +5 -1
- package/src/filiale/hanzhong/android/SafecheckDevices.vue +24 -24
- package/src/filiale/hanzhong/android/SafecheckOrderV.vue +2 -2
- package/src/filiale/hanzhong/pc/CheckSafeStatus.vue +1 -1
- package/src/filiale/hanzhong/pc/NewCheckpaper.vue +1923 -0
- package/src/filiale/hanzhong/pc.js +4 -1
- package/src/filiale/huatong/android/CurrentCreate.vue +564 -564
- package/src/filiale/huatong/android/SafecheckOrderV.vue +8 -0
- package/src/filiale/jingyang/android/AddPlanItem.vue +458 -0
- package/src/filiale/jingyang/android/CurrentCreate.vue +1080 -0
- package/src/filiale/jingyang/android/PhoneUpUserinfo.vue +34 -34
- package/src/filiale/jingyang/android/SafecheckOrderV.vue +2734 -0
- package/src/filiale/jingyang/android/SafecheckUserInfo.vue +780 -0
- package/src/filiale/kelai/android/AddPlanItem.vue +488 -0
- package/src/filiale/kelai/android.js +1 -0
- package/src/filiale/liaoyuan/android/CurrentCreate.vue +1066 -0
- package/src/filiale/liaoyuan/android.js +1 -0
- package/src/filiale/pingxiang/pc/DefectPaperNew.vue +1 -1
- package/src/filiale/qianneng/android/PaperFeedback.vue +40 -0
- package/src/filiale/qianneng/pc/PaperList.vue +6 -0
- package/src/filiale/qingjian/android/PhoneUpUserinfo.vue +6 -0
- package/src/filiale/tianke/pc/checkScreen.vue +4 -4
- package/src/filiale/tianke/pc/cq.jpg +0 -0
- package/src/filiale/tianke/pc/qy.jpg +0 -0
- package/src/filiale/tongchuan/android/SafecheckDevices.vue +1 -0
- package/src/filiale/tongchuan/pc/PaperDefectMain.vue +371 -401
- package/src/filiale/wensu/android/AndroidDefectDeal.vue +321 -366
- package/src/filiale/wensu/android/AndroidDefectDealItems.vue +480 -0
- package/src/filiale/wensu/android.js +1 -0
- package/src/filiale/wensu/pc/CheckSearchUser.vue +64 -0
- package/src/filiale/wensu/pc/DefectPaperNew.vue +16 -10
- package/src/filiale/wensu/pc/NewCheckpaper.vue +1936 -0
- package/src/filiale/wensu/pc/RoleSelector.vue +4 -1
- package/src/filiale/wensu/pc/checkUserList.vue +50 -0
- package/src/filiale/wensu/pc.js +2 -1
- package/src/filiale/wenxi/pc/DefectPaper.vue +1 -1
- package/src/filiale/wuhai/android/SafecheckOrderV.vue +2069 -2041
- package/src/filiale/wuhai/pc/NewCheckpaper.vue +26 -24
- package/src/filiale/yangchunboneng/android/PaperFeedback.vue +20 -0
- package/src/filiale/yangchunboneng/pc/CheckBookDetails.vue +19 -0
- package/src/filiale/yongzhou/pc/CheckSearchUser.vue +1092 -0
- package/src/filiale/yongzhou/pc/LodopFuncs.js +159 -0
- package/src/filiale/yongzhou/pc/NoCheckplanSafecheck.vue +252 -0
- package/src/filiale/yongzhou/pc/PaperList.vue +798 -0
- package/src/filiale/yongzhou/pc/PrintData.vue +243 -0
- package/src/filiale/yongzhou/pc/PrintTable.vue +241 -0
- package/src/filiale/yongzhou/pc/communityDetail.vue +35 -12
- package/src/filiale/yongzhou/pc/communityTypeDetailG.vue +28 -14
- package/src/filiale/yongzhou/pc/communityTypeDetailM.vue +28 -14
- package/src/filiale/yongzhou/pc/safeDetail.vue +43 -15
- package/src/filiale/yongzhou/pc/safeStatistics.vue +16 -6
- package/src/filiale/yongzhou/pc/safeStatisticsDay.vue +81 -27
- package/src/filiale/yongzhou/pc/safeStatisticsMonth.vue +56 -26
- package/src/filiale/yongzhou/pc/safeStatisticsYear.vue +16 -6
- package/src/filiale/yongzhou/pc/safeTable.vue +10 -2
- package/src/filiale/yongzhou/pc.js +17 -12
- package/src/filiale/zhongsheng/android/CurrentCreate.vue +540 -536
- package/src/filiale/zhongsheng/android/SafecheckUserInfo.vue +151 -53
- package/src/filiale/zhongsheng/pc/NewCheckpaper.vue +14 -0
- package/src/main.js +1 -1
- package/src/safecheck.js +12 -0
@@ -1,68 +1,68 @@
|
|
1
1
|
<style scoped>
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
2
|
+
.bg {
|
3
|
+
background-color: blue;
|
4
|
+
height: 1px;
|
5
|
+
border: 0;
|
6
|
+
}
|
7
|
+
.app-row {
|
8
|
+
background-color: white;
|
9
|
+
padding: 10px 10px 0 10px;
|
10
|
+
border-bottom: 1px solid rgba(235, 235, 235, 0.5);
|
11
|
+
}
|
12
|
+
.search_input {
|
13
|
+
border: 0;
|
14
|
+
outline: none;
|
15
|
+
}
|
16
|
+
.font{
|
17
|
+
font: 15px PingFang-SC-Medium;
|
18
|
+
color: #666666;
|
19
|
+
}
|
20
|
+
.input-font{
|
21
|
+
font: 15px PingFang-SC-Medium;
|
22
|
+
color: #333333;
|
23
|
+
}
|
24
|
+
.btn-font{
|
25
|
+
font:600 16px PingFang-SC-Bold;
|
26
|
+
color: #499EDF;
|
27
|
+
}
|
28
|
+
.btn-color{
|
29
|
+
background-color: #FFFFFF;
|
30
|
+
border-radius: 10px ;
|
31
|
+
border: 1px solid #499EDF;
|
32
|
+
}
|
33
|
+
.app-text {
|
34
|
+
font-size: 12px;
|
35
|
+
}
|
36
|
+
.panel-self{
|
37
|
+
border-radius: 10px;
|
38
|
+
border:1px solid #499EDF;
|
39
|
+
background-color: #F8F8F8;
|
40
|
+
}
|
41
|
+
.yybtn-color{
|
42
|
+
background-color:#499edf;
|
43
|
+
border-radius: 4px ;
|
44
|
+
border: 1px solid #499EDF;
|
45
|
+
color: #FFFFFF;
|
46
|
+
font: 14px PingFang-SC-Bold;
|
47
|
+
}
|
48
|
+
.qxbtn-color{
|
49
|
+
background-color: #FFFFFF;
|
50
|
+
border-radius: 4px ;
|
51
|
+
color: #499edf;
|
52
|
+
font: 14px PingFang-SC-Bold;
|
53
|
+
border: 1px solid #499EDF;
|
54
|
+
}
|
55
|
+
|
56
|
+
.button_shrink_top {width: 35px; height: 35px; background-size:100%;background-image: url("../../../../static/newStyle/stretch_top.png")}
|
57
|
+
.button_shrink_bottom {width: 35px; height: 35px; background-size:100%;background-image: url("../../../../static/newStyle/stretch_bottom.png")}
|
58
|
+
.button_shrink_left {width: 35px; height: 35px; background-size:100%;background-image: url("../../../../static/newStyle/stretch_left.png")}
|
59
|
+
.button_shrink_right {width: 35px; height: 35px; background-size:100%;background-image: url("../../../../static/newStyle/stretch_right.png")}
|
60
60
|
</style>
|
61
61
|
<style>
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
62
|
+
.clear-select-with .dropdown-menu{
|
63
|
+
left: 0px !important;
|
64
|
+
width: 200% !important;
|
65
|
+
}
|
66
66
|
</style>
|
67
67
|
<template>
|
68
68
|
<div style="height: auto;width: 100%">
|
@@ -482,542 +482,542 @@
|
|
482
482
|
</template>
|
483
483
|
|
484
484
|
<script>
|
485
|
-
|
486
|
-
|
487
|
-
|
488
|
-
|
489
|
-
|
490
|
-
|
491
|
-
|
492
|
-
|
493
|
-
|
494
|
-
|
495
|
-
|
496
|
-
|
497
|
-
|
498
|
-
|
499
|
-
|
500
|
-
})
|
485
|
+
import LocalPagedList from '../../../plugins/LocalPagedList'
|
486
|
+
import Vue from 'vue'
|
487
|
+
import { PagedList,HttpResetClass } from 'vue-client'
|
488
|
+
import * as Util from '../../../components/Util'
|
489
|
+
import co from 'co'
|
490
|
+
let select = function * (self) {
|
491
|
+
let http = new HttpResetClass()
|
492
|
+
http.load('POST', `${self.$androidUtil.getProxyUrl()}/rs/search`, {
|
493
|
+
source: 'this.getParentByType($department$).getAllChildrens().where(row.getAttributes().get($rolestr$).indexOf($安检员$) != -1))',
|
494
|
+
userid: Vue.user.id
|
495
|
+
}, {resolveMsg: null, rejectMsg: null}).then((res) => {
|
496
|
+
//tag
|
497
|
+
self.checkers.push({label:'全部',value:''})
|
498
|
+
res.data.forEach((checker)=>{
|
499
|
+
self.checkers.push({label:checker.name,value:checker.id})
|
501
500
|
})
|
502
|
-
}
|
503
|
-
|
504
|
-
|
505
|
-
|
506
|
-
|
507
|
-
|
508
|
-
|
509
|
-
|
510
|
-
|
511
|
-
|
512
|
-
|
513
|
-
|
514
|
-
|
515
|
-
|
516
|
-
|
517
|
-
|
518
|
-
|
519
|
-
|
520
|
-
|
521
|
-
|
522
|
-
|
523
|
-
|
524
|
-
|
525
|
-
|
526
|
-
|
527
|
-
|
528
|
-
|
529
|
-
|
530
|
-
|
531
|
-
|
532
|
-
|
533
|
-
|
534
|
-
|
535
|
-
|
536
|
-
|
537
|
-
|
538
|
-
|
539
|
-
|
540
|
-
|
541
|
-
|
542
|
-
|
543
|
-
|
544
|
-
|
545
|
-
|
546
|
-
|
547
|
-
|
548
|
-
|
549
|
-
|
550
|
-
|
551
|
-
|
552
|
-
|
553
|
-
|
554
|
-
|
555
|
-
|
556
|
-
|
557
|
-
|
558
|
-
|
559
|
-
|
560
|
-
|
561
|
-
|
562
|
-
|
563
|
-
|
564
|
-
|
565
|
-
|
566
|
-
}
|
567
|
-
|
568
|
-
|
569
|
-
|
570
|
-
|
571
|
-
|
572
|
-
|
501
|
+
})
|
502
|
+
}
|
503
|
+
export default {
|
504
|
+
title: '无计划安检查询',
|
505
|
+
props: ['planName'],
|
506
|
+
data() {
|
507
|
+
return {
|
508
|
+
f_filialeids:'('+Vue.user.orgid+')',
|
509
|
+
//f_filialeids:'(305)',
|
510
|
+
planparam:[],
|
511
|
+
check:'',
|
512
|
+
plan:'',
|
513
|
+
planid:'',
|
514
|
+
model:Vue.android? new LocalPagedList('androidGetuserinfo',20,{condition:'this.condition'}): new PagedList( 'AndroidRest/rs/sql/androidGetuserinfo',20,{condition:'this.condition'}),
|
515
|
+
showModal: false,
|
516
|
+
showModal2:false,
|
517
|
+
showModal3:false,
|
518
|
+
needid:'',
|
519
|
+
criteriaShow: false,
|
520
|
+
planoption:[],
|
521
|
+
condition:'',
|
522
|
+
checkers:[],
|
523
|
+
param: null,
|
524
|
+
f_preset_dt : Util.to3339TimeString(),
|
525
|
+
flow_direction:[
|
526
|
+
{label: '请选择挂表方式', value: ''},
|
527
|
+
{label: '左表', value: '左表'},
|
528
|
+
{label: '右表', value: '右表'}
|
529
|
+
],
|
530
|
+
check_states: [
|
531
|
+
{label: '请选择安检状态', value: ''},
|
532
|
+
{label: '未检', value: '未检'},
|
533
|
+
{label: '临时保存', value: '已检'},
|
534
|
+
],
|
535
|
+
last_check_states: [
|
536
|
+
{label: '请选择上次安检状态', value: ''},
|
537
|
+
{label: '入户', value: '入户'},
|
538
|
+
{label: '拒检', value: '拒检'},
|
539
|
+
{label: '到访不遇', value: '到访不遇'},
|
540
|
+
{label: '未使用天然气', value: '未使用天然气'}
|
541
|
+
],
|
542
|
+
upload_states: [
|
543
|
+
{label: '请选择上传状态', value: ''},
|
544
|
+
{label: '未传', value: '未传'},
|
545
|
+
{label: '已传', value: '已传'}
|
546
|
+
],
|
547
|
+
user_types: [
|
548
|
+
{label: '请选择用户类型', value: ''},
|
549
|
+
{label: '民用', value: '民用'},
|
550
|
+
{label: '非民用', value: '非民用'},
|
551
|
+
],
|
552
|
+
verify_state: [
|
553
|
+
{label: '请选择审核状态', value: ''},
|
554
|
+
{label: '未审核', value: '未审核'},
|
555
|
+
{label: '打回', value: '打回'}
|
556
|
+
],
|
557
|
+
residentialAreaOptions: [],
|
558
|
+
buildOptions: [],
|
559
|
+
unitOptions: [],
|
560
|
+
planNameOptions: [],
|
561
|
+
upcomingCount: 0,
|
562
|
+
doneCount: 0,
|
563
|
+
tempSaveCount: 0,
|
564
|
+
allPlanCount: 0
|
565
|
+
}
|
566
|
+
},
|
567
|
+
ready(){
|
568
|
+
this.getAllArea()
|
569
|
+
this.getAllPlanName()
|
570
|
+
this.selfSearch()
|
571
|
+
let gen = select(this)
|
572
|
+
co(gen)
|
573
|
+
},
|
574
|
+
mounted(){
|
575
|
+
//tag
|
576
|
+
if (window.history && window.history.pushState) {
|
577
|
+
history.pushState(null, null, document.URL);
|
578
|
+
window.addEventListener('popstate', this.fun, false);//false阻止默认事件
|
579
|
+
}
|
580
|
+
},
|
581
|
+
destroyed(){
|
582
|
+
//tag
|
583
|
+
window.removeEventListener('popstate', this.fun, false);//false阻止默认事件
|
584
|
+
},
|
585
|
+
methods: {
|
586
|
+
scan(){
|
587
|
+
HostApp.__this__=this,
|
588
|
+
HostApp.scanCode({callback:"javascript:HostApp.__this__.getCode();"})
|
573
589
|
},
|
574
|
-
|
590
|
+
getCode(){
|
591
|
+
const datapa = HostApp.getCode().data;
|
575
592
|
//tag
|
576
|
-
|
577
|
-
|
578
|
-
window.addEventListener('popstate', this.fun, false);//false阻止默认事件
|
579
|
-
}
|
593
|
+
this.$refs.paged.$refs.cri.model.f_meter_no = datapa
|
594
|
+
|
580
595
|
},
|
581
|
-
|
596
|
+
fun () {
|
597
|
+
//tag
|
582
598
|
//tag
|
583
|
-
window.removeEventListener('popstate', this.fun, false);//false阻止默认事件
|
584
599
|
},
|
585
|
-
|
586
|
-
|
587
|
-
|
588
|
-
|
589
|
-
|
590
|
-
|
591
|
-
|
592
|
-
|
593
|
-
|
594
|
-
|
595
|
-
|
596
|
-
|
597
|
-
|
598
|
-
|
599
|
-
|
600
|
-
|
601
|
-
|
602
|
-
this.showModal3=false
|
603
|
-
this.planoption=[]
|
604
|
-
},
|
605
|
-
timeSet(val){
|
606
|
-
return val
|
607
|
-
},
|
608
|
-
async isok(){
|
609
|
-
if(this.planoption.length==0){
|
610
|
-
this.$showMessage("请选择计划")
|
611
|
-
return false
|
612
|
-
}
|
613
|
-
for (let i = 0; i <this.planoption.length ; i++) {
|
614
|
-
if (this.planoption[i]["selected"]==true){
|
615
|
-
this.planid=this.planoption[i].value
|
616
|
-
break
|
617
|
-
}
|
618
|
-
}
|
619
|
-
if(this.planid==''){
|
620
|
-
this.$showMessage("请选择计划")
|
621
|
-
return false
|
622
|
-
}
|
623
|
-
await this.okput()
|
624
|
-
},
|
625
|
-
async manyisok(){
|
626
|
-
if(this.planoption.length==0){
|
627
|
-
this.$showMessage("请选择计划")
|
628
|
-
return false
|
629
|
-
}
|
630
|
-
for (let i = 0; i <this.planoption.length ; i++) {
|
631
|
-
if (this.planoption[i]["selected"]==true){
|
632
|
-
this.planid=this.planoption[i].value
|
633
|
-
break
|
634
|
-
}
|
600
|
+
iscancel(){
|
601
|
+
this.showModal2=false
|
602
|
+
this.showModal3=false
|
603
|
+
this.planoption=[]
|
604
|
+
},
|
605
|
+
timeSet(val){
|
606
|
+
return val
|
607
|
+
},
|
608
|
+
async isok(){
|
609
|
+
if(this.planoption.length==0){
|
610
|
+
this.$showMessage("请选择计划")
|
611
|
+
return false
|
612
|
+
}
|
613
|
+
for (let i = 0; i <this.planoption.length ; i++) {
|
614
|
+
if (this.planoption[i]["selected"]==true){
|
615
|
+
this.planid=this.planoption[i].value
|
616
|
+
break
|
635
617
|
}
|
636
|
-
|
637
|
-
|
638
|
-
|
618
|
+
}
|
619
|
+
if(this.planid==''){
|
620
|
+
this.$showMessage("请选择计划")
|
621
|
+
return false
|
622
|
+
}
|
623
|
+
await this.okput()
|
624
|
+
},
|
625
|
+
async manyisok(){
|
626
|
+
if(this.planoption.length==0){
|
627
|
+
this.$showMessage("请选择计划")
|
628
|
+
return false
|
629
|
+
}
|
630
|
+
for (let i = 0; i <this.planoption.length ; i++) {
|
631
|
+
if (this.planoption[i]["selected"]==true){
|
632
|
+
this.planid=this.planoption[i].value
|
633
|
+
break
|
639
634
|
}
|
640
|
-
|
641
|
-
|
642
|
-
|
643
|
-
|
644
|
-
|
645
|
-
|
646
|
-
|
647
|
-
|
648
|
-
|
649
|
-
|
650
|
-
|
651
|
-
|
652
|
-
|
653
|
-
|
654
|
-
|
655
|
-
|
656
|
-
|
657
|
-
|
658
|
-
|
659
|
-
|
660
|
-
|
661
|
-
|
662
|
-
async manyokput(){
|
663
|
-
let res= await this.$resetpost(`${this.$androidUtil.getProxyUrl()}/rs/logic/UpCheckPlanItem`, {data:{
|
664
|
-
columnName:"i.id",
|
665
|
-
condition:"1=1",
|
666
|
-
f_plan_id:this.planid,
|
667
|
-
switchCheckAll:true,
|
668
|
-
param:this.planparam,
|
669
|
-
checkAll:false,
|
670
|
-
f_operator:Vue.user.name
|
671
|
-
}
|
672
|
-
})
|
673
|
-
await this.changenull()
|
674
|
-
await this.getNewOrder()
|
675
|
-
},
|
676
|
-
async plansearch(){
|
677
|
-
this.planoption=[]
|
678
|
-
let condition= '1 = 1 '
|
679
|
-
if(this.check){
|
680
|
-
condition += ` and f_checker_id= '${this.check}'`
|
635
|
+
}
|
636
|
+
if(this.planid==''){
|
637
|
+
this.$showMessage("请选择计划")
|
638
|
+
return false
|
639
|
+
}
|
640
|
+
await this.manyokput()
|
641
|
+
},
|
642
|
+
changenull(){
|
643
|
+
this.showModal2=false
|
644
|
+
this.showModal3=false
|
645
|
+
this.planoption=[]
|
646
|
+
this.plan=''
|
647
|
+
this.check=''
|
648
|
+
},
|
649
|
+
async okput(){
|
650
|
+
let res= await this.$resetpost(`${this.$androidUtil.getProxyUrl()}/rs/logic/UpCheckPlanItem`, {data:{
|
651
|
+
|
652
|
+
condition:`i.id='`+this.needid+`'`,
|
653
|
+
f_plan_id:this.planid,
|
654
|
+
switchCheckAll:false,
|
655
|
+
checkAll:false,
|
656
|
+
f_operator:Vue.user.name
|
681
657
|
}
|
682
|
-
|
683
|
-
|
658
|
+
})
|
659
|
+
await this.changenull()
|
660
|
+
await this.getNewOrder()
|
661
|
+
},
|
662
|
+
async manyokput(){
|
663
|
+
let res= await this.$resetpost(`${this.$androidUtil.getProxyUrl()}/rs/logic/UpCheckPlanItem`, {data:{
|
664
|
+
columnName:"i.id",
|
665
|
+
condition:"1=1",
|
666
|
+
f_plan_id:this.planid,
|
667
|
+
switchCheckAll:true,
|
668
|
+
param:this.planparam,
|
669
|
+
checkAll:false,
|
670
|
+
f_operator:Vue.user.name
|
684
671
|
}
|
685
|
-
|
686
|
-
|
687
|
-
|
688
|
-
|
689
|
-
|
690
|
-
|
691
|
-
|
692
|
-
|
693
|
-
|
672
|
+
})
|
673
|
+
await this.changenull()
|
674
|
+
await this.getNewOrder()
|
675
|
+
},
|
676
|
+
async plansearch(){
|
677
|
+
this.planoption=[]
|
678
|
+
let condition= '1 = 1 '
|
679
|
+
if(this.check){
|
680
|
+
condition += ` and f_checker_id= '${this.check}'`
|
681
|
+
}
|
682
|
+
if(this.plan){
|
683
|
+
condition += ` and f_plan_name like '%${this.plan}%'`
|
684
|
+
}
|
685
|
+
let res= await this.$resetpost(`${this.$androidUtil.getProxyUrl()}/rs/sql/预约计划下发`, {data:{
|
686
|
+
condition:condition,
|
687
|
+
f_filialeids:this.f_filialeids,
|
688
|
+
groupitem:'',
|
689
|
+
orderitem:'id'
|
690
|
+
}})
|
691
|
+
let resoult=res.data
|
692
|
+
for (let i = 0; i < resoult.length; i++) {
|
693
|
+
this.planoption.push({label: resoult[i].f_plan_name,selected:false, value: resoult[i].id})
|
694
|
+
}
|
695
|
+
},
|
696
|
+
|
697
|
+
select(row, idx) {
|
698
|
+
this.$set('planoption[' + idx + '].selected', true)
|
699
|
+
for (let i = 0; i <this.planoption.length ; i++) {
|
700
|
+
if (i!=idx){
|
701
|
+
this.planoption[i]["selected"]=false
|
694
702
|
}
|
695
|
-
}
|
703
|
+
}
|
704
|
+
},
|
705
|
+
planclose(){
|
706
|
+
this.showModal2=false
|
707
|
+
this.showModal3=false
|
708
|
+
},
|
709
|
+
queryplan(val){
|
710
|
+
this.needid=val
|
711
|
+
this.showModal2 = true
|
712
|
+
},
|
713
|
+
queryplanmany(){
|
696
714
|
|
697
|
-
|
698
|
-
|
699
|
-
|
700
|
-
|
701
|
-
|
702
|
-
|
715
|
+
this.showModal3 = true
|
716
|
+
},
|
717
|
+
reload(){
|
718
|
+
// this.getAllArea()
|
719
|
+
// this.getAllPlanName()
|
720
|
+
this.selfSearch()
|
721
|
+
},
|
722
|
+
cancelReserve (idx, id) {
|
723
|
+
if(Vue.android){
|
724
|
+
let res = this.$androidUtil.bzLogic('BookingCheck', {dt: '', id: id})
|
725
|
+
this.$set('model.rows[' + idx + '].f_prearranged_date', null)
|
726
|
+
if (res.code == 200) {
|
727
|
+
this.$showMessage("取消预约成功")
|
703
728
|
}
|
704
|
-
}
|
705
|
-
|
706
|
-
this.showModal2=false
|
707
|
-
this.showModal3=false
|
708
|
-
},
|
709
|
-
queryplan(val){
|
710
|
-
this.needid=val
|
711
|
-
this.showModal2 = true
|
712
|
-
},
|
713
|
-
queryplanmany(){
|
714
|
-
|
715
|
-
this.showModal3 = true
|
716
|
-
},
|
717
|
-
reload(){
|
718
|
-
// this.getAllArea()
|
719
|
-
// this.getAllPlanName()
|
720
|
-
this.selfSearch()
|
721
|
-
},
|
722
|
-
cancelReserve (idx, id) {
|
723
|
-
if(Vue.android){
|
724
|
-
let res = this.$androidUtil.bzLogic('BookingCheck', {dt: '', id: id})
|
729
|
+
}else {
|
730
|
+
this.$androidUtil.bzLogic('PCbookingCheck', {dt: '', id: id}).then((repanse) => {
|
725
731
|
this.$set('model.rows[' + idx + '].f_prearranged_date', null)
|
726
|
-
if (
|
727
|
-
|
728
|
-
}
|
729
|
-
}else {
|
730
|
-
this.$androidUtil.bzLogic('PCbookingCheck', {dt: '', id: id}).then((repanse) => {
|
731
|
-
this.$set('model.rows[' + idx + '].f_prearranged_date', null)
|
732
|
-
if (repanse.data.code == 200) {
|
733
|
-
alert("取消预约成功!")
|
734
|
-
}
|
735
|
-
})
|
736
|
-
}},
|
737
|
-
genuineReserve () {
|
738
|
-
if(Vue.android){
|
739
|
-
if (!this.f_preset_dt) {
|
740
|
-
this.$showMessage('请选择一个日期')
|
741
|
-
return
|
742
|
-
}
|
743
|
-
let pdt = this.f_preset_dt.replace('T', ' ')
|
744
|
-
let respanse = this.$androidUtil.bzLogic('BookingCheck', {id: this.model.rows[this.param].id, dt: pdt})
|
745
|
-
this.$set('model.rows[' + this.param + '].f_prearranged_date', pdt)
|
746
|
-
if(respanse.code == 200) {
|
747
|
-
this.$showMessage("预约成功!")
|
748
|
-
}
|
749
|
-
this.showModal = false
|
750
|
-
}else {
|
751
|
-
if (!this.f_preset_dt) {
|
752
|
-
alert('请选择一个日期')
|
753
|
-
return
|
754
|
-
}
|
755
|
-
let pdt = this.f_preset_dt.replace('T', ' ')
|
756
|
-
this.$androidUtil.bzLogic('PCbookingCheck', {id: this.model.rows[this.param].id, dt: pdt}).then((res) => {
|
757
|
-
this.$set('model.rows[' + this.param + '].f_prearranged_date', pdt)
|
758
|
-
if(res.data.code == 200) {
|
759
|
-
alert("预约成功!")
|
760
|
-
}
|
761
|
-
this.showModal = false
|
762
|
-
})
|
763
|
-
}
|
764
|
-
},
|
765
|
-
inspect(row) {
|
766
|
-
var _this = this
|
767
|
-
let http = new HttpResetClass()
|
768
|
-
http.load('POST',`${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {data: {
|
769
|
-
items: 'id',
|
770
|
-
tablename: 't_check_plan_item',
|
771
|
-
condition: `id = '${row.id}'`,
|
772
|
-
orderitem: "id",
|
773
|
-
}}, {resolveMsg: null, rejectMsg: null}).then((getcheckplan) => {
|
774
|
-
console.log('getcheckplan=', JSON.stringify(getcheckplan))
|
775
|
-
this.getcheckplandata = getcheckplan.data[0]
|
776
|
-
if(this.getcheckplandata){
|
777
|
-
if (row.f_upload_state == '未传' || (row.f_upload_state == '已传' && row.f_state == '未检' && row.f_no_checkplan != '无计划安检' ) ) {
|
778
|
-
_this.$resetpost(`${_this.$androidUtil.getProxyUrl()}/rs/sql/查询计划项表信息`, {data: {f_userid: row.f_userinfoid}},{resolveMsg: null,rejectMsg: null}).then((response) => {
|
779
|
-
row['f_plan_meters'] = response.data
|
780
|
-
var pardate = {
|
781
|
-
_this:_this,
|
782
|
-
title:'安全检查',
|
783
|
-
safe:true
|
784
|
-
}
|
785
|
-
_this.$dispatch('gotoson',pardate)
|
786
|
-
//tag
|
787
|
-
_this.$goto('safecheck-order-v', {f_plan_id: row.f_plan_id, item: row, role: 'inspect',parentPage:'CurrentCreate'}, 'self', _this.reload)
|
788
|
-
}).catch ((msg)=>{
|
789
|
-
this.$showMessage("网络异常,请检查网络后再试!")
|
790
|
-
})
|
791
|
-
}else{
|
792
|
-
this.$showMessage("该安检单已被上传!")
|
793
|
-
}
|
794
|
-
}else {
|
795
|
-
this.$showMessage("该用户安检单已被移除,请联系管理员确认!")
|
732
|
+
if (repanse.data.code == 200) {
|
733
|
+
alert("取消预约成功!")
|
796
734
|
}
|
797
735
|
})
|
798
|
-
},
|
799
|
-
|
800
|
-
|
801
|
-
|
802
|
-
|
803
|
-
this.param = idx
|
804
|
-
this.showModal = true
|
805
|
-
},
|
806
|
-
search(args) {
|
807
|
-
this.model.rows = []
|
808
|
-
this.model.search(args.condition, args.model)
|
809
|
-
},
|
810
|
-
selfSearch () {
|
811
|
-
this.getPlanCount()
|
812
|
-
let condition = ""
|
813
|
-
if(this.$refs.paged.$refs.cri.model.f_residential_area)
|
814
|
-
condition += " and ti.f_residential_area = '"+this.$refs.paged.$refs.cri.model.f_residential_area+"'"
|
815
|
-
if(this.$refs.paged.$refs.cri.model.f_building)
|
816
|
-
condition += " and ti.f_building = "+this.$refs.paged.$refs.cri.model.f_building+""
|
817
|
-
if(this.$refs.paged.$refs.cri.model.f_unit)
|
818
|
-
condition += ` and ti.f_unit = '${this.$refs.paged.$refs.cri.model.f_unit}'`
|
819
|
-
if (this.planName){
|
820
|
-
condition += " and f_plan_name like '%"+this.planName +"%'"
|
821
|
-
}else {
|
822
|
-
if(this.$refs.paged.$refs.cri.model.f_plan_name)
|
823
|
-
condition += " and f_plan_name like '%"+this.$refs.paged.$refs.cri.model.f_plan_name +"%'"
|
824
|
-
}
|
825
|
-
// if(this.$refs.paged.$refs.cri.model.f_plan_year)
|
826
|
-
// condition += " and f_plan_year = '"+this.$refs.paged.$refs.cri.model.f_plan_year +"'"
|
827
|
-
// if(this.$refs.paged.$refs.cri.model.f_plan_month)
|
828
|
-
// condition += " and f_plan_month = '"+this.$refs.paged.$refs.cri.model.f_plan_month +"'"
|
829
|
-
if(this.$refs.paged.$refs.cri.model.f_userinfo_code)
|
830
|
-
condition += " and ti.f_userinfo_code like '%"+this.$refs.paged.$refs.cri.model.f_userinfo_code+"%'"
|
831
|
-
if(this.$refs.paged.$refs.cri.model.f_keyword)
|
832
|
-
condition += " and ti.f_address like '%"+this.$refs.paged.$refs.cri.model.f_keyword+"%'"
|
833
|
-
if(this.$refs.paged.$refs.cri.model.f_user_name)
|
834
|
-
condition += " and ti.f_user_name like '%"+this.$refs.paged.$refs.cri.model.f_user_name+"%'"
|
835
|
-
if(this.$refs.paged.$refs.cri.model.f_state[0])
|
836
|
-
condition += " and ti.f_state='"+this.$refs.paged.$refs.cri.model.f_state[0]+"'"
|
837
|
-
// if(this.$refs.paged.$refs.cri.model.f_last_state[0])
|
838
|
-
// condition += " and ti.f_last_check_state='"+this.$refs.paged.$refs.cri.model.f_last_state[0]+"'"
|
839
|
-
if(this.$refs.paged.$refs.cri.model.f_user_type[0])
|
840
|
-
condition += " and ti.f_user_type='"+this.$refs.paged.$refs.cri.model.f_user_type[0]+"'"
|
841
|
-
if(this.$refs.paged.$refs.cri.model.f_meter_no)
|
842
|
-
condition += " and tm.f_meter_no like '%"+this.$refs.paged.$refs.cri.model.f_meter_no+"%'"
|
843
|
-
// if(this.$refs.paged.$refs.cri.model.f_flow_direction[0])
|
844
|
-
// condition += " and tm.f_flow_direction = '"+this.$refs.paged.$refs.cri.model.f_flow_direction[0]+"'"
|
845
|
-
|
846
|
-
if(this.$refs.paged.$refs.cri.model.f_enter_number)
|
847
|
-
condition += " and ti.f_enter_number like '%"+this.$refs.paged.$refs.cri.model.f_enter_number+"%'"
|
848
|
-
|
849
|
-
//tag
|
850
|
-
this.model.search("((f_complete = '' or f_complete = null or f_complete = '未完成') or (f_state = '未检')) and ti.f_no_checkplan = '有计划安检'" + condition)
|
851
|
-
},
|
852
|
-
getNewOrder(){
|
853
|
-
HostApp.__this__ = this
|
854
|
-
HostApp.logicWithHint({
|
855
|
-
// logic别名,key必须为logic
|
856
|
-
'logic': 'SafeCheckServiceTimeOut',
|
857
|
-
// 回调执行方法名,key必须为callback
|
858
|
-
'callback': 'javascript:HostApp.__this__.getNewOrderCallBack()',
|
859
|
-
// logic执行需要的业务参数
|
860
|
-
'data': {params: ''},
|
861
|
-
// 固定key,代表是否将logic执行结果作为参数传入回调方法,1代表true,0代表false,
|
862
|
-
// 执行回调方法传入key为backresult
|
863
|
-
// 如需额外拼接参数,写在logic返回值的params,例如xxlogic返回:{"params": "success"}
|
864
|
-
'backresult': 1
|
865
|
-
})
|
866
|
-
},
|
867
|
-
getNewOrderCallBack() {
|
868
|
-
this.selfSearch()
|
869
|
-
this.getAllArea()
|
870
|
-
this.getAllPlanName()
|
871
|
-
},
|
872
|
-
hidden() {
|
873
|
-
this.criteriaShow = !this.criteriaShow
|
874
|
-
},
|
875
|
-
getAllArea(){
|
876
|
-
this.residentialAreaOptions = []
|
877
|
-
this.buildOptions = []
|
878
|
-
this.unitOptions = []
|
879
|
-
this.$refs.paged.$refs.cri.model.f_residential_area = ''
|
880
|
-
this.$refs.paged.$refs.cri.model.f_building = ''
|
881
|
-
this.$refs.paged.$refs.cri.model.f_unit = ''
|
882
|
-
let criteria = {
|
883
|
-
items: 'f_residential_area',
|
884
|
-
tablename: 't_check_plan_item',
|
885
|
-
condition: `f_residential_area IS NOT NULL AND f_residential_area != '' AND f_state <> '已检'`,
|
886
|
-
groupitem: 'f_residential_area'
|
887
|
-
}
|
888
|
-
let result = HostApp._executeTask({'type':'sql', 'data':{'alias': 'safe_singleTable_GroupBy', 'criteria': criteria}})
|
889
|
-
//tag)
|
890
|
-
if(result.code == 200){
|
891
|
-
result.data.rows.forEach(item => this.residentialAreaOptions.push({label:item.f_residential_area,value:item.f_residential_area}))
|
892
|
-
}
|
893
|
-
//tag)
|
894
|
-
},
|
895
|
-
getbuilds(f_residential_area){
|
896
|
-
//tag)
|
897
|
-
this.buildOptions = []
|
898
|
-
this.unitOptions = []
|
899
|
-
this.$refs.paged.$refs.cri.model.f_building = ''
|
900
|
-
this.$refs.paged.$refs.cri.model.f_unit = ''
|
901
|
-
if(!f_residential_area){
|
736
|
+
}},
|
737
|
+
genuineReserve () {
|
738
|
+
if(Vue.android){
|
739
|
+
if (!this.f_preset_dt) {
|
740
|
+
this.$showMessage('请选择一个日期')
|
902
741
|
return
|
903
742
|
}
|
904
|
-
let
|
905
|
-
|
906
|
-
|
907
|
-
|
908
|
-
|
743
|
+
let pdt = this.f_preset_dt.replace('T', ' ')
|
744
|
+
let respanse = this.$androidUtil.bzLogic('BookingCheck', {id: this.model.rows[this.param].id, dt: pdt})
|
745
|
+
this.$set('model.rows[' + this.param + '].f_prearranged_date', pdt)
|
746
|
+
if(respanse.code == 200) {
|
747
|
+
this.$showMessage("预约成功!")
|
909
748
|
}
|
910
|
-
|
911
|
-
|
912
|
-
|
913
|
-
|
914
|
-
this.buildOptions.sort((a,b)=>{
|
915
|
-
return Number(a.label)- Number(b.label)
|
916
|
-
})
|
917
|
-
//tag)
|
918
|
-
},
|
919
|
-
getUnits(f_building){
|
920
|
-
f_building = f_building[0]
|
921
|
-
//tag)
|
922
|
-
this.unitOptions = []
|
923
|
-
this.$refs.paged.$refs.cri.model.f_unit = ''
|
924
|
-
if(!f_building){
|
749
|
+
this.showModal = false
|
750
|
+
}else {
|
751
|
+
if (!this.f_preset_dt) {
|
752
|
+
alert('请选择一个日期')
|
925
753
|
return
|
926
754
|
}
|
927
|
-
let
|
928
|
-
|
929
|
-
|
930
|
-
|
931
|
-
|
932
|
-
|
933
|
-
|
934
|
-
if(result.code == 200){
|
935
|
-
result.data.rows.forEach(item => this.unitOptions.push({label:item.f_unit,value:item.f_unit}))
|
936
|
-
}
|
937
|
-
this.unitOptions.sort((a,b)=>{
|
938
|
-
return Number(a.label)- Number(b.label)
|
755
|
+
let pdt = this.f_preset_dt.replace('T', ' ')
|
756
|
+
this.$androidUtil.bzLogic('PCbookingCheck', {id: this.model.rows[this.param].id, dt: pdt}).then((res) => {
|
757
|
+
this.$set('model.rows[' + this.param + '].f_prearranged_date', pdt)
|
758
|
+
if(res.data.code == 200) {
|
759
|
+
alert("预约成功!")
|
760
|
+
}
|
761
|
+
this.showModal = false
|
939
762
|
})
|
940
|
-
}
|
941
|
-
|
942
|
-
|
943
|
-
|
944
|
-
|
945
|
-
|
946
|
-
|
947
|
-
items: 'count(id) count',
|
763
|
+
}
|
764
|
+
},
|
765
|
+
inspect(row) {
|
766
|
+
var _this = this
|
767
|
+
let http = new HttpResetClass()
|
768
|
+
http.load('POST',`${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {data: {
|
769
|
+
items: 'id',
|
948
770
|
tablename: 't_check_plan_item',
|
949
|
-
condition:
|
950
|
-
|
951
|
-
}
|
952
|
-
|
953
|
-
|
954
|
-
|
955
|
-
|
771
|
+
condition: `id = '${row.id}'`,
|
772
|
+
orderitem: "id",
|
773
|
+
}}, {resolveMsg: null, rejectMsg: null}).then((getcheckplan) => {
|
774
|
+
console.log('getcheckplan=', JSON.stringify(getcheckplan))
|
775
|
+
this.getcheckplandata = getcheckplan.data[0]
|
776
|
+
if(this.getcheckplandata){
|
777
|
+
if (row.f_upload_state == '未传' || (row.f_upload_state == '已传' && row.f_state == '未检' && row.f_no_checkplan != '无计划安检' ) ) {
|
778
|
+
_this.$resetpost(`${_this.$androidUtil.getProxyUrl()}/rs/sql/查询计划项表信息`, {data: {f_userid: row.f_userinfoid}},{resolveMsg: null,rejectMsg: null}).then((response) => {
|
779
|
+
row['f_plan_meters'] = response.data
|
780
|
+
var pardate = {
|
781
|
+
_this:_this,
|
782
|
+
title:'安全检查',
|
783
|
+
safe:true
|
784
|
+
}
|
785
|
+
_this.$dispatch('gotoson',pardate)
|
786
|
+
//tag
|
787
|
+
_this.$goto('safecheck-order-v', {f_plan_id: row.f_plan_id, item: row, role: 'inspect',parentPage:'CurrentCreate'}, 'self', _this.reload)
|
788
|
+
}).catch ((msg)=>{
|
789
|
+
this.$showMessage("网络异常,请检查网络后再试!")
|
790
|
+
})
|
791
|
+
}else{
|
792
|
+
this.$showMessage("该安检单已被上传!")
|
956
793
|
}
|
794
|
+
}else {
|
795
|
+
this.$showMessage("该用户安检单已被移除,请联系管理员确认!")
|
957
796
|
}
|
958
|
-
|
959
|
-
|
960
|
-
|
961
|
-
|
962
|
-
|
963
|
-
|
964
|
-
|
965
|
-
|
966
|
-
|
967
|
-
|
968
|
-
|
797
|
+
})
|
798
|
+
},
|
799
|
+
makeAPhoneCall(phoneNumber) {
|
800
|
+
this.$androidUtil.makeAPhoneCall(phoneNumber)
|
801
|
+
},
|
802
|
+
reserve (idx) {
|
803
|
+
this.param = idx
|
804
|
+
this.showModal = true
|
805
|
+
},
|
806
|
+
search(args) {
|
807
|
+
this.model.rows = []
|
808
|
+
this.model.search(args.condition, args.model)
|
809
|
+
},
|
810
|
+
selfSearch () {
|
811
|
+
this.getPlanCount()
|
812
|
+
let condition = ""
|
813
|
+
if(this.$refs.paged.$refs.cri.model.f_residential_area)
|
814
|
+
condition += " and ti.f_residential_area = '"+this.$refs.paged.$refs.cri.model.f_residential_area+"'"
|
815
|
+
if(this.$refs.paged.$refs.cri.model.f_building)
|
816
|
+
condition += ` and ti.f_building ='${this.$refs.paged.$refs.cri.model.f_building}'`
|
817
|
+
if(this.$refs.paged.$refs.cri.model.f_unit)
|
818
|
+
condition += ` and ti.f_unit = '${this.$refs.paged.$refs.cri.model.f_unit}'`
|
819
|
+
if (this.planName){
|
820
|
+
condition += " and f_plan_name like '%"+this.planName +"%'"
|
821
|
+
}else {
|
822
|
+
if(this.$refs.paged.$refs.cri.model.f_plan_name)
|
823
|
+
condition += " and f_plan_name like '%"+this.$refs.paged.$refs.cri.model.f_plan_name +"%'"
|
824
|
+
}
|
825
|
+
// if(this.$refs.paged.$refs.cri.model.f_plan_year)
|
826
|
+
// condition += " and f_plan_year = '"+this.$refs.paged.$refs.cri.model.f_plan_year +"'"
|
827
|
+
// if(this.$refs.paged.$refs.cri.model.f_plan_month)
|
828
|
+
// condition += " and f_plan_month = '"+this.$refs.paged.$refs.cri.model.f_plan_month +"'"
|
829
|
+
if(this.$refs.paged.$refs.cri.model.f_userinfo_code)
|
830
|
+
condition += " and ti.f_userinfo_code like '%"+this.$refs.paged.$refs.cri.model.f_userinfo_code+"%'"
|
831
|
+
if(this.$refs.paged.$refs.cri.model.f_keyword)
|
832
|
+
condition += " and ti.f_address like '%"+this.$refs.paged.$refs.cri.model.f_keyword+"%'"
|
833
|
+
if(this.$refs.paged.$refs.cri.model.f_user_name)
|
834
|
+
condition += " and ti.f_user_name like '%"+this.$refs.paged.$refs.cri.model.f_user_name+"%'"
|
835
|
+
if(this.$refs.paged.$refs.cri.model.f_state[0])
|
836
|
+
condition += " and ti.f_state='"+this.$refs.paged.$refs.cri.model.f_state[0]+"'"
|
837
|
+
// if(this.$refs.paged.$refs.cri.model.f_last_state[0])
|
838
|
+
// condition += " and ti.f_last_check_state='"+this.$refs.paged.$refs.cri.model.f_last_state[0]+"'"
|
839
|
+
if(this.$refs.paged.$refs.cri.model.f_user_type[0])
|
840
|
+
condition += " and ti.f_user_type='"+this.$refs.paged.$refs.cri.model.f_user_type[0]+"'"
|
841
|
+
if(this.$refs.paged.$refs.cri.model.f_meter_no)
|
842
|
+
condition += " and tm.f_meter_no like '%"+this.$refs.paged.$refs.cri.model.f_meter_no+"%'"
|
843
|
+
// if(this.$refs.paged.$refs.cri.model.f_flow_direction[0])
|
844
|
+
// condition += " and tm.f_flow_direction = '"+this.$refs.paged.$refs.cri.model.f_flow_direction[0]+"'"
|
845
|
+
|
846
|
+
if(this.$refs.paged.$refs.cri.model.f_enter_number)
|
847
|
+
condition += " and ti.f_enter_number like '%"+this.$refs.paged.$refs.cri.model.f_enter_number+"%'"
|
848
|
+
|
849
|
+
//tag
|
850
|
+
this.model.search("((f_complete = '' or f_complete = null or f_complete = '未完成') or (f_state = '未检')) and ti.f_no_checkplan = '有计划安检'" + condition)
|
851
|
+
},
|
852
|
+
getNewOrder(){
|
853
|
+
HostApp.__this__ = this
|
854
|
+
HostApp.logicWithHint({
|
855
|
+
// logic别名,key必须为logic
|
856
|
+
'logic': 'SafeCheckServiceTimeOut',
|
857
|
+
// 回调执行方法名,key必须为callback
|
858
|
+
'callback': 'javascript:HostApp.__this__.getNewOrderCallBack()',
|
859
|
+
// logic执行需要的业务参数
|
860
|
+
'data': {params: ''},
|
861
|
+
// 固定key,代表是否将logic执行结果作为参数传入回调方法,1代表true,0代表false,
|
862
|
+
// 执行回调方法传入key为backresult
|
863
|
+
// 如需额外拼接参数,写在logic返回值的params,例如xxlogic返回:{"params": "success"}
|
864
|
+
'backresult': 1
|
865
|
+
})
|
866
|
+
},
|
867
|
+
getNewOrderCallBack() {
|
868
|
+
this.selfSearch()
|
869
|
+
this.getAllArea()
|
870
|
+
this.getAllPlanName()
|
871
|
+
},
|
872
|
+
hidden() {
|
873
|
+
this.criteriaShow = !this.criteriaShow
|
874
|
+
},
|
875
|
+
getAllArea(){
|
876
|
+
this.residentialAreaOptions = []
|
877
|
+
this.buildOptions = []
|
878
|
+
this.unitOptions = []
|
879
|
+
this.$refs.paged.$refs.cri.model.f_residential_area = ''
|
880
|
+
this.$refs.paged.$refs.cri.model.f_building = ''
|
881
|
+
this.$refs.paged.$refs.cri.model.f_unit = ''
|
882
|
+
let criteria = {
|
883
|
+
items: 'f_residential_area',
|
884
|
+
tablename: 't_check_plan_item',
|
885
|
+
condition: `f_residential_area IS NOT NULL AND f_residential_area != '' AND f_state <> '已检'`,
|
886
|
+
groupitem: 'f_residential_area'
|
887
|
+
}
|
888
|
+
let result = HostApp._executeTask({'type':'sql', 'data':{'alias': 'safe_singleTable_GroupBy', 'criteria': criteria}})
|
889
|
+
//tag)
|
890
|
+
if(result.code == 200){
|
891
|
+
result.data.rows.forEach(item => this.residentialAreaOptions.push({label:item.f_residential_area,value:item.f_residential_area}))
|
892
|
+
}
|
893
|
+
//tag)
|
894
|
+
},
|
895
|
+
getbuilds(f_residential_area){
|
896
|
+
//tag)
|
897
|
+
this.buildOptions = []
|
898
|
+
this.unitOptions = []
|
899
|
+
this.$refs.paged.$refs.cri.model.f_building = ''
|
900
|
+
this.$refs.paged.$refs.cri.model.f_unit = ''
|
901
|
+
if(!f_residential_area){
|
902
|
+
return
|
903
|
+
}
|
904
|
+
let criteria = {
|
905
|
+
items: 'f_building',
|
906
|
+
tablename: 't_check_plan_item',
|
907
|
+
condition: `f_building IS NOT NULL AND f_building != '' AND f_state <> '已检' AND f_residential_area = '${f_residential_area}'`,
|
908
|
+
groupitem: 'f_building order by f_building+0'
|
909
|
+
}
|
910
|
+
let result = HostApp._executeTask({'type':'sql', 'data':{'alias': 'safe_singleTable_GroupBy', 'criteria': criteria}})
|
911
|
+
if(result.code == 200){
|
912
|
+
result.data.rows.forEach(item => this.buildOptions.push({label:item.f_building,value:item.f_building}))
|
913
|
+
}
|
914
|
+
this.buildOptions.sort((a,b)=>{
|
915
|
+
return Number(a.label)- Number(b.label)
|
916
|
+
})
|
917
|
+
//tag)
|
918
|
+
},
|
919
|
+
getUnits(f_building){
|
920
|
+
f_building = f_building[0]
|
921
|
+
//tag)
|
922
|
+
this.unitOptions = []
|
923
|
+
this.$refs.paged.$refs.cri.model.f_unit = ''
|
924
|
+
if(!f_building){
|
925
|
+
return
|
926
|
+
}
|
927
|
+
let criteria = {
|
928
|
+
items: 'f_unit',
|
929
|
+
tablename: 't_check_plan_item',
|
930
|
+
condition: `f_unit IS NOT NULL AND f_unit != '' AND f_state <> '已检' AND f_residential_area = '${this.$refs.paged.$refs.cri.model.f_residential_area}' AND f_building = '${f_building}'`,
|
931
|
+
groupitem: 'f_unit'
|
932
|
+
}
|
933
|
+
let result = HostApp._executeTask({'type':'sql', 'data':{'alias': 'safe_singleTable_GroupBy', 'criteria': criteria}})
|
934
|
+
if(result.code == 200){
|
935
|
+
result.data.rows.forEach(item => this.unitOptions.push({label:item.f_unit,value:item.f_unit}))
|
936
|
+
}
|
937
|
+
this.unitOptions.sort((a,b)=>{
|
938
|
+
return Number(a.label)- Number(b.label)
|
939
|
+
})
|
940
|
+
},
|
941
|
+
getPlanCount(){
|
942
|
+
this.upcomingCount = 0
|
943
|
+
this.tempSaveCount = 0
|
944
|
+
this.doneCount = 0
|
945
|
+
this.allPlanCount = 0
|
946
|
+
let criteria = {
|
947
|
+
items: 'count(id) count',
|
948
|
+
tablename: 't_check_plan_item',
|
949
|
+
condition: `f_state = '未检'`,
|
950
|
+
groupitem: 'f_state'
|
951
|
+
}
|
952
|
+
let result = HostApp._executeTask({'type':'sql', 'data':{'alias': 'safe_singleTable_GroupBy', 'criteria': criteria}})
|
953
|
+
if(result.code && result.code == 200){
|
954
|
+
if(result.data.rows[0] && !isNaN(result.data.rows[0].count)) {
|
955
|
+
this.upcomingCount = result.data.rows[0].count
|
969
956
|
}
|
970
|
-
|
971
|
-
|
972
|
-
|
973
|
-
|
974
|
-
|
957
|
+
}
|
958
|
+
criteria = {
|
959
|
+
items: 'count(id) count',
|
960
|
+
tablename: 't_check_plan_item',
|
961
|
+
condition: `(f_complete = '' or f_complete = null or f_complete = '未完成') AND f_state = '已检'`,
|
962
|
+
groupitem: 'f_state'
|
963
|
+
}
|
964
|
+
result = HostApp._executeTask({'type':'sql', 'data':{'alias': 'safe_singleTable_GroupBy', 'criteria': criteria}})
|
965
|
+
if(result.code && result.code == 200){
|
966
|
+
if(result.data.rows[0] && !isNaN(result.data.rows[0].count)){
|
967
|
+
this.tempSaveCount = result.data.rows[0].count
|
975
968
|
}
|
976
|
-
|
977
|
-
|
978
|
-
|
979
|
-
|
980
|
-
|
969
|
+
}
|
970
|
+
criteria = {
|
971
|
+
items: 'count(id) count',
|
972
|
+
tablename: 't_check_plan_item',
|
973
|
+
condition: `f_complete = '已完成' AND f_state = '已检'`,
|
974
|
+
groupitem: 'f_state'
|
975
|
+
}
|
976
|
+
result = HostApp._executeTask({'type':'sql', 'data':{'alias': 'safe_singleTable_GroupBy', 'criteria': criteria}})
|
977
|
+
if(result.code && result.code == 200){
|
978
|
+
if(result.data.rows[0] && !isNaN(result.data.rows[0].count)){
|
979
|
+
this.doneCount = result.data.rows[0].count
|
981
980
|
}
|
982
|
-
|
981
|
+
}
|
982
|
+
this.allPlanCount = this.upcomingCount + this.tempSaveCount + this.doneCount
|
983
983
|
|
984
|
+
//tag
|
985
|
+
//tag
|
986
|
+
//tag
|
987
|
+
//tag
|
988
|
+
},
|
989
|
+
getAllPlanName(){
|
990
|
+
this.planNameOptions = []
|
991
|
+
this.$refs.paged.$refs.cri.model.f_plan_name = ''
|
992
|
+
let criteria = {
|
993
|
+
items: 'f_plan_name',
|
994
|
+
tablename: 't_check_plan',
|
995
|
+
condition: `f_plan_name IS NOT NULL AND f_plan_name != ''`,
|
996
|
+
groupitem: 'f_plan_name'
|
997
|
+
}
|
998
|
+
let result = HostApp._executeTask({'type':'sql', 'data':{'alias': 'safe_singleTable_GroupBy', 'criteria': criteria}})
|
999
|
+
//tag)
|
1000
|
+
if(result.code == 200){
|
1001
|
+
result.data.rows.forEach(item => this.planNameOptions.push({label:item.f_plan_name,value:item.f_plan_name}))
|
1002
|
+
}
|
1003
|
+
//tag)
|
1004
|
+
},
|
1005
|
+
setPlanParam(detailsType, event) {
|
1006
|
+
if (event.srcElement.checked) {
|
1007
|
+
this.planparam.push(detailsType)
|
984
1008
|
//tag
|
985
|
-
|
986
|
-
|
987
|
-
|
988
|
-
|
989
|
-
|
990
|
-
|
991
|
-
this.$refs.paged.$refs.cri.model.f_plan_name = ''
|
992
|
-
let criteria = {
|
993
|
-
items: 'f_plan_name',
|
994
|
-
tablename: 't_check_plan',
|
995
|
-
condition: `f_plan_name IS NOT NULL AND f_plan_name != ''`,
|
996
|
-
groupitem: 'f_plan_name'
|
997
|
-
}
|
998
|
-
let result = HostApp._executeTask({'type':'sql', 'data':{'alias': 'safe_singleTable_GroupBy', 'criteria': criteria}})
|
999
|
-
//tag)
|
1000
|
-
if(result.code == 200){
|
1001
|
-
result.data.rows.forEach(item => this.planNameOptions.push({label:item.f_plan_name,value:item.f_plan_name}))
|
1002
|
-
}
|
1003
|
-
//tag)
|
1004
|
-
},
|
1005
|
-
setPlanParam(detailsType, event) {
|
1006
|
-
if (event.srcElement.checked) {
|
1007
|
-
this.planparam.push(detailsType)
|
1009
|
+
} else {
|
1010
|
+
if(this.planparam.length>0){
|
1011
|
+
let planid= this.planparam.findIndex((value) => {
|
1012
|
+
return value === detailsType
|
1013
|
+
})
|
1014
|
+
this.planparam.splice(planid, 1)
|
1008
1015
|
//tag
|
1009
|
-
} else {
|
1010
|
-
if(this.planparam.length>0){
|
1011
|
-
let planid= this.planparam.findIndex((value) => {
|
1012
|
-
return value === detailsType
|
1013
|
-
})
|
1014
|
-
this.planparam.splice(planid, 1)
|
1015
|
-
//tag
|
1016
|
-
|
1017
|
-
}
|
1018
1016
|
|
1019
1017
|
}
|
1018
|
+
|
1020
1019
|
}
|
1021
1020
|
}
|
1022
1021
|
}
|
1022
|
+
}
|
1023
1023
|
</script>
|