You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Hetong.vue 2.7KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147
  1. <template>
  2. <view class="hetong-container">
  3. <view class="check-content">
  4. <view class="posi">
  5. <u-checkbox-group>
  6. <u-checkbox v-model="checked" shape="circle">
  7. </u-checkbox>
  8. </u-checkbox-group>
  9. <view class="content">
  10. 我已阅读并同意 <text class="item-line" @click="isShow = true">{{`《${linkName}》`}}</text>
  11. <!-- 和<text class="item-line"
  12. @click="handleDialog('risk')">《风险提示告知书》</text> -->
  13. </view>
  14. </view>
  15. </view>
  16. <u-modal v-model="isShow" width='700rpx' mask-close-able :show-title='false' :show-confirm-button='false'>
  17. <view class="slot-content">
  18. <Protocol :url='typeUrl' />
  19. <!-- <ETCUserAgreement v-if='type=="etc"' /> -->
  20. </view>
  21. </u-modal>
  22. </view>
  23. </template>
  24. <script setup lang='ts'>
  25. import {
  26. ref,
  27. computed
  28. } from 'vue'
  29. import Protocol from './Protocol.vue'
  30. interface PropsType {
  31. modelValue: any
  32. link: any
  33. }
  34. const props = defineProps < PropsType > ()
  35. const emit = defineEmits(['update:modelValue'])
  36. const checked = computed({
  37. get: function() {
  38. return props.modelValue
  39. },
  40. set: function(newValue) {
  41. emit('update:modelValue', newValue)
  42. },
  43. })
  44. //获取页面配置
  45. const isShow = ref(false)
  46. const typeUrl = ref('')
  47. const linkName = computed(() => {
  48. let name = ''
  49. if (props.link) {
  50. console.log(props.link);
  51. typeUrl.value = props.link
  52. let arr = props.link.split('/')
  53. arr = arr[arr.length - 1].split('_')
  54. if(arr.length <= 1){
  55. name = arr[0]
  56. }else{
  57. arr.splice(0, 1)
  58. arr = arr.join('_')
  59. arr = arr.split('.')
  60. arr.pop()
  61. name = arr.join('.')
  62. }
  63. }
  64. return name
  65. })
  66. function handleDialog(types) {
  67. isShow.value = true
  68. if (types == 'etc') {
  69. typeUrl.value = '/sett-minio/template/ETC用户协议(阳光行A).docx'
  70. } else {
  71. typeUrl.value = '/sett-minio/template/风险提示告知书.docx'
  72. }
  73. }
  74. </script>
  75. <!-- 签约管理 -->
  76. <style lang='scss' scoped>
  77. .sig-manage {
  78. height: 100vh;
  79. width: 100%;
  80. display: flex;
  81. justify-content: center;
  82. align-items: center;
  83. }
  84. .hetong-container {
  85. width: 100%;
  86. display: flex;
  87. flex-direction: column;
  88. }
  89. :deep(.u-checkbox__label) {
  90. margin: 0;
  91. margin-right: 5rpx;
  92. }
  93. .check-content {
  94. flex: 1 1 auto;
  95. .posi {
  96. bottom: 30rpx;
  97. left: 0;
  98. width: 100%;
  99. }
  100. }
  101. .content {
  102. display: inline;
  103. word-wrap: break-word;
  104. }
  105. .item-line {
  106. color: $u-type-primary;
  107. cursor: pointer;
  108. }
  109. .btn {
  110. height: 80rpx;
  111. opacity: 1;
  112. border-radius: 100rpx;
  113. margin: 20rpx;
  114. }
  115. .btn-text {
  116. color: #FFFFFF;
  117. font-size: 28rpx;
  118. }
  119. .nav-bg {
  120. /* background: linear-gradient(to right, #13E7C1, #43A1E0); */
  121. border: 1px solid #FFFFFF;
  122. background: #1AAC1B;
  123. }
  124. .btn-buttom {
  125. flex: 0 0 auto;
  126. }
  127. .slot-content {
  128. height: 82vh;
  129. overflow-y: auto;
  130. }
  131. </style>