manage-client 3.3.122 → 3.3.123

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.
@@ -19,9 +19,9 @@ var qtx= 'http://36.103.222.144:6300/'
19
19
  // var bendi = 'http://203.57.101.233:8400/'
20
20
  // var bendi = 'http://121.36.106.17:8400/'
21
21
  // var fuwu = 'http://203.57.101.233:9001'
22
- var bendi = 'http://192.168.50.67:31785'
22
+ var bendi = 'http://121.36.106.17:8400'
23
23
  // var bendi = 'http://119.187.112.234:8400/'
24
- var wode = 'http://192.168.50.67:31785'
24
+ var wode = 'http://121.36.106.17:8400'
25
25
  // 192.168.
26
26
  // var str = 'http://127.0.0.1:8080/manage', str2 = 'http://192.168.50.199:8300'
27
27
  // var str = 'http://192.168.10.233:8300', str2 = 'http://192.168.10.14:8300'
@@ -91,7 +91,7 @@ var proxyTable = {
91
91
  target: bendi
92
92
  },
93
93
  '/rs/sql': {
94
- target: 'http://localhost:8084/'
94
+ target: bendi
95
95
  },
96
96
  '/rs': {
97
97
  target: wode
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "manage-client",
3
- "version": "3.3.122",
3
+ "version": "3.3.123",
4
4
  "description": "经营管控模块前台组件",
5
5
  "main": "src/index.js",
6
6
  "directories": {
@@ -0,0 +1,250 @@
1
+ <template>
2
+ <div class="basic-main" style="height: 98%">
3
+ <criteria-paged :model="model" :pager='false' v-ref:paged>
4
+ <criteria partial='criteria' @condition-changed='$parent.selfSearch' v-ref:criteria>
5
+ <p class="bg-info text-center" style="padding: 8px;">用气量统计汇总</p>
6
+ <div class="form-group" v-if="!$parent.$parent.data.f_files_path"></div>
7
+ <div novalidate class="form-horizontal select-overspread container-fluid auto" partial >
8
+ <div class="row">
9
+ <div class="col-sm-2 form-group" >
10
+ <label class="font_normal_body" for="startDate">开始日期:</label>
11
+ <datepicker id="startDate" placeholder="开始日期" style="width: 60%"
12
+ v-model="model.startDate"
13
+ :value.sync="model.startDate"
14
+ :disabled-days-of-Week="[]"
15
+ :format="'yyyy-MM-dd HH:mm:ss'"
16
+ :show-reset-button="reset">
17
+ </datepicker>
18
+ </div>
19
+ <div class="col-sm-2 form-group" >
20
+ <label class="font_normal_body" for="endDate">结束日期:</label>
21
+ <datepicker id="endDate" placeholder="结束日期" style="width: 60%"
22
+ v-model="model.endDate"
23
+ :value.sync="model.endDate"
24
+ :disabled-days-of-Week="[]"
25
+ :format="'yyyy-MM-dd HH:mm:ss'"
26
+ :show-reset-button="reset">
27
+ </datepicker>
28
+ </div>
29
+ <div class="col-sm-2 form-group">
30
+ <label class="font_normal_body">&nbsp;&nbsp;公&nbsp;&nbsp;&nbsp;司&nbsp;&nbsp; </label>
31
+ <right-tree @re-res="$parent.$parent.getRes"></right-tree>
32
+ </div>
33
+ <div class="col-sm-2 form-group">
34
+ <label class="font_normal_body">&nbsp;&nbsp;部&nbsp;&nbsp;&nbsp;门&nbsp;&nbsp; </label>
35
+ <res-select restype='department'
36
+ is-mul="false"
37
+ @res-select="$parent.$parent.getdep"
38
+ :parentresid="$parent.$parent.depresid"
39
+ :initresid='$parent.$parent.depid'>
40
+ </res-select>
41
+
42
+ </div>
43
+ <div class="col-sm-2 form-group">
44
+ <label class="font_normal_body">&nbsp;&nbsp;人&nbsp;&nbsp;&nbsp;员&nbsp;&nbsp; </label>
45
+ <res-select restype='user'
46
+ is-mul="false"
47
+ @res-select="$parent.$parent.getuser"
48
+ :parentresid="$parent.$parent.userresid"
49
+ :initresid='$parent.$parent.operatorid'>
50
+ </res-select>
51
+ </div>
52
+ </div>
53
+ <div class="span" style = "float:right;">
54
+ <button class="button_search" @click="$parent.$parent.searchData()">查询</button>
55
+ <report-print id='gasprice' top='3cm' left='0' width='100%' height='100%' :preview="true"></report-print>
56
+ <report-excel id='gasprice'></report-excel>
57
+ </div>
58
+ </div>
59
+ </criteria>
60
+ <div partial='list' v-el:handcollect id='gasprice' style="overflow-y: scroll">
61
+ <table class='tableprint' style="margin: 0px auto;">
62
+ <thead>
63
+ <tr>
64
+ <th colspan='18' style="font-weight: normal; text-align: left;">
65
+ <h2 style="text-align: center">{{$parent.orgname}}</h2>
66
+ <h3 style="text-align: center">用气量统计汇总</h3>
67
+ </th>
68
+ </tr>
69
+ <tr>
70
+ <th colspan='18' style="font-weight: normal; text-align: center;">
71
+ 开始时间:{{model.model.startDate}}&nbsp;&nbsp;&nbsp;
72
+ 结束时间:{{ model.model.endDate }}&nbsp;&nbsp;<br/>
73
+ 打印时间:{{{$parent.printTime}}}
74
+ </th>
75
+ </tr>
76
+ <tr>
77
+ <th colspan='18' style="font-weight: normal; text-align: center;">
78
+ <div>
79
+ <span v-show="$parent.depname.trim()!=''">网点:{{$parent.depname}}</span>
80
+ <span v-show="$parent.operatorname.trim()!=''">操作员:{{$parent.operatorname}}</span>
81
+ </div>
82
+ </th>
83
+ </tr>
84
+ </thead>
85
+ <tr>
86
+ <td colspan='18'>
87
+ {{{ model.data.substring(26,model.data.length-8) }}}
88
+ </td>
89
+ </tr>
90
+ <tfoot>
91
+ <tr style="text-align: left">
92
+ <th colspan='6'>财务审核:</th>
93
+ <th colspan='6'>收款审核:</th>
94
+ <th colspan='6'>收款员:</th>
95
+ </tr>
96
+ </tfoot>
97
+ </table>
98
+ {{{ $parent.reportStr}}}
99
+ </div>
100
+ </criteria-paged>
101
+ <modal :show.sync="show" v-ref:modal small backdrop="false">
102
+ <header slot="modal-header" class="modal-header">
103
+ <h4 class="modal-title">输入文件名称</h4>
104
+ </header>
105
+ <article slot="modal-body" class="modal-body">
106
+ <div class="form-group">
107
+ <input type="text" class="form-control" v-model="filename" placeholder='保存的文件名'>
108
+ </div>
109
+ </article>
110
+ <footer slot="modal-footer" class="modal-footer">
111
+ <button v-show="show" type="button" class="btn btn-default" @click='close'>取消</button>
112
+ <button v-show="show" type="button" class="btn btn-success" @click='confirm(filename)'>确认</button>
113
+ </footer>
114
+ </modal>
115
+ </div>
116
+ </template>
117
+
118
+ <script>
119
+ import { DataModel } from 'vue-client'
120
+ import co from 'co'
121
+ let saveFile = function * (self) {
122
+ // 线验证文件是否重名
123
+ let count = yield self.$resetpost('rs/sql/manageSingleTable',
124
+ {data: {tablename: 't_report_record', condition: `f_files_name = '${self.filename}'`}},
125
+ {resolveMsg: null, rejectMsg: null})
126
+ if (count.data.length > 0) {
127
+ self.$showAlert('无法保存,文件名重名', 'warning', 3000)
128
+ return
129
+ }
130
+ let saveBack = yield self.$resetpost('rs/logic/saveReport', {f_files_content: self.$refs.paged.$els.handcollect.innerHTML,
131
+ f_files_name: self.filename, f_files_type: self.data.f_report_type, f_component_name: 'manage-bus-summary',
132
+ f_operator: this.$login.f.name, f_query_month: `${self.model.model.startDate}-${self.model.model.endDate}`,
133
+ f_outlets: this.$login.f.depname})
134
+ if (saveBack.data.status === 'succeed') {
135
+ self.show = false
136
+ self.filename = ''
137
+ // 后台保存完成,通知刷新
138
+ self.$dispatch('save-success', self.filename)
139
+ }
140
+ }
141
+ export default {
142
+ title: '用气量统计汇总',
143
+ props: ['data'],
144
+ data () {
145
+ return {
146
+ printTime: this.$login.toStandardTimeString(),
147
+ depresid: [],
148
+
149
+ userresid: [],
150
+ f_orgid: this.$login.f.orgid,
151
+ f_depid: this.$login.f.depids,
152
+ f_operatorid: this.$login.f.id,
153
+ operatorid: [],
154
+ depid: [],
155
+ orgname: '',
156
+ depname: '',
157
+ operatorname: '',
158
+ meterbrands: [],
159
+ orgCondtionStr: '1=1',
160
+ model: new DataModel('rs/report/ycGasSummary', {startDate: 'this.model.startDate', endDate: 'this.model.endDate',
161
+ f_orgid: 'this.model.f_orgid'}),
162
+ reportStr: null,
163
+ show: false,
164
+ }
165
+ },
166
+ ready () {
167
+ this.$refs.paged.$refs.criteria.model.startDate = this.$login.toStandardDateString() + ' 00:00:00'
168
+ this.$refs.paged.$refs.criteria.model.endDate = this.$login.toStandardDateString() + ' 23:59:59'
169
+ console.log(this.$login.f)
170
+ },
171
+ methods: {
172
+ searchData () {
173
+ this.$refs.paged.$refs.criteria.search()
174
+ },
175
+ selfSearch (args) {
176
+ this.printTime = this.$login.toStandardTimeString()
177
+ let orgcondition = ` f_orgid in ('${this.f_orgid}')`
178
+ if (this.f_depid[0]) {
179
+ orgcondition += ` and f_depid in ('${this.f_depid}')`
180
+ }
181
+ if(this.f_operatorid[0]) {
182
+ orgcondition += ` and f_operatorid in ('${this.f_operatorid}')`
183
+ }
184
+ this.$refs.paged.$refs.criteria.model.f_orgid = orgcondition
185
+ this.$refs.paged.search(args)
186
+ },
187
+ getRes (obj) {
188
+ this.orgname = obj.res[0]
189
+ this.depresid = obj.resids
190
+ this.f_orgid = obj.resids
191
+ },
192
+ getdep (obj, val) {
193
+ this.userresid = obj
194
+ this.f_depid = obj
195
+ },
196
+ getuser ( obj, val) {
197
+ this.operatorname = val[0]
198
+ this.f_operatorid = obj
199
+ },
200
+
201
+ // 根据文件路径获取储存的报表内容
202
+ getFileContent (path) {
203
+ this.$resetpost('rs/logic/getReportFileContent', {f_files_path: path}, {resolveMsg: null, rejectMsg: null}).then((res) => {
204
+ this.reportStr = res.data.filecontent
205
+ this.model.state = '正确'
206
+ })
207
+ },
208
+ confirm () {
209
+ if (!this.filename || this.filename === '') {
210
+ this.$showAlert('无法保存,文件名不能为空', 'warning', 3000)
211
+ }
212
+ let saveGen = saveFile(this)
213
+ co(saveGen)
214
+ },
215
+ close () {
216
+ this.show = false
217
+ },
218
+ // 将报表保存成文件
219
+ confirmReport () {
220
+ this.show = true
221
+ this.filename = this.data.f_report_name + this.$login.toStandardDateString()
222
+ },
223
+ },
224
+ watch: {
225
+ 'data' (val) {
226
+ if (val.f_files_path) {
227
+ this.getFileContent(val.f_files_path)
228
+ } else {
229
+ this.reportStr = null
230
+ }
231
+ }
232
+ },
233
+ computed: {
234
+ metertypes () {
235
+ return [{label: ' 全部 ', value: ''}, ...this.$appdata.getParam('气表类型')]
236
+ },
237
+ chargetype () {
238
+ return [{label: ' 全部 ', value: ''}, ...this.$appdata.getParam('补气类型')]
239
+ }
240
+ }
241
+ }
242
+ </script>
243
+ <style scoped>
244
+ .noborder{
245
+ border: none;
246
+ }
247
+ .fontSize{
248
+ font-size: 13px;
249
+ }
250
+ </style>
@@ -0,0 +1,282 @@
1
+ <template>
2
+ <div id="unit" class="flex-row">
3
+ <div class="basic-main" @keyup.enter="search">
4
+ <div class="flex">
5
+ <criteria-paged :model="model" v-ref:paged>
6
+ <criteria partial='criteria' @condition-changed='$parent.selfSearch' v-ref:cri>
7
+ <div novalidate class="form-horizontal select-overspread container-fluid auto" partial>
8
+ <div class="row">
9
+ <res-select-group :show-component="$parent.$parent.resshow" :initres="$parent.$parent.initres"
10
+ :cascade=true @re-res="$parent.$parent.getRes" v-ref:sel></res-select-group>
11
+ <div class="col-sm-2 form-group" >
12
+ <label for="startDate" class="font_normal_body" title="开始日期">开始时间</label>
13
+ <datepicker id="startDate" placeholder="开始日期" style="width:60%"
14
+ v-model="model.startDate"
15
+ :value.sync="model.startDate"
16
+ :format="'yyyy-MM-dd'"
17
+ :show-reset-button="true"
18
+ >
19
+ </datepicker>
20
+ </div>
21
+ <div class="col-sm-2 form-group" >
22
+ <label for="endDate" class="font_normal_body" title="结束日期">结束时间</label>
23
+ <datepicker id="endDate" placeholder="结束日期" style="width:60%"
24
+ v-model="model.endDate"
25
+ :value.sync="model.endDate"
26
+ :format="'yyyy-MM-dd'"
27
+ :show-reset-button="true"
28
+ >
29
+ </datepicker>
30
+ </div>
31
+
32
+ <div class="span" style="float:right;">
33
+ <button class="button_search button_spacing" @click="search()">查询</button>
34
+ <button class="button_clear button_spacing" @click="$parent.$parent.clear()">清空</button>
35
+
36
+ <button class="button_clear button_spacing" style="margin-top: 10px;background-color: #6aa6e2;" @click="$parent.$parent.downloadFiles()">导出</button>
37
+ <div style="float: right" class="button_spacing"
38
+ :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
39
+ @click="$parent.$parent.hidden()"></div>
40
+
41
+ </div>
42
+ </div>
43
+ <div class="row" v-show="$parent.$parent.criteriaShow">
44
+ </div>
45
+ </div>
46
+ </criteria>
47
+
48
+ <data-grid :model="model" partial='list' class="list_area table_sy" style="height: 95%" v-ref:grid>
49
+ <template partial='head'>
50
+ <tr>
51
+ <th colspan="4" style="text-align: center;"><nobr>壁挂炉</nobr></th>
52
+ <th colspan="4" style="text-align: center;"><nobr>门面房</nobr></th>
53
+ <th colspan="3" style="text-align: center;"><nobr>三项强制措施</nobr></th>
54
+ <th colspan="1" style="text-align: center;"><nobr>欠费户数</nobr></th>
55
+ <th colspan="2" style="text-align: center;"><nobr></nobr></th>
56
+ </tr>
57
+ <tr>
58
+ <th style="text-align: center;">
59
+ <nobr>膜式表</nobr>
60
+ </th>
61
+ <th style="text-align: center;">
62
+ <nobr>卡表</nobr>
63
+ </th>
64
+ <th style="text-align: center;">
65
+ <nobr>金卡物联网表</nobr>
66
+ </th>
67
+ <th style="text-align: center;">
68
+ <nobr>新天物联网表</nobr>
69
+ </th>
70
+ <th style="text-align: center;">
71
+ <nobr>膜式表</nobr>
72
+ </th>
73
+ <th style="text-align: center;">
74
+ <nobr>卡表</nobr>
75
+ </th>
76
+ <th style="text-align: center;">
77
+ <nobr>金卡网联表</nobr>
78
+ </th>
79
+ <th style="text-align: center;">
80
+ <nobr>新天物联网表</nobr>
81
+ </th>
82
+ <th style="text-align: center;">
83
+ <nobr>自闭阀已装</nobr>
84
+ </th>
85
+ <th style="text-align: center;">
86
+ <nobr>不锈钢波纹软管已装</nobr>
87
+ </th>
88
+ <th style="text-align: center;">
89
+ <nobr>带熄火保护灶具</nobr>
90
+ </th>
91
+ <th style="text-align: center;">
92
+ <nobr>膜式表</nobr>
93
+ </th>
94
+ <th style="text-align: center;">
95
+ <nobr>长期不用停用数量(月)</nobr>
96
+ </th>
97
+ <th style="text-align: center;">
98
+ <nobr>当月用气量</nobr>
99
+ </th>
100
+ </tr>
101
+ </template>
102
+ <template partial='body'>
103
+ <tr style="position: relative" class="table-bordered">
104
+ <td style="text-align: center;">{{ row.gbl_machine }}</td>
105
+ <td style="text-align: center;">{{ row.gbl_card }}</td>
106
+ <td style="text-align: center;">{{ row.gbl_xt }}</td>
107
+ <td style="text-align: center;">{{ row.gbl_jk }}</td>
108
+ <td style="text-align: center;">{{ row.sy_machine }}</td>
109
+ <td style="text-align: center;">{{ row.sy_card }}</td>
110
+ <td style="text-align: center;">{{ row.sy_xt }}</td>
111
+ <td style="text-align: center;">{{ row.sy_jk }}</td>
112
+ <td style="text-align: center;">{{ row.force_zbf }}</td>
113
+ <td style="text-align: center;">{{ row.force_bwg }}</td>
114
+ <td style="text-align: center;">{{ row.force_zj }}</td>
115
+ <td style="text-align: center;">{{ row.owenum }}</td>
116
+ <td style="text-align: center;">{{ row.unusenum }}</td>
117
+ <td style="text-align: center;">{{ row.f_oughtamount }}</td>
118
+
119
+ </tr>
120
+ </template>
121
+ <template partial='foot'></template>
122
+ </data-grid>
123
+ </criteria-paged>
124
+ </div>
125
+ </div>
126
+ </div>
127
+ </template>
128
+
129
+ <script>
130
+ import {HttpResetClass, PagedList} from 'vue-client'
131
+
132
+ let readySomething = async function (self) {
133
+ await self.$MagLoadParams.loadParam()
134
+ self.initmeterbook()
135
+ }
136
+ export default {
137
+ props: ['data'],
138
+ title: '居民用户各项数据统计表(月报)',
139
+ data () {
140
+ return {
141
+ model: new PagedList('rs/sql/YCMonthSummary', 50, {
142
+ startDate: 'this.model.startDate',
143
+ endDate: 'this.model.endDate'
144
+ }),
145
+ years:[],
146
+ other: [],
147
+ orgCondtionStr: '',
148
+ resshow: ['company'],
149
+ initres: {
150
+ org: [this.$login.f.orgid]
151
+ },
152
+ meterbrands: [],
153
+ meterbooks:[],
154
+ gasproperties:[],
155
+ inputtores: [{label: '全部',value: ''}],
156
+ criteriaShow: false,
157
+ condition: '',
158
+ //小区
159
+ residentialArea: []
160
+ }
161
+ },
162
+ ready () {
163
+ let year = new Date().getFullYear()
164
+ this.$refs.paged.$refs.cri.model.searchyear = year
165
+ this.$refs.paged.$refs.cri.model.compareyear = year-1
166
+ this.getinputtores()
167
+ this.getaddress()
168
+ readySomething(this).then(() => {
169
+ this.$emit('ready')
170
+ }).catch((error) => {
171
+ this.$emit('error', error)
172
+ })
173
+ },
174
+ methods: {
175
+ async initmeterbook(){
176
+ this.meterbooks = [{label: '全部', value: ''}, ...this.$GetSaleParam.getMeterBooks()]
177
+ },
178
+ async getaddress(){
179
+ let HttpReset = new HttpResetClass()
180
+ var data = await HttpReset.load('POST', 'rs/sql/manage_getarealist', {
181
+ data: {
182
+ condition: `1=1 and s.f_orgid = '${this.$login.f.orgid}'`
183
+ }
184
+ }, {resolveMsg: null, rejectMsg: '获取小区失败!'})
185
+ let house = [{label: '全部', value: ''}]
186
+ for (let row of data.data){
187
+ house.push({label: row.f_residential_area, value: row.f_residential_area})
188
+ }
189
+ this.residentialArea = house
190
+ },
191
+ async getinputtores () {
192
+ // 获取抄表员
193
+ let rs = []
194
+ if (this.$login.f.f_gasman.length > 0) {
195
+ for (let i = 0; i < this.$login.f.f_gasman.length; i++) {
196
+ let temp = {
197
+ label: this.$login.f.f_gasman[i].name,
198
+ value: this.$login.f.f_gasman[i].name
199
+ }
200
+ rs.push(temp)
201
+ }
202
+ }
203
+ this.inputtores = [{label: '全部', value: ''}, ...rs]
204
+ },
205
+ cancel () {
206
+ this.show = false
207
+ },
208
+ userTypeChange () {
209
+ this.gasproperties = []
210
+ if (this.$refs.paged.$refs.cri.model !== null) {
211
+ this.$refs.paged.$refs.cri.model.f_gasproperties = []
212
+ this.gasproperties = this.$appdata.getParam('用气性质')
213
+ } else {
214
+ this.gasproperties = [{label: '全部', value: ''}]
215
+ }
216
+ },
217
+ initParams () {
218
+ // 初始化气表品牌
219
+ let brandArr = []
220
+ this.$MagGetSaleParam.getGasbrand().forEach((item) => {
221
+ let temp = {}
222
+ temp.label = item.label
223
+ temp.value = item.value.f_meter_brand
224
+ brandArr.push(temp)
225
+ })
226
+ this.meterbrands = [{label: '全部', value: ''}, ...brandArr]
227
+ //初始化气表价格
228
+ this.prices = this.$MagGetSaleParam.getPrices()
229
+ },
230
+ search () {
231
+ this.$refs.paged.$refs.cri.search()
232
+ },
233
+ selfSearch (args) {
234
+ let f_orgstr = this.orgCondtionStr
235
+ args.condition = `${args.condition} ` + f_orgstr
236
+ this.condition = args.condition
237
+ this.model.search(args.condition, args.model)
238
+ },
239
+ clear () {
240
+ Object.keys(this.$refs.paged.$refs.cri.model).forEach((key) => {
241
+ this.$refs.paged.$refs.cri.model[key] = []
242
+ })
243
+ },
244
+ show () {
245
+ this.criteriaShow = true
246
+ },
247
+ hidden () {
248
+ this.criteriaShow = !this.criteriaShow
249
+ },
250
+ async getRes (condition, obj) {
251
+ this.orgCondtionStr = condition
252
+ this.orgname = obj.orgnames[0]
253
+ },
254
+ },
255
+ events: {},
256
+ watch: {},
257
+ computed: {
258
+ getfield () {
259
+ return {
260
+
261
+ }
262
+ },
263
+ getCondition () {
264
+ return {
265
+ startDate: this.$refs.paged.$refs.cri.model.startDate,
266
+ endDate: this.$refs.paged.$refs.cri.model.endDate,
267
+ condition: this.condition
268
+ }
269
+ },
270
+ usertypes () {
271
+ return [{label: ' 全部 ', value: ''}, ...this.$appdata.getParam('用户类型')]
272
+ },
273
+ meterStyle () {
274
+ return [{label: ' 全部 ', value: ''}, ...this.$appdata.getParam('燃气表型号')]
275
+ },
276
+
277
+
278
+
279
+ }
280
+ }
281
+ </script>
282
+