apply1.vue 9.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377
  1. <template>
  2. <view class="personal">
  3. <view class="">
  4. <text class="title">求职意向</text>
  5. <view class="titleb">不同的求职意向,会为您推荐不同的职位</view>
  6. </view>
  7. <view class="u-flex content u-row-between" v-for="(item,index) in job_intention" :key="item.id" @click="toapply1(2,item.id)">
  8. <view class="biaoti">
  9. <view class="">
  10. <view v-if="item.is_pay" class="fei" >付费</view>
  11. <text>{{item.province.slice(0,-1)}}</text>
  12. <text style="margin: 0 20rpx;">|</text>
  13. <text>{{item.category_industry_name}}</text>
  14. </view>
  15. <view class="money">
  16. <text>{{item.salary_month}}K·</text>
  17. <text>{{item.category_job_name|| "行业不限"}}</text>
  18. </view>
  19. </view>
  20. <u-icon name="arrow-right" color="#4C4C4C" size="24"></u-icon>
  21. </view>
  22. <view class="add" @click="toapply(1)">
  23. +添加求职意向
  24. </view>
  25. <view class="bottom u-flex u-row-between">
  26. <text>求职状态</text>
  27. <view class="u-flex">
  28. <text @click="show = true">{{job_status_name||"请选择"}}</text>
  29. <u-icon name="arrow-right" color="#4C4C4C" size="16"></u-icon>
  30. </view>
  31. </view>
  32. <u-picker @cancel="show = false" :show="show" :columns="columns" keyName="name" @confirm="enter"></u-picker>
  33. </view>
  34. </template>
  35. <script setup>
  36. import {
  37. getAllArea,
  38. get_job_status,
  39. resumeDetail,
  40. update
  41. } from "@/units/inquire.js"
  42. export default {
  43. data() {
  44. return {
  45. show:false,
  46. value: false,
  47. province: [], //省数据
  48. city: [], //市数据
  49. area: [], //区数据
  50. provinceid: "", //省数据
  51. cityid: "", //市数据
  52. areaid: "", //区数据
  53. indexs: [], //默认地区下标
  54. //选择器状态
  55. birthdayShow: false, //出生年月
  56. workShow: false, //工作时间
  57. cityShow: false, //户口所在地
  58. jobShow: false, //工作显示
  59. cityList: [], //数据地址
  60. cityids: [], //数据地址
  61. joblist: [],
  62. job_status_id:"",
  63. job_status_name:"",
  64. columns:[[]],
  65. job_intention:[],
  66. source_id:''
  67. }
  68. },
  69. onLoad() {
  70. this.resumeDetail()
  71. this.AllArea()
  72. this.get_job_status()
  73. },
  74. methods: {
  75. toapply1(type,id){
  76. uni.navigateTo({
  77. url:"/pagesD/apply?type="+type+"&id="+id,
  78. events:{
  79. refresh:(res)=>{
  80. this.resumeDetail()
  81. }
  82. }
  83. })
  84. },
  85. resumeDetail(){
  86. resumeDetail().then(res=>{
  87. this.source_id = res.data.id
  88. this.job_intention = res.data.job_intention
  89. this.job_status_name = res.data.job_status_name
  90. })
  91. },
  92. enter(e){
  93. update({
  94. source_type:"resume",
  95. source_id:this.source_id,
  96. job_status_id: e.value[0].id
  97. }).then(res=>{
  98. this.resumeDetail()
  99. })
  100. this.job_status_name = e.value[0].name
  101. this.show = false
  102. },
  103. get_job_status(){
  104. get_job_status().then(res=>{
  105. this.columns[0] = res.data
  106. })
  107. },
  108. toapply(){
  109. uni.navigateTo({
  110. url:"/pagesD/apply"
  111. })
  112. },
  113. //所有地区
  114. AllArea() {
  115. getAllArea().then((res) => {
  116. this.province = res.data.map(t => {
  117. return {
  118. name: t.name,
  119. id: t.id
  120. }
  121. })
  122. console.log("aaa", this.province);
  123. this.city = res.data.map(t => t.children.map(v => {
  124. return {
  125. name: v.name,
  126. id: v.id
  127. }
  128. }))
  129. this.area = res.data.map(t => t.children.map(v => v.children.map(i => {
  130. return {
  131. name: i.name,
  132. id: i.id
  133. }
  134. })))
  135. //默认显示数据
  136. // this.cityList = [
  137. // this.province.map(res => res.name),
  138. // this.city[0].map(res => res.name),
  139. // this.area[0][0].map(res => res.name)
  140. // ]
  141. let a = []
  142. let b = []
  143. let c = []
  144. this.province.map(res => {
  145. a.push({
  146. name: res.name,
  147. id: res.id,
  148. })
  149. })
  150. this.city[0].map(res => {
  151. b.push({
  152. name: res.name,
  153. id: res.id,
  154. })
  155. })
  156. this.area[0][0].map(res => {
  157. c.push({
  158. name: res.name,
  159. id: res.id,
  160. })
  161. })
  162. this.cityList = [a, b, c]
  163. // if (this.province && this.city && this.area) {
  164. // //省索引
  165. // let pIdx = this.province.findIndex(v => v.name == this.province);
  166. // //根据省索引设置默认市数据
  167. // this.columns[1] = this.city[pIdx].map(res => res.name)
  168. // //市索引
  169. // let cIdx = this.city[pIdx].findIndex(v => v.name == this.city);
  170. // //根据市索引设置默认区数据
  171. // this.columns[2] = this.area[pIdx][cIdx].map(res => res.name)
  172. // //区索引
  173. // let aIdx = this.area[pIdx][cIdx].findIndex(v => v.name == this.area);
  174. // this.indexs = [pIdx, cIdx, aIdx];
  175. // // console.log(pIdx, cIdx, aIdx);
  176. // console.log(this.indexs);
  177. // }
  178. // if (this.addressData.province && this.addressData.city && this.addressData.area) {
  179. // //省索引
  180. // let pIdx = this.province.findIndex(v => v.name == this.addressData.province);
  181. // //根据省索引设置默认市数据
  182. // this.columns[1] = this.city[pIdx].map(res => res.name)
  183. // //市索引
  184. // let cIdx = this.city[pIdx].findIndex(v => v.name == this.addressData.city);
  185. // //根据市索引设置默认区数据
  186. // this.columns[2] = this.area[pIdx][cIdx].map(res => res.name)
  187. // //区索引
  188. // let aIdx = this.area[pIdx][cIdx].findIndex(v => v.name == this.addressData.area);
  189. // this.indexs = [pIdx, cIdx, aIdx];
  190. // // console.log(pIdx, cIdx, aIdx);
  191. // console.log(this.indexs);
  192. // }
  193. })
  194. },
  195. changeHandler(e) {
  196. const {
  197. columnIndex, //当前改变值的列下标
  198. value,
  199. values, // values为当前变化列的数组内容
  200. indexs, //当前地区值下标
  201. picker = this.$refs.uPicker
  202. } = e
  203. //columnIndex代表第几列,意思是下标为0的列发生变化
  204. if (columnIndex === 0) {
  205. picker.setColumnValues(1, this.city[indexs[0]].map(v => {
  206. return {
  207. name: v.name,
  208. id: v.id
  209. }
  210. }))
  211. picker.setColumnValues(2, this.area[indexs[0]][0].map(v => {
  212. return {
  213. name: v.name,
  214. id: v.id
  215. }
  216. }))
  217. }
  218. if (columnIndex === 1) {
  219. picker.setColumnValues(2, this.area[indexs[0]][indexs[1]].map(v => {
  220. return {
  221. name: v.name,
  222. id: v.id
  223. }
  224. }))
  225. }
  226. },
  227. //点击显示时间选择器
  228. birthdayBtn() {
  229. this.birthdayShow = true
  230. //new Date(this.endDate).getTime()为你需要在选择器上显示的时间戳
  231. this.$refs.picker.innerValue = new Date(946656000000).getTime()
  232. },
  233. //出生日期选择器
  234. async birthdayConfirm(e) {
  235. const timeFormat = uni.$u.timeFormat;
  236. let timeValue = await timeFormat(e.value, 'yyyy-mm-dd');
  237. this.from.birthday = timeValue;
  238. this.birthdayShow = false
  239. },
  240. //户口地址
  241. cityconfirm(e) {
  242. let a = e.value[0].name + e.value[1].name + e.value[2].name
  243. let ids = String(e.value[0].id) + String(e.value[1].id) + String(e.value[2].id)
  244. this.from.domicile_city_id = e.value[1].id
  245. this.from.domicile_province_id = e.value[0].id
  246. // this.city1 = e.value.join("")
  247. this.city1 = a
  248. this.cityShow = false
  249. },
  250. }
  251. }
  252. </script>
  253. <style lang="scss" scoped>
  254. .content {
  255. padding: 24rpx 20rpx;
  256. background: #F6F6F6;
  257. border-radius: 16rpx;
  258. box-sizing: border-box;
  259. margin-top: 32rpx;
  260. position: relative;
  261. }
  262. .fei{
  263. background: #FF5335;
  264. border-radius: 16rpx 0rpx 16rpx 0rpx;
  265. font-size: 22rpx;
  266. font-family: PingFangSC-Regular, PingFang SC;
  267. font-weight: 400;
  268. color: #FFFFFF;
  269. position: absolute;
  270. left: 0;
  271. top: 0;
  272. }
  273. .add {
  274. background: rgba(12, 102, 194, 0.05);
  275. border-radius: 12rpx;
  276. border: 2rpx dashed #0C66C2;
  277. text-align: center;
  278. height: 108rpx;
  279. line-height: 108rpx;
  280. margin-top: 44rpx;
  281. font-size: 32rpx;
  282. font-family: PingFangSC-Medium, PingFang SC;
  283. font-weight: 500;
  284. color: #0C66C2;
  285. }
  286. .biaoti {
  287. font-size: 32rpx;
  288. font-family: PingFangSC-Regular, PingFang SC;
  289. font-weight: 400;
  290. color: #222222;
  291. }
  292. .money {
  293. font-size: 26rpx;
  294. font-family: SFPro-Regular, SFPro;
  295. font-weight: 400;
  296. color: #888888;
  297. margin-top: 16rpx;
  298. }
  299. .bottom {
  300. height: 144rpx;
  301. border-bottom: 2rpx solid #F0F0F0;
  302. }
  303. //个人信息
  304. .personal {
  305. width: 750rpx;
  306. background: #FFFFFF;
  307. border-radius: 28rpx 28rpx 0rpx 0rpx;
  308. margin-top: -40rpx;
  309. position: relative;
  310. z-index: 99;
  311. padding: 40rpx 32rpx 0;
  312. margin-bottom: 60rpx;
  313. box-sizing: border-box;
  314. .title {
  315. font-size: 48rpx;
  316. font-family: PingFangSC-Medium, PingFang SC;
  317. font-weight: 500;
  318. color: #222222;
  319. }
  320. .titleb {
  321. font-size: 26rpx;
  322. font-family: PingFangSC-Regular, PingFang SC;
  323. font-weight: 400;
  324. color: #777777;
  325. margin-top: 20rpx;
  326. }
  327. .body-input {
  328. height: 150rpx;
  329. border-bottom: 2rpx solid #F4F4F4;
  330. .input-title {
  331. font-size: 26rpx;
  332. font-family: PingFangSC-Regular, PingFang SC;
  333. font-weight: 400;
  334. color: #888888;
  335. margin-top: 30rpx;
  336. box-sizing: border-box;
  337. }
  338. .input-style {
  339. font-size: 32rpx;
  340. font-family: PingFangSC-Regular, PingFang SC;
  341. font-weight: 400;
  342. color: #CACACA;
  343. }
  344. }
  345. .button {
  346. width: 686rpx;
  347. height: 88rpx !important;
  348. background: #0C66C2;
  349. border-radius: 12rpx;
  350. font-size: 32rpx;
  351. font-family: PingFangSC-Medium, PingFang SC;
  352. font-weight: 500;
  353. color: #FFFFFF;
  354. line-height: 88rpx;
  355. margin: 54rpx 0 0rpx 0;
  356. display: flex;
  357. justify-content: center;
  358. }
  359. }
  360. </style>