sale-client 3.5.69 → 3.5.71

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,164 +1,164 @@
1
- var express = require('express')
2
- var webpack = require('webpack')
3
- var config = require('./webpack.dev.conf')
4
- var proxyMiddleware = require('http-proxy-middleware')
5
- // var httpProxy = require('http-proxy')
6
-
7
- var app = express()
8
- var compiler = webpack(config)
9
- // var proxy = httpProxy.createProxyServer()
10
-
11
- // Define HTTP proxies to your custom API backend
12
- // https://github.com/chimurai/http-proxy-middleware
13
- var bendi = 'http://121.36.106.17:8400', bendi1 = 'http://121.36.106.17:8400/'
14
- // 公司测试服务
15
- var fuwu = 'http://121.36.106.17:8400'
16
- // var fuwu = 'http://121.36.106.17:8400/'
17
- // 铜川正式
18
- // var fuwu = 'http://61.134.55.234:9999/'
19
- // 铜川测试
20
- // var fuwu = 'http://61.134.55.234:9999/'
21
- // var fuwu = 'http://60.222.250.39:8300/'
22
- // 韶关
23
- // var fuwu = 'http://119.146.1.106:8300/'
24
- // 巩义测试服务
25
- // var fuwu = 'http://192.168.0.227:8400'
26
- // 燎原测试服务
27
- // var fuwu = 'http://121.41.19.238:8400 '
28
- // var fuwu = 'http://121.41.19.238:9001/'
29
-
30
- // var fuwu = 'http://139.214.92.34:8301/'
31
-
32
- var proxyTable = {
33
- '/rs/logic/saleExport': {
34
- target: fuwu
35
- },
36
- '/rs/logic/saleGetExportProgress': {
37
- target: fuwu
38
- },
39
- '/rs/file': {
40
- target: fuwu
41
- },
42
- '/files': {
43
- target: fuwu
44
- },
45
- // 查找资源服务数据
46
- '/rs/search': {
47
- target: fuwu
48
- },
49
- // 查找资源服务数据
50
- '/rs/logic/getLogin': {
51
- target: fuwu
52
- },
53
- // 查找资源服务数据
54
- '/rs/logic/getInitData': {
55
- target: fuwu
56
- },
57
- '/rs/logic/getSaleInitData': {
58
- target: fuwu
59
- },
60
- '/invoice': {
61
- target: fuwu
62
- },
63
- // 用户登录服务地址
64
- '/rs/user': {
65
- target: fuwu
66
- },
67
- '/rs/path/getParams': {
68
- target: fuwu
69
- },
70
- '/rs/data': {
71
- target: fuwu
72
- },
73
- '/rs/license': {
74
- target: fuwu
75
- },
76
- '/rs/db': {
77
- target: fuwu
78
- },
79
- '/excel': {
80
- target: fuwu
81
- },
82
- '/rs/config': {
83
- target: fuwu
84
- },
85
- '/rs/sql/getLicenseById': {
86
- target: fuwu
87
- },
88
- '/rs/sql/manage_getarealist': {
89
- target: fuwu
90
- },
91
- '/rs/sql/manage_getstreetlist': {
92
- target: fuwu
93
- },
94
- '/rs/report': {
95
- target: 'http://121.36.106.17:8400/'
96
- },
97
- '/rs/vue': {
98
- target: fuwu
99
- },
100
- '/webmeter': {
101
- target: 'http://192.168.50.4:8450'
102
- },
103
- '/rs': {
104
- // target: 'http://192.168.30.63:8081/'
105
- // target: 'http://121.36.106.17:8400/'
106
- target: fuwu
107
- }
108
- }
109
-
110
- var devMiddleware = require('webpack-dev-middleware')(compiler, {
111
- publicPath: config.output.publicPath,
112
- stats: {
113
- colors: true,
114
- chunks: false
115
- }
116
- })
117
-
118
- var hotMiddleware = require('webpack-hot-middleware')(compiler)
119
- // force page reload when html-webpack-plugin template changes
120
- compiler.plugin('compilation', function (compilation) {
121
- compilation.plugin('html-webpack-plugin-after-emit', function (data, cb) {
122
- hotMiddleware.publish({action: 'reload'})
123
- cb()
124
- })
125
- })
126
-
127
- // proxy api requests
128
- Object.keys(proxyTable).forEach(function (context) {
129
- var options = proxyTable[context]
130
- if (typeof options === 'string') {
131
- options = {target: options}
132
- }
133
- app.use(proxyMiddleware(context, options))
134
- })
135
-
136
- // handle fallback for HTML5 history API
137
- app.use(require('connect-history-api-fallback')())
138
- // app.use(function (req, res, next) {
139
- // res.header('Access-Control-Allow-Origin', '*')
140
- // res.header('Access-Control-Allow-Headers', 'X-Requested-With')
141
- // res.header('Access-Control-Allow-Methods', 'PUT, POST, GET,DELETE, OPTIONS')
142
- // res.header('X-Powered-By', '3,2,1')
143
- // res.header('Access-Control-Allow-Credentials', 'true')
144
- // res.header('Content-Type', 'application/json;charset=utf-8')
145
- // next()
146
- // })
147
-
148
- // serve webpack bundle output
149
- app.use(devMiddleware)
150
-
151
- // enable hot-reload and state-preserving
152
- // compilation error display
153
- app.use(hotMiddleware)
154
-
155
- // serve pure static assets
156
- app.use('/static', express.static('./static'))
157
-
158
- module.exports = app.listen(8085, function (err) {
159
- if (err) {
160
- console.log(err)
161
- return
162
- }
163
- console.log('Listening at http://localhost:8089')
164
- })
1
+ var express = require('express')
2
+ var webpack = require('webpack')
3
+ var config = require('./webpack.dev.conf')
4
+ var proxyMiddleware = require('http-proxy-middleware')
5
+ // var httpProxy = require('http-proxy')
6
+
7
+ var app = express()
8
+ var compiler = webpack(config)
9
+ // var proxy = httpProxy.createProxyServer()
10
+
11
+ // Define HTTP proxies to your custom API backend
12
+ // https://github.com/chimurai/http-proxy-middleware
13
+ var bendi = 'http://121.36.106.17:8400', bendi1 = 'http://121.36.106.17:8400/'
14
+ // 公司测试服务
15
+ var fuwu = 'http://117.33.181.102:8400/'
16
+ // var fuwu = 'http://121.36.106.17:8400/'
17
+ // 铜川正式
18
+ // var fuwu = 'http://61.134.55.234:9999/'
19
+ // 铜川测试
20
+ // var fuwu = 'http://61.134.55.234:9999/'
21
+ // var fuwu = 'http://60.222.250.39:8300/'
22
+ // 韶关
23
+ // var fuwu = 'http://119.146.1.106:8300/'
24
+ // 巩义测试服务
25
+ // var fuwu = 'http://192.168.0.227:8400'
26
+ // 燎原测试服务
27
+ // var fuwu = 'http://121.41.19.238:8400 '
28
+ // var fuwu = 'http://121.41.19.238:9001/'
29
+
30
+ // var fuwu = 'http://139.214.92.34:8301/'
31
+
32
+ var proxyTable = {
33
+ '/rs/logic/saleExport': {
34
+ target: fuwu
35
+ },
36
+ '/rs/logic/saleGetExportProgress': {
37
+ target: fuwu
38
+ },
39
+ '/rs/file': {
40
+ target: fuwu
41
+ },
42
+ '/files': {
43
+ target: fuwu
44
+ },
45
+ // 查找资源服务数据
46
+ '/rs/search': {
47
+ target: fuwu
48
+ },
49
+ // 查找资源服务数据
50
+ '/rs/logic/getLogin': {
51
+ target: fuwu
52
+ },
53
+ // 查找资源服务数据
54
+ '/rs/logic/getInitData': {
55
+ target: fuwu
56
+ },
57
+ '/rs/logic/getSaleInitData': {
58
+ target: fuwu
59
+ },
60
+ '/invoice': {
61
+ target: fuwu
62
+ },
63
+ // 用户登录服务地址
64
+ '/rs/user': {
65
+ target: fuwu
66
+ },
67
+ '/rs/path/getParams': {
68
+ target: fuwu
69
+ },
70
+ '/rs/data': {
71
+ target: fuwu
72
+ },
73
+ '/rs/license': {
74
+ target: fuwu
75
+ },
76
+ '/rs/db': {
77
+ target: fuwu
78
+ },
79
+ '/excel': {
80
+ target: fuwu
81
+ },
82
+ '/rs/config': {
83
+ target: fuwu
84
+ },
85
+ '/rs/sql/getLicenseById': {
86
+ target: fuwu
87
+ },
88
+ '/rs/sql/manage_getarealist': {
89
+ target: fuwu
90
+ },
91
+ '/rs/sql/manage_getstreetlist': {
92
+ target: fuwu
93
+ },
94
+ '/rs/report': {
95
+ target: 'http://117.33.181.102:8400/'
96
+ },
97
+ '/rs/vue': {
98
+ target: fuwu
99
+ },
100
+ '/webmeter': {
101
+ target: 'http://39.108.82.124:8400/'
102
+ },
103
+ '/rs': {
104
+ // target: 'http://192.168.30.63:8081/'
105
+ // target: 'http://121.36.106.17:8400/'
106
+ target: fuwu
107
+ }
108
+ }
109
+
110
+ var devMiddleware = require('webpack-dev-middleware')(compiler, {
111
+ publicPath: config.output.publicPath,
112
+ stats: {
113
+ colors: true,
114
+ chunks: false
115
+ }
116
+ })
117
+
118
+ var hotMiddleware = require('webpack-hot-middleware')(compiler)
119
+ // force page reload when html-webpack-plugin template changes
120
+ compiler.plugin('compilation', function (compilation) {
121
+ compilation.plugin('html-webpack-plugin-after-emit', function (data, cb) {
122
+ hotMiddleware.publish({action: 'reload'})
123
+ cb()
124
+ })
125
+ })
126
+
127
+ // proxy api requests
128
+ Object.keys(proxyTable).forEach(function (context) {
129
+ var options = proxyTable[context]
130
+ if (typeof options === 'string') {
131
+ options = {target: options}
132
+ }
133
+ app.use(proxyMiddleware(context, options))
134
+ })
135
+
136
+ // handle fallback for HTML5 history API
137
+ app.use(require('connect-history-api-fallback')())
138
+ // app.use(function (req, res, next) {
139
+ // res.header('Access-Control-Allow-Origin', '*')
140
+ // res.header('Access-Control-Allow-Headers', 'X-Requested-With')
141
+ // res.header('Access-Control-Allow-Methods', 'PUT, POST, GET,DELETE, OPTIONS')
142
+ // res.header('X-Powered-By', '3,2,1')
143
+ // res.header('Access-Control-Allow-Credentials', 'true')
144
+ // res.header('Content-Type', 'application/json;charset=utf-8')
145
+ // next()
146
+ // })
147
+
148
+ // serve webpack bundle output
149
+ app.use(devMiddleware)
150
+
151
+ // enable hot-reload and state-preserving
152
+ // compilation error display
153
+ app.use(hotMiddleware)
154
+
155
+ // serve pure static assets
156
+ app.use('/static', express.static('./static'))
157
+
158
+ module.exports = app.listen(8085, function (err) {
159
+ if (err) {
160
+ console.log(err)
161
+ return
162
+ }
163
+ console.log('Listening at http://localhost:8089')
164
+ })
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sale-client",
3
- "version": "3.5.69",
3
+ "version": "3.5.71",
4
4
  "description": "收费模块前台组件",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
@@ -220,8 +220,8 @@
220
220
  // this.typenumberList = this.$appdata.getParam(val)
221
221
  // },
222
222
  selectoperator () {
223
- let f_operator = this.model.operator
224
- console.log('处理签的this.f_operatorid', this.f_operatorid)
223
+ let f_operator = this.model.f_operator
224
+ console.log('处理签的this.model.f_operatorid', this.model.f_operator)
225
225
  let http = new HttpResetClass()
226
226
  http.load('POST', 'rs/logic/findOperator',
227
227
  {f_operator: f_operator},
@@ -230,10 +230,10 @@
230
230
  if(res.data.length>0){
231
231
  this.model.f_operatorid = res.data[0].id
232
232
  }else{
233
- this.model.operator=''
233
+ this.model.f_operator=''
234
234
  this.$showAlert('操作员信息未找到,请在参数管理进行添加','warning',2000)
235
235
  }
236
- console.log('this.f_operatorid', this.f_operatorid)
236
+ console.log('this.model.f_operatorid', this.model.f_operatorid)
237
237
  })
238
238
  },
239
239
  editclose () {
@@ -178,6 +178,7 @@
178
178
 
179
179
  import {HttpResetClass} from 'vue-client'
180
180
  import CardService from './CardService'
181
+ import PrintBill from './PrintBill'
181
182
 
182
183
  let preamountGen = async function (self) {
183
184
  let calFee = (self.model.f_totalcost - 0) + (self.model.f_fill_money - 0)
@@ -329,6 +330,7 @@ let preamountGen = async function (self) {
329
330
 
330
331
  export default {
331
332
  title: '换表补气',
333
+ component: {PrintBill},
332
334
  data () {
333
335
  return {
334
336
  config: {
@@ -154,6 +154,7 @@ let cardChargeCancelGen = async function (self) {
154
154
  self.row.cardInfo = self.cardData
155
155
  self.model = Object.assign({}, self.model, self.correctModel)
156
156
  let res = null
157
+ debugger
157
158
  if (self.xmodel.id) {
158
159
  res = await CardService.cardAndFillGasCancel(self.model, self.xmodel, self.row)
159
160
  } else {
@@ -401,6 +401,7 @@ let sellCancelGen = async function (model, row) {
401
401
  if (!cardParams || !result || cardRes.data.Err || cardRes.data.Exception) {
402
402
  await rollbackGen(result, model, row)
403
403
  } else {
404
+ await modify(row.f_userfiles_id, '0', '2')
404
405
  Vue.showAlert('撤销成功', 'success', 2000)
405
406
  return result
406
407
  }
@@ -38,12 +38,14 @@
38
38
  let temp = {
39
39
  reprint: "'正常'",
40
40
  operator: `'${self.$login.f.name}'`,
41
- condition: self.data.id
41
+ condition: self.data.id,
42
+ fillgasid: ''
42
43
  }
43
44
  if (self.data.fillgasid) {
44
- temp.fillgasid = `"${self.data.fillgasid}"`
45
+ temp.fillgasid = `${self.data.fillgasid}`
45
46
  }
46
47
  console.log('self.billData.url:', self.billData.url)
48
+ debugger
47
49
  self.bill = new DataModel(self.billData.url, temp)
48
50
  await self.bill.search(self.data.id)
49
51
  // 获取发票号
@@ -339,6 +339,7 @@ export default {
339
339
  if (this.fileSaveData.userinfo.f_userinfo_id) {
340
340
  if (this.row.f_user_state === '预备' && this.fileSaveData.userinfo.f_user_state === '正常') {
341
341
  this.fileSaveData.modifyReason = this.reason = '建档(档案信息完善)'
342
+ this.fileSaveData.userinfo.f_createfile_person = this.$login.f.name
342
343
  } else {
343
344
  this.reason = '其他'
344
345
  this.fileSaveData.modifyReason = ''
@@ -0,0 +1,80 @@
1
+ <template>
2
+ <div id="unit" class="flex-row">
3
+ <div :class="{'basic-main': !iseditmetetinfo,'binary-left': iseditmetetinfo}" :style="{width:iseditmetetinfo ? '50%' : '100%'}">
4
+ <web-meter-list style="width:auto;" :styles="iseditmetetinfo?'form-group col-sm-3':'form-group col-sm-2'" :showfields="iseditmetetinfo?false:true" v-ref:list @dblclick="showeditinfo"></web-meter-list>
5
+ </div>
6
+ <div class="binary-right" style="width:50%" v-if="iseditmetetinfo" >
7
+ <edit-meter-info :oldmeter="row" v-if="ismeterinfo" :f_filialeid="f_filialeid" @close="closeedit" style="overflow-y: auto;"></edit-meter-info>
8
+
9
+ <use-web-meter :meterinfos="meterinfos" v-if="isUseMeter" @close="closeedit" style="overflow-y: auto;"></use-web-meter>
10
+ <!--<ul class="nav nav-tabs">-->
11
+ <!--<li class="active"><a>操作历史</a></li>-->
12
+ <!--</ul>-->
13
+ <!--<meter-history :id="row.id" @close="closeedit" style="height:30%"></meter-history>-->
14
+ </div>
15
+ </div>
16
+ </template>
17
+ <script>
18
+ import { PagedList } from 'vue-client'
19
+ import * as WebmeterUtil from '../../components/WebmeterUtil'
20
+ import * as webMeterList from './WebMeterList'
21
+ import * as meterHistory from '../../components/webMeter/webInfo/MeterHistory'
22
+ import Vue from 'vue'
23
+
24
+ export default {
25
+ components: {webMeterList, meterHistory},
26
+ title: '表计信息',
27
+ data () {
28
+ return {
29
+ model: new PagedList('rs/sql/singleTable_OrderBy', 20, {items: '"*"', tablename: '"t_meterinfo"', orderitem: '"id"'}),
30
+ f_filialeid: '',
31
+ iseditmetetinfo: false,
32
+ row: {},
33
+ criteriaShow: false,
34
+ show: false,
35
+ isUseMeter: false,
36
+ meterinfos: [],
37
+ ismeterinfo: false
38
+ }
39
+ },
40
+ ready () {
41
+
42
+ },
43
+ methods: {
44
+ showeditinfo (obj) {
45
+ console.log('====================obj')
46
+ if (obj) {
47
+ this.row = obj
48
+ this.iseditmetetinfo = true
49
+ this.ismeterinfo = true
50
+ this.isUseMeter = false
51
+ }
52
+ },
53
+ hidden () {
54
+ this.criteriaShow = !this.criteriaShow
55
+ },
56
+ clearmsg () {
57
+ this.$refs.paged.$refs.criteria.model = {}
58
+ },
59
+ closeedit () {
60
+ this.iseditmetetinfo = false
61
+ this.isUseMeter = false
62
+ this.ismeterinfo = false
63
+ this.$refs.list.search()
64
+ }
65
+ }
66
+ }
67
+ </script>
68
+ <style>
69
+ .form-input-group label {
70
+ text-align: right;
71
+ width: auto;
72
+ }
73
+ .datapanel {
74
+ color: #333;
75
+ background-color: white;
76
+ box-shadow: darkgrey 0.5px 0.5px 0.5px 0.5px ;
77
+ padding: 10px 30px 10px 30px;
78
+ border-radius:15px;
79
+ }
80
+ </style>
@@ -0,0 +1,437 @@
1
+ <template style="position: absolute;">
2
+ <div id="WebMeterList">
3
+ <criteria-paged :model="model" v-ref:paged>
4
+ <criteria partial='criteria' v-ref:criteria @condition-changed='$parent.selfSearch'>
5
+ <div novalidate class="form-horizontal select-overspread container-fluid auto" partial>
6
+ <div class="row" width="100%">
7
+ <div :class="$parent.$parent.styles" >
8
+ <label class=" font_normal_body" >&nbsp;&nbsp;&nbsp;表钢号</label>
9
+ <input type="text" class="input_search" style="width:60%" v-model="model.f_meternumber"
10
+ condition="f_meternumber='{}'" placeholder="表钢号" >
11
+ </div>
12
+ <div class="row">
13
+
14
+
15
+ <div style="float:right">
16
+ <button class="button_search" @click="search()" v-el:cba>查询</button>
17
+ <button class="button_search" @click="$parent.$parent.addmeter()">新增</button>
18
+ <button class="button_search" @click="$parent.$parent.useMeter()">领用</button>
19
+ <button class="button_export" @click="$parent.$parent.importFile">导入</button>
20
+ <export-excel :data="$parent.$parent.getCondition" :field="$parent.$parent.getfield" :choose-col="true" v-ref:excel attach="webmeterlist"
21
+ sqlurl="rs/logic/saleExport" sql-name="webMeterInfo" template-name='表计信息导出'>
22
+ </export-excel>
23
+ <button class="button_search" style="width: 90px" @click="$parent.$parent.downloadFiles()">模板下载</button>
24
+ <button class="button_search" @click="$parent.$parent.clearmsg">清空</button>
25
+ <div style="float: right" class="button_spacing" :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}" @click="$parent.$parent.hidden()"></div>
26
+ </div>
27
+ </div>
28
+ <div class="row" v-show="$parent.$parent.criteriaShow">
29
+ <div :class="$parent.$parent.styles" >
30
+ <label class=" font_normal_body" >表计电话</label>
31
+ <input type="text" class="input_search" style="width:60%" v-model="model.f_meter_phone"
32
+ condition="f_meter_phone='{}'" placeholder="表计电话">
33
+ </div>
34
+ <div :class="$parent.$parent.styles" >
35
+ <label class=" font_normal_body" >&nbsp;&nbsp;&nbsp;IMEI码</label>
36
+ <input type="text" class="input_search" style="width:60%" v-model="model.f_imei"
37
+ condition="f_imei='{}'" placeholder="IMEI码">
38
+ </div>
39
+ <res-select-group :show-component="['company','department','operator']" :initres="$parent.$parent.initres" @re-res="$parent.$parent.getRes" v-ref:sel></res-select-group>
40
+ <!--<div :class="$parent.$parent.styles">-->
41
+ <!--<label class="font_normal_body">组织机构</label>-->
42
+ <!--<res-select restype='organization'-->
43
+ <!--:is-mul="false"-->
44
+ <!--:initresid="$parent.$parent.curorgid"-->
45
+ <!--@res-select="$parent.$parent.getorgCur">-->
46
+ <!--</res-select>-->
47
+ <!--</div>-->
48
+ <div :class="$parent.$parent.styles" >
49
+ <label class="font_normal_body">气表品牌</label>
50
+ <v-select
51
+ placeholder='气表品牌'
52
+ :value.sync="model.f_meter_brand"
53
+ style="width:60%"
54
+ v-model="model.f_meter_brand"
55
+ :options='$parent.$parent.meterbrand'
56
+ close-on-select
57
+ condition="f_meter_brand='{}'">
58
+ </v-select>
59
+ </div>
60
+ <div :class="$parent.$parent.styles" >
61
+ <label class="font_normal_body">安装状态</label>
62
+ <v-select
63
+ placeholder='安装状态'
64
+ :value.sync="model.aa"
65
+ style="width:60%"
66
+ v-model="model.aa"
67
+ :options='$parent.$parent.azstate'
68
+ close-on-select
69
+ condition="aa='{}'">
70
+ </v-select>
71
+ </div>
72
+ <div :class="$parent.$parent.styles" >
73
+ <label class=" font_normal_body" >&nbsp;&nbsp;&nbsp;批次&nbsp;&nbsp;&nbsp;</label>
74
+ <input type="text" class="input_search" style="width:60%" v-model="model.f_batch_number"
75
+ condition="f_batch_number like '%{}%'" placeholder="批次">
76
+ </div>
77
+ <div :class="$parent.$parent.styles" >
78
+ <label class="font_normal_body">是否领用</label>
79
+ <v-select
80
+ placeholder='是否领用'
81
+ :value.sync="model.f_is_receive"
82
+ style="width:60%"
83
+ v-model="model.f_is_receive"
84
+ :options='$parent.$parent.isreceived'
85
+ close-on-select
86
+ condition="f_is_receive='{}'">
87
+ </v-select>
88
+ </div>
89
+ <div :class="$parent.$parent.styles" >
90
+ <label class=" font_normal_body" >&nbsp;&nbsp;&nbsp;领用人</label>
91
+ <input type="text" class="input_search" style="width:60%" v-model="model.f_receive_unit"
92
+ condition="f_receive_unit like '%{}%'" placeholder="领用人">
93
+ </div>
94
+ <div :class="$parent.$parent.styles" >
95
+ <label class=" font_normal_body" >领用电话</label>
96
+ <input type="text" class="input_search" style="width:60%" v-model="model.f_receive_phone"
97
+ condition="f_receive_phone like '%{}%'" placeholder="领用电话">
98
+ </div>
99
+ <div :class="$parent.$parent.styles">
100
+ <label class="font_normal_body">领用日期</label>
101
+ <datepicker id="startDate" placeholder=""
102
+ v-model="model.f_start_date"
103
+ :value.sync="model.f_start_date"
104
+ :disabled-days-of-Week="[]"
105
+ style="width: 60%"
106
+ :format="'yyyy-MM-dd 00:00:00'"
107
+ condition="f_receive_date >= '{}'">
108
+ </datepicker>
109
+ </div>
110
+ <div :class="$parent.$parent.styles">
111
+ <label class="font_normal_body">&emsp;&emsp;至&emsp;</label>
112
+ <datepicker id="endDate" placeholder=""
113
+ v-model="model.f_end_date"
114
+ :value.sync="model.f_end_date"
115
+ style="width: 60%"
116
+ :disabled-days-of-Week="[]"
117
+ :format="'yyyy-MM-dd 23:59:59'"
118
+ condition="f_receive_date <= '{}'">
119
+ </datepicker>
120
+ </div>
121
+
122
+ </div>
123
+ </div>
124
+ </div>
125
+ </criteria>
126
+ <data-grid id="webmeterinfo" :model="model" class="list_area table_sy" partial='list' v-ref:grid>
127
+ <template partial='head'>
128
+ <tr>
129
+ <th>
130
+ <input type="checkbox" @click="$parent.$parent.$parent.addOrRemove()">
131
+ </th>
132
+ <th><nobr>序号</nobr></th>
133
+ <th><nobr>表号</nobr></th>
134
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>imei码</nobr></th>
135
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>imsi码</nobr></th>
136
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>批次</nobr></th>
137
+ <!-- <th><nobr>设备号</nobr></th>-->
138
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>表计电话</nobr></th>
139
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>表通道类型</nobr></th>
140
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>阀控标识</nobr></th>
141
+ <!-- <th><nobr>表通讯序号</nobr></th>-->
142
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>设备地址</nobr></th>
143
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>终端名称</nobr></th>
144
+ <!-- <th><nobr>厂商代码</nobr></th>-->
145
+ <th><nobr>状态</nobr></th>
146
+ <th><nobr>气表品牌</nobr></th>
147
+
148
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>设备号</nobr></th>
149
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>气表年限</nobr></th>
150
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>生产日期</nobr></th>
151
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>批次号</nobr></th>
152
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>气表厂家</nobr></th>
153
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>采购人</nobr></th>
154
+ <th v-if="$parent.$parent.$parent.showfields"><nobr>采购时间</nobr></th>
155
+ <th><nobr>是否领用</nobr></th>
156
+ <th><nobr>领用人</nobr></th>
157
+ <th><nobr>领用时间</nobr></th>
158
+ <th><nobr>领用电话</nobr></th>
159
+ </tr>
160
+ </template>
161
+ <template partial='body' >
162
+ <td style="text-align:center">
163
+ <input type="checkbox" v-model="$parent.$parent.$parent.$parent.meterinfos" :disabled="row.f_receive==='已领用'" :value="row" @click="$parent.$parent.$parent.checkboxMeter()" >
164
+ </td>
165
+ <td style="text-align: center;" >{{$index+1}}</td>
166
+ <td style="text-align: center" >{{row.f_meternumber}}</td>
167
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_imei}}</td>
168
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_imsi}}</td>
169
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_batch_number}}</td>
170
+ <!-- <td style="text-align: center" >{{row.f_device_id}}</td>-->
171
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_meter_phone}}</td>
172
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_iot_type}}</td>
173
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_valvemark}}</td>
174
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_device_address}}</td>
175
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_terminal_id}}</td>
176
+ <!-- <td style="text-align: center" >{{row.f_vender}}</td>-->
177
+
178
+ <td style="text-align: center" >{{row.aa}}</td>
179
+ <td style="text-align: center" >{{row.f_meter_brand}}</td>
180
+
181
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_device_id}}</td>
182
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_years}}</td>
183
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_manufacture_date}}</td>
184
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_batch_number}}</td>
185
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_manufacturers}}</td>
186
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_purchaser}}</td>
187
+ <td style="text-align: center" v-if="$parent.$parent.$parent.showfields">{{row.f_purchase_date}}</td>
188
+ <td style="text-align: center" >{{row.f_receive}}</td>
189
+ <td style="text-align: center" >{{row.f_receive_unit}}</td>
190
+ <td style="text-align: center" >{{row.f_receive_date}}</td>
191
+ <td style="text-align: center" >{{row.f_receive_date}}</td>
192
+
193
+
194
+ </template>
195
+ </data-grid>
196
+ </criteria-paged>
197
+ </div>
198
+ <modal :show.sync="show" width="500px" title="文件导入" v-ref:modal large backdrop="false">
199
+ <article slot="modal-body" class="modal-body">
200
+ <file-upload class="my-file-uploader " name="UploadFile" class="btn btn-success" style="border-radius: 2px;"
201
+ action="rs/file/uploadFile" tagname="导入表计" v-ref:file :headers="headers" multiple></file-upload>
202
+ </article>
203
+ <footer slot="modal-footer" class="modal-footer">
204
+ </footer>
205
+ </modal>
206
+ </template>
207
+ <script>
208
+ import { PagedList } from 'vue-client'
209
+ import * as WebmeterUtil from '../../components/WebmeterUtil'
210
+ import Vue from 'vue'
211
+
212
+ let readyGen = async function (self) {
213
+ await self.$LoadParams.loadParam()
214
+ self.initQueryParam()
215
+ // self.reflash()
216
+ }
217
+
218
+ export default {
219
+ title: '表计管理',
220
+ props:['showfields','styles'],
221
+ data () {
222
+ return {
223
+ getCondition: null,
224
+ getfield: null,
225
+ meterbrand: [],
226
+ azstate: [{label: '全部', value: ''}, {label: '已安装', value: '已安装'}, {label: '未安装', value: '未安装'}],
227
+ isreceived:[{label: '全部', value: ''}, {label: '已领用', value: '是'}, {label: '未领用', value: '否'}],
228
+ // curorgid: [this.$login.f.orgid],
229
+ orgCondtionStr: '',
230
+ // 公司下拉
231
+ initres: {
232
+ org: [],
233
+ dep: [],
234
+ user: []
235
+ },
236
+ model: new PagedList('rs/sql/webMeterInfo', 20, {items: '"*"', tablename: '"t_meterinfo"', orderitem: '"id"'}),
237
+ headers: {'username': Vue.$login.f.name, 'blodid': WebmeterUtil.guid()},
238
+ criteriaShow: false,
239
+ f_orgid: '',
240
+ show: false,
241
+ meterinfos: [],
242
+ isAddOrMove: false
243
+ }
244
+ },
245
+ ready () {
246
+ this.loadGetField()
247
+ this.search()
248
+ readyGen(this)
249
+ this.$parent.meterinfos = []
250
+ console.log('this', this)
251
+ this.$refs.paged.$refs.criteria.model.f_table_state = ['正常']
252
+ this.$refs.paged.$refs.criteria.search()
253
+ },
254
+
255
+ methods: {
256
+ async getRes (condition, obj) {
257
+ this.orgCondtionStr = condition
258
+ },
259
+ loadGetField () {
260
+ this.getfield = {
261
+ 'f_meternumber': '表号',
262
+ 'f_imei': 'imei码',
263
+ 'f_imsi': 'imsi码',
264
+ 'f_meter_phone': '表计电话',
265
+ 'f_iot_type': '表通道类型',
266
+ 'f_valvemark': '阀控标识',
267
+ 'f_device_address': '设备地址',
268
+ 'f_terminal_id': '终端名称',
269
+ 'aa': '状态',
270
+ 'f_meter_brand': '气表品牌',
271
+ 'f_device_id': '设备号',
272
+ 'f_years': '气表年限',
273
+ 'f_manufacture_date': '生产日期',
274
+ 'f_batch_number': '批次号',
275
+ 'f_manufacturers': '气表厂家',
276
+ 'f_purchaser': '采购人',
277
+ 'f_purchase_date': '采购时间',
278
+ 'f_receive': '是否领用',
279
+ 'f_receive_unit': '领用人',
280
+ 'f_receive_date': '领用时间',
281
+ }
282
+ },
283
+ downloadFiles(){
284
+ let downurl='rs/downloadfile/file?filename=表计导入模板';
285
+ this.$resetget(downurl,{}).then(res=>{
286
+ var link = document.createElement('a');
287
+ link.target="_blank"
288
+ link.href =downurl ;
289
+ link.setAttribute("download", "表计导入模板.xlsx"); //指定下载后的文件名,防跳转
290
+ document.body.appendChild(link);
291
+ link.click();
292
+ })
293
+ },
294
+ addOrRemove () {
295
+ this.$parent.meterinfos = []
296
+ if (this.isAddOrMove) {
297
+ this.$parent.meterinfos = []
298
+ } else {
299
+ this.model.rows.forEach((row) => {
300
+ if (row.f_receive !== '已领用') {
301
+ this.$parent.meterinfos.push(row)
302
+ }
303
+ })
304
+ }
305
+ this.isAddOrMove = !this.isAddOrMove
306
+ },
307
+ useMeter () {
308
+ console.log("meterinfos",this.$parent.meterinfos)
309
+ this.$parent.iseditmetetinfo = true
310
+ this.$parent.isUseMeter = true
311
+ this.$parent.ismeterinfo = false
312
+ console.log("1",this.$parent.iseditmetetinfo)
313
+ console.log("2",this.$parent.ismeterinfo)
314
+ console.log("3",this.$parent.isUseMeter)
315
+ },
316
+ checkboxMeter () {
317
+ console.log("这是当前页的meterinfos",this.meterinfos)
318
+ console.log("这是当前页的meterinfos",this.$parent.meterinfos)
319
+ },
320
+ initQueryParam () {
321
+ let arr = []
322
+ this.$GetSaleParam.getGasbrand().forEach((item) => {
323
+ let temp = {}
324
+ // if(item.value.f_meter_type==='物联网表'){
325
+ temp.label = item.label
326
+ temp.value = item.value.f_meter_brand
327
+ arr.push(temp)
328
+ // }
329
+ })
330
+ this.meterbrand = [{label: '全部', value: ''}, ...arr]
331
+ },
332
+ hidden () {
333
+ this.criteriaShow = !this.criteriaShow
334
+ },
335
+ addmeter () {
336
+ this.$parent.row = {}
337
+ this.$parent.iseditmetetinfo = true
338
+ this.$parent.ismeterinfo = true
339
+ this.$parent.isUseMeter = false
340
+ this.$parent.f_filialeids = this.f_filialeids
341
+ },
342
+ clearmsg () {
343
+ this.$refs.paged.$refs.criteria.model = {}
344
+ },
345
+ search () {
346
+ this.$refs.paged.$refs.criteria.search()
347
+ },
348
+ selfSearch (args) {
349
+ this.$parent.meterinfos = []
350
+ if (!this.f_orgid) {
351
+ this.f_orgid = this.$login.f.orgid
352
+ }
353
+ let f_orgstr = this.orgCondtionStr ? this.orgCondtionStr : "and f_filialeid in ('" + this.f_orgid + "')"
354
+ args.condition = `${args.condition} ` + f_orgstr
355
+ // if (this.f_orgid) {
356
+ // args.condition = `${args.condition} and f_filialeid in ${this.f_orgid}`
357
+ // }
358
+ this.getCondition = {condition: args.condition}
359
+ this.model.search(args.condition, args.model)
360
+ },
361
+
362
+ getorgCur (val) {
363
+ console.log('组织事件返回。。', val[0])
364
+ this.f_orgid = this.$login.convertToIn(val)
365
+ this.f_filialeids = val[0]
366
+ this.$parent.f_filialeid = val[0]
367
+ this.search()
368
+ },
369
+ importFile () {
370
+ this.show = true
371
+ }
372
+
373
+ },
374
+ events: {
375
+ onFileUpload: function (file, res) {
376
+ console.log(this.$login.f, '======')
377
+ console.log(res)
378
+
379
+ let data = {
380
+ tablename: 't_meterinfo',
381
+ filepath: res.f_downloadpath,
382
+ info: {
383
+ f_orgid: this.$login.f.orgid ? this.$login.f.orgid : '',
384
+ f_orgname: this.$login.f.orgs ? this.$login.f.orgs : '',
385
+ f_depid: this.$login.f.depids ? this.$login.f.depids : '',
386
+ f_depname: this.$login.f.deps ? this.$login.f.deps : '',
387
+ f_operator: this.$login.f.name,
388
+ f_operatorid: this.$login.f.id,
389
+ f_filialeid: this.f_orgid === '' ? this.$login.f.orgid : this.f_orgid.replace(/[^0-9]/ig, '')
390
+ }
391
+ }
392
+
393
+ console.log(data, '++++++++++++++++++++++++++')
394
+ this.$resetpost('rs/logic/iot_meterinfo_import', {data: data}, {resolveMsg: null, rejectMsg: '上传失败'}).then((res) => {
395
+ // window.location.href = '/excel/表具导入异常信息.txt';
396
+ let mes = '成功导入' + res.data.successnum + '条数据 '
397
+ if (res.data.successnum !== res.data.allnum) {
398
+ var link = document.createElement('a')
399
+ let path = '表具导入异常信息.txt'
400
+ // 本地
401
+ let pathName = 'http://' + location.host + '/excel/' + path
402
+ link.href = pathName
403
+ link.download = path
404
+ link.dispatchEvent(new MouseEvent('click'))
405
+ mes = mes + ',有 ' + (((res.data.allnum - 0) - (res.data.successnum - 0)) - 0) + ' 条数据导入失败,请确保气表品牌存在,且表号、IMEI号唯一,详细信息请查看表具导入异常信息.txt'
406
+ }
407
+ this.$showMessage(mes)
408
+ this.search()
409
+ })
410
+ }
411
+ }
412
+ }
413
+ </script>
414
+ <style lang="less">
415
+ #WebMeterList {
416
+ .form-input-group label {
417
+ text-align: right;
418
+ width: auto;
419
+ }
420
+ .datapanel {
421
+ color: #333;
422
+ background-color: white;
423
+ box-shadow: darkgrey 0.5px 0.5px 0.5px 0.5px ;
424
+ padding: 10px 30px 10px 30px;
425
+ border-radius:15px;
426
+ }
427
+ #webmeterinfo {
428
+ tr > td {
429
+ white-space: nowrap;
430
+ }
431
+ }
432
+ #vc-exportexcel-webmeterlist {
433
+ margin: 0;
434
+ }
435
+ }
436
+
437
+ </style>
@@ -1,6 +1,10 @@
1
1
  // 分公司特殊组件页面注册
2
+ import Vue from "vue";
3
+
2
4
  let specialComp = {
3
5
  // 售气收费 --收费gas-move
4
6
  'charge-manage': (resolve) => { require(['./ChargeManage'], resolve) },
7
+ // 表计管理
8
+ 'web-meter-info': (resolve) => { require(['./WebMeterInfo'], resolve) }
5
9
  }
6
10
  exports.specialComp = specialComp
package/src/main.js CHANGED
@@ -1,22 +1,22 @@
1
- import Vue from 'vue'
2
- import { all } from 'vue-client'
3
- import App from './App'
4
- import { system } from 'system-clients'
5
- import sale from './sale'
6
- import { address } from 'address-client'
7
- import { ldap } from 'ldap-clients'
8
- import VueClipboard from 'vue-clipboard2'
9
- Vue.use(VueClipboard)
10
- Vue.config.silent = true
11
-
12
- all()
13
- system(false)
14
- sale()
15
- address()
16
- ldap()
17
- require('system-clients/src/styles/less/bootstrap.less')
18
-
19
- new Vue({
20
- el: 'body',
21
- components: { App }
22
- })
1
+ import Vue from 'vue'
2
+ import { all } from 'vue-client'
3
+ import App from './App'
4
+ import { system } from 'system-clients'
5
+ import sale from './sale'
6
+ import { address } from 'address-client'
7
+ import { ldap } from 'ldap-clients'
8
+ import VueClipboard from 'vue-clipboard2'
9
+ Vue.use(VueClipboard)
10
+ Vue.config.silent = true
11
+
12
+ all()
13
+ system(false)
14
+ sale('guangxi')
15
+ address()
16
+ ldap()
17
+ require('system-clients/src/styles/less/bootstrap.less')
18
+
19
+ new Vue({
20
+ el: 'body',
21
+ components: { App }
22
+ })