sale-client 4.0.72-preview → 4.0.73-preview

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.
@@ -0,0 +1,2 @@
1
+ #Mon Dec 30 14:38:17 CST 2024
2
+ gradle.version=5.2.1
@@ -31,6 +31,12 @@ var devConfig = {
31
31
  // },
32
32
  target: serverRul
33
33
  },
34
+ '/weixin2/rs':{
35
+ pathRewrite: {
36
+ '/weixin2/rs': '/rs'
37
+ },
38
+ target: 'http://410663id1ia4.vicp.fun'
39
+ },
34
40
  '/api/af-revenue/sql': {
35
41
  pathRewrite: {
36
42
  '/api/af-revenue/sql': '/sql'
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sale-client",
3
- "version": "4.0.72-preview",
3
+ "version": "4.0.73-preview",
4
4
  "description": "收费模块前台组件",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
@@ -52,11 +52,27 @@
52
52
  <input class="input_search" style="width:80%" v-model="model.f_reason" v-validate:f_reason='{required: true }' rows="3" placeholder="请填写原因">
53
53
  </div>
54
54
  </div>
55
+ <div class="row" style="margin-top:10px;">
56
+ <div v-if="config.hasAudit" :class="[$v.f_meter_base.required ? 'has-error' : 'has-success']">
57
+ <label class="ch font_normal_body">审核人员</label>
58
+ <input v-show="false" v-model="model.f_audit_person"
59
+ v-validate:f_audit_person='{required: true}'>
60
+ <v-select :value.sync="model.f_audit_person"
61
+ :options='auditor' placeholder='请选择'
62
+ selected="审核人员"
63
+ :value-single="true"
64
+ style="width:60%"
65
+ close-on-select></v-select>
66
+ </div>
67
+ </div>
55
68
  </form>
56
69
  <upload :blodid="useraccount[0].f_userinfo_id" isremark="true" fusetype="销户" v-ref:caneclfile></upload>
57
70
 
58
71
  <div style="text-align:right;height:auto;margin-top:30px;margin-right:50px;">
59
- <button class="button_search" @click="createHand()" :disabled='!$v.valid'>确认</button>
72
+ <button class="button_search" v-show="config.hasAudit" type="button" @click="createHand()" :disabled='!$v.valid'>
73
+ 过户审核
74
+ </button>
75
+ <button class="button_search" v-show="!config.hasAudit" @click="createHand()" :disabled='!$v.valid'>确认</button>
60
76
  <button class="button_clear" @click="clean()">取消</button>
61
77
  </div>
62
78
  </validator>
@@ -67,29 +83,34 @@ import Vue from 'vue'
67
83
  import {HttpResetClass} from 'vue-client'
68
84
 
69
85
  /**
70
- *综合业务
71
- 表具停用组件
72
- */
86
+ *综合业务
87
+ 表具停用组件
88
+ */
73
89
  export default {
74
90
  title: '批量销户',
75
91
  data () {
76
92
  return {
93
+ resid: [], // 存放新增的f_files表中id
77
94
  config: {
78
- upload: false // 默认附件不必传
95
+ upload: false, // 默认附件不必传
96
+ hasAudit: false // 是否审核
79
97
  },
80
98
  model: {
81
99
  count: 0,
82
100
  discount: 0,
83
101
  f_meter_base: null,
84
102
  f_reason: '',
85
- userinfo: {}
103
+ userinfo: {},
104
+ f_operat_type: '销户'
86
105
  },
87
- infoIds: []
106
+ infoIds: [],
107
+ auditor: []
88
108
  }
89
109
  },
90
110
  props: ['useraccount'],
91
111
  async ready () {
92
112
  await this.$getConfig(this, 'UserFiles')
113
+ this.getAuditor()
93
114
  this.useraccount.forEach((item) => {
94
115
  if (item.f_user_state !== '销户') {
95
116
  this.model.count = this.model.count + 1
@@ -125,7 +146,10 @@ export default {
125
146
  // },
126
147
 
127
148
  methods: {
128
-
149
+ async getAuditor () {
150
+ await this.$GetSaleParam.initinputtor()
151
+ this.auditor = this.$GetSaleParam.getAudit(this.$login.f.orgid)
152
+ },
129
153
  async createHand () {
130
154
  if (this.config.upload) {
131
155
  if (this.$refs.caneclfile.fileInfoData && this.$refs.caneclfile.fileInfoData.length > 0) {
@@ -172,13 +196,13 @@ export default {
172
196
  async confirm () {
173
197
  let http = new HttpResetClass()
174
198
  let owe = await http.load('POST', 'api/af-revenue/sql/singleTable_OrderBy', {
175
- data: {
176
- items: 'f_whether_pay',
177
- tablename: 't_handplan',
178
- condition: ` f_userfiles_id = '${this.useraccount[0].f_userfiles_id}' and f_hand_state = '有效' and f_meter_state='已抄表' and f_whether_pay='否'`,
179
- orderitem: ' id desc'
180
- }
181
- }, {resolveMsg: null, rejectMsg: null}
199
+ data: {
200
+ items: 'f_whether_pay',
201
+ tablename: 't_handplan',
202
+ condition: ` f_userfiles_id = '${this.useraccount[0].f_userfiles_id}' and f_hand_state = '有效' and f_meter_state='已抄表' and f_whether_pay='否'`,
203
+ orderitem: ' id desc'
204
+ }
205
+ }, {resolveMsg: null, rejectMsg: null}
182
206
  )
183
207
  console.log('获取到的欠费记录', owe)
184
208
  // 如果是机表/物联网表,验证是否有欠费
@@ -189,7 +213,11 @@ export default {
189
213
  } else if ((this.model.userinfo.f_meter_classify === '物联网表' && this.model.userinfo.f_balance_amount && this.model.userinfo.f_balance_amount > 0) || (this.model.userinfo.f_meter_classify !== '物联网表' && this.model.userinfo.f_balance && this.model.userinfo.f_balance > 0)) {
190
214
  this.$showAlert('该表有余额,无法销户', 'warning', 3000)
191
215
  } else {
192
- await this.cancellation()
216
+ if (!this.config.hasAudit) {
217
+ await this.cancellation()
218
+ } else {
219
+ this.auditConfirm()
220
+ }
193
221
  }
194
222
  },
195
223
  async cancellation () {
@@ -204,6 +232,64 @@ export default {
204
232
  this.$dispatch('error', '批量销户', this.row, error)
205
233
  })
206
234
  },
235
+ async auditConfirm () {
236
+ let fileParam = []
237
+ for (let row of this.resid) {
238
+ fileParam.push({id: row.id})
239
+ }
240
+ let param = {
241
+ // 业务参数
242
+ requestParam: {
243
+ f_operat_type: '销户',
244
+ f_describe: `${Vue.$login.f.name}对客户${this.model.userinfo.f_user_name}进行销户`,
245
+ f_user_id: this.model.userinfo.f_user_id,
246
+ f_user_name: this.model.userinfo.f_user_name,
247
+ f_state: '销户',
248
+ f_comments: this.model.f_reason,
249
+ f_operator: Vue.$login.f.name,
250
+ f_operatorid: Vue.$login.f.id,
251
+ f_orgid: Vue.$login.f.orgid,
252
+ f_orgname: Vue.$login.f.orgs,
253
+ f_depid: Vue.$login.f.depids,
254
+ f_depname: Vue.$login.f.deps,
255
+ f_userinfo_id: this.model.userinfo.f_userinfo_id
256
+ },
257
+ // 审核人
258
+ f_audit_person: this.model.f_audit_person,
259
+ // 描述
260
+ f_describe: `${this.$login.f.name}对用户${this.useraccount[0].f_user_name}进行销户`,
261
+ // 附件
262
+ fileParam: fileParam,
263
+ // 登录人信息
264
+ userBaseInfo: {
265
+ f_operator: Vue.$login.f.name,
266
+ f_userinfo_code: this.useraccount[0].f_userinfo_code,
267
+ f_userinfo_id: this.useraccount[0].f_userinfo_id,
268
+ f_operatorid: Vue.$login.f.id,
269
+ f_orgid: Vue.$login.f.orgid,
270
+ f_orgname: Vue.$login.f.orgs,
271
+ f_depid: Vue.$login.f.depids,
272
+ f_depname: Vue.$login.f.deps
273
+ },
274
+ // 业务类型
275
+ type: '销户',
276
+ // 执行业务
277
+ f_type: this.model.f_operat_type,
278
+ // 其他业务请求
279
+ f_otherparam: [],
280
+ // 备注
281
+ f_comments: this.model.f_reason,
282
+ // 执行logic
283
+ logicName: 'saveSingleCancellation'
284
+ }
285
+ this.$resetpost('api/af-revenue/logic/commonAuditLogic', {data: param}, {
286
+ warnMsg: `确定要对用户${this.useraccount[0].f_user_name}进行${this.model.f_operat_type}审核吗?`,
287
+ resolveMsg: `提交审核完成!!`,
288
+ rejectMsg: `提交审核失败!!请重试!!`
289
+ }).then((res) => {
290
+ this.clean()
291
+ })
292
+ },
207
293
  // confirm () {
208
294
  // this.model.f_reality_count = this.model.count
209
295
  //
@@ -237,6 +323,17 @@ export default {
237
323
  this.$info('取消操作')
238
324
  this.$dispatch('clean', '批量销户', this.row)
239
325
  }
326
+ },
327
+ events: {
328
+ // 删除Resid数组元素
329
+ 'delResid' (val) {
330
+ this.resid.$remove({id: val, f_biobid: ''})
331
+ // this.resid.splice(this.resid.indexOf({id:val,f_biobid:''}),1);
332
+ },
333
+ // 增加Resid数组元素
334
+ 'resid' (val) {
335
+ this.resid.push({id: val, f_biobid: ''})
336
+ }
240
337
  }
241
338
  }
242
339
  </script>