sale-client 3.6.127 → 3.6.128

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": "sale-client",
3
- "version": "3.6.127",
3
+ "version": "3.6.128",
4
4
  "description": "收费模块前台组件",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
@@ -248,7 +248,7 @@
248
248
  <div
249
249
  :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
250
250
  class="form-group" >
251
- <label class="font_normal_body">客户等级</label>
251
+ <label class="font_normal_body" title="参数名称:用户等级">客户等级</label>
252
252
  <v-select :options='$parent.$parent.userlevel' :search='true'
253
253
  :value.sync="model.userlevel"
254
254
  close-on-select
@@ -86,7 +86,7 @@
86
86
  <div class="col-sm-2 form-group">
87
87
  <label class="font_normal_body">用户姓名</label>
88
88
  <input style="width:60%" type="text" class="form-control" v-model="model.f_user_name" placeholder='用户姓名'
89
- condition="f_user_name = '{}'">
89
+ condition="f_user_name like '%{}%'">
90
90
  </div>
91
91
  <div class="col-sm-2 form-group">
92
92
  <label class="font_normal_body">用户地址</label>
@@ -71,7 +71,7 @@
71
71
  <div class="col-sm-2 form-group">
72
72
  <label class="font_normal_body">客户姓名</label>
73
73
  <input type="text" style="width:60%" class="input_search" v-model="model.f_user_name" placeholder='客户姓名'
74
- condition="f_user_name = '{}'">
74
+ condition="f_user_name like '%{}%'">
75
75
  </div>
76
76
  <div class="col-sm-2 form-group">
77
77
  <label class="font_normal_body">小&ensp;&ensp;&ensp;&ensp;区</label>
@@ -92,7 +92,7 @@
92
92
  <script>
93
93
  import {HttpResetClass} from 'vue-client'
94
94
  // 导入IC卡相关查询界面
95
- import ChangeMeterQueryUser from '../../components/common/userinfo_detail/ic_detail/ChangeMeterQueryUser'
95
+ import ChangeMeterQueryUser from './ic_detail/ChangeMeterQueryUser'
96
96
  import ChargeQueryUser from './ChargeQueryUser'
97
97
  import ChargeRecordQueryUser from '../../components/common/userinfo_detail/ic_detail/ChargeRecordQuery'
98
98
  import FillCardQueryUser from '../../components/common/userinfo_detail/ic_detail/FillCardQueryUser'
@@ -0,0 +1,241 @@
1
+ <template >
2
+ <div class="flex" style="justify-content: space-between;">
3
+ <div @keyup.enter="search" style="">
4
+ <criteria-paged :model="model" v-ref:paged>
5
+ <criteria @condition-changed='$parent.search' partial='criteria' v-ref:criteria>
6
+ <div class="form-horizontal select-overspread container-fluid auto" novalidate partial>
7
+ <div class="row">
8
+
9
+ <div class="col-sm-2 form-group">
10
+ <label class="font_normal_body">开始时间</label>
11
+ <datepicker :format="'yyyy-MM-dd'" :value.sync="model.f_start_date"
12
+ class="datepicker"
13
+ condition="f_changemeter_date >= '{} 00:00:00' "
14
+ placeholder="起始时间"
15
+ style="width:60%"
16
+ v-model="model.f_start_date"
17
+ ></datepicker>
18
+ </div>
19
+ <div class="col-sm-2 form-group" >
20
+ <label class="font_normal_body" >结束时间</label>
21
+ <datepicker :format="'yyyy-MM-dd'" :value.sync="model.f_end_date"
22
+ class="datepicker"
23
+ condition="f_changemeter_date <= '{} 23:59:59'"
24
+ placeholder="结束时间"
25
+ style="width:60%"
26
+ v-model="model.f_end_date"
27
+ ></datepicker>
28
+ </div>
29
+ <div class="col-sm-2 form-group">
30
+ <label class="font_normal_body">换表类型</label>
31
+ <v-select :options='$parent.$parent.changeType' :value.sync="model.f_change_type"
32
+ close-on-select
33
+ condition="f_change_type='{}'"
34
+ placeholder='换表类型'
35
+ style="width:60%"
36
+ v-model="model.f_change_type"
37
+ ></v-select>
38
+ </div>
39
+ <div class="col-sm-2 form-group">
40
+ <label class="font_normal_body">换表状态</label>
41
+ <v-select :value.sync="model.f_state" v-model='model.f_state'
42
+ style="width:60%"
43
+ :options='$parent.$parent.isstates' placeholder='换表状态'
44
+ close-on-select
45
+ condition="f_state = '{}'"></v-select>
46
+ </div>
47
+ <div style="float: right">
48
+ <button @click="search()" class="button_search" style="margin-right: 10px" v-el:cba>查询</button>
49
+ <print-data :defaultfield="$parent.$parent.defaultfield" :field="$parent.$parent.fields" :is-selected="true" :model="$parent.$parent.printModel"
50
+ @print-data="$parent.$parent.print()" print-name="换表流水" ></print-data>
51
+ </div>
52
+
53
+
54
+ </div>
55
+ </div>
56
+ </criteria>
57
+ <data-grid :model="model" class="list_area table_sy" partial='list' v-ref:grid>
58
+ <template partial='head'>
59
+ <tr>
60
+
61
+ <th><nobr>换表类型</nobr></th>
62
+ <th><nobr>旧表底数</nobr></th>
63
+ <th><nobr>旧表剩余</nobr></th>
64
+ <th><nobr>旧表品牌</nobr></th>
65
+ <th><nobr>新表品牌</nobr></th>
66
+ <th><nobr>旧表号</nobr></th>
67
+ <th><nobr>新表号</nobr></th>
68
+ <th><nobr>换表费</nobr></th>
69
+ <th><nobr>操作人</nobr></th>
70
+ <th><nobr>状态</nobr></th>
71
+ <th><nobr>换表日期</nobr></th>
72
+ <th><nobr>换表原因</nobr></th>
73
+ </tr>
74
+ </template>
75
+ <template partial='body' partial='list' v-ref:grid>
76
+ <tr >
77
+
78
+ <td style="text-align: center;"><nobr>{{row.f_type}}</nobr></td>
79
+ <td style="text-align: center;"><nobr>{{row.f_using_base_old}}</nobr></td>
80
+ <td style="text-align: center;"><nobr>{{row.f_remanent_gas}}</nobr></td>
81
+ <td style="text-align: center;"><nobr>{{row.f_meter_brand_old}}</nobr></td>
82
+ <td style="text-align: center;"><nobr>{{row.f_meter_brand}}</nobr></td>
83
+ <td style="text-align: center;"><nobr>{{row.f_meternumber_old}}</nobr></td>
84
+ <td style="text-align: center;"><nobr>{{row.f_meternumber}}</nobr></td>
85
+ <td style="text-align: center;"><nobr>{{row.f_changemeter_fee}}</nobr></td>
86
+ <td style="text-align: center;"><nobr>{{row.f_operator}}</nobr></td>
87
+ <td style="text-align: center;"><nobr>{{row.f_state}}</nobr></td>
88
+ <td style="text-align: center;"><nobr>{{row.f_operate_date}}</nobr></td>
89
+ <td style="text-align: center;"><nobr>{{row.f_reason}}/{{row.f_othereason}}</nobr></td>
90
+ </tr>
91
+ </template>
92
+ <template partial='foot'></template>
93
+ </data-grid>
94
+ </criteria-paged>
95
+ </div>
96
+ </div>
97
+ </template>
98
+
99
+ <script>
100
+ import {HttpResetClass, PagedList} from 'vue-client'
101
+
102
+ export default {
103
+ title: '收费',
104
+ data () {
105
+ return {
106
+ condition: '1=1',
107
+ model: new PagedList('rs/sql/sale_ChangeMeterQuery', 20),
108
+ // 控制单选
109
+ radio: [],
110
+ // 选中的页
111
+ all: [],
112
+ isstates: this.$appdata.getParam('是否有效') ? [{
113
+ label: '全部',
114
+ value: ''
115
+ }, ...this.$appdata.getParam('是否有效')] : [],
116
+ // row数据
117
+ rowsdata: [],
118
+ searchValue: this.$appdata.getSingleValue('综合条件查询') ? this.$appdata.getSingleValue('综合条件查询') : 'f_userinfo_id',
119
+ fields: {'f_userinfo_code': '客户编号', 'f_user_name': '客户姓名', 'f_type': '换表类型', 'f_meter_base': '旧表底数', 'f_newmeter_base': '新表底数', 'f_changemeter_fee': '换表费', 'f_operator': '操作员', 'f_changemeter_date': '换表日期'},
120
+ defaultfield: [
121
+ 'f_userinfo_code', 'f_user_name', 'f_type', 'f_meter_base', 'f_newmeter_base', 'f_changemeter_fee', 'f_operator', 'f_changemeter_date'
122
+ ],
123
+ printModel: {
124
+ rows: []
125
+ }
126
+ }
127
+ },
128
+ props: ['row'],
129
+ ready () {
130
+ this.$refs.paged.$refs.criteria.search()
131
+ },
132
+ methods: {
133
+ async search () {
134
+ this.condition = `${this.$refs.paged.$refs.criteria.condition} and ${this.searchValue} = '${this.row[this.searchValue]}' `
135
+ this.model.search(this.condition, this.model)
136
+ let http = new HttpResetClass()
137
+ let res = await http.load('POST', 'rs/sql/sale_ChangeMeterQuery', {
138
+ data: {
139
+ condition: this.condition
140
+ }
141
+ }, {resolveMsg: null, rejectMsg: null})
142
+ this.printModel.rows = res.data
143
+ },
144
+ // 多选框初始化
145
+ selectInit () {
146
+ this.rowsdata = []
147
+ this.all = []
148
+ this.radio = []
149
+ },
150
+ print () {
151
+ this.selectInit()
152
+ },
153
+ select () {
154
+ let index = this.model.pageIndex - 1
155
+ if (!this.radio[index]) {
156
+ this.radio.$set(index, [])
157
+ }
158
+ if (this.all[index]) {
159
+ // 数据
160
+ this.rowsdata[index] = Object.assign([], this.model.rows)
161
+ // 勾选
162
+ for (var i = 0; i < this.model.rows.length; i++) {
163
+ this.radio[index].$set(i, true)
164
+ }
165
+ } else {
166
+ // 数据
167
+ this.rowsdata[index] = []
168
+ // 不勾选
169
+ for (var i = 0; i < this.model.rows.length; i++) {
170
+ this.radio[index].$set(i, false)
171
+ }
172
+ }
173
+ let z = 0
174
+ for (let i = 0; i < this.all.length; i++) {
175
+ for (let j = 0; this.rowsdata[i] && j < this.rowsdata[i].length; j++) {
176
+ this.printModel.rows[z++] = this.rowsdata[i][j]
177
+ }
178
+ }
179
+ },
180
+ selectOne (event, row, i) {
181
+ let index = this.model.pageIndex - 1
182
+ if (!this.rowsdata[index]) {
183
+ this.rowsdata[index] = []
184
+ }
185
+ if (!this.radio[index]) {
186
+ this.radio.$set(index, [])
187
+ }
188
+ if (event.target.checked) {
189
+ // 数据
190
+ this.rowsdata[index][i] = row
191
+ // 勾选
192
+ this.radio[index].$set(i, true)
193
+ // 判断是否全部选中
194
+ var allState = true
195
+ if (this.model.rows.length != this.radio[index].length) {
196
+ allState = false
197
+ }
198
+ for (var state of this.radio[index]) {
199
+ if (!state) {
200
+ allState = false
201
+ }
202
+ }
203
+ if (allState) {
204
+ this.all.$set(index, true)
205
+ } else {
206
+ this.all.$set(index, false)
207
+ }
208
+ } else {
209
+ // 数据
210
+ this.rowsdata[index][i] = []
211
+ // 不勾选
212
+ this.radio[index].$set(i, false)
213
+ // 任意取消一个则全选状态设为false
214
+ this.all.$set(index, false)
215
+ }
216
+ let z = 0
217
+ this.printModel.rows = []
218
+ for (let i = 0; i < this.all.length; i++) {
219
+ for (let j = 0; this.rowsdata[i] && j < this.rowsdata[i].length; j++) {
220
+ if (this.rowsdata[i][j] && this.rowsdata[i][j].f_user_id) {
221
+ this.printModel.rows[z++] = this.rowsdata[i][j]
222
+ }
223
+ }
224
+ }
225
+ }
226
+ },
227
+ computed: {
228
+ ischecked () {
229
+ return function (index, i) {
230
+ if (!this.radio[index]) {
231
+ return false
232
+ }
233
+ return this.radio[index][i]
234
+ }
235
+ },
236
+ changeType () {
237
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('换表类型')]
238
+ }
239
+ }
240
+ }
241
+ </script>