@zscreate/zhxy-app-component 1.0.287 → 1.0.288
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.
|
@@ -1,128 +1,128 @@
|
|
|
1
|
-
<script>
|
|
2
|
-
import FullModal from "../../fullModal/fullModal.vue";
|
|
3
|
-
|
|
4
|
-
export default {
|
|
5
|
-
name: "responsibility",
|
|
6
|
-
props: {
|
|
7
|
-
value: {
|
|
8
|
-
type: String,
|
|
9
|
-
default: ''
|
|
10
|
-
},
|
|
11
|
-
widget: {
|
|
12
|
-
type: Object,
|
|
13
|
-
default: () => ({})
|
|
14
|
-
},
|
|
15
|
-
},
|
|
16
|
-
components: {FullModal},
|
|
17
|
-
data() {
|
|
18
|
-
return {
|
|
19
|
-
countDown: 0,
|
|
20
|
-
force: false,
|
|
21
|
-
clearTimeout: null,
|
|
22
|
-
dataModel: false,
|
|
23
|
-
isShow: false,
|
|
24
|
-
}
|
|
25
|
-
},
|
|
26
|
-
watch: {
|
|
27
|
-
value: {
|
|
28
|
-
handler(val) {
|
|
29
|
-
if (!val) return this.dataModel = false
|
|
30
|
-
this.dataModel = true
|
|
31
|
-
},
|
|
32
|
-
immediate: true
|
|
33
|
-
},
|
|
34
|
-
dataModel(val) {
|
|
35
|
-
this.$emit('input', val ? true : '')
|
|
36
|
-
this.$emit('change', val ? true: '')
|
|
37
|
-
},
|
|
38
|
-
},
|
|
39
|
-
methods: {
|
|
40
|
-
handleClick() {
|
|
41
|
-
if (this.widget.options.disabled) {
|
|
42
|
-
this.isShow = true
|
|
43
|
-
return
|
|
44
|
-
}
|
|
45
|
-
this.isShow = true
|
|
46
|
-
this.countDown = 0
|
|
47
|
-
clearInterval(this.clearTimeout)
|
|
48
|
-
if (this.widget.options.force) {
|
|
49
|
-
this.countDown = this.widget.options.countDown
|
|
50
|
-
this.clearTimeout = setInterval(() => {
|
|
51
|
-
if (this.countDown < 0) {
|
|
52
|
-
clearInterval(this.clearTimeout)
|
|
53
|
-
}
|
|
54
|
-
this.countDown -= 1
|
|
55
|
-
}, 1000)
|
|
56
|
-
}
|
|
57
|
-
},
|
|
58
|
-
confirm() {
|
|
59
|
-
if (this.countDown <= 0) {
|
|
60
|
-
this.dataModel = true
|
|
61
|
-
this.isShow = false
|
|
62
|
-
}
|
|
63
|
-
},
|
|
64
|
-
cancel() {
|
|
65
|
-
this.isShow = false
|
|
66
|
-
this.dataModel = false
|
|
67
|
-
clearInterval(this.clearTimeout)
|
|
68
|
-
},
|
|
69
|
-
handleCheck() {
|
|
70
|
-
const { disabled, force} = this.widget.options
|
|
71
|
-
if (disabled) return
|
|
72
|
-
if (force && !disabled) {
|
|
73
|
-
if (this.dataModel) return this.dataModel = false
|
|
74
|
-
return this.handleClick()
|
|
75
|
-
}
|
|
76
|
-
this.dataModel = !this.dataModel
|
|
77
|
-
},
|
|
78
|
-
change(e) {
|
|
79
|
-
console.log(e)
|
|
80
|
-
},
|
|
81
|
-
disabledScroll() {
|
|
82
|
-
return
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
</script>
|
|
87
|
-
|
|
88
|
-
<template>
|
|
89
|
-
<view>
|
|
90
|
-
<full-modal v-model="isShow">
|
|
91
|
-
<view style="height: 100%; background-color: #fff" @touchmove.stop.prevent="disabledScroll">
|
|
92
|
-
<scroll-view scroll-y="true" style="height: calc(100% - 100rpx); " >
|
|
93
|
-
<view style="padding: 20rpx 40rpx;">
|
|
94
|
-
<rich-text :nodes="widget.options.content" style="text-align: left"></rich-text>
|
|
95
|
-
</view>
|
|
96
|
-
<view v-if="!widget.options.disabled" style="display: flex; padding: 20rpx; margin-bottom: 20rpx; justify-content: center">
|
|
97
|
-
<button @click="confirm" type="primary" style="margin-right: 10px; border-radius: 10rpx; padding: 0 20px; height: 60rpx; line-height: 60rpx; font-size: 26rpx" :disabled="widget.options.force && countDown > 0">我同意 <text v-if="widget.options.force && countDown > 0">({{ countDown }}s)</text></button>
|
|
98
|
-
<button style="height: 60rpx; line-height: 60rpx; font-size: 26rpx; border-radius: 10rpx; color: #333" @click="cancel">不同意</button>
|
|
99
|
-
</view>
|
|
100
|
-
<view v-else style="display: flex; justify-content: center; align-items: center">
|
|
101
|
-
<button @click="isShow = false" type="primary" style="margin-bottom: 20px; border-radius: 10rpx; padding: 0 20px; height: 60rpx; line-height: 60rpx; font-size: 26rpx; " >关闭</button>
|
|
102
|
-
</view>
|
|
103
|
-
</scroll-view>
|
|
104
|
-
</view>
|
|
105
|
-
</full-modal>
|
|
106
|
-
<view class="responsibility_check" >
|
|
107
|
-
<view @click.stop="handleCheck">
|
|
108
|
-
<label>
|
|
109
|
-
<checkbox :disabled="widget.options.disabled" :readonly="widget.options.disabled" v-if="!isShow" :checked="dataModel" color="#007AFF" style="transform: scale(0.8,0.8);"/>
|
|
110
|
-
</label>
|
|
111
|
-
</view>
|
|
112
|
-
<view class="option-font-size" @click.stop="handleClick">{{ widget.options.title }}</view>
|
|
113
|
-
|
|
114
|
-
</view>
|
|
115
|
-
</view>
|
|
116
|
-
|
|
117
|
-
</template>
|
|
118
|
-
|
|
119
|
-
<style lang="less">
|
|
120
|
-
.responsibility_check {
|
|
121
|
-
display: flex;
|
|
122
|
-
align-items: center;
|
|
123
|
-
/deep/ .uni-checkbox-input {
|
|
124
|
-
width: 18px;
|
|
125
|
-
height: 18px;
|
|
126
|
-
}
|
|
127
|
-
}
|
|
1
|
+
<script>
|
|
2
|
+
import FullModal from "../../fullModal/fullModal.vue";
|
|
3
|
+
|
|
4
|
+
export default {
|
|
5
|
+
name: "responsibility",
|
|
6
|
+
props: {
|
|
7
|
+
value: {
|
|
8
|
+
type: String,
|
|
9
|
+
default: ''
|
|
10
|
+
},
|
|
11
|
+
widget: {
|
|
12
|
+
type: Object,
|
|
13
|
+
default: () => ({})
|
|
14
|
+
},
|
|
15
|
+
},
|
|
16
|
+
components: {FullModal},
|
|
17
|
+
data() {
|
|
18
|
+
return {
|
|
19
|
+
countDown: 0,
|
|
20
|
+
force: false,
|
|
21
|
+
clearTimeout: null,
|
|
22
|
+
dataModel: false,
|
|
23
|
+
isShow: false,
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
watch: {
|
|
27
|
+
value: {
|
|
28
|
+
handler(val) {
|
|
29
|
+
if (!val) return this.dataModel = false
|
|
30
|
+
this.dataModel = true
|
|
31
|
+
},
|
|
32
|
+
immediate: true
|
|
33
|
+
},
|
|
34
|
+
dataModel(val) {
|
|
35
|
+
this.$emit('input', val ? true : '')
|
|
36
|
+
this.$emit('change', val ? true: '')
|
|
37
|
+
},
|
|
38
|
+
},
|
|
39
|
+
methods: {
|
|
40
|
+
handleClick() {
|
|
41
|
+
if (this.widget.options.disabled) {
|
|
42
|
+
this.isShow = true
|
|
43
|
+
return
|
|
44
|
+
}
|
|
45
|
+
this.isShow = true
|
|
46
|
+
this.countDown = 0
|
|
47
|
+
clearInterval(this.clearTimeout)
|
|
48
|
+
if (this.widget.options.force) {
|
|
49
|
+
this.countDown = this.widget.options.countDown
|
|
50
|
+
this.clearTimeout = setInterval(() => {
|
|
51
|
+
if (this.countDown < 0) {
|
|
52
|
+
clearInterval(this.clearTimeout)
|
|
53
|
+
}
|
|
54
|
+
this.countDown -= 1
|
|
55
|
+
}, 1000)
|
|
56
|
+
}
|
|
57
|
+
},
|
|
58
|
+
confirm() {
|
|
59
|
+
if (this.countDown <= 0) {
|
|
60
|
+
this.dataModel = true
|
|
61
|
+
this.isShow = false
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
cancel() {
|
|
65
|
+
this.isShow = false
|
|
66
|
+
this.dataModel = false
|
|
67
|
+
clearInterval(this.clearTimeout)
|
|
68
|
+
},
|
|
69
|
+
handleCheck() {
|
|
70
|
+
const { disabled, force} = this.widget.options
|
|
71
|
+
if (disabled) return
|
|
72
|
+
if (force && !disabled) {
|
|
73
|
+
if (this.dataModel) return this.dataModel = false
|
|
74
|
+
return this.handleClick()
|
|
75
|
+
}
|
|
76
|
+
this.dataModel = !this.dataModel
|
|
77
|
+
},
|
|
78
|
+
change(e) {
|
|
79
|
+
console.log(e)
|
|
80
|
+
},
|
|
81
|
+
disabledScroll() {
|
|
82
|
+
return
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
</script>
|
|
87
|
+
|
|
88
|
+
<template>
|
|
89
|
+
<view>
|
|
90
|
+
<full-modal v-model="isShow">
|
|
91
|
+
<view style="height: 100%; background-color: #fff" @touchmove.stop.prevent="disabledScroll">
|
|
92
|
+
<scroll-view scroll-y="true" style="height: calc(100% - 100rpx); " >
|
|
93
|
+
<view style="padding: 20rpx 40rpx;">
|
|
94
|
+
<rich-text :nodes="widget.options.content" style="text-align: left"></rich-text>
|
|
95
|
+
</view>
|
|
96
|
+
<view v-if="!widget.options.disabled" style="display: flex; padding: 20rpx; margin-bottom: 20rpx; justify-content: center">
|
|
97
|
+
<button @click="confirm" type="primary" style="margin-right: 10px; border-radius: 10rpx; padding: 0 20px; height: 60rpx; line-height: 60rpx; font-size: 26rpx" :disabled="widget.options.force && countDown > 0">我同意 <text v-if="widget.options.force && countDown > 0">({{ countDown }}s)</text></button>
|
|
98
|
+
<button style="height: 60rpx; line-height: 60rpx; font-size: 26rpx; border-radius: 10rpx; color: #333" @click="cancel">不同意</button>
|
|
99
|
+
</view>
|
|
100
|
+
<view v-else style="display: flex; justify-content: center; align-items: center">
|
|
101
|
+
<button @click="isShow = false" type="primary" style="margin-bottom: 20px; border-radius: 10rpx; padding: 0 20px; height: 60rpx; line-height: 60rpx; font-size: 26rpx; " >关闭</button>
|
|
102
|
+
</view>
|
|
103
|
+
</scroll-view>
|
|
104
|
+
</view>
|
|
105
|
+
</full-modal>
|
|
106
|
+
<view class="responsibility_check" >
|
|
107
|
+
<view @click.stop="handleCheck">
|
|
108
|
+
<label>
|
|
109
|
+
<checkbox :disabled="widget.options.disabled" :readonly="widget.options.disabled" v-if="!isShow" :checked="dataModel" color="#007AFF" style="transform: scale(0.8,0.8);"/>
|
|
110
|
+
</label>
|
|
111
|
+
</view>
|
|
112
|
+
<view class="option-font-size" @click.stop="handleClick">{{ widget.options.title }}</view>
|
|
113
|
+
|
|
114
|
+
</view>
|
|
115
|
+
</view>
|
|
116
|
+
|
|
117
|
+
</template>
|
|
118
|
+
|
|
119
|
+
<style lang="less">
|
|
120
|
+
.responsibility_check {
|
|
121
|
+
display: flex;
|
|
122
|
+
align-items: center;
|
|
123
|
+
/deep/ .uni-checkbox-input {
|
|
124
|
+
width: 18px;
|
|
125
|
+
height: 18px;
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
128
|
</style>
|
|
@@ -181,8 +181,19 @@
|
|
|
181
181
|
@confirm="changeTime"
|
|
182
182
|
@cancel="cancel"
|
|
183
183
|
/> -->
|
|
184
|
-
|
|
185
|
-
|
|
184
|
+
<view class="evan-form-item-container__main--body" v-if="zjfmFormDesign && zbrqList && widget.model == 'zbrq'">
|
|
185
|
+
<view class="option-font-size" @click="zbrqshow = !widget.options.disabled">
|
|
186
|
+
{{ dataModel | filterDataModel(widget) }}
|
|
187
|
+
</view>
|
|
188
|
+
<u-calendar v-model="zbrqshow" :date="zbrqList.minTime" :mode="'date'" @change="changeZBRQDate" :min-date="zbrqList.minTime" :max-date="zbrqList.maxTime" class="zbrq-calendar"></u-calendar>
|
|
189
|
+
</view>
|
|
190
|
+
<view class="evan-form-item-container__main--body" v-else-if="zjfmFormDesign && thrqList && widget.model == 'thrq'">
|
|
191
|
+
<view class="option-font-size" @click="thrqshow = !widget.options.disabled">
|
|
192
|
+
{{ dataModel | filterDataModel(widget) }}
|
|
193
|
+
</view>
|
|
194
|
+
<u-calendar v-model="thrqshow" :date="thrqList.minTime" :mode="'date'" @change="changeTHRQDate" :min-date="thrqList.minTime" :max-date="thrqList.maxTime" class="zbrq-calendar" :defaultDate="'2024-08-02'"></u-calendar>
|
|
195
|
+
</view>
|
|
196
|
+
<view class="evan-form-item-container__main--body" v-else>
|
|
186
197
|
<uni-datetime-picker ref="datetime_picker" @change="dateChange" :hide-second="!widget.options.format.includes(':ss')" @click.native="isClickByUser = true" :type="widget.options.type"
|
|
187
198
|
:format="formatTime()" :clearIcon="!widget.options.disabled && widget.options.clearable"
|
|
188
199
|
v-model="dataModel" @maskClick="maskClick" :border="false" :disabled="widget.options.disabled">
|
|
@@ -716,7 +727,27 @@ export default {
|
|
|
716
727
|
applyId: {
|
|
717
728
|
type: String,
|
|
718
729
|
default: ""
|
|
719
|
-
}
|
|
730
|
+
},
|
|
731
|
+
zbrqList: {
|
|
732
|
+
type: Object,
|
|
733
|
+
default() {
|
|
734
|
+
return null
|
|
735
|
+
}
|
|
736
|
+
},
|
|
737
|
+
thrqList: {
|
|
738
|
+
type: Object,
|
|
739
|
+
default() {
|
|
740
|
+
return null
|
|
741
|
+
}
|
|
742
|
+
},
|
|
743
|
+
zjfmFormDesign: {
|
|
744
|
+
type: Boolean,
|
|
745
|
+
default: false
|
|
746
|
+
},
|
|
747
|
+
thrqDataModalShow: {
|
|
748
|
+
type: String,
|
|
749
|
+
default: ''
|
|
750
|
+
},
|
|
720
751
|
},
|
|
721
752
|
filters: {
|
|
722
753
|
filterDataModel(dataModel, widget) {
|
|
@@ -754,7 +785,7 @@ export default {
|
|
|
754
785
|
formShowError: {
|
|
755
786
|
form: 'formShowError',
|
|
756
787
|
default: true
|
|
757
|
-
}
|
|
788
|
+
},
|
|
758
789
|
},
|
|
759
790
|
data() {
|
|
760
791
|
return {
|
|
@@ -777,7 +808,9 @@ export default {
|
|
|
777
808
|
checkboxAndRadioOptions: [],
|
|
778
809
|
selectedData: [],
|
|
779
810
|
locationInfo: {},
|
|
780
|
-
correctObj: undefined
|
|
811
|
+
correctObj: undefined,
|
|
812
|
+
zbrqshow: false,
|
|
813
|
+
thrqshow: false,
|
|
781
814
|
}
|
|
782
815
|
},
|
|
783
816
|
mounted() {
|
|
@@ -845,6 +878,9 @@ export default {
|
|
|
845
878
|
handleClear() {
|
|
846
879
|
this.dataModel = []
|
|
847
880
|
this.dataModelShow = ''
|
|
881
|
+
if(this.zjfmFormDesign && this.widget.model == 'thr') {
|
|
882
|
+
this.models.thxq = ''
|
|
883
|
+
}
|
|
848
884
|
if (this.widget.type === 'select') {
|
|
849
885
|
this.clearAllLinkageSelect(this.widget.options?.linkage)
|
|
850
886
|
}
|
|
@@ -964,6 +1000,55 @@ export default {
|
|
|
964
1000
|
}
|
|
965
1001
|
return flag
|
|
966
1002
|
},
|
|
1003
|
+
// 工贸定制化时间切换
|
|
1004
|
+
changeZBRQDate(val,e) {
|
|
1005
|
+
this.models.zbxq = ''
|
|
1006
|
+
this.models.thrq = ''
|
|
1007
|
+
this.models.thr = ''
|
|
1008
|
+
this.$emit('changedate', 'thrqDataModalShow')
|
|
1009
|
+
this.models.thxq = ''
|
|
1010
|
+
let chooseVal = moment(val.year + '-' + val.month + '-' + val.day).format('YYYY-MM-DD')
|
|
1011
|
+
let minTime = this.zbrqList.minTime
|
|
1012
|
+
let maxTime = this.zbrqList.maxTime
|
|
1013
|
+
if(new Date(chooseVal).getTime() >= new Date(minTime).getTime() && new Date(chooseVal).getTime() <= new Date(maxTime).getTime()) {
|
|
1014
|
+
console.log('成功');
|
|
1015
|
+
} else {
|
|
1016
|
+
chooseVal = ''
|
|
1017
|
+
}
|
|
1018
|
+
if (this.tableKey) {
|
|
1019
|
+
this.models[this.tableKey][this.tableIndex][this.widget.model] = chooseVal;
|
|
1020
|
+
} else {
|
|
1021
|
+
this.dataModel = chooseVal;
|
|
1022
|
+
}
|
|
1023
|
+
if(chooseVal) this.$emit('changedate', 'thrq', chooseVal)
|
|
1024
|
+
let rule = this.rules[this.widget.model]
|
|
1025
|
+
if (rule.length > 0) {
|
|
1026
|
+
this.validateInit()
|
|
1027
|
+
}
|
|
1028
|
+
},
|
|
1029
|
+
changeTHRQDate(val,e) {
|
|
1030
|
+
this.models.thr = ''
|
|
1031
|
+
this.$emit('changedate', 'thrqDataModalShow')
|
|
1032
|
+
this.models.thxq = ''
|
|
1033
|
+
let chooseVal = moment(val.year + '-' + val.month + '-' + val.day).format('YYYY-MM-DD')
|
|
1034
|
+
let minTime = this.thrqList.minTime
|
|
1035
|
+
let maxTime = this.thrqList.maxTime
|
|
1036
|
+
if(new Date(chooseVal).getTime() >= new Date(minTime).getTime() && new Date(chooseVal).getTime() <= new Date(maxTime).getTime()) {
|
|
1037
|
+
console.log('成功');
|
|
1038
|
+
} else {
|
|
1039
|
+
chooseVal = ''
|
|
1040
|
+
}
|
|
1041
|
+
if (this.tableKey) {
|
|
1042
|
+
this.models[this.tableKey][this.tableIndex][this.widget.model] = chooseVal;
|
|
1043
|
+
} else {
|
|
1044
|
+
this.dataModel = chooseVal;
|
|
1045
|
+
}
|
|
1046
|
+
// if(chooseVal) this.$emit('changedate', 'thr', chooseVal)
|
|
1047
|
+
let rule = this.rules[this.widget.model]
|
|
1048
|
+
if (rule.length > 0) {
|
|
1049
|
+
this.validateInit()
|
|
1050
|
+
}
|
|
1051
|
+
},
|
|
967
1052
|
//切换时间
|
|
968
1053
|
dateChange(val) {
|
|
969
1054
|
if (this.tableKey) {
|
|
@@ -1680,6 +1765,10 @@ export default {
|
|
|
1680
1765
|
this.dataModel = value
|
|
1681
1766
|
} else {
|
|
1682
1767
|
value.length > 0 ? this.dataModel = value[0] : null
|
|
1768
|
+
if(this.zjfmFormDesign && value.length > 0) {
|
|
1769
|
+
this.models.thxq = data[0].xq
|
|
1770
|
+
this.dataModelShow = data[0].label
|
|
1771
|
+
}
|
|
1683
1772
|
}
|
|
1684
1773
|
|
|
1685
1774
|
if (!data || !Array.isArray(data) || data.length == 0) {
|
|
@@ -1705,10 +1794,19 @@ export default {
|
|
|
1705
1794
|
if (arr.length > 0 && this.linkage.hasOwnProperty(model)) {
|
|
1706
1795
|
id = this.linkage[model]
|
|
1707
1796
|
}
|
|
1708
|
-
|
|
1797
|
+
console.log(this.models);
|
|
1798
|
+
if(this.zjfmFormDesign) {
|
|
1799
|
+
uni.setStorageSync('zjfmFormDesignModels', this.models)
|
|
1800
|
+
uni.navigateTo({
|
|
1801
|
+
url: '/pages/picker/service?sign=' + PubsubSign + '&zjfmFormDesign=true'
|
|
1802
|
+
});
|
|
1803
|
+
} else {
|
|
1804
|
+
uni.navigateTo({
|
|
1709
1805
|
url: '/pages/picker/service?sign=' + PubsubSign + '&multiple=' + flag + '&optionsData=' +
|
|
1710
1806
|
encodeURIComponent(optionsData) + '&dataModel=' + JSON.stringify(this.dataModel) + '&id=' + id + '&applyId=' + this.applyId
|
|
1711
1807
|
});
|
|
1808
|
+
}
|
|
1809
|
+
|
|
1712
1810
|
}
|
|
1713
1811
|
},
|
|
1714
1812
|
/****选择部门****/
|
|
@@ -1911,9 +2009,10 @@ export default {
|
|
|
1911
2009
|
handler(v) {
|
|
1912
2010
|
// this.updateDataModel(); // 当脚本文件里面 改动 models值后 需要更新 对应的
|
|
1913
2011
|
// this.showFormData();
|
|
1914
|
-
|
|
2012
|
+
console.log(this.widget.model);
|
|
2013
|
+
if (this.tableKey || (['zbrq', 'zbxq', 'thxq', 'thr', 'thxq'].includes(this.widget.model) && this.zjfmFormDesign)) { //处理子表单删除行的时候 值未更新
|
|
1915
2014
|
this.updateDataModel();
|
|
1916
|
-
this.showFormData();
|
|
2015
|
+
if(!(this.widget.model == 'thr' && this.zjfmFormDesign)) this.showFormData();
|
|
1917
2016
|
}
|
|
1918
2017
|
}
|
|
1919
2018
|
},
|
|
@@ -1932,8 +2031,8 @@ export default {
|
|
|
1932
2031
|
}
|
|
1933
2032
|
if (this.widget.type === 'deptSelector') {
|
|
1934
2033
|
this.updatedeptSelectorModal()
|
|
1935
|
-
}
|
|
1936
|
-
if (['select', 'radio', 'checkbox'].includes(this.widget.type)) {
|
|
2034
|
+
}7
|
|
2035
|
+
if (['select', 'radio', 'checkbox'].includes(this.widget.type) && !this.zjfmFormDesign) {
|
|
1937
2036
|
this.updatedSelectModal()
|
|
1938
2037
|
}
|
|
1939
2038
|
if (this.widget.type === 'userSelectorByRole' && v && v.length > 0) {
|
|
@@ -2015,6 +2114,11 @@ export default {
|
|
|
2015
2114
|
// this.validateInit()
|
|
2016
2115
|
// }
|
|
2017
2116
|
}
|
|
2117
|
+
},
|
|
2118
|
+
thrqDataModalShow(val) {
|
|
2119
|
+
if (this.zjfmFormDesign && this.widget.model === 'thr') {
|
|
2120
|
+
this.dataModelShow = this.thrqDataModalShow
|
|
2121
|
+
}
|
|
2018
2122
|
}
|
|
2019
2123
|
}
|
|
2020
2124
|
}
|
|
@@ -2340,6 +2444,20 @@ checkbox-group label {
|
|
|
2340
2444
|
::v-deep .uni-slider-thumb {
|
|
2341
2445
|
z-index: 1;
|
|
2342
2446
|
}
|
|
2447
|
+
.zbrq-calendar {
|
|
2448
|
+
::v-deep .u-hover-class {
|
|
2449
|
+
background-color: #f0f0f0 !important;
|
|
2450
|
+
opacity: .3;
|
|
2451
|
+
}
|
|
2452
|
+
::v-deep .u-calendar__action {
|
|
2453
|
+
display: flex;
|
|
2454
|
+
align-items: center;
|
|
2455
|
+
justify-content: center;
|
|
2456
|
+
}
|
|
2457
|
+
::v-deep .u-calendar__bottom__choose {
|
|
2458
|
+
opacity: 0;
|
|
2459
|
+
}
|
|
2460
|
+
}
|
|
2343
2461
|
</style>
|
|
2344
2462
|
<style>
|
|
2345
2463
|
|
|
@@ -114,7 +114,9 @@
|
|
|
114
114
|
<view v-for="(col, itemIndex) in colItem.list" :key="itemIndex" v-show="col.options.canView">
|
|
115
115
|
<evan-form-item :isCorrect="isCorrect" :labelPosition="labelPosition" :prop="col.model"
|
|
116
116
|
:ref="String(Math.random()).split('.')[1]" :models.sync="models" :rules="rules"
|
|
117
|
-
:widget.sync="col" :isDraft="isDraft" :formId="formId" :linkage="linkage" :isApply="isApply" :applyId="applyId"
|
|
117
|
+
:widget.sync="col" :isDraft="isDraft" :formId="formId" :linkage="linkage" :isApply="isApply" :applyId="applyId"
|
|
118
|
+
@changedate="changedate" :zbrqList="zbrqList" :thrqList="thrqList" :zjfmFormDesign="zjfmFormDesign" :thrqDataModalShow="thrqDataModalShow"
|
|
119
|
+
>
|
|
118
120
|
</evan-form-item>
|
|
119
121
|
</view>
|
|
120
122
|
</view>
|
|
@@ -307,7 +309,12 @@ export default {
|
|
|
307
309
|
phone: '15232656598',
|
|
308
310
|
sub: '',
|
|
309
311
|
},
|
|
310
|
-
pickerIndex: 0
|
|
312
|
+
pickerIndex: 0,
|
|
313
|
+
zbrqList: null,
|
|
314
|
+
thrqList: null,
|
|
315
|
+
zjfmFormDesign: false,
|
|
316
|
+
thrqDataModalShow: '',
|
|
317
|
+
formDesignFlag: false
|
|
311
318
|
}
|
|
312
319
|
},
|
|
313
320
|
watch: {
|
|
@@ -335,6 +342,61 @@ export default {
|
|
|
335
342
|
deep: true,
|
|
336
343
|
handler(v) {
|
|
337
344
|
this.isScroll = true;
|
|
345
|
+
if(v && !this.formDesignFlag) {
|
|
346
|
+
this.formDesignFlag = true
|
|
347
|
+
this.$u.get('sys/dict/getDictItems/zbb_th_app_id').then((res) => {
|
|
348
|
+
if (res.success) {
|
|
349
|
+
if(res.result && res.result.length > 0 && res.result[0].value == this.$Route.query.id) {
|
|
350
|
+
if(this.$Route.query.type && this.$Route.query.type === 'detail') {
|
|
351
|
+
|
|
352
|
+
} else {
|
|
353
|
+
this.$u.get('zhxyZbb/canOpenZbbThsq', {appId: this.$Route.query.id}).then((res) => {
|
|
354
|
+
if(!res.result) {
|
|
355
|
+
uni.showToast({
|
|
356
|
+
title: "当前无值班信息!",
|
|
357
|
+
duration: 2000,
|
|
358
|
+
icon: "none",
|
|
359
|
+
});
|
|
360
|
+
setTimeout(() => {
|
|
361
|
+
uni.navigateBack({
|
|
362
|
+
//uni.navigateTo跳转的返回,默认1为返回上一级
|
|
363
|
+
delta: 1,
|
|
364
|
+
});
|
|
365
|
+
}, 2000)
|
|
366
|
+
return
|
|
367
|
+
}
|
|
368
|
+
})
|
|
369
|
+
}
|
|
370
|
+
|
|
371
|
+
this.zjfmFormDesign = true
|
|
372
|
+
this.$u.post("zhxyZbb/zhxyZbbZbth", this.models).then((res) => {
|
|
373
|
+
if (res.success) {
|
|
374
|
+
this.zbrqList = res.result;
|
|
375
|
+
} else {
|
|
376
|
+
this.zbrqList = null
|
|
377
|
+
}
|
|
378
|
+
});
|
|
379
|
+
if(this.models.zbrq) {
|
|
380
|
+
this.getThrqList(this.models.zbrq)
|
|
381
|
+
}
|
|
382
|
+
if(this.models.thr) {
|
|
383
|
+
this.$u.post("zhxyZbb/zhxyZbbZbth", {value:this.models, model: 'thrq', applyId: this.$Route.query.applyId }).then((res) => {
|
|
384
|
+
if (res.success) {
|
|
385
|
+
// this.zbrqList = res.result
|
|
386
|
+
this.thrqDataModalShow = res.result.filter(item => item.gh == this.models.thr)[0].xm
|
|
387
|
+
} else {
|
|
388
|
+
this.thrqDataModalShow = ''
|
|
389
|
+
}
|
|
390
|
+
});
|
|
391
|
+
}
|
|
392
|
+
} else {
|
|
393
|
+
this.zjfmFormDesign = false
|
|
394
|
+
}
|
|
395
|
+
} else {
|
|
396
|
+
this.zjfmFormDesign = false
|
|
397
|
+
}
|
|
398
|
+
})
|
|
399
|
+
}
|
|
338
400
|
}
|
|
339
401
|
},
|
|
340
402
|
dataObj: {
|
|
@@ -416,6 +478,35 @@ export default {
|
|
|
416
478
|
// this.initPo();
|
|
417
479
|
},
|
|
418
480
|
methods: {
|
|
481
|
+
changedate(key,value) {
|
|
482
|
+
if(key == 'thrq') {
|
|
483
|
+
this.getThrqList(value)
|
|
484
|
+
} else {
|
|
485
|
+
this.thrqDataModalShow = ''
|
|
486
|
+
}
|
|
487
|
+
},
|
|
488
|
+
getThrqList(value) {
|
|
489
|
+
this.models.zbrq = value
|
|
490
|
+
this.$u.post("zhxyZbb/zhxyZbbZbth", {value:this.models, model: 'zbrq' }).then((res) => {
|
|
491
|
+
if (res.success) {
|
|
492
|
+
this.thrqList = res.result;
|
|
493
|
+
this.models.zbxq = this.thrqList.zbxq
|
|
494
|
+
} else {
|
|
495
|
+
this.thrqList = null
|
|
496
|
+
this.models.zbrq = ''
|
|
497
|
+
if(this.$Route.query.type && this.$Route.query.type === 'detail') {
|
|
498
|
+
|
|
499
|
+
} else {
|
|
500
|
+
uni.showToast({
|
|
501
|
+
title: res.message,
|
|
502
|
+
duration: 2000,
|
|
503
|
+
icon: "none",
|
|
504
|
+
});
|
|
505
|
+
}
|
|
506
|
+
|
|
507
|
+
}
|
|
508
|
+
});
|
|
509
|
+
},
|
|
419
510
|
warpVerifyDisable(widget) {
|
|
420
511
|
if (widget.options.isConfirmComponent) return widget.options.disabled
|
|
421
512
|
return widget.model !== this.verifyNode
|
package/package.json
CHANGED