123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175 |
- <template>
- <view>
- <view class="box">
- <view class="flex align-center justify-between" @click="getPost">
- <view class=" text-bold">岗位 </view>
- <view class="text-right flex align-center padding-tb-sm">
- <view class="">{{resumesPost?resumesPost:'请选择岗位'}}</view>
- <view class="margin-left-sm">
- <image src="../../static/images/my/right_icon.png" style="width: 12upx;height: 21upx;"></image>
- </view>
- </view>
- </view>
- <view class="margin-tb-sm" style="width: 100%;height: 1rpx;background: #F2F2F2;"></view>
- <view class="flex align-center justify-between" @click="getPostlist">
- <view class=" text-bold">专业</view>
- <view class="text-right flex align-center padding-tb-sm">
- <view>{{ rulePostName? rulePostName:'请选择专业'}}</view>
- <view class="margin-left-sm">
- <image src="../../static/images/my/right_icon.png" style="width: 12upx;height: 21upx;"></image>
- </view>
- </view>
- </view>
- </view>
- <!-- 求职岗位 -->
- <u-select v-model="postShow" :list="postlist" @confirm="postConfirm"></u-select>
- <!-- 求职岗位 -->
- <u-select v-model="show" :list="ErjiList" @confirm="postlistConfirm"></u-select>
- <view class="btn" @click="submit()">保存</view>
- </view>
- </template>
- <script>
- export default {
- data() {
- return {
- resumesPost: '',
- rulePostId: '',
- postShow: false, //一级岗位
- postlist: [],
- ruleClassifyId: '',
- show: false, //二级岗位
- ErjiList: [],
- rulePostName:''
- }
- },
- onLoad() {
- },
- onShow() {
- },
- methods: {
- postConfirm(e) {
- this.resumesPost = e[0].label
- this.ruleClassifyId = e[0].value
- },
- getPost() {
- this.getClassifyList()
- },
- //获取求职岗位
- getClassifyList() {
- let data = {
- status: 1
- }
- this.$Request.get('/app/rule/selectRuleClassifyList', data).then(res => {
- if (res.code == 0) {
- var arr = []
- res.data.forEach((d, index) => {
- var data = {}
- data.label = d.ruleClassifyName
- data.value = d.ruleClassifyId
- arr.push(data)
- })
- this.postlist = arr
- this.postShow = true
- }
- })
- },
- postlistConfirm(e) {
- this.rulePostName = e[0].label
- this.rulePostId = e[0].value
- },
- getPostlist() {
- this.getPostList()
- },
- //获取岗位
- getPostList() {
- if (!this.ruleClassifyId) {
- uni.showToast({
- title: '请先选择岗位',
- icon: 'none',
- duration: 1000
- })
- return
- }
- let data = {
- ruleClassifyId: this.ruleClassifyId
- }
- this.$Request.post('/app/rule/selectRulePostList', data).then(res => {
- if (res.code == 0) {
- var arr = []
- res.data.forEach((d, index) => {
- var data = {}
- data.label = d.rulePostName
- data.value = d.rulePostId
- arr.push(data)
- })
- this.ErjiList = arr
- this.show = true
- }
- })
- },
- submit() {
- if (!this.resumesPost) {
- uni.showToast({
- title: '请选择岗位',
- icon: 'none',
- duration: 1000
- })
- return
- }
- if (!this.rulePostName) {
- uni.showToast({
- title: '请选择专业',
- icon: 'none',
- duration: 1000
- })
- return
- }
- let data = {
- resumesPost: this.resumesPost,
- rulePostId: this.rulePostId,
- rulePostName:this.rulePostName,
- ruleClassifyId:this.ruleClassifyId
- }
- uni.setStorageSync("resumes", data)
- uni.navigateBack()
- }
- }
- }
- </script>
- <style lang="less">
- page {
- background: #F2F2F7;
- }
- .box {
- background: #FFFFFF;
- border-radius: 24upx;
- margin: 30upx;
- padding: 30upx;
- }
- .u-input__input {
- text-align: right !important;
- }
- .btn {
- background: #00B88F;
- border-radius: 10upx;
- text-align: center;
- // margin-top: 30upx;
- padding: 30upx 0upx;
- color: #FFFFFF;
- // font-weight: bold;
- // letter-spacing: 2rpx;
- margin: 30upx;
- }
- </style>
|