apply-clients 3.5.4-62 → 3.5.4-63

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": "apply-clients",
3
- "version": "3.5.4-62",
3
+ "version": "3.5.4-63",
4
4
  "description": "报建前端模块",
5
5
  "main": "src/index.js",
6
6
  "directories": {
@@ -532,6 +532,25 @@
532
532
  throw null
533
533
  }
534
534
  },
535
+ // 缴费前置
536
+ async gethostBefore () {
537
+ let data = {
538
+ tablename: 't_apply',
539
+ condition: `f_process_id = '${this.show_data.f_parent_process_id}'`
540
+ }
541
+ let http = new HttpResetClass()
542
+ let res = await http.load(
543
+ 'POST',
544
+ `rs/sql/apply_singleTable`,
545
+ {data: data},
546
+ {resolveMsg: null, rejectMsg: '集收单位查询失败!!!'}
547
+ )
548
+ let show_data = res.data[0]
549
+ if (Number(show_data.f_due_money) > Number(show_data.f_cumulative_payment_money) || Number(show_data.f_surplus_money) > 0) {
550
+ this.$showAlert('主流程费用未结清!!!', 'warning', 3000)
551
+ throw null
552
+ }
553
+ },
535
554
  // 施工前置 加表具后状态是待开通 提交后是正常 所以这里的判断条件需改正 (and uf.f_meter_classify is null and f_meternumber is null)
536
555
  async constructionBefore () {
537
556
  let http = new HttpResetClass()
@@ -551,6 +570,66 @@
551
570
  throw `还有${res.data[0].num}户未安装,无法提交`
552
571
  }
553
572
  },
573
+ async materialinput () {
574
+ let http = new HttpResetClass()
575
+ let data = {
576
+ condition: `f_parent_process_id = '${this.show_data.f_process_id}'`,
577
+ defname: ` defname = '工程施工' and state = '结束'`
578
+ }
579
+ let res = await http.load(
580
+ 'POST',
581
+ 'rs/sql/getdefnamenum',
582
+ {data: data},
583
+ {
584
+ resolveMsg: null,
585
+ rejectMsg: '子流程工程施工结束数量查询失败!!!'
586
+ })
587
+ if (res.data[0].num > res.data[0].actnum) {
588
+ let num = res.data[0].num - res.data[0].actnum
589
+ this.$showAlert(`还有${num}户工程施工未结束,无法提交!!!`, 'warning', 3000)
590
+ throw `还有${num}户工程施工未结束,无法提交!!!`
591
+ }
592
+ },
593
+ async qualitytesting () {
594
+ let http = new HttpResetClass()
595
+ let data = {
596
+ condition: `f_parent_process_id = '${this.show_data.f_process_id}'`,
597
+ defname: ` defname = '质检' and state = '结束'`
598
+ }
599
+ let res = await http.load(
600
+ 'POST',
601
+ 'rs/sql/getdefnamenum',
602
+ {data: data},
603
+ {
604
+ resolveMsg: null,
605
+ rejectMsg: '子流程工程施工结束数量查询失败!!!'
606
+ })
607
+ if (this.show_data.f_installed_households > res.data[0].actnum) {
608
+ let num = this.show_data.f_installed_households - res.data[0].actnum
609
+ this.$showAlert(`还有${num}户质检未结束,无法提交!!!`, 'warning', 3000)
610
+ throw `还有${num}户质检未结束,无法提交!!!`
611
+ }
612
+ },
613
+ async construction () {
614
+ let http = new HttpResetClass()
615
+ let data = {
616
+ condition: `f_parent_process_id = '${this.show_data.f_process_id}'`,
617
+ defname: ` defname = '完工' and state = '开始活动'`
618
+ }
619
+ let res = await http.load(
620
+ 'POST',
621
+ 'rs/sql/getdefnamenum',
622
+ {data: data},
623
+ {
624
+ resolveMsg: null,
625
+ rejectMsg: '子流程完工数量查询失败!!!'
626
+ })
627
+ if (res.data[0].num > res.data[0].actnum) {
628
+ let num = res.data[0].num - res.data[0].actnum
629
+ this.$showAlert(`还有${num}户子流程未完工,无法提交!!!`, 'warning', 3000)
630
+ throw `还有${num}户子流程未完工,无法提交!!!`
631
+ }
632
+ },
554
633
  changePipeBuild () {
555
634
  if (this.selectdata.f_process_dep === '工程部') {
556
635
  return 'this.getParentByType($organization$).getChildByName($工程部报装$).getChildren()'
@@ -1437,23 +1516,18 @@
1437
1516
  this.$dispatch('loadPage')
1438
1517
  return
1439
1518
  }
1440
- // if(this.show_data.f_apply_type === '散户报建' && this.show_data.defname === '合同签订' && (this.show_data.button.button_name === '保存'||this.show_data.button.button_name === '提交')){
1441
- // let dataz = {
1442
- // condition: `u.id = ${this.show_data.id}`,
1443
- // data: {
1444
- // id: this.$login.f.id,
1445
- // orgid: this.$login.f.orgid
1446
- // }
1447
- // }
1448
- // let http = new HttpResetClass()
1449
- // let restpz = await http.load(
1450
- // 'POST',
1451
- // `rs/sql/checkuser`,
1452
- // {data: dataz},
1453
- // {resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
1454
- // )
1455
- // this.show_data.actid=restpz.data[0].actid
1456
- // }
1519
+ if(this.show_data.f_apply_type === '团购报建' && this.show_data.defname === '室内外工程' && this.show_data.button.button_name === '提交'){
1520
+ if(this.show_data.f_no_indoors == '是'){
1521
+ this.show_data.button.button_name = '转散户'
1522
+ }else {
1523
+ this.show_data.button.button_name = '室外'
1524
+ }
1525
+ }
1526
+ if(this.show_data.f_apply_type === '团购报建' && this.show_data.defname === '室外施工' && this.show_data.button.button_name === '提交'){
1527
+ if(this.show_data.f_no_indoors == '否'){
1528
+ this.show_data.button.button_name = '转散户'
1529
+ }
1530
+ }
1457
1531
  let res = await this.$resetpost(
1458
1532
  `rs/logic/ApplyProductService`,
1459
1533
  {data: this.show_data},
@@ -1464,120 +1538,11 @@
1464
1538
  if (this.show_data.button.after) {
1465
1539
  this[this.show_data.button.after]()
1466
1540
  }
1467
- // // 改管报建 增容报建 优化
1468
- // if((this.show_data.f_apply_type === '改管报建'||this.show_data.f_apply_type === '增容报建') && this.show_data.defname === '报装申请' && this.show_data.button.button_name === '缴费'){
1469
- // let datagg = {
1470
- // condition: `t.f_process_id='${this.show_data.f_process_id}'`,
1471
- // }
1472
- // let http = new HttpResetClass()
1473
- // let restgg = await http.load(
1474
- // 'POST',
1475
- // `rs/sql/checkusertwo`,
1476
- // {data: datagg},
1477
- // {resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
1478
- // )
1479
- // debugger
1480
- // if(this.show_data.f_apply_type === '改管报建'){
1481
- // restgg.data[0].processname = '改管报建流程'
1482
- // restgg.data[0].defname = '报装缴费'
1483
- // }else{
1484
- // restgg.data[0].processname = '增容报建流程'
1485
- // restgg.data[0].defname = '报装缴费'
1486
- // }
1487
- // restgg.data[0].actid = restgg.data[0].actid + 1
1488
- // this.$dispatch('apply',restgg.data[0])
1489
- //
1490
- // }
1491
- //
1492
- // // 退款报建 优化
1493
- // if(this.show_data.f_apply_type === '退款报建' && this.show_data.defname === '终止报建' && this.show_data.button.button_name === '提交'){
1494
- // let datatk = {
1495
- // condition: `t.f_process_id='${this.show_data.f_process_id}'`,
1496
- // }
1497
- // let http = new HttpResetClass()
1498
- // let resttk = await http.load(
1499
- // 'POST',
1500
- // `rs/sql/checkusertwo`,
1501
- // {data: datatk},
1502
- // {resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
1503
- // )
1504
- // debugger
1505
- // resttk.data[0].processname = '退款报建流程'
1506
- // resttk.data[0].defname = '退款'
1507
- // this.$dispatch('apply',resttk.data[0])
1508
- //
1509
- // }
1510
- //
1511
- //
1512
- // if(this.show_data.f_apply_type === '散户报建' && this.show_data.defname === '报装申请' && this.show_data.button.button_name === '合同'){
1513
- // let data = {
1514
- // tablename: 't_apply',
1515
- // condition: `f_process_id='${this.show_data.f_process_id}'`
1516
- // }
1517
- // let http = new HttpResetClass()
1518
- // let restp = await http.load(
1519
- // 'POST',
1520
- // `rs/sql/apply_singleTable`,
1521
- // {data: data},
1522
- // {resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
1523
- // )
1524
- // debugger
1525
- // restp.data[0].processname = '散户报建流程'
1526
- // restp.data[0].defname = '合同签订'
1527
- // this.$dispatch('apply',restp.data[0])
1528
- //
1529
- // } else if(this.show_data.f_apply_type === '散户报建' && this.show_data.defname === '合同签订' && this.show_data.button.button_name === '提交'){
1530
- // let data2 = {
1531
- // condition: `u.id = ${this.show_data.id}`,
1532
- // data: {
1533
- // id: this.$login.f.id,
1534
- // orgid: this.$login.f.orgid
1535
- // }
1536
- // }
1537
- // let http = new HttpResetClass()
1538
- // let restp1 = await http.load(
1539
- // 'POST',
1540
- // `rs/sql/checkuser`,
1541
- // {data: data2},
1542
- // {resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
1543
- // )
1544
- // debugger
1545
- // console.log('有没有发请求打印查询的内容restp1',restp1)
1546
- // // restp1.data[0].processname = '散户报建流程'
1547
- // // restp1.data[0].defname = '报装缴费'
1548
- // this.$dispatch('apply',restp1.data[0])
1549
- // }else if(this.show_data.f_apply_type === '散户报建' && this.show_data.defname === '报装缴费' && this.show_data.button.button_name === '提交'){
1550
- // let data3 = {
1551
- // condition: `u.id = ${this.show_data.id}`,
1552
- // data: {
1553
- // id: this.$login.f.id,
1554
- // orgid: this.$login.f.orgid
1555
- // }
1556
- // }
1557
- // let http = new HttpResetClass()
1558
- // let restp2 = await http.load(
1559
- // 'POST',
1560
- // `rs/sql/checkuser`,
1561
- // {data: data3},
1562
- // {resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
1563
- // )
1564
- // debugger
1565
- // console.log('打印查询的内容',restp2)
1566
- // if(restp2.length>0){
1567
- // this.$dispatch('apply',restp2.data[0])
1568
- // }else{
1569
- // debugger
1570
- // this.$dispatch('loadPage')
1571
- // }
1572
- // }
1573
- // else{
1574
- // this.$dispatch('loadPage')
1575
- // }
1576
1541
  this.$dispatch('loadPage')
1577
1542
  },
1578
1543
  // 失去焦点出触发事件
1579
1544
  'onchange' (index) {
1580
- if (this.show_data.defname === '报装申请' || this.show_data.defname === '信息确认' || this.show_data.defname === '合同签订') {
1545
+ if (this.show_data.defname === '报装申请' || this.show_data.defname === '通气点火' || this.show_data.defname === '合同签订') {
1581
1546
 
1582
1547
  if (
1583
1548
  this.show_data.fields[index].label === '区/县' ||