|
@@ -598,9 +598,6 @@ export default class raiseMoney extends Component {
|
598
|
598
|
}
|
599
|
599
|
|
600
|
600
|
makePay = () => {
|
601
|
|
- this.setState({
|
602
|
|
- payClick: false
|
603
|
|
- })
|
604
|
601
|
const { payType, record = {} } = this.state
|
605
|
602
|
if (!payType) {
|
606
|
603
|
Taro.showToast({
|
|
@@ -708,6 +705,9 @@ export default class raiseMoney extends Component {
|
708
|
705
|
}
|
709
|
706
|
|
710
|
707
|
nextStep(current) {
|
|
708
|
+ const { payClick } = this.state
|
|
709
|
+ if (!payClick) return;
|
|
710
|
+
|
711
|
711
|
// 缴费的下一步
|
712
|
712
|
if (current > 3) {
|
713
|
713
|
this.setState({
|
|
@@ -744,13 +744,20 @@ export default class raiseMoney extends Component {
|
744
|
744
|
|
745
|
745
|
// 缴费
|
746
|
746
|
case 3:
|
|
747
|
+ this.setState({
|
|
748
|
+ payClick: false
|
|
749
|
+ })
|
|
750
|
+
|
747
|
751
|
this.makePay().then(() => {
|
748
|
752
|
|
749
|
753
|
this.setState({
|
750
|
754
|
payClick: true,
|
751
|
755
|
current: current + 1
|
752
|
756
|
})
|
|
757
|
+ }).catch(() => {
|
|
758
|
+ this.setState({ payClick: true })
|
753
|
759
|
})
|
|
760
|
+
|
754
|
761
|
return;
|
755
|
762
|
|
756
|
763
|
//
|
|
@@ -771,7 +778,7 @@ export default class raiseMoney extends Component {
|
771
|
778
|
}
|
772
|
779
|
|
773
|
780
|
renderBottomBtn() {
|
774
|
|
- const { current, protocolCountdown, payClick } = this.state
|
|
781
|
+ const { current, protocolCountdown } = this.state
|
775
|
782
|
const { payType } = this.state
|
776
|
783
|
return (
|
777
|
784
|
<View className="bottom-btn">
|
|
@@ -779,7 +786,7 @@ export default class raiseMoney extends Component {
|
779
|
786
|
{current != 4 &&
|
780
|
787
|
<NextStep
|
781
|
788
|
countdown={current == 1 ? protocolCountdown : 0}
|
782
|
|
- onClick={() => payClick ? this.nextStep(current) : ''}
|
|
789
|
+ onClick={() => this.nextStep(current)}
|
783
|
790
|
text={current == 3 && payType === 'onLine' ? '现在缴费' : '下一步'}
|
784
|
791
|
/>
|
785
|
792
|
}
|