safecheck-client 3.0.30-50 → 3.0.30-52

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,213 +1,213 @@
1
- <template>
2
- <div class="auto select-overspread">
3
- <validator name='v'>
4
- <form class="form-horizontal" novalidate>
5
- <ul class="nav nav-tabs" style="margin-bottom: 10px">
6
- <li class="active"><a href="#">安检册信息</a></li>
7
- </ul>
8
- <div class="row" style="margin-top: 10px">
9
- <div class="col-sm-12 form-group" style="margin: 0">
10
- <role-selector-safe
11
- @alluser="getUsers"
12
- @re-res="getRes"
13
- role-name="安检员"
14
- role-lable="安&nbsp;检&nbsp;员&nbsp;"
15
- :value.sync="checkBook.f_checker_name"
16
- v-model="checkBook.f_checker_name">
17
- </role-selector-safe>
18
- </div>
19
- <!-- <div class="form-group col-sm-6" style="margin-top: 20px" :class="[$v.f_check_book_type.required ? 'has-error' : '']">-->
20
- <!-- <label class="font_normal_body">表册类型</label>-->
21
- <!-- <input type="text" v-show="false" v-model="checkBook.f_check_book_type"-->
22
- <!-- :value.sync="checkBook.f_check_book_type"-->
23
- <!-- v-validate:f_check_book_type='{required: true }'>-->
24
- <!-- <v-select :value.sync="checkBook.f_check_book_type" v-model='checkBook.f_check_book_type'-->
25
- <!-- :value-single="true" style="width: 60%"-->
26
- <!-- class="select_list select"-->
27
- <!-- :options='bookTypes' placeholder=''-->
28
- <!-- close-on-select></v-select>-->
29
- <!-- </div>-->
30
- <div class="form-group col-sm-6" style="margin-top: 20px" :class="[$v.f_user_type.required ? 'has-error' : '']">
31
- <label class="font_normal_body">用户类型</label>
32
- <input type="text" v-show="false" v-model="checkBook.f_user_type"
33
- v-validate:f_user_type='{required: true }'>
34
- <v-select :value.sync="checkBook.f_user_type" v-model='checkBook.f_user_type'
35
- :value-single="true" style="width: 60%"
36
- class="select_list select"
37
- :options='userTypes' placeholder=''
38
- close-on-select></v-select>
39
- </div>
40
- <div class="form-group col-sm-6" style="margin-top: 20px" :class="[$v.f_check_book_name.required ? 'has-error' : '']">
41
- <label class="font_normal_body">安检册名称</label>
42
- <input type="text" class="input_search" v-model="checkBook.f_check_book_name"
43
- style="width: 60%" v-validate:f_check_book_name='{ required: true }'>
44
- </div>
45
- <div class="form-group col-sm-6" style="margin-top: 20px">
46
- <label class="font_normal_body">上次执行日期</label>
47
- <datepicker
48
- :value.sync="checkBook.f_last_run_date"
49
- style="width: 60%"
50
- :format="'yyyy-MM-dd'"
51
- v-model="checkBook.f_last_run_date"
52
- >
53
- </datepicker>
54
- </div>
55
- <div class="form-group col-sm-6" style="margin-top: 20px">
56
- <label class="font_normal_body">执行日期</label>
57
- <datepicker
58
- :value.sync="checkBook.f_run_date"
59
- style="width: 60%"
60
- :format="'yyyy-MM-dd'"
61
- v-model="checkBook.f_run_date"
62
- >
63
- </datepicker>
64
- </div>
65
- <div class="form-group col-sm-6" style="margin-top: 20px">
66
- <label class="font_normal_body">执行周期</label>
67
- <input type="number" class="input_search" v-model="checkBook.f_around_time"
68
- style="width: 60%" >
69
- </div>
70
- <div class="form-group col-sm-6" style="margin-top: 20px">
71
- <label class="font_normal_body">周期单位</label>
72
- <v-select :value.sync="checkBook.f_around_unit" v-model='checkBook.f_around_unit'
73
- :value-single="true" style="width: 60%"
74
- class="select_list select"
75
- :options='aroundUnit' placeholder=''
76
- close-on-select></v-select>
77
- </div>
78
-
79
-
80
- <!-- <div class="form-group col-sm-6" style="margin-top: 20px">-->
81
- <!-- <label class="font_normal_body">自动下发</label>-->
82
- <!-- <v-select :value.sync="checkBook.f_is_auto" v-model='checkBook.f_is_auto'-->
83
- <!-- :value-single="true" style="width: 60%"-->
84
- <!-- class="select_list select"-->
85
- <!-- :options='autos' placeholder=''-->
86
- <!-- close-on-select></v-select>-->
87
- <!-- </div>-->
88
- </div>
89
- </form>
90
- <div style="text-align:right;height:auto;margin-top:6px;margin-right: 10%">
91
- <button @click="confirm()" class="button_search">确认</button>
92
- <!-- <button @click="deleteBook()" class="button_delete">删除</button>-->
93
- <button @click="close()" class="button_clear">取消</button>
94
- </div>
95
- </validator>
96
- </div>
97
- </template>
98
- <script>
99
- import * as Util from "../../../components/Util";
100
- import bus from "../../../bus";
101
- import {HttpResetClass} from 'vue-client'
102
-
103
- export default {
104
- data () {
105
- return {
106
- aroundUnit: [{label: '年', value: '年'}, {label: '月', value: '月'}, {label: '日', value: '日'}],
107
- bookTypes:[{label: '用户', value: '用户'}, {label: '小区', value: '小区'}],
108
- userTypes:[{label: '民用', value: '民用'}, {label: '非民用', value: '非民用'}],
109
- autos:[{label: '是', value: '是'}, {label: '否', value: '否'}],
110
- allUsers:[],
111
- checkBook: {
112
- f_check_book_name: '',
113
- f_run_date: '',
114
- f_around_time: '',
115
- f_around_unit: '',
116
- f_create_date: '',
117
- f_create_person: '',
118
- f_user_type:'',
119
- f_orgid: '',
120
- f_is_auto:'否',
121
- f_check_book_type:"用户",
122
- f_checker_name: '',
123
- f_checker_id:'',
124
- }
125
- }
126
- },
127
- props: ['row','showtype'],
128
- watch: {
129
- 'checkBook.f_checker_name' (val) {
130
- const user = this.allUsers.filter(item=>item.name==val);
131
- if(user.length>0){
132
- this.checkBook.f_checker_id = user[0]["id"]
133
- }
134
- console.log("777",this.checkBook)
135
- },
136
- row (row) {
137
- this.changeCheckBook(row)
138
- }
139
- },
140
- ready () {
141
- // console.log(this.$login.f.orgid)
142
- this.changeCheckBook(this.row)
143
- this.checkBook.f_user_type = this.showtype
144
- console.log('row', JSON.stringify(this.row))
145
- },
146
- methods: {
147
- changeCheckBook (row) {
148
- console.log('row改变了', row)
149
- if (row && row.id) {
150
- console.log('进入修改赋值')
151
- this.checkBook = row
152
- }
153
- },
154
- deleteBook () {
155
- console.log('delete', this.row)
156
- },
157
- close () {
158
- console.log('关闭')
159
- this.$parent.showItem = false
160
- },
161
- confirm () {
162
- if(!this.checkBook.f_check_book_name){
163
- this.$showMessage('请填写片区名称')
164
- return
165
- }
166
- // if(!this.checkBook.f_check_book_type){
167
- // this.$showMessage('请选择表册类型')
168
- // return
169
- // }
170
- if(!this.checkBook.f_user_type){
171
- this.$showMessage('请选择用户类型')
172
- return
173
-
174
- }
175
- this.checkBook.f_orgid = this.$login.f.orgid
176
- this.checkBook.f_create_person = this.$login.f.name
177
- this.checkBook.f_create_date = Util.toStandardDateString()
178
- console.log('checkbook', this.checkBook)
179
- let http = new HttpResetClass()
180
- http.load('POST', 'rs/logic/safeEntity', {data: {tableName: 't_check_book', entityData: this.checkBook}},
181
- {resolveMsg: '保存片区信息成功', rejectMsg: '保存片区信息失败'}).then(res => {
182
- if (res.data.code === 200) {
183
- let dataplan ={
184
- id:res.data.id,
185
- f_check_book_name: this.checkBook.f_check_book_name,
186
- f_checker_name:this.checkBook.f_checker_name,
187
- f_checker_id:this.checkBook.f_checker_id,
188
- f_create_person: this.$login.f.name,
189
- f_orgid: this.$login.f.orgid
190
- }
191
- http.load('POST', 'rs/logic/CreatorBookplan', {data:dataplan},{resolveMsg: null, rejectMsg: null})
192
- this.$showMessage('保存片区信息成功',['confirm']).then(res=>{
193
- if (res==='confirm'){
194
- bus.$emit('fresh-main')
195
- }
196
- })
197
- }else{
198
- this.$showMessage('保存片区信息失败')
199
- }
200
- })
201
- },
202
- getRes (obj) {
203
- if (obj.resids) {
204
- this.checkBook.f_orgid = obj.resids[0]
205
- console.log('id', this.checkBook.f_orgid)
206
- }
207
- },
208
- getUsers(obj){
209
- this.allUsers = obj
210
- }
211
- }
212
- }
213
- </script>
1
+ <template>
2
+ <div class="auto select-overspread">
3
+ <validator name='v'>
4
+ <form class="form-horizontal" novalidate>
5
+ <ul class="nav nav-tabs" style="margin-bottom: 10px">
6
+ <li class="active"><a href="#">安检册信息</a></li>
7
+ </ul>
8
+ <div class="row" style="margin-top: 10px">
9
+ <div class="col-sm-12 form-group" style="margin: 0">
10
+ <role-selector-safe
11
+ @alluser="getUsers"
12
+ @re-res="getRes"
13
+ role-name="安检员"
14
+ role-lable="安&nbsp;检&nbsp;员&nbsp;"
15
+ :value.sync="checkBook.f_checker_name"
16
+ v-model="checkBook.f_checker_name">
17
+ </role-selector-safe>
18
+ </div>
19
+ <!-- <div class="form-group col-sm-6" style="margin-top: 20px" :class="[$v.f_check_book_type.required ? 'has-error' : '']">-->
20
+ <!-- <label class="font_normal_body">表册类型</label>-->
21
+ <!-- <input type="text" v-show="false" v-model="checkBook.f_check_book_type"-->
22
+ <!-- :value.sync="checkBook.f_check_book_type"-->
23
+ <!-- v-validate:f_check_book_type='{required: true }'>-->
24
+ <!-- <v-select :value.sync="checkBook.f_check_book_type" v-model='checkBook.f_check_book_type'-->
25
+ <!-- :value-single="true" style="width: 60%"-->
26
+ <!-- class="select_list select"-->
27
+ <!-- :options='bookTypes' placeholder=''-->
28
+ <!-- close-on-select></v-select>-->
29
+ <!-- </div>-->
30
+ <div class="form-group col-sm-6" style="margin-top: 20px" :class="[$v.f_user_type.required ? 'has-error' : '']">
31
+ <label class="font_normal_body">用户类型</label>
32
+ <input type="text" v-show="false" v-model="checkBook.f_user_type"
33
+ v-validate:f_user_type='{required: true }'>
34
+ <v-select :value.sync="checkBook.f_user_type" v-model='checkBook.f_user_type'
35
+ :value-single="true" style="width: 60%"
36
+ class="select_list select"
37
+ :options='userTypes' placeholder=''
38
+ close-on-select></v-select>
39
+ </div>
40
+ <div class="form-group col-sm-6" style="margin-top: 20px" :class="[$v.f_check_book_name.required ? 'has-error' : '']">
41
+ <label class="font_normal_body">安检册名称</label>
42
+ <input type="text" class="input_search" v-model="checkBook.f_check_book_name"
43
+ style="width: 60%" v-validate:f_check_book_name='{ required: true }'>
44
+ </div>
45
+ <div class="form-group col-sm-6" style="margin-top: 20px">
46
+ <label class="font_normal_body">上次执行日期</label>
47
+ <datepicker
48
+ :value.sync="checkBook.f_last_run_date"
49
+ style="width: 60%"
50
+ :format="'yyyy-MM-dd'"
51
+ v-model="checkBook.f_last_run_date"
52
+ >
53
+ </datepicker>
54
+ </div>
55
+ <div class="form-group col-sm-6" style="margin-top: 20px">
56
+ <label class="font_normal_body">执行日期</label>
57
+ <datepicker
58
+ :value.sync="checkBook.f_run_date"
59
+ style="width: 60%"
60
+ :format="'yyyy-MM-dd'"
61
+ v-model="checkBook.f_run_date"
62
+ >
63
+ </datepicker>
64
+ </div>
65
+ <div class="form-group col-sm-6" style="margin-top: 20px">
66
+ <label class="font_normal_body">执行周期</label>
67
+ <input type="number" class="input_search" v-model="checkBook.f_around_time"
68
+ style="width: 60%" >
69
+ </div>
70
+ <div class="form-group col-sm-6" style="margin-top: 20px">
71
+ <label class="font_normal_body">周期单位</label>
72
+ <v-select :value.sync="checkBook.f_around_unit" v-model='checkBook.f_around_unit'
73
+ :value-single="true" style="width: 60%"
74
+ class="select_list select"
75
+ :options='aroundUnit' placeholder=''
76
+ close-on-select></v-select>
77
+ </div>
78
+
79
+
80
+ <!-- <div class="form-group col-sm-6" style="margin-top: 20px">-->
81
+ <!-- <label class="font_normal_body">自动下发</label>-->
82
+ <!-- <v-select :value.sync="checkBook.f_is_auto" v-model='checkBook.f_is_auto'-->
83
+ <!-- :value-single="true" style="width: 60%"-->
84
+ <!-- class="select_list select"-->
85
+ <!-- :options='autos' placeholder=''-->
86
+ <!-- close-on-select></v-select>-->
87
+ <!-- </div>-->
88
+ </div>
89
+ </form>
90
+ <div style="text-align:right;height:auto;margin-top:6px;margin-right: 10%">
91
+ <button @click="confirm()" class="button_search">确认</button>
92
+ <!-- <button @click="deleteBook()" class="button_delete">删除</button>-->
93
+ <button @click="close()" class="button_clear">取消</button>
94
+ </div>
95
+ </validator>
96
+ </div>
97
+ </template>
98
+ <script>
99
+ import * as Util from "../../../components/Util";
100
+ import bus from "../../../bus";
101
+ import {HttpResetClass} from 'vue-client'
102
+
103
+ export default {
104
+ data () {
105
+ return {
106
+ aroundUnit: [{label: '年', value: '年'}, {label: '月', value: '月'}, {label: '日', value: '日'}],
107
+ bookTypes:[{label: '用户', value: '用户'}, {label: '小区', value: '小区'}],
108
+ userTypes:[{label: '民用', value: '民用'}, {label: '非民用', value: '非民用'}],
109
+ autos:[{label: '是', value: '是'}, {label: '否', value: '否'}],
110
+ allUsers:[],
111
+ checkBook: {
112
+ f_check_book_name: '',
113
+ f_run_date: '',
114
+ f_around_time: '',
115
+ f_around_unit: '',
116
+ f_create_date: '',
117
+ f_create_person: '',
118
+ f_user_type:'',
119
+ f_orgid: '',
120
+ f_is_auto:'否',
121
+ f_check_book_type:"用户",
122
+ f_checker_name: '',
123
+ f_checker_id:'',
124
+ }
125
+ }
126
+ },
127
+ props: ['row','showtype'],
128
+ watch: {
129
+ 'checkBook.f_checker_name' (val) {
130
+ const user = this.allUsers.filter(item=>item.name==val);
131
+ if(user.length>0){
132
+ this.checkBook.f_checker_id = user[0]["id"]
133
+ }
134
+ console.log("777",this.checkBook)
135
+ },
136
+ row (row) {
137
+ this.changeCheckBook(row)
138
+ }
139
+ },
140
+ ready () {
141
+ // console.log(this.$login.f.orgid)
142
+ this.changeCheckBook(this.row)
143
+ this.checkBook.f_user_type = this.showtype
144
+ console.log('row', JSON.stringify(this.row))
145
+ },
146
+ methods: {
147
+ changeCheckBook (row) {
148
+ console.log('row改变了', row)
149
+ if (row && row.id) {
150
+ console.log('进入修改赋值')
151
+ this.checkBook = row
152
+ }
153
+ },
154
+ deleteBook () {
155
+ console.log('delete', this.row)
156
+ },
157
+ close () {
158
+ console.log('关闭')
159
+ this.$parent.showItem = false
160
+ },
161
+ confirm () {
162
+ if(!this.checkBook.f_check_book_name){
163
+ this.$showMessage('请填写片区名称')
164
+ return
165
+ }
166
+ // if(!this.checkBook.f_check_book_type){
167
+ // this.$showMessage('请选择表册类型')
168
+ // return
169
+ // }
170
+ if(!this.checkBook.f_user_type){
171
+ this.$showMessage('请选择用户类型')
172
+ return
173
+
174
+ }
175
+ this.checkBook.f_orgid = this.$login.f.orgid
176
+ this.checkBook.f_create_person = this.$login.f.name
177
+ this.checkBook.f_create_date = Util.toStandardDateString()
178
+ console.log('checkbook', this.checkBook)
179
+ let http = new HttpResetClass()
180
+ http.load('POST', 'rs/logic/safeEntity', {data: {tableName: 't_check_book', entityData: this.checkBook}},
181
+ {resolveMsg: '保存片区信息成功', rejectMsg: '保存片区信息失败'}).then(res => {
182
+ if (res.data.code === 200) {
183
+ let dataplan ={
184
+ id:res.data.id,
185
+ f_check_book_name: this.checkBook.f_check_book_name,
186
+ f_checker_name:this.checkBook.f_checker_name,
187
+ f_checker_id:this.checkBook.f_checker_id,
188
+ f_create_person: this.$login.f.name,
189
+ f_orgid: this.$login.f.orgid
190
+ }
191
+ http.load('POST', 'rs/logic/CreatorBookplan', {data:dataplan},{resolveMsg: null, rejectMsg: null})
192
+ this.$showMessage('保存片区信息成功',['confirm']).then(res=>{
193
+ if (res==='confirm'){
194
+ bus.$emit('fresh-main')
195
+ }
196
+ })
197
+ }else{
198
+ this.$showMessage('保存片区信息失败')
199
+ }
200
+ })
201
+ },
202
+ getRes (obj) {
203
+ if (obj.resids) {
204
+ this.checkBook.f_orgid = obj.resids[0]
205
+ console.log('id', this.checkBook.f_orgid)
206
+ }
207
+ },
208
+ getUsers(obj){
209
+ this.allUsers = obj
210
+ }
211
+ }
212
+ }
213
+ </script>
package/src/main.js CHANGED
@@ -1,33 +1,33 @@
1
- import Vue from 'vue'
2
- import App from './App'
3
- import { all } from 'vue-client'
4
- import { system } from 'system-clients'
5
- import safecheck from './safecheck'
6
- import echarts from 'echarts'
7
- // import safecheck from './rongcheng'
8
-
9
- all()
10
- // 验证码开关赋值
11
- var Verificationfalg = false
12
- system(Verificationfalg)
13
- // system()
14
- //safecheck(process.env.SAFE_CHECK);
15
- safecheck('wensu')
16
- require('./bootstrap/less/bootstrap.less')
17
- require('./expandcss.less')
18
-
19
- Vue.prototype.$echarts = echarts
20
- Vue.android = false
21
-
22
- Vue.url = '/SafeCheck/rs/'
23
- if(Vue.android)
24
- Vue.url = Vue.staticUrl
25
- Vue.interval = 1*60*1000
26
- Vue.nopic = 'file:///android_asset/nopic.png'
27
- Vue.mapSetup = false
28
-
29
- /* eslint-disable no-new */
30
- new Vue({
31
- el: 'body',
32
- components: { App }
33
- })
1
+ import Vue from 'vue'
2
+ import App from './App'
3
+ import { all } from 'vue-client'
4
+ import { system } from 'system-clients'
5
+ import safecheck from './safecheck'
6
+ import echarts from 'echarts'
7
+ // import safecheck from './rongcheng'
8
+
9
+ all()
10
+ // 验证码开关赋值
11
+ var Verificationfalg = false
12
+ system(Verificationfalg)
13
+ // system()
14
+ safecheck('bayan');
15
+ // safecheck('rizhao')
16
+ require('./bootstrap/less/bootstrap.less')
17
+ require('./expandcss.less')
18
+
19
+ Vue.prototype.$echarts = echarts
20
+ Vue.android = false
21
+
22
+ Vue.url = '/SafeCheck/rs/'
23
+ if(Vue.android)
24
+ Vue.url = Vue.staticUrl
25
+ Vue.interval = 1*60*1000
26
+ Vue.nopic = 'file:///android_asset/nopic.png'
27
+ Vue.mapSetup = false
28
+
29
+ /* eslint-disable no-new */
30
+ new Vue({
31
+ el: 'body',
32
+ components: { App }
33
+ })