apply.vue 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129
  1. <template>
  2. <view>
  3. <view class="listbox" v-for="(item,index) in postPushList" :key="index" @click="gotoInfo(item.postPushId)">
  4. <view class="flex align-center justify-between">
  5. <view class="text-xl text-bold" style="color: #6696FF;">{{item.postDetails?item.postDetails.postName:'未知'}}</view>
  6. <view class="text-lg text-bold" style="color: #FF4A28;">{{item.postDetails?item.postDetails.postPrice:'0'}}</view>
  7. </view>
  8. <view class="flex align-center margin-top-sm">
  9. <view class="argrtn" v-for="(ite,index) in item.postPush?item.postPush.projectType.split(','):[]" :key="index">{{ite}}</view>
  10. </view>
  11. <view class="flex align-center justify-between margin-top" style="margin-top: 60rpx;">
  12. <view class="" style="color: #666666;">{{item.postPush.projectName}}</view>
  13. <view>{{item.postPush.address}}</view>
  14. </view>
  15. <view class="bnlogo" v-if="item.status==2">
  16. <image src="../static/bmSuccess.png" style="width: 145upx;height: 115upx;"></image>
  17. </view>
  18. <view class="bnlogo" v-if="item.status==1">
  19. <image src="../static/bmS.png" style="width: 145upx;height: 115upx;"></image>
  20. </view>
  21. <view class="bnlogo" v-if="item.status==3">
  22. <image src="../static/bmShibai.png" style="width: 145upx;height: 115upx;"></image>
  23. </view>
  24. </view>
  25. <empty v-if="postPushList.length==0" />
  26. </view>
  27. </template>
  28. <script>
  29. import empty from '@/components/empty.vue'
  30. export default {
  31. components:{
  32. empty
  33. },
  34. data() {
  35. return {
  36. postPushList:[],
  37. page:1,
  38. limit:10,
  39. cont:'',
  40. }
  41. },
  42. onLoad() {
  43. this.getBaomingList();
  44. },
  45. onReachBottom() {
  46. if(this.page == this.cont){
  47. uni.showToast({
  48. title:'已经到底了',
  49. icon:"none"
  50. })
  51. }else{
  52. this.page += 1
  53. this.getBaomingList();
  54. }
  55. },
  56. onPullDownRefresh() {
  57. this.page = 1
  58. this.getBaomingList();
  59. },
  60. methods: {
  61. //项目详情
  62. gotoInfo(postPushId){
  63. uni.navigateTo({
  64. url:'/pages/index/game/order?postPushId='+postPushId
  65. })
  66. },
  67. //报名列表
  68. getBaomingList(){
  69. let data = {
  70. page:this.page,
  71. limit:this.limit,
  72. classify:1
  73. }
  74. this.$Request.get('/app/postPush/selectResumesPushList', data).then(res => {
  75. if (res.code == 0) {
  76. this.cont = res.data.totalPage
  77. let arr = res.data.list
  78. arr.map(item=>{
  79. if(item.postPush && item.postPush.address.indexOf('北京市')!=-1){
  80. item.postPush.address = '北京市'
  81. }else if(item.postPush && item.postPush.address.indexOf('重庆市')!=-1){
  82. item.postPush.address = '重庆市'
  83. }else if(item.postPush && item.postPush.address.indexOf('天津市')!=-1){
  84. item.postPush.address = '天津市'
  85. }else if(item.postPush && item.postPush.address.indexOf('上海市')!=-1){
  86. item.postPush.address = '上海市'
  87. }
  88. })
  89. if(this.page==1){
  90. this.postPushList = arr
  91. }else{
  92. this.postPushList = [...this.postPushList,...arr]
  93. }
  94. uni.stopPullDownRefresh()
  95. }
  96. })
  97. },
  98. },
  99. }
  100. </script>
  101. <style lang="less">
  102. page {
  103. background: #F2F2F7;
  104. }
  105. .listbox {
  106. background: #FFFFFF;
  107. border-radius: 24upx;
  108. margin: 20upx 30upx;
  109. padding: 30upx;
  110. position: relative;
  111. }
  112. .bnlogo{
  113. position: absolute;
  114. top: 70upx;
  115. right: 30upx;
  116. z-index: 99;
  117. }
  118. .argrtn {
  119. background: #F6F6F6;
  120. color: #666666;
  121. font-size: 24upx;
  122. border-radius: 8upx;
  123. padding: 5upx 20upx;
  124. margin-right: 20upx;
  125. }
  126. </style>