donateDetail.vue 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571
  1. <template>
  2. <view class="detail">
  3. <view class="top">
  4. <image src="../../static/images/bgi2.png" mode=""></image>
  5. <view class="title clamp">夏天的清凉阳光孤儿院物资爱心捐赠活动</view>
  6. <view class="tip">
  7. <view class=""></view>
  8. 基本信息
  9. </view>
  10. <view class="base-info">
  11. <view class="item">
  12. <text>捐赠进度</text>
  13. <text class="status">30%</text>
  14. </view>
  15. <view class="item">
  16. <text>创立时间</text>
  17. 2021年6月10日
  18. </view>
  19. <view class="item">
  20. <text>开始时间</text>
  21. 2021年6月10日
  22. </view>
  23. <view class="item">
  24. <text>结束时间</text>
  25. 2021年6月10日
  26. </view>
  27. </view>
  28. <view class="dynamic flex">
  29. <view class="left">实时动态</view>
  30. <view class="right flex">
  31. <view>捐赠时间:2021年06月10日</view>
  32. <view>
  33. 捐赠人:
  34. <text>李**</text>
  35. </view>
  36. <view class="clamp" style="width: 500rpx;">捐赠数量:帐篷[100]顶,帐篷[100]顶,帐篷[100]顶,帐篷[100]顶</view>
  37. </view>
  38. </view>
  39. </view>
  40. <view class="content">
  41. <view class="content-nav flex">
  42. <view class="nav-item" v-for="(item, index) in navList" :key="index" :class="{ active: currentIndex === index }" @click="navClick(index)">{{ item }}</view>
  43. </view>
  44. </view>
  45. <view v-if="currentIndex === 0">
  46. <view class="item-detail" ref="swiperItemOne">
  47. <view class="tip">
  48. <view class=""></view>
  49. 捐赠介绍
  50. </view>
  51. <view class="item-content">内容介绍内容介绍内容介绍内容介绍内容介绍内容介绍, 内容介绍内容介绍内容介绍内。</view>
  52. <view class="tip">
  53. <view class=""></view>
  54. 项目需求
  55. </view>
  56. <view class="item-needs">
  57. <view class="need-item">
  58. <view class="">
  59. 帐篷类(帐篷):
  60. <text>500</text>
  61. </view>
  62. <view class="">
  63. 最低需求捐赠数:
  64. <text>500</text>
  65. </view>
  66. <view class="">
  67. 物资捐赠要求:
  68. <text>全新</text>
  69. </view>
  70. </view>
  71. <view class="need-item">
  72. <view class="">
  73. 帐篷类(帐篷):
  74. <text>500</text>
  75. </view>
  76. <view class="">
  77. 最低需求捐赠数:
  78. <text>500</text>
  79. </view>
  80. <view class="">
  81. 物资捐赠要求:
  82. <text>全新</text>
  83. </view>
  84. </view>
  85. </view>
  86. </view>
  87. </view>
  88. <view v-else class="feedback">
  89. <view class="feedback-nav">
  90. <view class="nav-item" :class="{'action': navCurrentIndex === 0}" @click="lookmore(0)">全部</view>
  91. <view class="nav-item" :class="{'action': navCurrentIndex === 1}" @click="lookmore(1)">已成功</view>
  92. <view class="nav-item nav-item-err" :class="{'action': navCurrentIndex === 2}" @click="lookmore(2)">已失败</view>
  93. </view>
  94. <view class="feedback-content">
  95. <view class="overall" v-if="navCurrentIndex === 0">
  96. <view class="title">
  97. 项目整体反馈
  98. </view>
  99. <view class="content">
  100. 截止2021年6月10日,荆州市红十字会已将捐赠的消毒液1120瓶和帐篷200顶,500箱矿泉水全数发往阳光福利院。
  101. </view>
  102. </view>
  103. <view class="feedback-item">
  104. <view class="item-top">
  105. <image src="" mode=""></image>
  106. <view class="item-name-time">
  107. <view class="item-name">荆州捐赠</view>
  108. <view class="item-time">2021年06月10日 22:25:14</view>
  109. </view>
  110. </view>
  111. <view class="item-content">
  112. <text>荆州XXXX有限分公司</text>2021年6月10日,荆州市红十字会已将贵公司捐赠的消毒液1120瓶和帐篷200顶,发往阳光福利院。
  113. </view>
  114. </view>
  115. </view>
  116. </view>
  117. <view class="btn-wrapper flex">
  118. <view class="btn1 btn" @click="navTo('/pages/donate/progress')">
  119. 实时进展
  120. </view>
  121. <view class="btn2 btn" @click="want()">
  122. 我要捐款
  123. </view>
  124. </view>
  125. <uni-popup ref="popup" type="center">
  126. <view class="type-box">
  127. <view class="box-title">捐款类型</view>
  128. <view class="box-tip">请选择您的捐赠身份类型</view>
  129. <view class="box-btn" @click="chooseType(1)">
  130. <image src="" mode=""></image>
  131. <view class="btn-title" >
  132. 个人捐赠
  133. </view>
  134. <view class="qq" :class="{'action': jxType === 1}">
  135. <view class="yx">
  136. </view>
  137. </view>
  138. </view>
  139. <view class="box-btn" @click="chooseType(0)">
  140. <image src="" mode=""></image>
  141. <view class="">
  142. 企业(团队)捐赠
  143. </view>
  144. <view class="qq" :class="{'action': jxType === 0}">
  145. <view class="yx">
  146. </view>
  147. </view>
  148. </view>
  149. <view class="qr" @click="qr()">
  150. 确认
  151. </view>
  152. </view>
  153. </uni-popup>
  154. </view>
  155. </template>
  156. <script>
  157. export default {
  158. data() {
  159. return {
  160. navList: ['捐赠详情', '捐赠反馈'],
  161. currentIndex: 0,
  162. swiperHeight: 0,
  163. navCurrentIndex: 0,
  164. jxType: 0,
  165. };
  166. },
  167. methods: {
  168. navTo(url) {
  169. uni.navigateTo({
  170. url: url
  171. })
  172. },
  173. navClick(index) {
  174. this.currentIndex = index;
  175. },
  176. lookmore(index) {
  177. this.navCurrentIndex = index
  178. },
  179. want() {
  180. this.$refs.popup.open()
  181. },
  182. chooseType(index) {
  183. this.jxType = index
  184. },
  185. qr() {
  186. this.$refs.popup.close()
  187. this.navTo('/pages/donate/idonate?type=' + this.jxType )
  188. }
  189. }
  190. };
  191. </script>
  192. <style lang="scss" scoped>
  193. page {
  194. width: 100%;
  195. }
  196. .top {
  197. height: 863rpx;
  198. background-color: #fff;
  199. border-top: 1rpx solid #f6f6f6;
  200. padding-top: 33rpx;
  201. margin-bottom: 20rpx;
  202. image {
  203. display: block;
  204. width: 680rpx;
  205. height: 375rpx;
  206. border-radius: 20rpx;
  207. margin: 0 auto;
  208. background-color: red;
  209. }
  210. .title {
  211. width: 580rpx;
  212. font-size: 32rpx;
  213. font-family: PingFang SC;
  214. font-weight: bold;
  215. color: #333333;
  216. line-height: 1;
  217. padding-top: 28rpx;
  218. padding-left: 42rpx;
  219. margin-bottom: 39rpx;
  220. }
  221. .base-info {
  222. font-size: 27rpx;
  223. font-family: PingFang SC;
  224. font-weight: 500;
  225. color: #999999;
  226. line-height: 1;
  227. display: flex;
  228. padding: 0 56rpx;
  229. flex-wrap: wrap;
  230. .item {
  231. width: 50%;
  232. padding-bottom: 40rpx;
  233. .status {
  234. color: red;
  235. font-weight: bold;
  236. }
  237. text {
  238. font-size: 26rpx;
  239. font-family: PingFang SC;
  240. font-weight: 500;
  241. color: #666666;
  242. display: inline-block;
  243. margin-right: 15rpx;
  244. }
  245. }
  246. }
  247. .dynamic {
  248. width: 666rpx;
  249. height: 111rpx;
  250. background: #efefef;
  251. border-radius: 10rpx;
  252. margin: 5rpx auto 0;
  253. .left {
  254. width: 115rpx;
  255. height: 111rpx;
  256. background: #5c93fc;
  257. border-radius: 10rpx 0px 0px 10rpx;
  258. font-size: 28rpx;
  259. font-family: PingFang SC;
  260. font-weight: 500;
  261. color: #ffffff;
  262. line-height: 34rpx;
  263. padding: 22rpx 29rpx;
  264. margin-right: 15rpx;
  265. }
  266. .right {
  267. font-size: 22rpx;
  268. font-family: PingFang SC;
  269. font-weight: 400;
  270. color: #333333;
  271. line-height: 1;
  272. padding: 12rpx 0;
  273. flex-direction: column;
  274. justify-content: space-between;
  275. text {
  276. color: red;
  277. font-weight: bold;
  278. }
  279. }
  280. }
  281. }
  282. .content {
  283. .content-nav {
  284. height: 82rpx;
  285. background: #ffffff;
  286. font-size: 30rpx;
  287. font-family: PingFang SC;
  288. font-weight: 500;
  289. color: #999999;
  290. line-height: 82rpx;
  291. justify-content: space-around;
  292. .active {
  293. border-bottom: 4rpx solid #fa7e67;
  294. color: #fa7e67;
  295. font-weight: bold;
  296. }
  297. }
  298. }
  299. .tip {
  300. margin-left: 42rpx;
  301. font-size: 30rpx;
  302. font-family: PingFang SC;
  303. font-weight: bold;
  304. color: #333333;
  305. line-height: 1;
  306. margin-bottom: 34rpx;
  307. view {
  308. display: inline-block;
  309. width: 4rpx;
  310. height: 30rpx;
  311. background: #fa7e67;
  312. border-radius: 2rpx;
  313. margin-right: 9rpx;
  314. position: relative;
  315. bottom: -2rpx;
  316. }
  317. }
  318. .btn-wrapper {
  319. .btn {
  320. width: 50%;
  321. text-align: center;
  322. height: 99rpx;
  323. line-height: 99rpx;
  324. font-size: 34rpx;
  325. font-family: PingFang SC;
  326. font-weight: 500;
  327. color: #ffffff;
  328. }
  329. .btn1 {
  330. background-color: #f7c03e;
  331. }
  332. .btn2 {
  333. background-color: #fa7e67;
  334. }
  335. }
  336. .item-detail {
  337. padding-top: 42rpx;
  338. .item-content {
  339. padding: 0 78rpx 0 48rpx;
  340. font-size: 26rpx;
  341. font-family: PingFang SC;
  342. font-weight: 500;
  343. color: #666666;
  344. line-height: 44rpx;
  345. margin-bottom: 32rpx;
  346. }
  347. .item-needs {
  348. .need-item {
  349. width: 666rpx;
  350. height: 150rpx;
  351. background: #f3f3f3;
  352. border-radius: 10rpx;
  353. margin: 0 auto;
  354. font-size: 26rpx;
  355. font-family: PingFang SC;
  356. font-weight: 500;
  357. color: #333333;
  358. margin-bottom: 10rpx;
  359. padding-top: 20rpx;
  360. padding-left: 13rpx;
  361. line-height: 1;
  362. view {
  363. margin-bottom: 15rpx;
  364. text {
  365. color: #e80000;
  366. }
  367. }
  368. }
  369. }
  370. }
  371. .feedback {
  372. padding: 25rpx 41rpx 36rpx;
  373. .feedback-nav {
  374. margin-bottom: 20rpx;
  375. .nav-item {
  376. display: inline-block;
  377. width: 100rpx;
  378. height: 55rpx;
  379. background: #FDCBC2;
  380. box-shadow: 0px 0px 10rpx 0rpx rgba(0, 0, 0, 0.1);
  381. border-radius: 10rpx;
  382. margin-right: 20rpx;
  383. text-align: center;
  384. line-height: 55rpx;
  385. font-size: 24rpx;
  386. font-family: PingFang SC;
  387. font-weight: 500;
  388. color: #FFFFFF;
  389. }
  390. .nav-item-err {
  391. color: #999999;
  392. background: #F1F1F0;
  393. }
  394. .action {
  395. background: #FA7E67;
  396. color: #fff;
  397. }
  398. }
  399. .feedback-content {
  400. .overall {
  401. .title {
  402. width: 667rpx;
  403. height: 75rpx;
  404. background: #FA7E67;
  405. box-shadow: 0px 0px 10rpx 0rpx rgba(0, 0, 0, 0.1);
  406. border-radius: 10rpx 10rpx 0px 0px;
  407. font-size: 28rpx;
  408. font-family: PingFang SC;
  409. font-weight: bold;
  410. color: #FFFFFF;
  411. line-height: 75rpx;
  412. padding-left: 17rpx;
  413. }
  414. .content {
  415. padding: 33rpx 36rpx 43rpx 30rpx;
  416. width: 667rpx;
  417. background-color: #fff;
  418. box-shadow: 0px 0px 10rpx 0px rgba(0, 0, 0, 0.1);
  419. border-radius: 0px 0px 10rpx 10rpx;
  420. font-size: 26rpx;
  421. font-family: PingFang SC;
  422. font-weight: 500;
  423. color: #999999;
  424. line-height: 42rpx;
  425. }
  426. }
  427. .feedback-item {
  428. margin: 20rpx auto;
  429. // display: flex;
  430. background-color: #fff;
  431. box-shadow: 0px 0px 10rpx 0px rgba(0, 0, 0, 0.1);
  432. border-radius: 10rpx 10rpx 10rpx;
  433. .item-top {
  434. height: 118rpx;
  435. border-radius: 10px 10px 0 0;
  436. border-bottom: 1px solid #ECECEC;
  437. padding: 25rpx 0 0 17rpx;
  438. display: flex;
  439. image {
  440. width: 77rpx;
  441. height: 77rpx;
  442. border-radius: 50%;
  443. background-color: red;
  444. margin-right: 12rpx;
  445. }
  446. .item-name-time {
  447. .item-name {
  448. font-size: 28rpx;
  449. font-family: PingFang SC;
  450. font-weight: bold;
  451. color: #333333;
  452. line-height: 35rpx;
  453. }
  454. .item-time {
  455. font-size: 24rpx;
  456. font-family: PingFang SC;
  457. font-weight: 500;
  458. color: #999999;
  459. line-height: 50rpx;
  460. }
  461. }
  462. }
  463. .item-content {
  464. padding: 25rpx 47rpx 40rpx 30rpx;
  465. border-radius: 0 0 10rpx 10rpx;
  466. font-size: 26rpx;
  467. font-family: PingFang SC;
  468. font-weight: 500;
  469. color: #999;
  470. line-height: 42rpx;
  471. text {
  472. color: #E80000;
  473. font-weight: bold;
  474. }
  475. }
  476. }
  477. }
  478. }
  479. .type-box {
  480. width: 542rpx;
  481. height: 575rpx;
  482. // background: linear-gradient(0deg, rgba(249, 98, 105, 0.06), rgba(255, 255, 255, 0.06));
  483. border-radius: 20rpx;
  484. background-color: #fff;
  485. position: relative;
  486. .box-title {
  487. text-align: center;
  488. font-size: 36rpx;
  489. font-family: PingFang SC;
  490. font-weight: bold;
  491. color: #333333;
  492. line-height: 1;
  493. padding-top: 77rpx;
  494. }
  495. .box-tip {
  496. text-align: center;
  497. font-size: 24rpx;
  498. font-family: PingFang SC;
  499. font-weight: 500;
  500. color: #808080;
  501. line-height: 1;
  502. padding-top: 12rpx;
  503. margin-bottom: 43rpx;
  504. }
  505. .box-btn {
  506. margin: 0 auto;
  507. width: 460rpx;
  508. height: 95rpx;
  509. display: flex;
  510. align-items: center;
  511. border-bottom: 1px solid #f3efef;
  512. position: relative;
  513. image {
  514. height: 43rpx;
  515. width: 43rpx;
  516. background-color: red;
  517. margin-right: 15rpx;
  518. }
  519. .qq {
  520. width: 32rpx;
  521. height: 32rpx;
  522. border: 1px solid #808080;
  523. opacity: 0.5;
  524. border-radius: 50%;
  525. position: absolute;
  526. right: 0;
  527. }
  528. .action {
  529. border-color: #FA7E67;
  530. // position: relative;
  531. .yx {
  532. width: 20rpx;
  533. height: 20rpx;
  534. background: #FA7E67;
  535. // border: 1px solid #FA7E67;
  536. border-radius: 50%;
  537. position: absolute;
  538. top: 0;
  539. bottom: 0;
  540. left: 0;
  541. right: 0;
  542. margin: auto;
  543. }
  544. }
  545. }
  546. .qr {
  547. width: 460rpx;
  548. height: 71rpx;
  549. background: #FA7E67;
  550. box-shadow: 0px 16rpx 16rpx 0px rgba(250, 126, 103, 0.5);
  551. border-radius: 10rpx;
  552. font-size: 28rpx;
  553. font-family: PingFang SC;
  554. font-weight: 500;
  555. color: #FFFFFF;
  556. text-align: center;
  557. line-height: 71rpx;
  558. margin: 62rpx auto 0;
  559. }
  560. }
  561. </style>