sale-client 3.6.310 → 3.6.311-wenxi-2

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.
@@ -11,7 +11,7 @@ var devConfig = {
11
11
  publicPath: baseConfig.output.publicPath,
12
12
  historyApiFallback: true,
13
13
  host: '127.0.0.1',
14
- port: 8089,
14
+ port: 8087,
15
15
  open: false,
16
16
  stats: {
17
17
  colors: false, // 配置控制台输出彩色日志
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sale-client",
3
- "version": "3.6.310",
3
+ "version": "3.6.311-wenxi-2",
4
4
  "description": "收费模块前台组件",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
@@ -245,7 +245,7 @@
245
245
  </div>
246
246
  <div class="col-sm-4 form-group" v-if="getConfigShowItem('f_reminder_amount')"
247
247
  v-show="(formconfig && formconfig.f_reminder_amount && formconfig.f_reminder_amount.required) || !onlyshowmust"
248
- :class="[$v.f_reminder_amount.required ? 'has-error' : '']">
248
+ :class="[$v.f_reminder_amount.required ? 'has-error' : '']" title="余额小于该值后,微信公众号或短信推送余额不足提醒">
249
249
  <label for="f_reminder_amount" :style="{color: baseinfo.base.f_reminder_amount === null || baseinfo.base.f_reminder_amount === '' ? 'red' : null}" class="font_normal_body">{{getConfigLabelName('f_reminder_amount','提示金额')}}</label>
250
250
  <input type="number" v-model="baseinfo.base.f_reminder_amount" class="input_search" style="width:60%"
251
251
  v-validate:f_reminder_amount=getConfigValidate("f_reminder_amount",false)
@@ -471,7 +471,7 @@
471
471
  },
472
472
  watch: {
473
473
  'baseinfo.base.f_userinfo_id' (val) {
474
- if (this.baseinfo.base.f_reminder_amount === null) {
474
+ if (this.baseinfo.base.f_reminder_amount === null && this.formconfig.f_reminder_amount.required) {
475
475
  this.$showAlert('当前用户还未设置余额提示金额,请在提示金额字段进行设置', 'warning', 3000)
476
476
  }
477
477
  },
@@ -144,16 +144,16 @@
144
144
  f_limit_times: '',
145
145
  f_time_value: '0',
146
146
  f_limit_type: '气量',
147
- f_limit_style:'',
147
+ f_limit_style: '',
148
148
  f_limit_value: '',
149
149
  f_limit_amount: '',
150
150
  f_start_date: this.$login.toStandardDateString()
151
151
  },
152
152
  limitshow: false,
153
- thirdPays: [{label: '支持', value: '1'},{label: '不支持', value: '0'}],
154
- timeTypes: [{label: '按月', value: '按月'},{label: '按日', value: '按日'}],
155
- limitTypes: [{label: '气量', value: '气量'},{label: '金额', value: '金额'}],
156
- limitstyle: [{label: '按次数', value: '按次数'},{label: '按总量', value: '按总量'}]
153
+ thirdPays: [{label: '包含', value: '1'}, {label: '不包含', value: '0'}, {label: '仅第三方', value: '-1'}],
154
+ timeTypes: [{label: '按月', value: '按月'}, {label: '按日', value: '按日'}],
155
+ limitTypes: [{label: '气量', value: '气量'}, {label: '金额', value: '金额'}],
156
+ limitstyle: [{label: '按次数', value: '按次数'}, {label: '按总量', value: '按总量'}]
157
157
  }
158
158
  },
159
159
  props: ['show', 'f_price_id', 'f_userinfo_id'],
@@ -214,7 +214,7 @@
214
214
  f_limit_times: '',
215
215
  f_time_value: '',
216
216
  f_limit_type: '气量',
217
- f_limit_style:'',
217
+ f_limit_style: '',
218
218
  f_limit_value: 0,
219
219
  f_limit_amount: 0,
220
220
  f_start_date: this.$login.toStandardDateString()
@@ -320,7 +320,30 @@
320
320
  {{row.f_hand_date}}
321
321
  </div></td>
322
322
  <td style="text-align: center;">{{row.f_last_hand_date}}</td>
323
- <td style="text-align: center;">{{row.f_last_tablebase}}</td>
323
+ <!-- <td style="text-align: center;">{{row.f_last_tablebase}}</td>-->
324
+ <td style="text-align: center;">
325
+ <!-- 民用-->
326
+ <div v-if="!(row.f_user_type==='非民用')">
327
+ {{ row.f_last_tablebase }}
328
+ </div>
329
+ <!-- 非民用、未抄表、states!=0-->
330
+ <div v-if="row.f_user_type==='非民用' && row.f_meter_state === '未抄表' && row.states !== 0 && ($parent.$parent.$parent.inputType==='rw' && $index+1===$parent.$parent.$parent.inputIndex)">
331
+ <input type="text" class="form-control" v-model="row.f_last_tablebase"
332
+ @blur="$parent.$parent.$parent.enter(row)"
333
+ v-next-el="{id: $index+1}" :id="$index" style="width: 100px;padding: 6px;"
334
+ :disabled="row.state === '开始'"
335
+ @change="$parent.$parent.$parent.inputType='ro'"
336
+ @focus="$parent.$parent.$parent.clearError(row)">
337
+ </div>
338
+ <div v-if="row.f_user_type==='非民用' && row.f_meter_state === '未抄表' && row.states !== 0 && $parent.$parent.$parent.inputType!=='rw'">
339
+ {{ row.f_last_tablebase }}
340
+ </div>
341
+ <!-- 非民用、未抄表、states=0-->
342
+ <div v-if="row.f_user_type==='非民用' && (row.f_meter_state !== '未抄表' || row.states === 0)">
343
+ {{ row.f_last_tablebase }}
344
+ </div>
345
+
346
+ </td>
324
347
  <td style="text-align: center;">
325
348
  <div class="form-group" style="margin-bottom:0px;" :class="{
326
349
  'has-success has-feedback': row.f_tablebase ? ((row.f_last_tablebase-0) <= (row.f_tablebase -0)) : false,
@@ -359,7 +382,7 @@
359
382
  </td>
360
383
 
361
384
 
362
- <td style="text-align: center;">{{row.f_actualtablebase}}</td>
385
+ <td style="text-align: center;">{{row.f_tablebase - row.f_last_tablebase}}</td>
363
386
  <td style="text-align: center;">
364
387
  <div class="form-group" style="margin-bottom:0px;"
365
388
  v-if="row.f_meter_state === '未抄表' ">
@@ -473,10 +496,17 @@
473
496
  <button type="button" name="button" class="btn btn-link"
474
497
  @click.stop="$parent.$parent.$parent.nopass(row)"
475
498
  v-if="row.f_meter_state === '待审核' && $parent.$parent.$parent.jurisdiction.includes('审核权限')">不通过</button>-->
476
- <button type="button" name="button" class="button_search button_spacing width-60" title="权限名称:(卡表抄表冲正)"
477
- @click.stop="$parent.$parent.$parent.cardhandCenter(row)"
478
- v-if="row.f_meter_state === '已抄表'">冲正
479
- </button>
499
+ <nobr>
500
+ <button type="button" name="button" class="button_search button_spacing width-60" title="权限名称:(卡表抄表冲正)"
501
+ @click.stop="$parent.$parent.$parent.cardhandCenter(row)"
502
+ v-if="row.f_meter_state === '已抄表'">冲正
503
+ </button>
504
+ <button type="button" name="button" class="button_search button_spacing width-60" title="替换表抄表"
505
+ @click.stop="$parent.$parent.$parent.changeInput(row,$index+1)"
506
+ v-if="row.f_user_type==='非民用' && row.f_meter_state === '未抄表' && row.states !== 0">
507
+ 替换表抄表
508
+ </button>
509
+ </nobr>
480
510
  </td>
481
511
  <td><span title="{{row.f_card_reason}}" v-if="row.f_card_reason !== ''">{{row.f_card_reason.substring(0,5)}} ...</span>
482
512
  </td>
@@ -596,7 +626,10 @@ import {HttpResetClass, PagedList} from 'vue-client'
596
626
  dep: [],
597
627
  user: []
598
628
  },
599
- orgCondtionStr: ''
629
+ orgCondtionStr: '',
630
+ inputType: 'ro',
631
+ inputIndex: -1,
632
+ f_cardhand_type: null,
600
633
  }
601
634
  },
602
635
  ready () {
@@ -757,6 +790,7 @@ import {HttpResetClass, PagedList} from 'vue-client'
757
790
  row.f_user_id = row.f_user_id + ''
758
791
  // 余气量=累购-(本期指数-表初始指数)
759
792
  // row.f_shengyu_gas = (row.f_total_gas - (row.f_tablebase - row.f_initial_base)).toFixed(2)
793
+ row.f_cardhand_type = this.f_cardhand_type
760
794
  console.log('录入完毕。。', row)
761
795
  this.$resetpost('rs/logic/cardhands', row, {resolveMsg: null, rejectMsg: '录入数据出错!!!'}).then((res) => {
762
796
  console.log('返回数据', res)
@@ -769,6 +803,7 @@ import {HttpResetClass, PagedList} from 'vue-client'
769
803
  } else {
770
804
 
771
805
  }
806
+ this.f_cardhand_type = null
772
807
  },
773
808
  batchAudit () {
774
809
  // 批量审核
@@ -799,6 +834,11 @@ import {HttpResetClass, PagedList} from 'vue-client'
799
834
  nopass (row) {
800
835
  co(modifyGen(this, row, 'rs/logic/cardhandnopass'))
801
836
  },
837
+ changeInput(row,num){
838
+ this.inputType = 'rw'
839
+ this.inputIndex = num
840
+ this.f_cardhand_type='替换表抄表'
841
+ },
802
842
  cardhandCenter (row) {
803
843
  // let load = new HttpResetClass()
804
844
  // load.load('POST', 'rs/logic/Correct', {data: row}, {warnMsg: null, resolveMsg: null})
@@ -327,17 +327,23 @@
327
327
  </div>
328
328
  </td>
329
329
  <td style="text-align: center;">
330
+ <!-- 民用-->
330
331
  <div v-if="!(row.f_user_type==='非民用')">
331
332
  {{ row.f_last_tablebase }}
332
333
  </div>
333
- <div v-if="row.f_user_type==='非民用' && row.f_meter_state === '未抄表' && row.states !== 0">
334
+ <!-- 非民用、未抄表、states!=0-->
335
+ <div v-if="row.f_user_type==='非民用' && row.f_meter_state === '未抄表' && row.states !== 0 && ($parent.$parent.$parent.inputType==='rw' && $index+1===$parent.$parent.$parent.inputIndex)">
334
336
  <input type="text" class="form-control" v-model="row.f_last_tablebase"
335
337
  @blur="$parent.$parent.$parent.enter(row)"
336
338
  v-next-el="{id: $index+1}" :id="$index" style="width: 100px;padding: 6px;"
337
339
  :disabled="row.state === '开始'"
338
- @change="row.f_card_reason = '替换表抄表'"
340
+ @change="$parent.$parent.$parent.inputType='ro'"
339
341
  @focus="$parent.$parent.$parent.clearError(row)">
340
342
  </div>
343
+ <div v-if="row.f_user_type==='非民用' && row.f_meter_state === '未抄表' && row.states !== 0 && $parent.$parent.$parent.inputType!=='rw'">
344
+ {{ row.f_last_tablebase }}
345
+ </div>
346
+ <!-- 非民用、未抄表、states=0-->
341
347
  <div v-if="row.f_user_type==='非民用' && (row.f_meter_state !== '未抄表' || row.states === 0)">
342
348
  {{ row.f_last_tablebase }}
343
349
  </div>
@@ -464,10 +470,17 @@
464
470
  <button type="button" name="button" class="btn btn-link"
465
471
  @click.stop="$parent.$parent.$parent.nopass(row)"
466
472
  v-if="row.f_meter_state === '待审核' && $parent.$parent.$parent.jurisdiction.includes('审核权限')">不通过</button>-->
467
- <button type="button" name="button" class="button_search button_spacing width-60" title="权限名称:(卡表抄表冲正)"
468
- @click.stop="$parent.$parent.$parent.cardhandCenter(row)"
469
- v-if="row.f_meter_state === '已抄表'">冲正
470
- </button>
473
+ <nobr>
474
+ <button type="button" name="button" class="button_search button_spacing width-60" title="权限名称:(卡表抄表冲正)"
475
+ @click.stop="$parent.$parent.$parent.cardhandCenter(row)"
476
+ v-if="row.f_meter_state === '已抄表'">冲正
477
+ </button>
478
+ <button type="button" name="button" class="button_search button_spacing width-60" title="替换表抄表"
479
+ @click.stop="$parent.$parent.$parent.changeInput(row,$index+1)"
480
+ v-if="row.f_user_type==='非民用' && row.f_meter_state === '未抄表' && row.states !== 0">
481
+ 替换表抄表
482
+ </button>
483
+ </nobr>
471
484
  </td>
472
485
  <td><span title="{{row.f_card_reason}}"
473
486
  v-if="row.f_card_reason">{{ row.f_card_reason.substring(0, 5) }} ...</span>
@@ -589,7 +602,10 @@ export default {
589
602
  initres: {
590
603
  org: [this.$login.f.orgid]
591
604
  },
592
- orgCondtionStr: ''
605
+ orgCondtionStr: '',
606
+ inputType: 'ro',
607
+ inputIndex: -1,
608
+ f_cardhand_type: null,
593
609
  }
594
610
  },
595
611
  beforeDestroy () {
@@ -748,6 +764,7 @@ export default {
748
764
  row.f_total_fee = row.total_fee
749
765
  // 余气量=累购-(本期指数-表初始指数)
750
766
  row.f_shengyu_gas = (row.f_total_gas - (row.f_tablebase - row.f_initial_base)).toFixed(2)
767
+ row.f_cardhand_type = this.f_cardhand_type
751
768
  console.log('录入完毕。。', row)
752
769
  this.$resetpost('rs/logic/cardCommonEnter', row, {resolveMsg: null, rejectMsg: '录入数据出错!!!'}).then((res) => {
753
770
  console.log('返回数据', res)
@@ -760,6 +777,7 @@ export default {
760
777
  } else {
761
778
 
762
779
  }
780
+ this.f_cardhand_type = null
763
781
  },
764
782
  batchAudit () {
765
783
  // 批量审核
@@ -790,6 +808,11 @@ export default {
790
808
  nopass (row) {
791
809
  co(modifyGen(this, row, 'rs/logic/cardhandnopass'))
792
810
  },
811
+ changeInput(row,num){
812
+ this.inputType = 'rw'
813
+ this.inputIndex = num
814
+ this.f_cardhand_type='替换表抄表'
815
+ },
793
816
  cardhandCenter (row) {
794
817
  // let load = new HttpResetClass()
795
818
  // load.load('POST', 'rs/logic/Correct', {data: row}, {warnMsg: null, resolveMsg: null})
@@ -225,6 +225,7 @@
225
225
  <div style="text-align:right; height: 25%">
226
226
  <strong style="color:red;margin-right: 5px">{{ $refs.givechange.promptText }}</strong>
227
227
  <strong style="font-size: large" v-if="!config.notShowFormula">计算公式:{{calculatedetail ? calculatedetail : ' 暂无'}}</strong><br/>
228
+ <strong style="font-size: large" v-if="deductdetail">{{deductdetail ? deductdetail : ' 暂无'}}</strong><br/>
228
229
  <payment-code-button :clickable="!$v.valid || validateOk || !islegal || clickConfirm|| model.f_preamount === 0"
229
230
  :payment.sync="model.f_payment" :payment-data="paytype"
230
231
  @confirm-payment="confirm()">
@@ -278,7 +279,13 @@
278
279
  self.model.f_pregas = Math.floor(getGas.data.gas - 0)
279
280
  }
280
281
  }
281
- self.model.f_totalcost = ((self.row.f_balance - 0) >= (self.model.f_preamount - 0) ? 0 : (self.model.f_preamount - 0 - self.row.f_balance))
282
+ self.model.getDeduct = 0
283
+ // 计算抵扣包间费用抵扣金额
284
+ if (self.row.f_project_money && self.row.f_project_money > 0) {
285
+ self.model.getDeduct = (self.$CommonService.getDeduct(self.row, self.model.f_pregas) - 0)
286
+ }
287
+ // end
288
+ self.model.f_totalcost = ((self.row.f_balance - 0) >= ((self.model.f_preamount - 0) + self.model.getDeduct) ? 0 : ((self.model.f_preamount - 0) + self.model.getDeduct) - self.row.f_balance)
282
289
 
283
290
  self.model.chargeprice = getGas.data.chargeprice
284
291
  Object.assign(self.model, self.model, getGas.data)
@@ -290,7 +297,7 @@
290
297
  self.model.f_totalcost = ((self.model.f_totalcost - 0) - (self.dymoney - 0)).toFixed(self.row.f_fee_decimal || 4)
291
298
  }
292
299
  self.model.f_preamount = (calFee - (self.dymoney - 0)).toFixed(self.row.f_fee_decimal || 4)
293
- self.calText(getGas.data.chargeprice)
300
+ self.calText(getGas.data.chargeprice, self.model.getDeduct)
294
301
  }
295
302
 
296
303
  // 输入气量,换算金额
@@ -303,8 +310,13 @@
303
310
  if ((self.model.f_pregas - 0) - (self.maxgas - 0) <= 0) {
304
311
  self.model.f_meter_type = self.row.f_meter_type
305
312
  let getAmount = await self.$CommonService.gasCalculate(self.model, self.model.f_pregas)
313
+ self.model.getDeduct = 0
314
+ // 计算抵扣包间费用抵扣金额
315
+ if (self.row.f_project_money && self.row.f_project_money > 0) {
316
+ self.model.getDeduct = (self.$CommonService.getDeduct(self.row, self.model.f_pregas) - 0)
317
+ }
306
318
  self.model.f_preamount = getAmount.data.chargenum.toFixed(self.row.f_fee_decimal || 4)
307
- self.model.f_totalcost = ((self.row.f_balance - 0) > (getAmount.data.chargenum - 0) ? 0 : ((getAmount.data.chargenum - 0) - (self.row.f_balance - 0)).toFixed(self.row.f_fee_decimal || 4))
319
+ self.model.f_totalcost = ((self.row.f_balance - 0) > ((getAmount.data.chargenum - 0) + self.model.getDeduct - 0) ? 0 : (((getAmount.data.chargenum - 0) + self.model.getDeduct - 0) - (self.row.f_balance - 0)).toFixed(self.row.f_fee_decimal || 4))
308
320
  Object.assign(self.model, self.model, getAmount.data)
309
321
  self.model.chargeprice = getAmount.data.chargeprice
310
322
  if (self.model.f_payment == '赠气') {
@@ -316,7 +328,7 @@
316
328
  self.model.f_collection = Math.ceil(self.model.f_collection)
317
329
  }
318
330
  }
319
- self.calText(getAmount.data.chargeprice)
331
+ self.calText(getAmount.data.chargeprice, self.model.getDeduct)
320
332
  }
321
333
  }
322
334
  // 执行保存逻辑
@@ -399,7 +411,7 @@
399
411
  }
400
412
  }
401
413
  } else {
402
- self.$dispatch('success', '卡表收费')
414
+ self.$dispatch('success', '卡表收费', self.row)
403
415
  }
404
416
  self.clickConfirm = false
405
417
  } catch (error) {
@@ -495,7 +507,7 @@
495
507
  self.$dispatch('refresh', self.row)
496
508
  } else {
497
509
  self.$resetpost('rs/logic/writeCardAgin', getNoWriteCard.data[0], {resolveMsg: '重新写卡成功', rejectMsg: '重新写卡失败'})
498
- self.$dispatch('success', '卡表收费')
510
+ self.$dispatch('success', '卡表收费', self.row)
499
511
  }
500
512
  } else {
501
513
  self.$dispatch('refresh', self.row)
@@ -547,9 +559,11 @@
547
559
  f_privilege_id: 0,
548
560
  f_privilege_money: 0,
549
561
  f_privilege_gas: 0,
550
- f_after_discount: 0
562
+ f_after_discount: 0,
563
+ getDeduct: 0
551
564
  },
552
565
  calculatedetail: '',
566
+ deductdetail: '',
553
567
 
554
568
  // 启用发票管理需要对票号进行验证
555
569
  hasValidateBill: false,
@@ -677,7 +691,7 @@
677
691
  async calculatePreByCollection () {
678
692
  console.log('调用了')
679
693
  try {
680
- // this.model.f_collection = (this.model.f_collection - 0)
694
+ this.model.f_collection = (this.model.f_collection - 0)
681
695
  let calFee = ((this.model.f_collection - 0) + (this.row.f_balance)).toFixed(4)
682
696
  // 通过收款进行划价
683
697
  let getGas = await this.$CommonService.feeCalculate(this.model, calFee)
@@ -687,7 +701,13 @@
687
701
  Object.assign(this.model, this.model, dymoney2.data)
688
702
  this.model.f_totalcost = ((this.row.f_balance - 0) > (dymoney2.data.chargenum - 0) ? 0 : ((dymoney2.data.chargenum - 0) - (this.row.f_balance - 0)).toFixed(this.row.f_fee_decimal || 4))
689
703
  this.model.f_preamount = dymoney2.data.chargenum
690
- this.calText(dymoney2.data.chargeprice)
704
+ this.model.getDeduct = 0
705
+ if (this.row.f_project_money && this.row.f_project_money > 0) {
706
+ this.model.getDeduct = (this.$CommonService.getDeduct(this.row, this.model.f_pregas) - 0)
707
+ this.model.f_totalcost = this.model.f_totalcost + this.model.getDeduct
708
+ this.model.f_collection = this.model.f_collection + this.model.getDeduct
709
+ }
710
+ this.calText(dymoney2.data.chargeprice, this.model.getDeduct)
691
711
  } catch (error) {
692
712
  this.$showAlert(`发卡售气划价错误,错误类型:${error}`, 'danger', 0)
693
713
  this.$dispatch('error', '发卡售气', this.model, error)
@@ -805,7 +825,7 @@
805
825
  this.$dispatch('error', '发卡售气', this.model, error)
806
826
  }
807
827
  },
808
- calText (val) {
828
+ calText (val, getDeduct = 0) {
809
829
  let str = ''
810
830
  let num = 0
811
831
  val.forEach((item) => {
@@ -818,6 +838,13 @@
818
838
  str = str + item.f_price + ' x ' + Math.floor(item.f_gas) + '+'
819
839
  }
820
840
  })
841
+ if (getDeduct > 0) {
842
+ if ((this.model.f_pregas * this.row.f_gas_type) > this.row.f_project_money) {
843
+ this.deductdetail = '当前未结金额' + this.row.f_project_money + '元,不足抵扣,以未结金额为准'
844
+ } else {
845
+ this.deductdetail = '未结金额计算公式:' + this.row.f_gas_type + ' x ' + this.model.f_pregas + '=' + getDeduct
846
+ }
847
+ }
821
848
  str = str.slice(0, str.length - 1)
822
849
  this.calculatedetail = str
823
850
  if (num > 1) {
package/src/main.js CHANGED
@@ -3,7 +3,7 @@ import all from 'vue-client/src/all'
3
3
  import App from './App'
4
4
  import system from 'system-clients/src/system'
5
5
  import sale from './sale'
6
- import FilialeSale from './filiale/rongchuang/sale'
6
+ import FilialeSale from './filiale/wenxi/sale'
7
7
  import address from 'address-client/src/address'
8
8
  import ldap from 'ldap-clients/src/ldap'
9
9
  import VueClipboard from 'vue-clipboard2'