index.js 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. import {
  2. getResume
  3. } from '../../services/index.js'
  4. import {
  5. imgServerUrl
  6. } from '../../config/config.js'
  7. import {
  8. showToast
  9. } from '../../utils/tips.js'
  10. import {
  11. formatTime
  12. } from '../../utils/util.js'
  13. const app = getApp();
  14. Page({
  15. data: {
  16. watermark: [],
  17. imgServerUrl: imgServerUrl,
  18. hpUserResumeId: '', //是否有简历
  19. eduList: ["请选择", "小学", "中学", "高中", "大专", "本科", "研究生", "博士", "博士后"],
  20. eduName: '', //学历
  21. expYear: "", //工作几年
  22. hpUserResumeId: '', //用户简历表id
  23. expectationPosition: ["普工", "客服", "销售", "服务员", "物流仓储", "司机", "才艺技能", "文员助理", "快递配送", "促销导购", "展会演出", "家教培训", "模特", "贸易采购", "厨师", "编辑", "线上推广", "设计", "技工", "保洁", "其它"],
  24. salaryList: [{
  25. "expectationSalary": -1,
  26. "hightNum": '不限'
  27. },
  28. {
  29. "expectationSalary": 0,
  30. "hightNum": '1000~2000'
  31. },
  32. {
  33. "expectationSalary": 1,
  34. "hightNum": '2001~3000'
  35. },
  36. {
  37. "expectationSalary": 2,
  38. "hightNum": '3001~4000'
  39. },
  40. {
  41. "expectationSalary": 3,
  42. "hightNum": '4001~5000'
  43. },
  44. {
  45. "expectationSalary": 4,
  46. "hightNum": '5001~6000'
  47. },
  48. {
  49. "expectationSalary": 5,
  50. "hightNum": '6001~7000'
  51. },
  52. {
  53. "expectationSalary": 6,
  54. "hightNum": '7001~8000'
  55. },
  56. {
  57. "expectationSalary": 7,
  58. "hightNum": '8001~9000'
  59. },
  60. {
  61. "expectationSalary": 8,
  62. "hightNum": '9001~10000'
  63. }, {
  64. "expectationSalary": 9,
  65. "hightNum": '10000以上'
  66. }
  67. ],
  68. },
  69. onLoad: function(options) {
  70. var userResume = wx.getStorageSync('userResume');
  71. if (userResume.expectationSalary) {
  72. var salaryList = this.data.salaryList;
  73. for (var i = 0; i < salaryList.length; i++) {
  74. if (salaryList[i].expectationSalary == userResume.expectationSalary) {
  75. userResume.expectationSalary = salaryList[i].hightNum
  76. }
  77. }
  78. }
  79. this.setData({
  80. userResume: userResume
  81. }, _ => {
  82. wx.createSelectorQuery().select('.container').fields({
  83. dataset: true,
  84. size: true,
  85. scrollOffset: true,
  86. properties: ['scrollX', 'scrollY'],
  87. computedStyle: ['margin', 'backgroundColor'],
  88. context: true,
  89. }, (res) => {
  90. this.setData({
  91. watermark: app.watermark(res.height)
  92. })
  93. }).exec()
  94. })
  95. },
  96. onShow: function(options) {
  97. },
  98. })