system-clients 3.0.40 → 3.0.42-fanxian

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/SystemClient.iml CHANGED
@@ -1,12 +1,12 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <module external.linked.project.id="SystemClient" external.linked.project.path="$MODULE_DIR$" external.root.project.path="$MODULE_DIR$" external.system.id="GRADLE" external.system.module.group="" external.system.module.version="1.6.18" type="JAVA_MODULE" version="4">
3
- <component name="NewModuleRootManager" inherit-compiler-output="true">
4
- <exclude-output />
5
- <content url="file://$MODULE_DIR$">
6
- <excludeFolder url="file://$MODULE_DIR$/.gradle" />
7
- <excludeFolder url="file://$MODULE_DIR$/build" />
8
- </content>
9
- <orderEntry type="inheritedJdk" />
10
- <orderEntry type="sourceFolder" forTests="false" />
11
- </component>
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <module external.linked.project.id="SystemClient" external.linked.project.path="$MODULE_DIR$" external.root.project.path="$MODULE_DIR$" external.system.id="GRADLE" external.system.module.group="" external.system.module.version="1.6.18" type="JAVA_MODULE" version="4">
3
+ <component name="NewModuleRootManager" inherit-compiler-output="true">
4
+ <exclude-output />
5
+ <content url="file://$MODULE_DIR$">
6
+ <excludeFolder url="file://$MODULE_DIR$/.gradle" />
7
+ <excludeFolder url="file://$MODULE_DIR$/build" />
8
+ </content>
9
+ <orderEntry type="inheritedJdk" />
10
+ <orderEntry type="sourceFolder" forTests="false" />
11
+ </component>
12
12
  </module>
package/index.html CHANGED
@@ -1,21 +1,21 @@
1
- <!DOCTYPE html>
2
- <html lang="zh-CN">
3
- <head>
4
- <meta charset="utf-8">
5
- <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
6
- <META HTTP-EQUIV="pragma" CONTENT="no-cache">
7
- <META HTTP-EQUIV="Cache-Control" CONTENT="no-cache, must-revalidate">
8
- <META HTTP-EQUIV="expires" CONTENT="0">
9
- <title>奥枫信息系统</title>
10
- <style media="screen">
11
- /*url(./static/newmainbg.jpg)*/
12
- body{width: 100%;background:#7f8eaf no-repeat center bottom; background-size: cover;}
13
- body .loginbg{ width:100%; height:100%; background:url(./static/loginbg.jpg) no-repeat center top;}
14
- </style>
15
- </head>
16
- <body id="bodymain" class="themeOne">
17
- <!-- <widget></widget> -->
18
- <app></app>
19
- <!-- built files will be auto injected -->
20
- </body>
21
- </html>
1
+ <!DOCTYPE html>
2
+ <html lang="zh-CN">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
6
+ <META HTTP-EQUIV="pragma" CONTENT="no-cache">
7
+ <META HTTP-EQUIV="Cache-Control" CONTENT="no-cache, must-revalidate">
8
+ <META HTTP-EQUIV="expires" CONTENT="0">
9
+ <title>奥枫信息系统</title>
10
+ <style media="screen">
11
+ /*url(./static/newmainbg.jpg)*/
12
+ body{width: 100%;background:#7f8eaf no-repeat center bottom; background-size: cover;}
13
+ body .loginbg{ width:100%; height:100%; background:url(./static/loginbg.jpg) no-repeat center top;}
14
+ </style>
15
+ </head>
16
+ <body id="bodymain" class="themeOne">
17
+ <!-- <widget></widget> -->
18
+ <app></app>
19
+ <!-- built files will be auto injected -->
20
+ </body>
21
+ </html>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "system-clients",
3
- "version": "3.0.40",
3
+ "version": "3.0.42-fanxian",
4
4
  "description": "系统基础框架",
5
5
  "main": "src/index.js",
6
6
  "directories": {
@@ -58,6 +58,16 @@
58
58
  <!-- </div>-->
59
59
 
60
60
  <div class='flex-row aaa system-main' id="box" v-el:box v-if="!isManger">
61
+ <div class="auto" style="position: fixed;right: 370px;top: 15px;color: #333">
62
+ <button class="btn" @click="showAbnormity = true" style="background: none;">
63
+ <img
64
+ src="../assets/shezhi-hover.png" height="15" width="15">
65
+ 异常警报<label style="display: inline-block;width: 8px;height: 8px;border-radius: 50%;background-color: red;text-align: center;line-height: 30px;" v-show="showaData"></label>
66
+ </button>
67
+ <button class="btn" @click="stopSound" style="background: none;">
68
+ 关闭警报
69
+ </button>
70
+ </div>
61
71
  <div class="auto" style="position: fixed;right: 30px;top: 20px;color: #333">
62
72
  <span>
63
73
  <img
@@ -115,6 +125,19 @@
115
125
  <!-- 修改密码组件 -->
116
126
  <modify-pw :show.sync="show" v-if="show"></modify-pw>
117
127
  <!-- 修改密码模态框 -->
128
+ <!-- 异常查看 -->
129
+ <modal v-if="showAbnormity" :show.sync="showAbnormity" :width="1000" v-ref:modal backdrop="false">
130
+ <header slot="modal-header" class="modal-header">
131
+ <button type="button" class="close" @click="showAbnormity = false"><span>&times;</span></button>
132
+ <h4 class="modal-title">异常报警</h4>
133
+ </header>
134
+ <article slot="modal-body" class="modal-body modifystyle auto form-horizontal">
135
+ <alarm-information :mergeinfo=abnormityWarningData></alarm-information>
136
+ </article>
137
+ <footer slot="modal-footer" class="modal-footer">
138
+ <button type="button" class="btn btn-success" @click='showAbnormity = false'>确认</button>
139
+ </footer>
140
+ </modal>
118
141
  </div>
119
142
  </template>
120
143
 
@@ -151,7 +174,16 @@
151
174
  tabs:[], //已初始化页签数组
152
175
  selecttab:'',
153
176
  setting:true,
154
- srcsetting:'../../static/newStyle/setting.png'
177
+ srcsetting:'../../static/newStyle/setting.png',
178
+ abnormityWarningData: {
179
+ data: []
180
+ },
181
+ showAbnormity: false,
182
+ showaData: false,
183
+ audio: null,
184
+ isTimeAb: parseInt(this.$appdata.getSingleValue('异常报警查询时间')),
185
+ isBell: this.$appdata.getSingleValue('是否响铃')
186
+
155
187
 
156
188
  // headerHint: true, // 右侧顶部提示信息
157
189
  // value: 25645.26,
@@ -203,8 +235,41 @@
203
235
  // return false
204
236
  // }
205
237
  this.changeShow()
238
+ // 在组件挂载后立即开始定时任务
239
+ this.abnormityWarning()
240
+ this.abnormityWarData()
206
241
  },
207
242
  methods: {
243
+ abnormityWarning () {
244
+ setInterval(() => {
245
+ this.abnormityWarningData = []
246
+ this.$resetpost('rs/sql/getAbnormityWarning', {data: {}}, {resolveMsg: '', rejectMsg: ''}).then(item => {
247
+ this.abnormityWarningData = item
248
+ if (this.abnormityWarningData.data.length > 0) {
249
+ this.playSound()
250
+ this.showaData = true
251
+ } else {
252
+ this.showaData = false
253
+ }
254
+ })
255
+ }, this.isTimeAb)
256
+ },
257
+ abnormityWarData () {
258
+ this.$resetpost('rs/sql/getAbnormityWarning', {data: {}}, {resolveMsg: '', rejectMsg: ''}).then(item => {
259
+ console.log('--------数据----------')
260
+ console.log(item)
261
+ console.log('------------------')
262
+ this.abnormityWarningData = item
263
+ if (this.isBell === '是') {
264
+ if (this.abnormityWarningData.data.length > 0) {
265
+ this.playSound()
266
+ this.showaData = true
267
+ } else {
268
+ this.showaData = false
269
+ }
270
+ }
271
+ })
272
+ },
208
273
  hindsetting(){
209
274
 
210
275
  this.setting=!this.setting
@@ -272,6 +337,22 @@
272
337
  tabcg(val){
273
338
  console.log(val)
274
339
  this.tabs = val
340
+ },
341
+ playSound () {
342
+ if (this.audio) {
343
+ this.audio.pause()
344
+ this.audio = null
345
+ }
346
+ this.audio = new Audio()
347
+ this.audio.src = 'static/newStyle/alarm.mp3' // 替换为实际的音频文件路径
348
+ this.audio.loop = true // 设置循环播放
349
+ this.audio.play()
350
+ },
351
+ stopSound () {
352
+ if (this.audio) {
353
+ this.audio.pause()
354
+ this.audio = null
355
+ }
275
356
  }
276
357
  },
277
358
  computed: {
@@ -0,0 +1,122 @@
1
+ <template>
2
+ <div id="unit" class="flex-row">
3
+ <div class="basic-main">
4
+ <criteria-paged :model="model" v-ref:paged >
5
+ <criteria partial='criteria' v-ref:criteria @condition-changed='$parent.search' >
6
+ <div v-show="false" novalidate class="form-horizontal select-overspread container-fluid auto" partial>
7
+ </div>
8
+
9
+ </criteria>
10
+ <data-grid :model="model" partial='list' class="list_area table_sy" v-ref:grid>
11
+ <template partial='head'>
12
+ <tr>
13
+ <th><nobr>客户编号</nobr></th>
14
+ <th><nobr>客户姓名</nobr></th>
15
+ <th><nobr>上报时间</nobr></th>
16
+ <th><nobr>上报级别</nobr></th>
17
+ <th><nobr>报警类型</nobr></th>
18
+ <th><nobr>报警详情</nobr></th>
19
+ <th>操作</th>
20
+ </tr>
21
+ </template>
22
+ <template partial='body'>
23
+ <tr>
24
+ <td style="text-align:center"><nobr>{{row.f_userinfo_code}}</nobr></td>
25
+ <td style="text-align:center"><nobr>{{row.f_user_name}}</nobr></td>
26
+ <td style="text-align:center"><nobr>{{row.f_insert_date}}</nobr></td>
27
+ <td style="text-align:center"><nobr>{{row.f_error_level}}</nobr></td>
28
+ <td style="text-align:center"><nobr>{{row.f_error_type}}</nobr></td>
29
+ <td style="text-align:center"><nobr>{{row.f_error_msg}}</nobr></td>
30
+ <td style="text-align:center;" v-if="row.f_is_read == false" >
31
+ <span ><a href="#" @click.stop="$parent.$parent.$parent.backSend1(row.id)">添加备注</a></span>
32
+ </td>
33
+ <td style="text-align:center;" v-if="row.f_is_read === true"><span title="备注信息:{{row.f_error_reason}}">备注信息</span></td>
34
+ </tr>
35
+ </template>
36
+ <template partial='foot'></template>
37
+ </data-grid>
38
+ </criteria-paged>
39
+
40
+ <modal :show.sync="watchshow" v-ref:modal backdrop="false">
41
+ <header slot="modal-header" class="modal-header">
42
+ <button type="button" class="close" @click="tableFault()"><span>&times;</span></button>
43
+ <h4 class="modal-title">信息备注</h4>
44
+ </header>
45
+ <article slot="modal-body" class="modal-body">
46
+ <div class="col-sm-12">
47
+ <label class="font_normal_body">添加信息备注</label>
48
+ <textarea name="name" rows="2" style="width: 100%"
49
+ class="ver-textarea" class="form-control"
50
+ placeholder='请填写信息备注'
51
+ v-model='f_error_reason'></textarea>
52
+ </div>
53
+ </article>
54
+ <footer slot="modal-footer" class="modal-footer">
55
+ <button v-show="watchshow" type="button" class="btn btn-default" @click='tableFault()'>取消</button>
56
+ <button v-show="watchshow" type="button" class="btn btn-danger btn-ln fr" @click='saveException()'>确认</button>
57
+ </footer>
58
+ </modal>
59
+ </div>
60
+ </div>
61
+ </template>
62
+ <script>
63
+ import {PagedList} from 'vue-client'
64
+
65
+ export default {
66
+ title: '异常警报信息',
67
+ props: ['mergeinfo'],
68
+ data () {
69
+ return {
70
+ watchshow: false,
71
+ cancelid: '',
72
+ condition: '1=1',
73
+ error_condition: '',
74
+ f_error_reason: '',
75
+ model: new PagedList('rs/sql/getAbnormityWarning', 8)
76
+ }
77
+ },
78
+ ready () {
79
+ this.model
80
+ this.$refs.paged.$refs.criteria.search()
81
+ },
82
+ methods: {
83
+ backSend1(megrow){
84
+ this.watchshow = true
85
+ this.cancelid = megrow
86
+ },
87
+ tableFault (val) {
88
+ if (val) {
89
+ console.log('开启弹窗')
90
+ } else {
91
+ console.log('返回置空')
92
+ this.f_error_reason = ''
93
+ }
94
+ this.watchshow = !this.watchshow
95
+ },
96
+ search (args) {
97
+ console.log(args)
98
+ this.condition = '1=1'
99
+ this.model.search(args.condition, args.model)
100
+ },
101
+ saveException () {
102
+ let send = {
103
+ id: this.cancelid, // 当前记录ID
104
+ f_is_read: 1,
105
+ f_error_reason: this.f_error_reason // 备注原因
106
+ }
107
+ let param = {
108
+ tablename: 't_exception',
109
+ id:1,
110
+ basedata: send
111
+ }
112
+ this.$resetpost('rs/logic/iat_saveTable', param).then(() => {
113
+ // this.params.rows.splice(index, 1)
114
+ this.watchshow = false
115
+ this.$refs.paged
116
+ this.f_error_reason = ''
117
+ })
118
+ }
119
+ }
120
+
121
+ }
122
+ </script>