recruitDetail.vue 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622
  1. <template>
  2. <view class="content">
  3. <view class="box">
  4. <view class="hflex acenter jbetween">
  5. <view class="top">{{pageData.title}}</view>
  6. <view class="text_blue">{{pageData.salary_start}}-{{pageData.salary_end}}</view>
  7. </view>
  8. <view class="hflex acenter fwrap">
  9. <view class="box_item" v-if="pageData.number_person">招{{pageData.number_person}}人</view>
  10. <view class="box_item" v-if="pageData.experience">{{pageData.experience}}</view>
  11. <view class="box_item" v-if="pageData.schooling">{{pageData.schooling}}</view>
  12. <view class="box_item" v-if="pageData.age">{{pageData.age}}</view>
  13. <view class="box_item" v-if="pageData.sex">{{pageData.sex}}性</view>
  14. </view>
  15. </view>
  16. <view class="box">
  17. <view class="hflex acenter">
  18. <image :src="pageData.contact_headimg" class="headimg"></image>
  19. <view class="text1">{{pageData.contact_person}}</view>
  20. </view>
  21. <view class="hflex acenter padT-26">
  22. <u-icon name="phone-fill" color="#666666" size="14" class="padR-24"></u-icon>
  23. <view class="text_style1">{{pageData.contact_phone}}<span style="color: #506dff;" @click="tall(pageData.contact_phone)"><span style="padding: 0 5rpx;">|</span>拨打</span></view>
  24. </view>
  25. <view class="hflex acenter padT-26">
  26. <image src="/static/images/index/demand/email.png" class="icon"></image>
  27. <view class="text_style1">{{pageData.contact_email}}<span style="color: #506dff;" @click="copy(pageData.contact_email)"><span style="padding: 0 5rpx;">|</span>复制</span></view>
  28. </view>
  29. </view>
  30. <view class="box">
  31. <view class="box_title">职位描述</view>
  32. <view class="desc">
  33. <view class="hflex pad_tb10">
  34. <view class="label">地区范围</view>
  35. <view class="text_style1">{{pageData.province}}{{pageData.city}}{{pageData.area}}{{pageData.address}}</view>
  36. </view>
  37. <view class="hflex acenter pad_tb10">
  38. <view class="label">用工时间</view>
  39. <view class="text_style1">{{pageData.working_time}}</view>
  40. </view>
  41. <view class="hflex acenter pad_tb10">
  42. <view class="label">用工性质</view>
  43. <view class="text_style1">{{pageData.work_nature}}</view>
  44. </view>
  45. </view>
  46. </view>
  47. <view class="box">
  48. <view class="box_title">必备技能</view>
  49. <view class="">
  50. <view class="text2">{{pageData.necessary_skills}}</view>
  51. <!-- <block v-for="(item,index) in pageData.necessary_skills" :key="index">
  52. <view class="text2">{{index+1}}.{{item.name}}</view>
  53. </block> -->
  54. </view>
  55. <view class="box_title" style="padding-top: 20rpx;">证书</view>
  56. <view class="hflex acenter">
  57. <view class="text2">{{pageData.certificate}}</view>
  58. <!-- <block v-for="(item,index) in pageData.certificate" :key="index">
  59. <view class="text2">{{item.name}}</view>
  60. </block> -->
  61. </view>
  62. </view>
  63. <view class="box">
  64. <view class="box_title">福利待遇</view>
  65. <view class="text2">{{pageData.welfare_benefits}}</view>
  66. </view>
  67. <view class="box" style="margin-bottom: 186rpx;">
  68. <view class="box_title">备注</view>
  69. <view class="text2">{{pageData.remark}}</view>
  70. </view>
  71. <view class="bottom hflex acenter jbetween">
  72. <view class="hflex acenter">
  73. <view class="vflex acenter" style="margin-right: 20rpx;" @click="collect">
  74. <u-icon name="star" color="#444444" size="20" v-if="pageData.is_collection == 0"></u-icon>
  75. <u-icon name="star-fill" color="#506DFF" size="20" v-else></u-icon>
  76. <view class="text_style1">收藏</view>
  77. </view>
  78. <view class="vflex acenter" @click="share('Poster1')">
  79. <image src="https://ship-expert.zhousi.hdlkeji.com/common/share.png" mode="" class="bottom_img"></image>
  80. <view class="text_style1">分享</view>
  81. </view>
  82. </view>
  83. <view class="left_btn hflex acenter jcenter" @click="like">
  84. <u-icon name="heart" color="#506DFF" size="20" v-if="pageData.is_like == 0"></u-icon>
  85. <u-icon name="heart-fill" color="#506DFF" size="20" v-else></u-icon>
  86. <view class="btn_text">感兴趣</view>
  87. </view>
  88. <view class="right_btn hflex acenter jcenter" @click="into_chatroom" v-if="pageData.huanxinID">
  89. <image src="https://ship-expert.zhousi.hdlkeji.com/common/chat.png" class="btn_icon"></image>
  90. <view class="btn_text2">立即沟通</view>
  91. </view>
  92. </view>
  93. <view class="share_content" :class="share_show?'':'share_content1'">
  94. <!-- <view style="width: 100%;height: 168rpx;"></view> -->
  95. <view class="share_box vflex">
  96. <view class="hflex acenter">
  97. <image class="Poster1 pos_img" data-etype="image" :data-enode="posImg" :src="posImg"></image>
  98. <view class="vflex">
  99. <view class="Poster1 pos_title" :data-enode="pageData.title">{{pageData.title}}</view>
  100. <view class="Poster1 pos_subtitle" :data-enode="pageData.salary_start+'-'+pageData.salary_end">{{pageData.salary_start}}-{{pageData.salary_end}}</view>
  101. </view>
  102. </view>
  103. <view class="Poster1 pos_title2" data-enode="职位描述">职位描述</view>
  104. <view class="hflex acenter">
  105. <view class="label Poster1" data-enode="地区范围">地区范围</view>
  106. <view class="Poster1 text" :data-enode="pageData.province + pageData.city + pageData.area + pageData.address">{{pageData.province}}{{pageData.city}}{{pageData.area}}{{pageData.address}}</view>
  107. </view>
  108. <view class="hflex acenter">
  109. <view class="label Poster1" data-enode="用工时间">用工时间</view>
  110. <view class="Poster1 text" :data-enode="pageData.working_time">{{pageData.working_time}}</view>
  111. </view>
  112. <view class="hflex acenter">
  113. <view class="label Poster1" data-enode="用工性质">用工性质</view>
  114. <view class="Poster1 text" :data-enode="pageData.work_nature">{{pageData.work_nature}}</view>
  115. </view>
  116. <view class="hflex acenter share_text jcenter Poster1" style=" margin: 0 190rpx 12rpx;" data-enode="长按或扫码查看">扫码查看职位详情</view>
  117. <view style="width: 100%;" class="vflex acenter jcenter">
  118. <image class="Poster1" style="width: 25rpx;height: 20rpx;" :data-enode="style.img1" data-etype="image" :src="style.img1"></image>
  119. <image class="Poster1" style="width: 100%;height: 2rpx;margin: 30rpx 0;" :data-enode="style.img2" data-etype="image" :src="style.img2"></image>
  120. </view>
  121. <view class="hflex acenter jbetween">
  122. <view class="vflex">
  123. <view class="share_name Poster1" style="margin: 54rpx 0 20rpx;" data-enode="船百知">船百知</view>
  124. <view class="share_text Poster1" style="margin: 0 0 36rpx;" data-enode="船百知伴你一起杨帆启航,驶向成功彼岸">船百知伴你一起杨帆启航,驶向成功彼岸</view>
  125. </view>
  126. <image class="Poster1" data-etype="image" :data-enode="style.code" :src="style.code" style="width: 136rpx;height: 136rpx;"></image>
  127. <!-- <image class="Poster1" data-etype="image" :data-enode="pageData.contact_headimg" :src="pageData.contact_headimg" style="width: 136rpx;height: 136rpx;"></image> -->
  128. </view>
  129. </view>
  130. <evils-el-poster width="325" height="467" @on-error="onError" :list="list" backgroundColor="rgb(255, 255, 255)" @on-success="onSuccess" ref="Eposter"></evils-el-poster>
  131. <view class="share_bottom">
  132. <view class="hflex acenter jcenter">
  133. <button class="vflex acenter jcenter bottom_item" open-type="share">
  134. <image src="https://ship-expert.zhousi.hdlkeji.com/common/wx.png" class="item_icon"></image>
  135. <view class="item_text">微信好友</view>
  136. </button>
  137. <!-- <button class="vflex acenter jcenter bottom_item" open-type="share">
  138. <image src="https://ship-expert.zhousi.hdlkeji.com/common/moments.png" class="item_icon"></image>
  139. <view class="item_text">朋友圈</view>
  140. </button> -->
  141. <view class="vflex acenter jcenter bottom_item" @click="saveImg">
  142. <image src="https://ship-expert.zhousi.hdlkeji.com/common/download.png" class="item_icon"></image>
  143. <view class="item_text">保存图片</view>
  144. </view>
  145. </view>
  146. <view class="share_cancel" @click="close">取消</view>
  147. </view>
  148. </view>
  149. </view>
  150. </template>
  151. <script>
  152. import $api from '@/static/js/api.js'
  153. var that = ''
  154. export default {
  155. data() {
  156. return {
  157. pageData: {},
  158. id: '',
  159. share_show: false,
  160. posImg: 'https://ship-expert.zhousi.hdlkeji.com/common/company2.png',
  161. list: {},
  162. style: {
  163. img1: 'https://ship-expert.zhousi.hdlkeji.com/common/down2.png',
  164. img2: 'https://ship-expert.zhousi.hdlkeji.com/common/line.png',
  165. code: 'https://ship-expert.zhousi.hdlkeji.com/common/code.jpg'
  166. },
  167. }
  168. },
  169. onLoad(options) {
  170. that = this
  171. that.id = options.id
  172. that.getData()
  173. let view = uni.createSelectorQuery().in(this).select(".Poster1");
  174. view.fields({
  175. size: true,
  176. rect: true,
  177. scrollOffset: true
  178. }, data => {
  179. }).exec();
  180. },
  181. onShareAppMessage(res) {
  182. console.log(res);
  183. if (res.from === 'button') {// 来自页面内分享按钮
  184. console.log(res.target)
  185. }
  186. return {
  187. title: '船百知', //分享的名称
  188. }
  189. },
  190. onShareTimeline(res) {
  191. console.log(res);
  192. return {
  193. title: '船百知',
  194. type: 0,
  195. summary: "",
  196. }
  197. },
  198. methods: {
  199. getData() {
  200. $api.req({
  201. url: '/data/api.auth.DemandLabor/demanddetail',
  202. method: 'POST',
  203. data: {
  204. type: 1,
  205. id: that.id
  206. }
  207. }, function(res) {
  208. if(res.code == 1) {
  209. console.log(res);
  210. that.pageData = res.data
  211. }
  212. })
  213. },
  214. // 复制
  215. copy(value) {
  216. uni.setClipboardData({
  217. data: value,
  218. success: function () {
  219. $api.info('复制成功')
  220. }
  221. });
  222. },
  223. tall(value) {
  224. uni.makePhoneCall({
  225. phoneNumber: value
  226. });
  227. },
  228. collect() {
  229. $api.req({
  230. url: '/data/api.auth.DemandLabor/cocanclecollection',
  231. method: 'POST',
  232. data: {
  233. type: 1,
  234. id: that.id,
  235. category: that.pageData.is_collection + 1
  236. }
  237. }, function(res) {
  238. if(res.code == 1) {
  239. $api.info(res.info)
  240. if(that.pageData.is_collection) {
  241. that.pageData.is_collection = 0
  242. } else {
  243. that.pageData.is_collection = 1
  244. }
  245. }
  246. })
  247. },
  248. like() {
  249. $api.req({
  250. url: '/data/api.auth.DemandLabor/cocanclelike',
  251. method: 'POST',
  252. data: {
  253. type: 1,
  254. id: that.id,
  255. category: that.pageData.is_like + 1
  256. }
  257. }, function(res) {
  258. if(res.code == 1) {
  259. $api.info(res.info)
  260. if(that.pageData.is_like) {
  261. that.pageData.is_like = 0
  262. } else {
  263. that.pageData.is_like = 1
  264. }
  265. }
  266. })
  267. },
  268. into_chatroom() {
  269. var my = uni.getStorageSync("myUsername");
  270. var nameList = {
  271. myName: my,
  272. your: that.pageData.huanxinID,
  273. };
  274. uni.navigateTo({
  275. url: "/pages/chatroom/chatroom?username=" + JSON.stringify(nameList),
  276. });
  277. },
  278. share(elClass) {
  279. that.share_show = true
  280. that.$refs.Eposter.createForElRect(elClass,false)
  281. },
  282. close() {
  283. that.share_show = false
  284. },
  285. onSuccess(e) {
  286. console.log('返回的地址',e);
  287. that.tempImage = e
  288. },
  289. onError(err) {
  290. console.log('发生错误');
  291. console.log(err);
  292. },
  293. saveImg() {
  294. console.log('准备保存的图片',that.tempImage);
  295. uni.authorize({
  296. scope: 'scope.writePhotosAlbum',
  297. success() {
  298. uni.saveImageToPhotosAlbum({
  299. filePath: that.tempImage,
  300. success: function () {
  301. console.log('save success');
  302. $api.info('保存成功')
  303. that.close()
  304. }
  305. });
  306. }
  307. })
  308. },
  309. },
  310. }
  311. </script>
  312. <style lang="scss" scoped>
  313. .content {
  314. .box {
  315. width: 690rpx;
  316. margin: 0 30rpx;
  317. box-sizing: border-box;
  318. padding: 20rpx 0;
  319. border-bottom: 1rpx solid #F4F4F4;
  320. .top {
  321. font-size: 40rpx;
  322. font-weight: 500;
  323. color: #222222;
  324. line-height: 56rpx;
  325. padding: 24rpx 0 20rpx;
  326. }
  327. .text_blue {
  328. font-size: 32rpx;
  329. font-weight: 400;
  330. color: #506DFF;
  331. line-height: 40rpx;
  332. }
  333. .box_item {
  334. width: auto;
  335. height: 40rpx;
  336. background: #F0F2F6;
  337. border-radius: 4rpx;
  338. margin: 0 20rpx 20rpx 0;
  339. padding: 0 16rpx;
  340. font-size: 22rpx;
  341. font-weight: 400;
  342. color: #444444;
  343. line-height: 40rpx;
  344. }
  345. .headimg {
  346. width: 72rpx;
  347. height: 72rpx;
  348. border-radius: 50%;
  349. margin-right: 20rpx;
  350. }
  351. .text1 {
  352. font-size: 30rpx;
  353. font-weight: 500;
  354. color: #222222;
  355. line-height: 42rpx;
  356. }
  357. .padT-26 {
  358. padding-top: 26rpx;
  359. }
  360. .padR-24 {
  361. padding-right: 24rpx;
  362. }
  363. .label {
  364. width: 20%;
  365. font-size: 24rpx;
  366. font-weight: 400;
  367. color: #444444;
  368. }
  369. .icon {
  370. width: 28rpx;
  371. height: 28rpx;
  372. }
  373. .text_style1 {
  374. width: 80%;
  375. font-size: 24rpx;
  376. padding-left: 5rpx;
  377. font-weight: 400;
  378. color: #666666;
  379. }
  380. .box_title {
  381. font-size: 32rpx;
  382. font-weight: 500;
  383. color: #222222;
  384. }
  385. .desc {
  386. margin: 16rpx 0 0;
  387. background: #F7F7F7;
  388. border-radius: 8px;
  389. box-sizing: border-box;
  390. padding: 24rpx 20rpx;
  391. .pad_tb10 {
  392. padding: 10rpx 0;
  393. }
  394. }
  395. .text2 {
  396. font-size: 24rpx;
  397. font-weight: 400;
  398. color: #333333;
  399. line-height: 34rpx;
  400. padding: 16rpx 0 0;
  401. }
  402. }
  403. .bottom {
  404. width: 100%;
  405. z-index: 9;
  406. position: fixed;
  407. bottom: 0;
  408. height: 166rpx;
  409. background: #FFFFFF;
  410. box-sizing: border-box;
  411. box-shadow: 0px -1px 0px 0px #F4F4F4;
  412. padding: 8rpx 30rpx 74rpx;
  413. .text_style1 {
  414. font-size: 20rpx;
  415. font-weight: 400;
  416. color: #444444;
  417. }
  418. .left_btn {
  419. width: 230rpx;
  420. height: 80rpx;
  421. background: #F1F6FF;
  422. border-radius: 42rpx;
  423. }
  424. .btn_text {
  425. font-size: 32rpx;
  426. font-weight: 500;
  427. color: #506DFF;
  428. line-height: 44rpx;
  429. padding-left: 10rpx;
  430. }
  431. .right_btn {
  432. width: 270rpx;
  433. height: 80rpx;
  434. background: #506DFF;
  435. border-radius: 42rpx;
  436. margin-left: 20rpx;
  437. .btn_icon {
  438. width: 40rpx;
  439. height: 40rpx;
  440. }
  441. .btn_text2 {
  442. font-size: 32rpx;
  443. font-weight: 500;
  444. color: #FFFFFF;
  445. line-height: 44rpx;
  446. padding-left: 10rpx;
  447. }
  448. }
  449. .bottom_img {
  450. width: 40rpx;
  451. height: 40rpx;
  452. }
  453. }
  454. .share_content {
  455. position: fixed;
  456. top: 0;
  457. left: 0;
  458. z-index: 99;
  459. width: 100vw;
  460. height: 100vh;
  461. background: rgba(0,0,0,0.5);
  462. backdrop-filter: blur(5px);
  463. padding: 0 0 0;
  464. .pos_img {
  465. width: 112rpx;
  466. height: 112rpx;
  467. margin: 0 12rpx 0 0;
  468. }
  469. .pos_title {
  470. font-size: 32rpx;
  471. font-weight: 500;
  472. color: #222222;
  473. line-height: 44rpx;
  474. margin: 0 0 0 0;
  475. }
  476. .pos_subtitle {
  477. font-size: 32rpx;
  478. font-weight: 400;
  479. color: #506DFF;
  480. line-height: 40rpx;
  481. margin: 24rpx 0 0;
  482. }
  483. .pos_title2 {
  484. font-size: 28rpx;
  485. font-weight: 500;
  486. color: #222222;
  487. line-height: 40rpx;
  488. margin: 36rpx 0 28rpx;
  489. }
  490. .label {
  491. width: 120rpx;
  492. font-size: 24rpx;
  493. font-weight: 400;
  494. color: #444444;
  495. line-height: 34rpx;
  496. margin: 0 0 20rpx;
  497. }
  498. .text {
  499. font-size: 24rpx;
  500. font-weight: 400;
  501. color: #444444;
  502. line-height: 34rpx;
  503. margin: 0 0 20rpx;
  504. }
  505. .share_box {
  506. margin: 130rpx auto 0;
  507. width: 650rpx;
  508. background: #FFFFFF;
  509. border-radius: 20rpx;
  510. box-sizing: border-box;
  511. padding: 48rpx 40rpx 0;
  512. .share_name {
  513. width: 100%;
  514. font-size: 32rpx;
  515. font-weight: 500;
  516. color: #222222;
  517. line-height: 44rpx;
  518. }
  519. .share_label {
  520. width: 100%;
  521. font-size: 28rpx;
  522. font-weight: 400;
  523. color: #222222;
  524. line-height: 40rpx;
  525. }
  526. .share_text {
  527. width: 100%;
  528. font-size: 24rpx;
  529. font-weight: 400;
  530. color: #999999;
  531. line-height: 34rpx;
  532. text-overflow: ellipsis;
  533. overflow: hidden;
  534. display: -webkit-box;
  535. -webkit-box-orient: vertical;
  536. box-orient: vertical;
  537. line-clamp: 5;
  538. -webkit-line-clamp: 5;
  539. }
  540. .box_bottom {
  541. width: 100%;
  542. padding: 34rpx 0 16rpx;
  543. border-top: 1rpx dashed #C3C3C3;
  544. .bottom_left1 {
  545. font-size: 32rpx;
  546. font-weight: 500;
  547. color: #222222;
  548. line-height: 44rpx;
  549. padding-bottom: 20rpx;
  550. }
  551. .bottom_left2 {
  552. font-size: 22rpx;
  553. font-weight: 400;
  554. color: #999999;
  555. line-height: 32rpx;
  556. }
  557. .bottom_right {
  558. width: 136rpx;
  559. height: 136rpx;
  560. }
  561. }
  562. }
  563. .canvas {
  564. position: absolute;
  565. top: 188rpx;
  566. left: 50rpx;
  567. width: 650rpx;
  568. min-height: 494rpx;
  569. background: #FFFFFF;
  570. border-radius: 20rpx;
  571. }
  572. .share_bottom {
  573. position: fixed;
  574. bottom: 0;
  575. width: 100%;
  576. height: 388rpx;
  577. background: #F5F7FF;
  578. border-radius: 40rpx 40rpx 0px 0px;
  579. .bottom_item {
  580. width: 33%;
  581. margin: 50rpx 0 90rpx;
  582. border: none !important;
  583. background-color: #F5F7FF !important;
  584. .item_icon {
  585. width: 76rpx;
  586. height: 76rpx;
  587. }
  588. .item_text {
  589. font-size: 26rpx;
  590. font-weight: 400;
  591. color: #333333;
  592. line-height: 36rpx;
  593. margin-top: 12rpx;
  594. }
  595. }
  596. button::after {
  597. border: none !important;
  598. }
  599. .share_cancel {
  600. width: 100%;
  601. text-align: center;
  602. font-size: 32rpx;
  603. font-weight: 400;
  604. color: #333333;
  605. line-height: 44rpx;
  606. }
  607. }
  608. }
  609. .share_content1 {
  610. z-index: -99 !important;
  611. }
  612. }
  613. </style>