other.vue 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250
  1. <template>
  2. <view class="content">
  3. <view class="top flex">
  4. <image src="../../static/img/002.png" mode="aspectFill"></image>
  5. <view class="font">
  6. <view class="china-font">{{redName}}</view>
  7. <view class="english-font">{{redEn}}</view>
  8. </view>
  9. </view>
  10. <view class="cross">社会捐款通道</view>
  11. <view class="box">
  12. <view class="title" style="margin-top: 0;">1.银行转账</view>
  13. <view class="detail" v-for="item in bankList" :key="item.id">
  14. <view class="detail-item">
  15. 开户名:{{ item.accountName }}
  16. <view class="copy" @click="copy(item.accountName)">复制开户名</view>
  17. </view>
  18. <view class="detail-item">
  19. 银行账户:{{ item.bankAccount }}
  20. <view class="copy" @click="copy(item.bankAccount)">复制账号</view>
  21. </view>
  22. <view class="detail-spe">
  23. 开户行:{{ item.bank }}
  24. <view class="copyband" @click="copy(item.bank)">复制开户行</view>
  25. </view>
  26. </view>
  27. <view class="image">
  28. <image src="../../static/images/oother.png" mode=""></image>
  29. </view>
  30. <!-- <view class="image">
  31. <image src="../../static/images/other.png" mode=""></image>
  32. </view> -->
  33. <!-- <view class="title">2.扫码捐款</view> -->
  34. <!-- <view class="zfb">支付宝扫码捐款</view> -->
  35. <!-- <view class="erweima"><image src="../../static/images/smjk.png" mode=""></image></view> -->
  36. <!-- <view class="weixin">微信扫码捐款</view>
  37. <view class="erweima" style="background: #02974A;"><image src="" mode=""></image></view> -->
  38. <view class="title">2.现场捐款/捐物</view>
  39. <view class="detail">
  40. <view class="detail-item">负责人:{{donationsInfo.name}}</view>
  41. <view class="detail-item">咨询电话:{{donationsInfo.phone}}</view>
  42. <view class="detail-item">地址:{{donationsInfo.address}}</view>
  43. </view>
  44. </view>
  45. </view>
  46. </template>
  47. <script>
  48. import uniCopy from '../../components/js_sdk/xb-copy/uni-copy.js';
  49. import { mapState, mapMutations } from 'vuex';
  50. export default {
  51. data() {
  52. return {
  53. };
  54. },
  55. computed: {
  56. ...mapState('info',['redName','redEn','bankList','donationsInfo'])
  57. },
  58. methods: {
  59. tocontrilist() {
  60. uni.navigateTo({
  61. url: '/pages/applic/tocontrilist'
  62. });
  63. },
  64. copy(value) {
  65. let obj = this;
  66. let content = value; //需要复制的内容
  67. console.log('复制的内容:', content);
  68. // content = typeof content === 'string' ? content : content.toString(); // 复制内容,必须字符串,数字需要转换为字符串
  69. const result = uniCopy(content);
  70. if (result === false) {
  71. uni.showToast({
  72. title: '不支持'
  73. });
  74. } else {
  75. uni.showToast({
  76. title: '复制成功',
  77. icon: 'none'
  78. });
  79. }
  80. }
  81. }
  82. };
  83. </script>
  84. <style lang="scss">
  85. body,
  86. page {
  87. height: 100%;
  88. background-color: #fefefe;
  89. }
  90. .content {
  91. background-color: #fefefe;
  92. line-height: 1;
  93. padding-top: 25rpx;
  94. padding: 24rpx 24rpx 90rpx;
  95. .top {
  96. align-items: center;
  97. width: 100%;
  98. image {
  99. width: 64rpx;
  100. height: 64rpx;
  101. border-radius: 50%;
  102. }
  103. .font {
  104. margin-left: 20rpx;
  105. .china-font {
  106. font-size: 27rpx;
  107. font-family: PingFang SC;
  108. font-weight: bold;
  109. color: #101010;
  110. letter-spacing:20rpx;
  111. }
  112. .english-font {
  113. margin-top: 6rpx;
  114. font-size: 12rpx;
  115. font-family: PingFang SC;
  116. // font-weight: bold;
  117. color: #101010;
  118. // letter-spacing:1rpx;
  119. }
  120. }
  121. }
  122. .cross {
  123. margin-left: 6rpx;
  124. height: 76rpx;
  125. line-height: 76rpx;
  126. color: #444444;
  127. border-bottom: 1rpx solid #cccccc;
  128. }
  129. .image {
  130. margin-top: 44rpx;
  131. margin-bottom: 48rpx;
  132. height: 404rpx;
  133. width: 100%;
  134. image {
  135. width: 100%;
  136. height: 100%;
  137. }
  138. }
  139. .box {
  140. padding: 20rpx 0 24rpx;
  141. .title {
  142. margin-top: 60rpx;
  143. font-size: 28rpx;
  144. font-family: PingFang SC;
  145. font-weight: bold;
  146. color: #101010;
  147. }
  148. .detail {
  149. padding-top: 10rpx;
  150. font-size: 28rpx;
  151. line-height: 40rpx;
  152. .detail-spe {
  153. margin-top: 10rpx;
  154. line-height: 46rpx;
  155. overflow: hidden;
  156. text-overflow: ellipsis;
  157. display: -webkit-box; //必须结合的属性,将对象作为弹性伸缩盒子模型显示
  158. -webkit-line-clamp: 2; //控制文本的行数
  159. -webkit-box-orient: vertical; //必须结合的属性,设置或检索伸缩盒对象的子元素的排列方式
  160. .copyband {
  161. display: flex;
  162. float: right;
  163. // float: right;
  164. justify-content: center;
  165. background-color: #f1f1f1;
  166. border-radius: 10rpx;
  167. line-height: 34rpx;
  168. font-size: 24rpx;
  169. color: #333;
  170. // padding: 0 24rpx;
  171. width: 168rpx;
  172. height: 34rpx;
  173. margin-top: 8rpx;
  174. }
  175. }
  176. .detail-item {
  177. display: flex;
  178. justify-content: space-between;
  179. align-items: center;
  180. // height: 40rpx;
  181. line-height: 46rpx;
  182. color: #000;
  183. margin-top: 10rpx;
  184. .copy {
  185. width: 168rpx;
  186. display: flex;
  187. justify-content: center;
  188. background-color: #f1f1f1;
  189. border-radius: 10rpx;
  190. line-height: 34rpx;
  191. font-size: 24rpx;
  192. color: #333;
  193. padding: 0 24rpx;
  194. // width: 144rpx;
  195. height: 34rpx;
  196. }
  197. }
  198. .phone {
  199. margin-left: 138rpx;
  200. height: 40rpx;
  201. color: #000;
  202. }
  203. }
  204. .erweima {
  205. width: 362rpx;
  206. height: 362rpx;
  207. background: #0b9edd;
  208. margin: 26rpx auto;
  209. image {
  210. height: 100%;
  211. width: 100%;
  212. }
  213. }
  214. .zfb {
  215. font-size: 30rpx;
  216. font-family: PingFang SC;
  217. font-weight: bold;
  218. color: #0b9edd;
  219. margin-top: 36rpx;
  220. text-align: center;
  221. }
  222. .weixin {
  223. font-size: 30rpx;
  224. font-family: PingFang SC;
  225. font-weight: bold;
  226. color: #02974a;
  227. margin-top: 36rpx;
  228. text-align: center;
  229. }
  230. }
  231. }
  232. </style>