progresst.vue 9.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362
  1. <template>
  2. <view class="progress">
  3. <view class="top">
  4. <view class="top-t">
  5. <view class="top-item">
  6. <image src="../../static/icon/x1.png" mode=""></image>
  7. <view class="item-tit">1.项目创建</view>
  8. </view>
  9. <view class="top-item">
  10. <image src="../../static/icon/x2.png" mode=""></image>
  11. <view class="item-tit">2.项目审核</view>
  12. </view>
  13. <view class="top-item">
  14. <image src="../../static/icon/x3.png" mode=""></image>
  15. <view class="item-tit">3.捐赠响应</view>
  16. </view>
  17. <view class="top-item">
  18. <image src="../../static/icon/x4.png" mode=""></image>
  19. <view class="item-tit">4.捐赠审核</view>
  20. </view>
  21. </view>
  22. <view class="top-t">
  23. <view class="top-item">
  24. <image src="../../static/icon/x5.png" mode=""></image>
  25. <view class="item-tit">5.捐赠品入库</view>
  26. </view>
  27. <view class="top-item">
  28. <image src="../../static/icon/x6.png" mode=""></image>
  29. <view class="item-tit">6.捐赠品出库</view>
  30. </view>
  31. <view class="top-item">
  32. <image src="../../static/icon/x7.png" mode=""></image>
  33. <view class="item-tit">7.发往受捐者</view>
  34. </view>
  35. <view class="top-item">
  36. <image src="../../static/icon/x8.png" mode=""></image>
  37. <view class="item-tit">8.受捐者反馈</view>
  38. </view>
  39. </view>
  40. </view>
  41. <view class="main">
  42. <view class="item">
  43. <image src="../../static/icon/xq1.png" mode=""></image>
  44. <view class="item-info">
  45. <view class="item-tit">响应捐赠</view>
  46. <view class="item-time">{{info.add_time | time }} {{info.name}}响应捐赠{{info.item | item(typeList)}},提交工作人员审核</view>
  47. </view>
  48. <view class="line1"></view>
  49. <view class="line5"></view>
  50. </view>
  51. <!-- <view class="item">
  52. <image src="../../static/icon/xq2.png" mode=""></image>
  53. <view class="item-info">
  54. <view class="item-tit">捐赠意向书</view>
  55. <view class="item-time">2021/06/17 12:20:34 荆州XXX公司签署捐赠意向书</view>
  56. </view>
  57. <view class="line5"></view>
  58. </view> -->
  59. <view class="item">
  60. <image src="../../static/icon/xq5.png" mode=""></image>
  61. <view class="item-info">
  62. <view class="item-tit">用户寄件方式</view>
  63. <view class="item-time">{{info.logistics}}</view>
  64. </view>
  65. <view class="line5"></view>
  66. </view>
  67. <view class="item">
  68. <image src="../../static/icon/xq3.png" mode=""></image>
  69. <view class="item-info">
  70. <view class="item-tit">捐赠审核</view>
  71. <view class="item-time" v-if="info.verify_time">{{info.verify_time | time }} {{info.name}}捐赠响应{{info.status_txt==='拒绝'? '未通过': '已通过'}}</view>
  72. </view>
  73. <view class="line5"></view>
  74. </view>
  75. <!-- <view class="item">
  76. <image src="../../static/icon/xq4.png" mode=""></image>
  77. <view class="item-info">
  78. <view class="item-tit">智能合约</view>
  79. <view class="item-time"></view>
  80. </view>
  81. <view class="line5"></view>
  82. </view> -->
  83. <view class="item">
  84. <image src="../../static/icon/xq6.png" mode=""></image>
  85. <view class="item-info">
  86. <view class="item-tit">入库单信息</view>
  87. <view class="item-time" v-if="info.receiving_time">{{info.receiving_time | time }} {{info.name}}捐赠的{{info.item | item(typeList)}}已入库</view>
  88. </view>
  89. <view class="line5"></view>
  90. </view>
  91. <view class="item">
  92. <image src="../../static/icon/xq7.png" mode=""></image>
  93. <view class="item-info">
  94. <view class="item-tit">出库单信息</view>
  95. <view class="item-time" v-if="info.out_delivery_time">{{info.out_delivery_time | time }} {{info.name}}捐赠的{{info.item | item(typeList)}}已出库</view>
  96. </view>
  97. <view class="line5"></view>
  98. </view>
  99. <!-- <view class="item">
  100. <image src="../../static/icon/xq8.png" mode=""></image>
  101. <view class="item-info">
  102. <view class="item-tit">出库物流信息</view>
  103. <view class="item-time"></view>
  104. </view>
  105. <view class="line5"></view>
  106. </view> -->
  107. <view class="item">
  108. <image src="../../static/icon/xq9.png" mode=""></image>
  109. <view class="item-info">
  110. <view class="item-tit">受捐反馈信息</view>
  111. <view class="item-time" v-if="info.feedback_time">{{info.feedback_time | time }} {{info.feedback}}</view>
  112. </view>
  113. <view class="line6"></view>
  114. </view>
  115. </view>
  116. </view>
  117. </template>
  118. <script>
  119. import { getOrderInfo, getDonationInfo, getLogistics } from '../../api/money.js'
  120. export default {
  121. data() {
  122. return {
  123. peopleList: [],
  124. isShow: false,
  125. info: {},
  126. typeList: [],
  127. logisticsList: [],
  128. };
  129. },
  130. filters: {
  131. time(val){
  132. let str = '';
  133. // console.log(val)
  134. if (val) {
  135. let date = new Date(val * 1000);
  136. let Y = date.getFullYear();
  137. let M = date.getMonth() + 1 > 9 ? (date.getMonth()+1) : '0' + (date.getMonth()+1);
  138. let D = date.getDate() > 9 ? date.getDate() : '0' + date.getDate();
  139. let h = date.getHours() > 9 ? date.getHours() : '0' + date.getHours()
  140. let m = date.getMinutes() > 9 ? date.getMinutes() : '0' + date.getMinutes()
  141. let s = date.getSeconds() > 9 ? date.getSeconds() : '0' +date.getSeconds()
  142. str = Y + '/' + M + '/' + D + ' ' + h + ':' + m + ':' + s;
  143. }
  144. return str;
  145. },
  146. item(val, typeList) {
  147. let str = '(';
  148. if (val&&typeList) {
  149. let arr = val.map(item => {
  150. for (let i = 0; i < typeList.length; i++) {
  151. if (item.project_donation_id == typeList[i].id) {
  152. str = str + typeList[i].name + item.project_donation_num + '、';
  153. }
  154. }
  155. });
  156. }
  157. return str.substr(0, str.length - 1) +')';
  158. },
  159. log(val,logisticsList) {
  160. let str = ''
  161. if(val&&logisticsList) {
  162. for(let i = 0 ,len = logisticsList.length ; i < len ; i++) {
  163. if(logisticsList[i].id == val) {
  164. console.log(logisticsList[i].name)
  165. return str = logisticsList[i].name
  166. }
  167. }
  168. }
  169. return str
  170. }
  171. },
  172. onLoad(opt) {
  173. this.info = JSON.parse(opt.item)
  174. console.log(this.info)
  175. this.getDonationInfo()
  176. this.getLogistics()
  177. },
  178. methods: {
  179. getDonationInfo() {
  180. getDonationInfo().then(({ data }) => {
  181. this.typeList = data;
  182. console.log(this.typeList, '获取所有物资');
  183. });
  184. },
  185. getLogistics() {
  186. getLogistics().then( ({data}) => {
  187. console.log('88888888888888888888',data)
  188. this.logisticsList = data
  189. })
  190. }
  191. }
  192. };
  193. </script>
  194. <style lang="scss" scoped>
  195. .top {
  196. padding: 40rpx 0;
  197. background-color: #fff;
  198. margin: 20rpx 0;
  199. .top-t {
  200. display: flex;
  201. justify-content: space-between;
  202. padding: 0 55rpx;
  203. .top-item {
  204. width: 160rpx;
  205. display: flex;
  206. flex-direction: column;
  207. justify-content: center;
  208. align-items: center;
  209. margin-bottom: 30rpx;
  210. image {
  211. width: 160rpx;
  212. height: 160rpx;
  213. background: #ffffff;
  214. border-radius: 14px;
  215. margin-bottom: 15rpx;
  216. }
  217. .item-tit {
  218. font-size: 24rpx;
  219. font-family: PingFang SC;
  220. font-weight: 500;
  221. color: #333333;
  222. line-height: 1;
  223. }
  224. }
  225. }
  226. }
  227. .main {
  228. background-color: #fff;
  229. padding-right: 30rpx;
  230. height: 100%;
  231. position: relative;
  232. .line {
  233. width: 2rpx;
  234. // height: 60rpx;
  235. height: 100%;
  236. background-color: #fa7e67;
  237. position: absolute;
  238. left: 60rpx;
  239. }
  240. .item {
  241. position: relative;
  242. image {
  243. width: 45rpx;
  244. height: 45rpx;
  245. background: #fa7e67;
  246. border-radius: 50%;
  247. position: absolute;
  248. top: 49rpx;
  249. left: 40rpx;
  250. z-index: 3;
  251. }
  252. .item-info {
  253. width: 600rpx;
  254. position: relative;
  255. left: 112rpx;
  256. padding-bottom: 34rpx;
  257. border-bottom: 1px solid #ededed;
  258. .item-tit {
  259. padding-top: 52rpx;
  260. font-size: 32rpx;
  261. font-family: PingFang SC;
  262. font-weight: 500;
  263. color: #333333;
  264. line-height: 1;
  265. text {
  266. display: inline-block;
  267. width: 87rpx;
  268. height: 33rpx;
  269. border: 1px solid #0ec400;
  270. border-radius: 5rpx;
  271. font-size: 24rpx;
  272. font-family: PingFang SC;
  273. font-weight: 500;
  274. color: #0ec400;
  275. text-align: center;
  276. line-height: 30rpx;
  277. margin-left: 10rpx;
  278. }
  279. }
  280. .item-time {
  281. padding-top: 17rpx;
  282. font-size: 24rpx;
  283. font-family: PingFang SC;
  284. font-weight: 500;
  285. color: #bfbfbf;
  286. line-height: 1;
  287. }
  288. .item-num {
  289. margin-top: 21rpx;
  290. height: 392rpx;
  291. width: 592rpx;
  292. background-color: red;
  293. }
  294. .all-info {
  295. margin-top: 20rpx;
  296. width: 601rpx;
  297. height: 174rpx;
  298. border: 1px solid #cccccc;
  299. border-radius: 10rpx;
  300. font-size: 24rpx;
  301. font-family: PingFang SC;
  302. font-weight: 500;
  303. color: #999999;
  304. align-items: center;
  305. flex-wrap: wrap;
  306. view {
  307. flex-shrink: 0;
  308. width: 50%;
  309. padding-left: 20rpx;
  310. text {
  311. display: inline-block;
  312. margin-left: 5rpx;
  313. color: #000000;
  314. }
  315. .jd {
  316. color: #e80000;
  317. }
  318. }
  319. }
  320. }
  321. .line1 {
  322. position: absolute;
  323. width: 2rpx;
  324. height: 61rpx;
  325. background-color: #fff;
  326. top: 0;
  327. left: 60rpx;
  328. z-index: 2;
  329. }
  330. .line2 {
  331. position: absolute;
  332. width: 2rpx;
  333. height: 250rpx;
  334. background-color: #fff;
  335. bottom: 0;
  336. left: 60rpx;
  337. }
  338. .line5 {
  339. position: absolute;
  340. width: 2rpx;
  341. height: 100%;
  342. background-color: #fa7e67;
  343. top: 0;
  344. left: 60rpx;
  345. z-index: 1;
  346. }
  347. .line6 {
  348. position: absolute;
  349. width: 2rpx;
  350. height: 61rpx;
  351. background-color: #fa7e67;
  352. top: 0;
  353. left: 60rpx;
  354. }
  355. }
  356. }
  357. </style>