testSAS.wxml 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159
  1. <!--miniprogram/pages/testSAS/testSAS.wxml-->
  2. <view class='container'>
  3. <!-- <canvas canvas-id="myCanvas" style="width: 350rpx; height: 350rpx;margin-top:20rpx;"></canvas> -->
  4. <!-- <view class="container-yh">
  5. <view class="top-text-yh">
  6. <view class="text-left-yh">
  7. <image class="icon-yh" src="/static/images/report/c_11.png" mode="aspectFit"></image>
  8. <text class="text-content-yh">左边文字内容</text>
  9. </view>
  10. <view class="text-right-yh">
  11. <image class="icon-yh" src="/static/images/report/c_11.png" mode="aspectFit"></image>
  12. <text class="text-content-yh">右边文字内容</text>
  13. </view>
  14. </view>
  15. <view class="circle-container-yh">
  16. <view class="text-container-yh left-text-yh">
  17. <view class="text-row-yh">
  18. <image class="icon-yh" src="/static/images/report/c_11.png" mode="aspectFit"></image>
  19. <text class="text-content-yh">左侧第一行文字内容</text>
  20. </view>
  21. <view class="text-row-yh">
  22. <image class="icon-yh" src="/static/images/report/c_11.png" mode="aspectFit"></image>
  23. <text class="text-content-yh">左侧第二行文字内容</text>
  24. </view>
  25. </view>
  26. <image class="circle-image-yh" src="/static/images/report/vortex.png" mode="aspectFit"></image>
  27. <view class="text-container-yh right-text-yh">
  28. <view class="text-row-yh">
  29. <image class="icon-yh" src="/static/images/report/c_11.png" mode="aspectFit"></image>
  30. <text class="text-content-yh">右侧第一行文字内容</text>
  31. </view>
  32. <view class="text-row-yh">
  33. <image class="icon-yh" src="/static/images/report/c_11.png" mode="aspectFit"></image>
  34. <text class="text-content-yh">右侧第二行文字内容</text>
  35. </view>
  36. </view>
  37. </view>
  38. <view class="centered-text-yh">
  39. <text class="text-line-yh text-line-yh-1">良好</text>
  40. <text class="text-line-yh text-line-yh-2">78</text>
  41. <text class="text-line-yh text-line-yh-3">香睡指数</text>
  42. </view>
  43. </view> -->
  44. <view class='idX'>睡眠调查问卷</view>
  45. <swiper class='sheet' current='{{id}}'>
  46. <block wx:for="{{qnaire}}">
  47. <swiper-item>
  48. <form bindsubmit='submit'>
  49. <view class='naire' wx:if="{{item.type == 'radio'}}">
  50. <view class='question'>{{item.question}}</view>
  51. <view class='question_1' wx:if="{{item.question_1 != ''}}">{{item.question_1}}</view>
  52. <!--view class='border' /-->
  53. <radio-group class="radio-group-1" name='answer' bindchange='radioChange'>
  54. <label class='radio'><radio value="A" color='#fcbe39' wx:if="{{item.option.a != '' && item.option.a != null}}"/>{{item.option.a}}</label>
  55. <label class='radio'><radio value="B" color='#fcbe39' wx:if="{{item.option.b != '' && item.option.b != null}}"/>{{item.option.b}}</label>
  56. <label class='radio'><radio value="C" color='#fcbe39' wx:if="{{item.option.c != '' && item.option.c != null}}"/>{{item.option.c}}</label>
  57. <label class='radio'><radio value="D" color='#fcbe39' wx:if="{{item.option.d != '' && item.option.d != null}}"/>{{item.option.d}}</label>
  58. <label class='radio'><radio value="E" color='#fcbe39' wx:if="{{item.option.e != '' && item.option.e != null}}"/>{{item.option.e}}</label>
  59. <label class='radio'><radio value="F" color='#fcbe39' wx:if="{{item.option.f != '' && item.option.f != null}}"/>{{item.option.f}}</label>
  60. <label class='radio'><radio value="G" color='#fcbe39' wx:if="{{item.option.g != '' && item.option.g != null}}"/>{{item.option.g}}</label>
  61. <label class='radio'><radio value="H" color='#fcbe39' wx:if="{{item.option.h != '' && item.option.h != null}}"/>{{item.option.h}}</label>
  62. <label class='radio'><radio value="I" color='#fcbe39' wx:if="{{item.option.i != '' && item.option.i != null}}"/>{{item.option.i}}</label>
  63. <label class='radio'><radio value="J" color='#fcbe39' wx:if="{{item.option.j != '' && item.option.j != null}}"/>{{item.option.j}}</label>
  64. </radio-group>
  65. </view>
  66. <view class='naire' wx:else>
  67. <view class='question'>{{item.question}}</view>
  68. <view class="sleep-time-container">
  69. <text>{{item.option.a}}</text>
  70. <input name='input' style="border: none;border-bottom: 1px solid #000000;width:30rpx;" class="input-underline" placeholder="" bindinput="handleInputChange" value="{{inputValue}}" data-id="{{id}}"/>
  71. <text wx:if="{{item.option.b != '' && item.option.b != null}}">{{item.option.b}}</text>
  72. </view>
  73. <view class='question_2' wx:if="{{id==3 && BMI != null}}">体重:{{item.BMI}}</view>
  74. </view>
  75. <view class='button-group'>
  76. <button class='button' hover-class='none' bindtap='lastq' disabled='{{id==0}}'>上一题</button>
  77. <button wx:if="{{id<26}}" class='button' hover-class='none' form-type='submit' bindtap='nextq'>下一题</button>
  78. <button wx:else class='button' hover-class='none' form-type='submit' bindtap='formSubmit'>提交</button>
  79. </view>
  80. </form>
  81. </swiper-item>
  82. </block>
  83. </swiper>
  84. <!-- <view class='button-group'>
  85. <button class='button' hover-class='none' bindtap='lastq' disabled='{{id==0}}'>上一题</button>
  86. <button wx:if="{{id<26}}" class='button' hover-class='none' form-type='submit' bindtap='nextq'>下一题</button>
  87. <button wx:else class='button' hover-class='none' form-type='submit' bindtap='formSubmit'>提交</button>
  88. </view> -->
  89. <view class='id'>{{id+1}}/{{qnaire.length}}</view>
  90. <view class="prompt" wx:if="{{promptTextMessage != null && promptTextMessage.length > 0}}">
  91. <view class='idR'>答题结果分析</view>
  92. <block wx:for="{{promptTextMessage}}">
  93. <view><text class="small-red-text">{{item}}</text></view>
  94. </block>
  95. </view>
  96. <view class='prompt' wx:else>
  97. <!-- <view class='idR'>温馨提示</view> -->
  98. <view><text class="small-red-text_ts">温馨提示:问卷提交后,会根据提您提交的答案,给出相应的分析指导。</text></view>
  99. </view>
  100. <!-- 弹出框 -->
  101. <view class="modal" wx:if="{{privacyDetailShow}}">
  102. <scroll-view class="modal-content" scroll-y="true">
  103. <!-- 这里是800字的内容,为了示例只显示部分内容 -->
  104. <view><text style="font-size:50rpx;font-weight:700rpx;">微信小程序调查问卷隐私条款</text></view>
  105. <view><text style="font-weight:400rpx;">一、前言</text></view>
  106. <view><text style="font-weight:400rpx;">我们非常重视用户的隐私和个人信息保护。为了保障用户在使用本微信小程序(以下简称“小程序”)进行调查问卷时的权益,我们制定了本隐私条款。本隐私条款详细说明了我们在收集、使用、存储和保护用户信息时的原则、范围、方式和目的。请用户在使用本小程序前,仔细阅读并理解本隐私条款。</text></view>
  107. <view><text style="font-weight:400rpx;">二、信息收集</text></view>
  108. <view><text style="font-weight:400rpx;">在用户参与调查问卷时,我们可能会收集用户的一些基本信息,如姓名、联系方式、电子邮箱等。这些信息将仅用于统计分析、改进服务质量和联系用户。</text></view>
  109. <view><text style="font-weight:400rpx;">我们可能会收集用户在使用小程序过程中产生的日志信息,包括但不限于设备型号、操作系统版本、IP地址、访问时间等。这些信息将用于优化小程序的性能和功能。</text></view>
  110. <view><text style="font-weight:400rpx;">三、信息使用</text></view>
  111. <view><text style="font-weight:400rpx;">我们将按照本隐私条款的规定,合法、正当地使用用户信息,不会将其用于与调查问卷无关的目的。</text></view>
  112. <view><text style="font-weight:400rpx;">我们可能会将用户信息用于以下用途:统计分析调查问卷结果,为改进服务质量和制定政策提供参考;</text></view>
  113. <view><text style="font-weight:400rpx;">在用户同意的前提下,向用户推荐相关的服务或产品。</text></view>
  114. <view><text style="font-weight:400rpx;">我们不会将用户信息泄露给任何第三方,除非得到用户的明确同意或法律法规另有规定。</text></view>
  115. <view><text style="font-weight:400rpx;">四、信息安全</text></view>
  116. <view><text style="font-weight:400rpx;">我们将采取合理的技术和管理措施,保障用户信息的安全,防止信息泄露、丢失、被篡改或非法获取。</text></view>
  117. <view><text style="font-weight:400rpx;">我们将定期对用户信息进行备份,以防止数据丢失。</text></view>
  118. <view><text style="font-weight:400rpx;">五、用户权利</text></view>
  119. <view><text style="font-weight:400rpx;">用户有权了解我们收集、使用其信息的情况,并可以要求我们提供相关的解释和说明。</text></view>
  120. <view><text style="font-weight:400rpx;">用户有权要求我们更正、删除其提供的不准确或不完整的个人信息。</text></view>
  121. <view><text style="font-weight:400rpx;">用户有权拒绝我们收集、使用其个人信息,但可能会影响其使用小程序的部分功能。</text></view>
  122. <view><text style="font-weight:400rpx;">六、隐私条款的修改</text></view>
  123. <view><text style="font-weight:400rpx;">我们可能会根据法律法规的变化、技术的进步或业务发展的需要,对本隐私条款进行修改。修改后的隐私条款将通过小程序内公告或其他适当的方式通知用户。请用户定期查看并了解最新的隐私条款内容。</text></view>
  124. <view><text style="font-weight:400rpx;">七、联系方式</text></view>
  125. <view><text style="font-weight:400rpx;">如果您对本隐私条款有任何疑问或建议,请通过以下方式与我们联系:[您的联系方式]。我们将尽快回复您并为您解答问题。</text></view>
  126. <view><text style="font-weight:400rpx;">八、法律适用和争议解决</text></view>
  127. <view><text style="font-weight:400rpx;">本隐私条款的解释、适用和争议解决均适用中华人民共和国法律。如双方因本隐私条款产生争议,应首先通过友好协商解决;协商不成的,任何一方均有权向有管辖权的人民法院提起诉讼。</text></view>
  128. <button class="close-btn" bindtap="hideModal">关闭</button>
  129. </scroll-view>
  130. <!-- 关闭图标 -->
  131. <view class="modal-close" bindtap="hideModal">
  132. <image src="/static/images/close.png" alt="关闭" />
  133. </view>
  134. </view>
  135. <!-- 隐私条款单选按钮和文本 -->
  136. <view class="privacy-section" wx:if="{{promptTextMessage == null || promptTextMessage.length <= 0}}">
  137. <!-- <checkbox class="privacy-checkbox" checked="{{isPrivacyAgreed}}" bindchange="checkboxChange">
  138. <text class="privacy-detail-btn" bindtap="showPrivacyDetail">隐私条款</text>
  139. </checkbox> -->
  140. <radio-group class="radio-group-2" bindchange="checkboxChange">
  141. <label class="checkbox-item" wx:for="{{checkboxes}}" wx:key="name">
  142. <radio value="{{item.name}}" checked="{{item.checked}}"/>
  143. </label>
  144. </radio-group>
  145. <text class="privacy-detail-btn">我已阅读并同意</text>
  146. <text class="privacy-detail-btn_tk" bindtap="showPrivacyDetail">《舒眠调查问卷隐私条款》</text>
  147. </view>
  148. </view>