other.vue 5.8 KB

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