宜呗小程序--微信小程序
Lzk
2025-08-05 b7bcaf556aa2424e808b6e6426ab22df9cfe11c1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
<script>
import {getProtocol} from "@/api/modules/user";
 
export default {
  name: "steps-d",
  data() {
    return {
      readTime:7,
      text:null
    }
  },
  created() {
    getProtocol('Credit_Authorization_KDN').then(res=>{
      this.text = res.content
      let yis = setInterval(()=>{
        this.readTime--;
        if(!this.readTime){
          clearInterval(yis);
        }
 
      },1000)
    })
  },
  methods: {
    sub(){
      let  page = getCurrentPages();
      let prevPage = page[page.length - 2];
      prevPage.$vm.submitFinal();
      uni.navigateBack({delta: 1})
 
    }
  },
}
</script>
 
<template>
  <view>
    <view  class="step-d">
      <view class="text-container"><rich-text :nodes="text"></rich-text></view>
      <view class="but">
        <uv-button
            :disabled="true"
            customStyle="height:100rpx"
            v-if="readTime!=0" color="#EEEEEE" type="primary" shape="circle">
          <text style="font-size: 34rpx;color: #666666">请仔细阅读该协议({{readTime}}s)</text>
        </uv-button>
        <uv-button @click="sub"  customStyle="height:100rpx" v-else  type="primary" shape="circle">
          <text style="font-size: 34rpx" >确认提交</text>
        </uv-button>
      </view>
    </view>
  </view>
</template>
 
<style scoped lang="scss">
.step-d{
  .text-container{
    padding: 40rpx 20rpx;
    margin-bottom: 160rpx;
  }
  .but{
    background: white;
    width: 100%;
    padding: 30rpx;
    position: fixed;
    bottom: 0;
  }
}
</style>