jobIntention.vue 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241
  1. <template>
  2. <view>
  3. <view class="list flex justify-center">
  4. <view class="list-box">
  5. <view class="list-box-item flex justify-center" v-for="(item,index) in list" :key="index">
  6. <view class="list-box-item-con flex justify-between align-center">
  7. <view class="flex flex-wrap list-box-item-con-l">
  8. <view class="list-box-item-con-l-title">
  9. {{item.ruleClassifyName}}
  10. </view>
  11. <view class="list-box-item-con-l-label flex align-center flex-wrap">
  12. <view class=""
  13. style="padding: 10rpx 15rpx 10rpx 15rpx;background-color: #F6F6F6;border-radius: 8rpx;margin-right: 20rpx;margin-bottom: 20rpx;">
  14. {{item.postType}}
  15. </view>
  16. <view class=""
  17. style="padding: 10rpx 15rpx 10rpx 15rpx;background-color: #F6F6F6;border-radius: 8rpx;margin-right: 20rpx;margin-bottom: 20rpx;">
  18. {{item.citys}}
  19. </view>
  20. <view class=""
  21. style="padding: 10rpx 15rpx 10rpx 15rpx;background-color: #F6F6F6;border-radius: 8rpx;margin-right: 20rpx;margin-bottom: 20rpx;">
  22. {{item.salaryRange}}
  23. </view>
  24. </view>
  25. <view class="list-box-item-con-l-type flex align-center">
  26. <view class="" v-for="(ite,ind) in item.industry.split(',')" :key="ind">
  27. {{ite}}
  28. <text style="margin-left: 20rpx;margin-right: 20rpx;"
  29. v-if="(ind + 1) != item.industry.split(',').length">|</text>
  30. </view>
  31. </view>
  32. </view>
  33. <view class="list-box-item-con-r flex align-center">
  34. <u-icon name="trash" color="#999999" size="46"
  35. @click="deleteJob(item.intentionId)"></u-icon>
  36. <text style="margin: 0 10rpx;color:#f2f2f2;font-size: 46rpx;">|</text>
  37. <u-icon name="edit-pen" color="#00B88F" size="46"
  38. @click="upData(item.intentionId)"></u-icon>
  39. </view>
  40. </view>
  41. </view>
  42. <empty v-if="list.length==0" />
  43. </view>
  44. </view>
  45. <!-- add -->
  46. <view class="addBtn flex justify-center" v-if="list.length<3">
  47. <view class="addBtn-box flex justify-center align-center" @tap="gotoNav()">
  48. 添加求职意向
  49. </view>
  50. </view>
  51. </view>
  52. </template>
  53. <script>
  54. import empty from '../../components/empty.vue'
  55. export default {
  56. components: {
  57. empty
  58. },
  59. data() {
  60. return {
  61. list: [],
  62. };
  63. },
  64. onLoad() {
  65. },
  66. onShow() {
  67. this.getMyList();
  68. },
  69. methods: {
  70. /**
  71. * @param {Object} intentionId
  72. * 删除求职意向
  73. */
  74. deleteJob(intentionId) {
  75. let that = this
  76. uni.showModal({
  77. title: '提示',
  78. content: '确认删除此求职意向吗?',
  79. complete(ret) {
  80. if (ret.confirm) {
  81. that.$Request.postT('/app/intention/deleteIntention', {
  82. intentionId: intentionId
  83. }).then(res => {
  84. if (res.code == 0) {
  85. uni.showToast({
  86. title: '删除成功'
  87. })
  88. that.getMyList()
  89. } else {
  90. uni.showToast({
  91. title: res.msg,
  92. icon: 'none'
  93. })
  94. }
  95. })
  96. }
  97. }
  98. })
  99. },
  100. /**
  101. * 获取我的求职意向列表
  102. */
  103. getMyList() {
  104. this.$Request.get('/app/intention/getIntentionList').then(res => {
  105. if (res.code == 0) {
  106. this.list = res.data.records
  107. }
  108. })
  109. },
  110. upData(intentionId) {
  111. uni.navigateTo({
  112. url: './edit?intentionId=' + intentionId
  113. })
  114. },
  115. //查询简历信息
  116. getResumesByUserId() {
  117. this.$Request.getT('/app/resumes/selectResumesByUserId').then(res => {
  118. if (res.code == 0) {
  119. if (res.data) {
  120. uni.navigateTo({
  121. url: './add'
  122. })
  123. } else {
  124. uni.showModal({
  125. title: '提示',
  126. content: '你还为添加简历,请添加简历后再添加求职意向',
  127. confirmColor: '#00B88F',
  128. confirmText: '添加简历',
  129. complete(ret) {
  130. if (ret.confirm) {
  131. uni.navigateTo({
  132. url: '/package/my/resume'
  133. })
  134. }
  135. }
  136. })
  137. }
  138. } else {
  139. uni.showToast({
  140. title: res.msg,
  141. icon: 'none'
  142. })
  143. }
  144. })
  145. },
  146. gotoNav() {
  147. this.getResumesByUserId()
  148. },
  149. }
  150. }
  151. </script>
  152. <style lang="scss">
  153. page {
  154. background: #F2F2F7;
  155. }
  156. .list {
  157. width: 100%;
  158. height: auto;
  159. margin-top: 30rpx;
  160. .list-box {
  161. width: 686rpx;
  162. height: auto;
  163. .list-box-item {
  164. width: 100%;
  165. // height: 227rpx;
  166. background: #FFFFFF;
  167. border-radius: 24rpx;
  168. margin-bottom: 20rpx;
  169. }
  170. .list-box-item-con {
  171. width: 626rpx;
  172. height: 100%;
  173. padding-top: 20rpx;
  174. padding-bottom: 20rpx;
  175. .list-box-item-con-l {
  176. width: 80%;
  177. height: 100%;
  178. align-items: center;
  179. align-content: center;
  180. .list-box-item-con-l-title {
  181. width: 100%;
  182. color: #1F1F1F;
  183. font-size: 38rpx;
  184. font-weight: 800;
  185. }
  186. .list-box-item-con-l-label {
  187. width: 100%;
  188. margin-top: 20rpx;
  189. color: #666666;
  190. font-size: 28rpx;
  191. }
  192. .list-box-item-con-l-type {
  193. width: 100%;
  194. // margin-top: 20rpx;
  195. color: #999999;
  196. font-size: 28rpx;
  197. }
  198. }
  199. .list-box-item-con-r {
  200. // width: 46rpx;
  201. height: 46rpx;
  202. z-index: 9999;
  203. }
  204. }
  205. }
  206. }
  207. .addBtn {
  208. width: 100%;
  209. height: 88rpx;
  210. position: fixed;
  211. bottom: 100rpx;
  212. .addBtn-box {
  213. width: 686rpx;
  214. height: 100%;
  215. border-radius: 44rpx;
  216. background-color: #00B88F;
  217. color: #FFFFFF;
  218. font-size: 32rpx;
  219. font-weight: bold;
  220. }
  221. }
  222. </style>