manage-client 3.2.12 → 3.2.13

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "manage-client",
3
- "version": "3.2.12",
3
+ "version": "3.2.13",
4
4
  "description": "经营管控模块前台组件",
5
5
  "main": "src/index.js",
6
6
  "directories": {
@@ -195,8 +195,7 @@
195
195
  footer: [],
196
196
  model: new PagedList('rs/sql/BusinesQuery', 20, {}, {f_money: 0}),
197
197
  criteriaShow: false,
198
- headData: ["客户编号", "客户名称", "操作人", "操作日期", "停用状态", "停用原因", "其他停用原因", "同步状态"],
199
- bodyData: ["f_userinfo_code", "f_user_name", "f_operat_type", "f_describe", "f_operat_type", "f_operate_date", "f_state", "f_operator"],
198
+ bodyData: ["f_userinfo_code", "f_user_name", "f_meternumber","f_money", "f_operat_type","f_state", "f_operate_date", "f_orgname", "f_depname", "f_operator"],
200
199
  orgCondtionStr: '',
201
200
  show:false,
202
201
  rowdata:{},
@@ -17,7 +17,7 @@ export default{
17
17
  },
18
18
  // 业务查询
19
19
  businesConfig: {
20
- 'f_userinfo_code': '客户编号', 'f_user_name': '客户名称', 'f_meternumber': '表号', 'f_operat_type': '操作类型', 'f_describe': '操作描述',
20
+ 'f_userinfo_code': '客户编号', 'f_user_name': '客户名称', 'f_meternumber': '表号', 'f_money': '收款金额', 'f_operat_type': '操作类型',
21
21
  'f_state': '操作状态', 'f_operate_date': '操作日期', 'f_orgname': '组织名称', 'f_depname': '部门名称', 'f_operator': '操作人'
22
22
  },
23
23
  // 资源操作
@@ -1,209 +1,208 @@
1
- <template lang="html">
2
- <div>
3
- <div id="m" :style="{width:'100%',height:'100%'}"></div>
4
- </div>
5
- </template>
6
-
7
- <script>
8
- import * as Util from '../../../../Util'
9
- import co from 'co'
10
- import { HttpResetClass } from 'vue-client'
11
-
12
- let getData = function * (self, condition) {
13
- console.log('6666666666')
14
- let load = new HttpResetClass()
15
- load.load('POST', 'rs/sql/webmeter_getUserGasGroup',
16
- {data: {condition: '1 = 1' + (self.orgid != null ? ' and f_orgid in ( ' + self.orgid +')' : ''),
17
- groupname: 'day',
18
- startDate: self.startdate + ' 00:00:00',
19
- endDate: self.enddate + ' 23:59:59'}},
20
- {resolveMsg: null, rejectMsg: null})
21
- .then((res) => {
22
- let arrparams = []
23
- let gasdata1 = []
24
- let gasdata2 = []
25
- for (var i = 0; i < res.data.length; i++) {
26
- arrparams[i] = res.data[i].f_type
27
- gasdata1[i] = res.data[i].f_oughtamount1
28
- gasdata2[i] = res.data[i].f_oughtamount2
29
- }
30
- self.set(arrparams, gasdata1, gasdata2)
31
- })
32
- }
33
- export default {
34
- props: {
35
- echarts:{
36
- type:Boolean,
37
- default:false
38
- },
39
- startdate: {
40
- type: String,
41
- default: Util.toStandardDateString()
42
- },
43
- enddate: {
44
- type: String,
45
- default: Util.toStandardDateString()
46
- },
47
- condition: {
48
- type: String,
49
- default: '1=1'
50
- },
51
- orgid:'',
52
- groupname: {
53
- type: String,
54
- default: 'year'
55
- }
56
- },
57
- data () {
58
- title: '业务类型'
59
- return {
60
- xc: ''
61
- }
62
- },
63
- ready(){
64
- console.log(this.echarts)
65
- this.searchdata()
66
- },
67
- methods: {
68
- set (arrparams, gasdata1, gasdata2) {
69
- console.log('--------->>>>>>>>>>>>',arrparams,gasdata1,gasdata2)
70
- console.log("ec:"+this.echarts)
71
- let name = ''
72
- if (this.groupname === 'year')
73
- {
74
- name = '年'
75
- } else if (this.groupname === 'month'){
76
- name = '月'
77
- } else if (this.groupname === 'week'){
78
- name = '周'
79
- } else {
80
- name = '日'
81
- }
82
- this.xc = this.$echarts.init(document.getElementById('m'))
83
- // this.xc.resize({height: '100%',width: '100%'})
84
- this.xc.setOption({
85
- title: {
86
- text: '用气' + name + '分析图',
87
- x: 'left',
88
- textStyle: {
89
- color: '#000',
90
- fontSize: 20
91
- }
92
- },
93
- color: ['#61a0a8', '#2f4554'],
94
- tooltip: {
95
- trigger: 'axis',
96
- extraCssText: 'width: auto;height: auto;'
97
- },
98
- grid:{
99
- top:'20%',
100
- },
101
- legend: {
102
- x: 'left',
103
- y: 'bottom',
104
- textStyle: {
105
- fontSize: 12
106
- },
107
- data: ['用气量(民用)(m³)', '用气量(非民用)(m³)']
108
- },
109
- toolbox: {
110
- show: true,
111
- feature: {
112
- mark: {show: true},
113
- dataView: {show: true, readOnly: false},
114
- magicType: {show: true, type: ['line', 'bar', 'stack', 'tiled']},
115
- restore: {show: true},
116
- saveAsImage: {show: true}
117
- }
118
- },
119
- calculable: true,
120
- xAxis: [
121
- { name: '日期',
122
- nameTextStyle: {
123
- fontSize: 15
124
- },
125
- type: 'category',
126
- data: arrparams
127
- }
128
- ],
129
- yAxis : [
130
- {
131
- type : 'value',
132
- name: '用气量(m³)',
133
- nameTextStyle: {
134
- fontSize: 15
135
- },
136
- axisLabel: {
137
- show: true,
138
- textStyle: {
139
- fontSize: 15,
140
- color: '#7d8000'
141
- }
142
- }
143
- }
144
- ],
145
- series : [
146
- {
147
- name: '用气量(民用)(m³)',
148
- type: 'bar',
149
- smooth: true,
150
- itemStyle: {normal: {areaStyle: {type: 'default'}}},
151
- data: gasdata1,
152
- markPoint: {
153
- data: [
154
- {type: 'max', name: '最大值'},
155
- {type: 'min', name: '最小值'}
156
- ]
157
- },
158
- markLine: {
159
- data: [
160
- {type: 'average', name: '平均值'}
161
- ]
162
- }
163
- },
164
- {
165
- name: '用气量(非民用)(m³)',
166
- type: 'bar',
167
- smooth: true,
168
- itemStyle: {normal: {areaStyle: {type: 'default'}}},
169
- data: gasdata2,
170
- markPoint: {
171
- data: [
172
- {type: 'max', name: '最大值'},
173
- {type: 'min', name: '最小值'}
174
- ]
175
- },
176
- markLine: {
177
- data: [
178
- {type: 'average', name: '平均值'}
179
- ]
180
- }
181
- }
182
- ]
183
- })
184
- },
185
- searchdata (condition) {
186
- console.log("ec:"+this.echarts)
187
- let getGen = getData(this, condition)
188
- co(getGen)
189
- }
190
- },
191
- watch: {
192
- // 'echarts' (val) {
193
- // this.searchdata(this.condition)
194
- // },
195
- // 'groupname' (val) {
196
- // this.searchdata(this.condition)
197
- // },
198
- 'startdate' (val) {
199
- this.searchdata()
200
- },
201
- 'enddate' (val) {
202
- this.searchdata()
203
- },
204
- 'orgid' (val) {
205
- this.searchdata()
206
- }
207
- }
208
- }
209
- </script>
1
+ <template lang="html">
2
+ <div>
3
+ <div id="m" :style="{width:'100%',height:'100%'}"></div>
4
+ </div>
5
+ </template>
6
+
7
+ <script>
8
+ import * as Util from '../../../../Util'
9
+ import co from 'co'
10
+ import { HttpResetClass } from 'vue-client'
11
+
12
+ let getData = function * (self, condition) {
13
+ console.log('6666666666')
14
+ let load = new HttpResetClass()
15
+ load.load('POST', 'rs/sql/webmeter_getUserGasGroup',
16
+ {data: {condition: '1 = 1' + (self.orgid != null ? ' and f_orgid in ( ' + self.orgid +')' : ''),
17
+ groupname: 'day',
18
+ startDate: self.startdate + ' 00:00:00',
19
+ endDate: self.enddate + ' 23:59:59'}},
20
+ {resolveMsg: null, rejectMsg: null})
21
+ .then((res) => {
22
+ let arrparams = Array.from(new Set(res.data.map(x => x.type)))
23
+ let gasdata1 = []
24
+ let gasdata2 = []
25
+ for (let i = 0; i < arrparams.length; i++) {
26
+ gasdata1.push(res.data.filter(item => item.type == arrparams[i] && item.f_user_type == '民用').map(x => x.f_gas).reduce((x, y) => x + y,0).toFixed(2))
27
+ gasdata2.push(res.data.filter(item => item.type == arrparams[i] && item.f_user_type == '非民用').map(x => x.f_gas).reduce((x, y) => x + y,0).toFixed(2))
28
+ }
29
+ self.set(arrparams, gasdata1, gasdata2)
30
+ })
31
+ }
32
+ export default {
33
+ props: {
34
+ echarts:{
35
+ type:Boolean,
36
+ default:false
37
+ },
38
+ startdate: {
39
+ type: String,
40
+ default: Util.toStandardDateString()
41
+ },
42
+ enddate: {
43
+ type: String,
44
+ default: Util.toStandardDateString()
45
+ },
46
+ condition: {
47
+ type: String,
48
+ default: '1=1'
49
+ },
50
+ orgid:'',
51
+ groupname: {
52
+ type: String,
53
+ default: 'year'
54
+ }
55
+ },
56
+ data () {
57
+ title: '业务类型'
58
+ return {
59
+ xc: ''
60
+ }
61
+ },
62
+ ready(){
63
+ console.log(this.echarts)
64
+ this.searchdata()
65
+ },
66
+ methods: {
67
+ set (arrparams, gasdata1, gasdata2) {
68
+ console.log('--------->>>>>>>>>>>>',arrparams,gasdata1,gasdata2)
69
+ console.log("ec:"+this.echarts)
70
+ let name = ''
71
+ if (this.groupname === 'year')
72
+ {
73
+ name = '年'
74
+ } else if (this.groupname === 'month'){
75
+ name = '月'
76
+ } else if (this.groupname === 'week'){
77
+ name = '周'
78
+ } else {
79
+ name = '日'
80
+ }
81
+ this.xc = this.$echarts.init(document.getElementById('m'))
82
+ // this.xc.resize({height: '100%',width: '100%'})
83
+ this.xc.setOption({
84
+ title: {
85
+ text: '用气' + name + '分析图',
86
+ x: 'left',
87
+ textStyle: {
88
+ color: '#000',
89
+ fontSize: 20
90
+ }
91
+ },
92
+ color: ['#61a0a8', '#2f4554'],
93
+ tooltip: {
94
+ trigger: 'axis',
95
+ extraCssText: 'width: auto;height: auto;'
96
+ },
97
+ grid:{
98
+ top:'20%',
99
+ },
100
+ legend: {
101
+ x: 'left',
102
+ y: 'bottom',
103
+ textStyle: {
104
+ fontSize: 12
105
+ },
106
+ data: ['用气量(民用)(m³)', '用气量(非民用)(m³)']
107
+ },
108
+ toolbox: {
109
+ show: true,
110
+ feature: {
111
+ mark: {show: true},
112
+ dataView: {show: true, readOnly: false},
113
+ magicType: {show: true, type: ['line', 'bar', 'stack', 'tiled']},
114
+ restore: {show: true},
115
+ saveAsImage: {show: true}
116
+ }
117
+ },
118
+ calculable: true,
119
+ xAxis: [
120
+ { name: '日期',
121
+ nameTextStyle: {
122
+ fontSize: 15
123
+ },
124
+ type: 'category',
125
+ data: arrparams
126
+ }
127
+ ],
128
+ yAxis : [
129
+ {
130
+ type : 'value',
131
+ name: '用气量(m³)',
132
+ nameTextStyle: {
133
+ fontSize: 15
134
+ },
135
+ axisLabel: {
136
+ show: true,
137
+ textStyle: {
138
+ fontSize: 15,
139
+ color: '#7d8000'
140
+ }
141
+ }
142
+ }
143
+ ],
144
+ series : [
145
+ {
146
+ name: '用气量(民用)(m³)',
147
+ type: 'bar',
148
+ smooth: true,
149
+ itemStyle: {normal: {areaStyle: {type: 'default'}}},
150
+ data: gasdata1,
151
+ markPoint: {
152
+ data: [
153
+ {type: 'max', name: '最大值'},
154
+ {type: 'min', name: '最小值'}
155
+ ]
156
+ },
157
+ markLine: {
158
+ data: [
159
+ {type: 'average', name: '平均值'}
160
+ ]
161
+ }
162
+ },
163
+ {
164
+ name: '用气量(非民用)(m³)',
165
+ type: 'bar',
166
+ smooth: true,
167
+ itemStyle: {normal: {areaStyle: {type: 'default'}}},
168
+ data: gasdata2,
169
+ markPoint: {
170
+ data: [
171
+ {type: 'max', name: '最大值'},
172
+ {type: 'min', name: '最小值'}
173
+ ]
174
+ },
175
+ markLine: {
176
+ data: [
177
+ {type: 'average', name: '平均值'}
178
+ ]
179
+ }
180
+ }
181
+ ]
182
+ })
183
+ },
184
+ searchdata (condition) {
185
+ console.log("ec:"+this.echarts)
186
+ let getGen = getData(this, condition)
187
+ co(getGen)
188
+ }
189
+ },
190
+ watch: {
191
+ // 'echarts' (val) {
192
+ // this.searchdata(this.condition)
193
+ // },
194
+ // 'groupname' (val) {
195
+ // this.searchdata(this.condition)
196
+ // },
197
+ 'startdate' (val) {
198
+ this.searchdata()
199
+ },
200
+ 'enddate' (val) {
201
+ this.searchdata()
202
+ },
203
+ 'orgid' (val) {
204
+ this.searchdata()
205
+ }
206
+ }
207
+ }
208
+ </script>
@@ -457,12 +457,10 @@ import {HttpResetClass, PagedList} from 'vue-client'
457
457
  // 初始化气表品牌
458
458
  let brandArr = []
459
459
  this.$MagGetSaleParam.getGasbrand().forEach((item) => {
460
- if (item.value.f_meter_type == '物联网表') {
461
460
  let temp = {}
462
461
  temp.label = item.label
463
462
  temp.value = item.value.f_meter_brand
464
463
  brandArr.push(temp)
465
- }
466
464
  })
467
465
  this.meterbrands = [{label: '全部', value: ''}, ...brandArr]
468
466
 
@@ -44,7 +44,7 @@
44
44
  let getData = function * (self, condition) {
45
45
  let load = new HttpResetClass()
46
46
  load.load('POST', 'rs/sql/webmeter_getUserGasGroup',
47
- {data: {condition: condition, groupname: self.groupname[0], startDate: self.startdate,
47
+ {data: {condition: condition, groupname: self.groupname, startDate: self.startdate,
48
48
  endDate: self.enddate}},
49
49
  {resolveMsg: null, rejectMsg: null})
50
50
  .then((res) => {