item.vue 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. <template>
  2. <view v-if="list.length > 0">
  3. <view v-for="(item, index) in list" :key="index" class="list-item defaultBgc default-border">
  4. <view class="sub-li-bottom" @click.stop="jumpToEnterpriseDetail(item.enterprise?.id)">
  5. <view class="avatarBox">
  6. <image class="enterAvatar" :src="item.enterprise?.logoUrl || 'https://minio.citupro.com/dev/menduner/company-avatar.png'"></image>
  7. </view>
  8. <view>
  9. <span class="ss-m-x-20 color-66 MiSans-Medium" style="font-weight: bold;">{{ item.contact?.name || ' -- ' }}</span>
  10. <span class="MiSans-Normal ss-m-r-10">{{ item.contact?.postNameCn }}</span>
  11. <span class="ss-m-r-10 MiSans-Normal">{{ item.invitePhone }}</span>
  12. </view>
  13. </view>
  14. <!-- 职位信息 -->
  15. <view class="list-shape ss-m-t-30">
  16. <view class="titleBox" @click="toDetail(item)">
  17. <span class="MiSans-Semibold" style="font-size: 16px;font-weight: 700; color: #0E100F;">{{ formatName(item.job?.name) }}</span>
  18. <span v-if="!item.job?.payFrom && !item.job?.payTo" class="salary-text MiSans-Semibold">面议</span>
  19. <span v-else class="salary-text MiSans-Semibold">{{ item.job?.payFrom }}-{{ item.job?.payTo }}{{ item.job?.payName ? '/' + item.job?.payName : '' }}</span>
  20. </view>
  21. <!-- 面试时间、地点 -->
  22. <view class="color-666 font-size-14 ss-m-t-20" @click="toDetail(item)">
  23. <view class="MiSans-Normal">面试时间:{{ timesTampChange(item.time, 'Y-M-D h:m') }}</view>
  24. <view class="ss-m-t-20 MiSans-Normal">面试地点:{{ item.address }}</view>
  25. </view>
  26. <view v-if="item.status === '0'">
  27. <view class="ss-m-y-30" style="border-top: 1rpx solid #E1E4E9;"></view>
  28. <view class="d-flex justify-end">
  29. <span class="MiSans-Normal" style="color: #dd524d;text-decoration: underline;" @click="handleAction(item, 'refuse')">拒绝</span>
  30. <span class="MiSans-Normal" style="color: #00B760;margin-left: 65rpx;text-decoration: underline;" @click="handleAction(item, 'agree')">同意</span>
  31. </view>
  32. </view>
  33. </view>
  34. </view>
  35. </view>
  36. </template>
  37. <script setup>
  38. import { timesTampChange } from '@/utils/date'
  39. import { formatName } from '@/utils/getText'
  40. import { jumpToEnterpriseDetail } from '@/utils/position'
  41. const emits = defineEmits(['action'])
  42. const props = defineProps({
  43. list: { type: Array, default: () => [] }
  44. })
  45. //岗位详情
  46. const toDetail = (item) =>{
  47. uni.navigateTo({ url: `/pagesB/positionDetail/index?id=${item.job?.id}&area=${item.job.area?.str ?? '全国'}` })
  48. }
  49. const handleAction = (item, type) => {
  50. emits('action', item, type)
  51. }
  52. </script>
  53. <style scoped lang="scss">
  54. .list-item {
  55. margin: 30rpx;
  56. border-radius: 20rpx;
  57. padding: 30rpx;
  58. &:last-child {
  59. margin-bottom: 0;
  60. }
  61. }
  62. .enterAvatar{
  63. width: 40px;
  64. height: 40px;
  65. border-radius: 50%;
  66. margin: auto;
  67. }
  68. .sub-li-bottom {
  69. display: flex;
  70. align-items: center;
  71. font-size: 13px;
  72. .avatarBox {
  73. max-width: 40px;
  74. max-height: 40px;
  75. }
  76. }
  77. .salary-text {
  78. float: right;
  79. color: #00B760;
  80. font-weight: 700;
  81. }
  82. .list-shape {
  83. .titleBox {
  84. display: flex;
  85. align-items: center;
  86. justify-content: space-between;
  87. }
  88. }
  89. </style>