tagManage.vue 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515
  1. <template>
  2. <view class="tag-manage">
  3. <!-- 顶部导航 -->
  4. <view class="nav-bar">
  5. <view class="nav-left" @click="goBack">
  6. <u-icon name="arrow-leftward" color="#fff" style="font-size: 38rpx;"></u-icon>
  7. </view>
  8. <view class="nav-title">期望职位</view>
  9. <view class="nav-right"></view>
  10. </view>
  11. <view class="tag-manage-text1">哪个岗位是你的心仪工作?</view>
  12. <view class="tag-manage-text">可以添加多个求职期望,获得更多精准推荐机会</view>
  13. <!-- 全职期望卡片 -->
  14. <view class="expectation-card">
  15. <view class="card-header">
  16. <view class="header-left">
  17. <image src="../../static/images/index/lingdai.svg" class="header-icon" />
  18. <text class="header-title">全职期望</text>
  19. </view>
  20. <text class="progress-text">2/3</text>
  21. </view>
  22. <view class="job-list">
  23. <view class="job-item">
  24. <view class="job-info">
  25. <view>
  26. <text class="job-title">亚马逊运营总监</text>
  27. <view @click="goToPreferenceSetting('亚马逊运营总监')">
  28. <view class="preference-btn">
  29. <text>设置求职偏好</text>
  30. </view>
  31. <u-icon name="arrow-right" color="rgba(29, 33, 41, 1)" size="28"></u-icon>
  32. </view>
  33. </view>
  34. <text class="job-details">30-40K・不限</text>
  35. <text class="job-location">深圳</text>
  36. </view>
  37. </view>
  38. <view class="job-item">
  39. <view class="job-info">
  40. <view>
  41. <text class="job-title">TikTok运营总监</text>
  42. <view @click="goToPreferenceSetting('TikTok运营总监')">
  43. <view class="preference-btn">
  44. <text>设置求职偏好</text>
  45. </view>
  46. <u-icon name="arrow-right" color="rgba(29, 33, 41, 1)" size="28"></u-icon>
  47. </view>
  48. </view>
  49. <text class="job-details">30-40K・精品铺货</text>
  50. <text class="job-location">深圳</text>
  51. </view>
  52. </view>
  53. </view>
  54. <view class="add-expectation-btn" @click="addExpectation">
  55. <text>添加求职期望</text>
  56. </view>
  57. </view>
  58. <!-- 求职状态卡片 -->
  59. <view class="status-card">
  60. <view class="status-item" @click="showJobStatusPicker">
  61. <text class="status-label">求职状态</text>
  62. <view class="status-value">
  63. <text>{{ selectedJobStatus }}</text>
  64. <u-icon name="arrow-right" color="rgba(29, 33, 41, 1)" size="24"></u-icon>
  65. </view>
  66. </view>
  67. </view>
  68. <!-- 求职状态选择器 -->
  69. <u-popup v-model="showJobStatusModal" mode="bottom" border-radius="42" height="auto" :safe-area-inset-bottom="true">
  70. <view class="job-status-picker">
  71. <view class="picker-header">
  72. <text class="picker-title">求职状态</text>
  73. </view>
  74. <view class="picker-content">
  75. <view
  76. class="status-option"
  77. :class="{ active: selectedJobStatus === item.text }"
  78. v-for="item in jobStatusList"
  79. :key="item.value"
  80. @click="selectJobStatus(item)"
  81. >
  82. <view class="option-left">
  83. <view class="radio-btn" :class="{ checked: selectedJobStatus === item.text }">
  84. <u-icon v-if="selectedJobStatus === item.text" name="checkmark" color="#ffffff" size="28"></u-icon>
  85. </view>
  86. <text class="option-text">{{ item.text }}</text>
  87. <view v-if="item.recommended" class="recommend-tag">
  88. <text>推荐</text>
  89. </view>
  90. </view>
  91. </view>
  92. </view>
  93. </view>
  94. </u-popup>
  95. </view>
  96. </template>
  97. <script>
  98. export default {
  99. data() {
  100. return {
  101. showJobStatusModal: false,
  102. selectedJobStatus: '在职-考虑机会',
  103. jobStatusList: [
  104. {
  105. value: 'unemployed_available',
  106. text: '离职-随时到岗',
  107. recommended: true
  108. },
  109. {
  110. value: 'employed_monthly',
  111. text: '在职-月内到岗',
  112. recommended: true
  113. },
  114. {
  115. value: 'employed_considering',
  116. text: '在职-考虑机会',
  117. recommended: false
  118. },
  119. {
  120. value: 'employed_not_considering',
  121. text: '在职-暂不考虑',
  122. recommended: false
  123. }
  124. ]
  125. }
  126. },
  127. methods: {
  128. goBack() {
  129. uni.navigateBack()
  130. },
  131. addExpectation() {
  132. uni.navigateTo({
  133. url: '/package/jobIntention/addExpectation'
  134. })
  135. },
  136. showJobStatusPicker() {
  137. this.showJobStatusModal = true
  138. },
  139. closeJobStatusPicker() {
  140. this.showJobStatusModal = false
  141. },
  142. selectJobStatus(item) {
  143. this.selectedJobStatus = item.text
  144. this.showJobStatusModal = false
  145. // 可以在这里添加保存状态的逻辑
  146. console.log('选择的求职状态:', item)
  147. },
  148. goToPreferenceSetting(jobTitle) {
  149. uni.navigateTo({
  150. url: `/package/jobIntention/preferenceSetting?jobTitle=${encodeURIComponent(jobTitle)}`
  151. })
  152. }
  153. },
  154. mounted() {
  155. // 监听偏好设置更新
  156. uni.$on('preferenceUpdated', (data) => {
  157. console.log('偏好设置已更新:', data)
  158. // 这里可以更新对应的职位偏好显示
  159. uni.showToast({
  160. title: `${data.jobTitle}偏好已更新`,
  161. icon: 'success'
  162. })
  163. })
  164. },
  165. beforeDestroy() {
  166. // 移除事件监听
  167. uni.$off('preferenceUpdated')
  168. }
  169. }
  170. </script>
  171. <style lang="scss" scoped>
  172. .tag-manage {
  173. min-height: 100vh;
  174. background: url('../../static/images/index/zhiwei.png') no-repeat;
  175. background-size: 100% 40%; /* 宽度100%,高度60% */
  176. background-position: top center;
  177. padding: 88rpx 40rpx 40rpx 40rpx;
  178. }
  179. .tag-manage-text1 {
  180. color: rgba(255, 255, 255, 1);
  181. font-family: DM Sans;
  182. font-size: 52rpx;
  183. font-weight: 700;
  184. line-height: 30px;
  185. letter-spacing: 0px;
  186. text-align: left;
  187. margin: 40rpx 0 30rpx 0;
  188. }
  189. .tag-manage-text {
  190. color: rgba(255, 255, 255, 1);
  191. font-family: DM Sans;
  192. font-size: 26rpx;
  193. font-weight: 400;
  194. line-height: 16px;
  195. letter-spacing: 0px;
  196. text-align: left;
  197. margin-bottom: 30rpx;
  198. }
  199. /* 全职期望卡片 */
  200. .expectation-card {
  201. background: #ffffff;
  202. border-radius: 12rpx;
  203. padding: 30rpx;
  204. margin-bottom: 20rpx;
  205. box-sizing: border-box;
  206. border: 0.5px solid rgba(227, 231, 236, 1);
  207. border-radius: 6px;
  208. background: rgba(253, 253, 253, 1);
  209. .card-header {
  210. display: flex;
  211. justify-content: space-between;
  212. align-items: center;
  213. .header-left {
  214. display: flex;
  215. align-items: center;
  216. .header-icon {
  217. width: 40rpx;
  218. height: 40rpx;
  219. margin-right: 20rpx;
  220. }
  221. .header-title {
  222. color: rgba(29, 33, 41, 1);
  223. font-family: DM Sans;
  224. font-size: 28rpx;
  225. font-weight: 500;
  226. line-height: 16px;
  227. letter-spacing: 0%;
  228. text-align: left;
  229. }
  230. }
  231. .progress-text {
  232. font-family: DM Sans;
  233. font-size: 24rpx;
  234. font-weight: 700;
  235. line-height: 13px;
  236. letter-spacing: 0%;
  237. text-align: right;
  238. }
  239. }
  240. .job-list {
  241. margin-bottom: 10rpx;
  242. .job-item {
  243. display: flex;
  244. justify-content: space-between;
  245. align-items: center;
  246. padding: 20rpx 0;
  247. &:last-child {
  248. border-bottom: none;
  249. }
  250. .job-info {
  251. flex: 1;
  252. > view:first-child {
  253. display: flex;
  254. justify-content: space-between;
  255. align-items: center;
  256. margin-bottom: 4rpx;
  257. }
  258. .job-title {
  259. color: rgba(29, 33, 41, 1);
  260. font-family: DM Sans;
  261. font-size: 28rpx;
  262. font-weight: 500;
  263. line-height: 16px;
  264. letter-spacing: 0%;
  265. text-align: left;
  266. }
  267. .job-details {
  268. display: block;
  269. font-size: 24rpx;
  270. color: rgba(153, 153, 153, 1);
  271. margin-bottom: 4rpx;
  272. }
  273. .job-location {
  274. font-size: 24rpx;
  275. color: rgba(153, 153, 153, 1);
  276. }
  277. }
  278. .preference-btn {
  279. display: flex;
  280. align-items: center;
  281. padding: 8rpx;
  282. border: 0.5rpx solid #007AFF;
  283. border-radius: 12rpx;
  284. margin-right: 10rpx;
  285. text {
  286. font-size: 18rpx;
  287. color: #007AFF;
  288. }
  289. }
  290. .job-info > view:first-child > view:last-child {
  291. display: flex;
  292. align-items: center;
  293. }
  294. }
  295. }
  296. .add-expectation-btn {
  297. width: 100%;
  298. height: 80rpx;
  299. border: 1rpx solid #007AFF;
  300. border-radius: 42rpx;
  301. display: flex;
  302. align-items: center;
  303. justify-content: center;
  304. text {
  305. font-size: 28rpx;
  306. color: #007AFF;
  307. font-weight: 500;
  308. }
  309. }
  310. }
  311. /* 求职状态卡片 */
  312. .status-card {
  313. background: #ffffff;
  314. border-radius: 20rpx;
  315. padding: 30rpx;
  316. box-sizing: border-box;
  317. border: 0.5px solid rgba(227, 231, 236, 1);
  318. border-radius: 6px;
  319. background: rgba(253, 253, 253, 1);
  320. .status-item {
  321. display: flex;
  322. justify-content: space-between;
  323. align-items: center;
  324. .status-label {
  325. color: rgba(29, 33, 41, 1);
  326. font-family: DM Sans;
  327. font-size: 28rpx;
  328. font-weight: 500;
  329. line-height: 16px;
  330. letter-spacing: 0%;
  331. text-align: left;
  332. }
  333. .status-value {
  334. display: flex;
  335. align-items: center;
  336. text {
  337. color: rgba(153, 153, 153, 1);
  338. font-family: DM Sans;
  339. font-size: 24rpx;
  340. font-weight: 400;
  341. line-height: 13px;
  342. letter-spacing: 0%;
  343. text-align: left;
  344. margin-right: 10rpx;
  345. }
  346. }
  347. }
  348. }
  349. .nav-bar {
  350. display: flex;
  351. align-items: center;
  352. justify-content: space-between;
  353. padding: 20rpx auto;
  354. .nav-left {
  355. display: flex;
  356. align-items: center;
  357. justify-content: center;
  358. }
  359. .nav-title {
  360. color: rgba(255, 255, 255, 1);
  361. font-family: DM Sans;
  362. font-size: 32rpx;
  363. font-weight: 700;
  364. line-height: 26px;
  365. letter-spacing: undefined;
  366. text-align: center;
  367. }
  368. }
  369. /* 求职状态选择器样式 */
  370. .job-status-picker {
  371. background: #fff;
  372. border-radius: 20rpx 20rpx 0 0;
  373. overflow: hidden;
  374. }
  375. .picker-header {
  376. display: flex;
  377. justify-content: center;
  378. align-items: center;
  379. padding: 30rpx 40rpx 20rpx;
  380. border-bottom: 1rpx solid #F2F2F2;
  381. position: relative;
  382. .picker-title {
  383. color: rgba(34, 37, 42, 1);
  384. font-family: DM Sans;
  385. font-size: 36rpx;
  386. font-weight: 500;
  387. line-height: 23px;
  388. letter-spacing: 0px;
  389. text-align: center;
  390. }
  391. .picker-close {
  392. width: 60rpx;
  393. height: 60rpx;
  394. display: flex;
  395. align-items: center;
  396. justify-content: center;
  397. }
  398. }
  399. .picker-content {
  400. padding: 32rpx;
  401. }
  402. .status-option {
  403. display: flex;
  404. flex-direction: row;
  405. justify-content: flex-start;
  406. align-items: center;
  407. padding: 16rpx 28rpx;
  408. box-sizing: border-box;
  409. border: 1px solid rgba(227, 231, 236, 1);
  410. border-radius: 24px;
  411. background: rgba(255, 255, 255, 1);
  412. margin-bottom: 32rpx;
  413. &:active {
  414. background-color: #F9F9F9;
  415. }
  416. .option-left {
  417. display: flex;
  418. align-items: center;
  419. flex: 1;
  420. .radio-btn {
  421. width: 40rpx;
  422. height: 40rpx;
  423. border: 2rpx solid #E5E5EA;
  424. border-radius: 50%;
  425. display: flex;
  426. align-items: center;
  427. justify-content: center;
  428. margin-right: 24rpx;
  429. background: #fff;
  430. transition: all 0.2s;
  431. &.checked {
  432. border-color: #007AFF;
  433. background: #007AFF;
  434. }
  435. }
  436. .option-text {
  437. font-size: 28rpx;
  438. color: rgba(29, 33, 41, 1);
  439. font-weight: 400;
  440. }
  441. }
  442. .recommend-tag {
  443. background: rgba(153, 196, 250, 0.4);
  444. border-radius: 8rpx;
  445. padding: 0 8rpx;
  446. margin-bottom: 0 !important;
  447. margin-left: 20rpx;
  448. text {
  449. font-size: 16rpx;
  450. line-height: 16rpx;
  451. color: rgba(1, 107, 246, 1);
  452. }
  453. }
  454. }
  455. .picker-content :last-child {
  456. margin-bottom: 0rpx;
  457. }
  458. </style>