index.vue 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217
  1. <template>
  2. <view class="ss-m-x-20">
  3. <view v-if="list.length > 0" class="ss-p-b-30 ss-p-t-20">
  4. <view v-for="(item, index) in list" :key="index" class="mList" :class="{ 'disable': item.job?.status === '1'}" @click="toDetail(item)">
  5. <!-- 职位信息 -->
  6. <view class="list-shape">
  7. <!-- 职位 -->
  8. <view class="titleBox my-5">
  9. <view style="display: flex;align-items: center;">
  10. <view v-if="item.job?.hire" class="iconfont icon-a-1_zhaopin ss-m-r-10" style="color: #e03506; font-size: 25px;"></view>
  11. <rich-text v-if="item.job?.name?.indexOf('style') !== -1" class="job-name" :nodes="item.job.name"></rich-text>
  12. <view v-else class="job-name">{{item.job?.name}}</view>
  13. </view>
  14. <span v-if="!item.job?.payFrom && !item.job?.payTo" class="salary-text">面议</span>
  15. <span v-else class="salary-text">{{ item.job?.payFrom }}-{{ item.job?.payTo }}{{ item.job?.payName ? '/' + item.job?.payName : '' }}</span>
  16. </view>
  17. <!-- 工作地 -->
  18. <view style="font-size: 13px;" class="mt">
  19. <span class="tag-gap" style="color: #808080;">
  20. <span>{{item.job?.areaName }}</span>
  21. <span class="divider-mx" v-if="item.job?.areaName && item.job?.eduName">|</span>
  22. <span>{{item.job?.eduName }}</span>
  23. <span class="divider-mx" v-if="item.job?.expName">|</span>
  24. <span>{{item.job?.expName }}</span>
  25. </span>
  26. </view>
  27. <!-- 岗位tag -->
  28. <view class="mt" v-if="showWelfareTag">
  29. <uni-tag
  30. v-for="(tag,i) in item.job?.tagList || []"
  31. :key="i"
  32. class="tag-gap"
  33. :text="tag"
  34. inverted="false"
  35. size="mini"
  36. custom-style="background-color: #ececec;color:#666;border-color:#ececec;display: inline-block;"
  37. />
  38. </view>
  39. <view style="text-align: end;" v-if="item.job?.hire">
  40. <uni-tag
  41. class="ss-m-l-10"
  42. v-if="item?.job?.hirePrice && item?.job?.hirePrice > 0"
  43. :text="`赏金:${commissionCalculation(item.job.hirePrice / 100, 1)}元`"
  44. inverted="false"
  45. size="default"
  46. custom-style="background-color: #e2f0ef; color:#00897B; border-color:#e2f0ef;"
  47. />
  48. </view>
  49. <view class="font-size-13 color-999" style="text-align: end;">发布时间:{{ timesTampChange(item.job.createTime, 'Y-M-D h:m') }}</view>
  50. </view>
  51. <!-- 企业信息 -->
  52. <view class="sub-li-bottom">
  53. <view class="avatarBox">
  54. <image class="enterAvatar ml" :src="item.enterprise?.logoUrl || 'https://minio.citupro.com/dev/menduner/company-avatar.png'"></image>
  55. </view>
  56. <view class="ss-m-l-35">
  57. <view class="mr">{{ item.enterprise?.anotherName || item.enterprise.name }}</view>
  58. <span class="color-999">{{ item.enterprise?.industryName || '' }}</span>
  59. <span class="divider tag-gap1" v-if="item.enterprise?.industryName && item.enterprise?.scaleName"> | </span>
  60. <span class="mr color-999">{{ item.enterprise?.scaleName || '' }}</span>
  61. </view>
  62. </view>
  63. </view>
  64. <view v-if="props.noMore" class="noMore">暂无更多数据</view>
  65. </view>
  66. <view v-else>
  67. <image src="https://minio.citupro.com/dev/static/nodata.png" mode="widthFix" style="width: 100vw;height: 100vh;"></image>
  68. <view style="color: gray; text-align: center;">暂无数据</view>
  69. </view>
  70. </view>
  71. </template>
  72. <script setup>
  73. import { commissionCalculation } from '@/utils/position'
  74. import { timesTampChange } from '@/utils/date'
  75. const props = defineProps({
  76. list: { type: Array, default: () => [] },
  77. noMore: { type: Boolean, default: false },
  78. showWelfareTag: { type: Boolean, default: true }
  79. })
  80. //岗位详情
  81. const toDetail = (item) =>{
  82. const url = `/pagesB/positionDetail/index?id=${item.job?.id}&area=${item.job.areaName}`
  83. uni.navigateTo({ url })
  84. }
  85. </script>
  86. <style scoped lang="scss">
  87. .noMore{
  88. margin: 20px 0;
  89. }
  90. .date-time{
  91. color:#d9d0d2;
  92. float: right;
  93. }
  94. .divided-line {
  95. width: 100%;
  96. height: 1px;
  97. background-color: #f0f2f7;
  98. margin: 20px 0;
  99. }
  100. .enterAvatar{
  101. width: 40px;
  102. height: 40px;
  103. border-radius: 50%;
  104. margin: auto;
  105. }
  106. .job-name {
  107. font-size: 16px;
  108. font-weight: 700;
  109. color: #345768;
  110. max-width: 50vw;
  111. overflow: hidden;
  112. white-space: nowrap;
  113. text-overflow: ellipsis;
  114. }
  115. .sub-li-bottom {
  116. display: flex;
  117. align-items: center;
  118. background-color: #fff;
  119. font-size: 13px;
  120. padding: 5px;
  121. border-radius: 0 0 12px 12px;
  122. .avatarBox {
  123. max-width: 40px;
  124. max-height: 40px;
  125. }
  126. }
  127. .salary-text {
  128. float: right;
  129. color: #CEC149;
  130. font-weight: 700;
  131. }
  132. .list-shape {
  133. padding: 10px 30rpx 10px;
  134. background-color: #fff;
  135. border-radius: 12px 12px 0 0;
  136. .titleBox {
  137. display: flex;
  138. align-items: center;
  139. justify-content: space-between;
  140. }
  141. }
  142. .tag-gap{
  143. margin: 10rpx 10rpx 10rpx 0;
  144. }
  145. .tag-gap1{
  146. margin-bottom: 20px;
  147. }
  148. .divider-mx{
  149. margin: 0 10rpx;
  150. }
  151. .divider {
  152. color:#e4d4d2;
  153. }
  154. //公司名称
  155. .cer-end{
  156. position: absolute;
  157. top: 85%;
  158. right: 16%;
  159. }
  160. .cer-text{
  161. text-decoration: underline;
  162. margin: 0 5rpx;
  163. }
  164. //一行展示不全...
  165. .dis{
  166. display: flex;
  167. align-items: center;
  168. }
  169. .show-more{
  170. width: 26vw;
  171. white-space: nowrap;
  172. overflow: hidden;
  173. text-overflow: ellipsis;
  174. }
  175. .mList {
  176. margin-bottom: 20rpx;
  177. }
  178. /* 列表触底暂无更多 */
  179. .noMore{ text-align:center; color:grey; }
  180. .mt { margin-top: 15rpx; }
  181. .mb { margin-bottom: 10rpx; }
  182. .ml { margin-left: 20rpx; }
  183. .mr { margin-right: 20rpx; }
  184. .mr-10{ margin-right: 10rpx; }
  185. .my-5{ margin: 5px 0; }
  186. .disable {
  187. position: relative;
  188. overflow: hidden;
  189. &::after {
  190. content: '已失效';
  191. position: absolute;
  192. display: flex;
  193. align-items: center;
  194. justify-content: center;
  195. font-size: 1.2em;
  196. font-weight: bold;
  197. color: #fc796f;
  198. top: 0;
  199. border-radius: 12px;
  200. left: 0;
  201. width: 100%;
  202. height: 100%;
  203. background-color: rgba(255, 255, 255, 0.75);
  204. }
  205. }
  206. </style>