index.vue 5.9 KB

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