<template>
|
|
<!-- 我发布的招工 -->
|
|
<view class="page">
|
|
|
|
<navbar title="我的找活"
|
|
:title="role ? '我的招工' : '我的找活'"
|
|
bgColor="#3796F8"
|
|
leftClick
|
|
color="#fff"
|
|
@leftClick="$utils.navigateBack"/>
|
|
|
|
<statisticsNumber :title="role ? '您当前的招工' : '您当前的找活'" :num="total"/>
|
|
|
|
<workListSwipe
|
|
:options="options"
|
|
v-if="role"
|
|
@clickSwipeAction="clickSwipeAction"
|
|
:list="list"/>
|
|
|
|
<userListSwipe
|
|
:options="options"
|
|
v-else
|
|
@clickSwipeAction="clickSwipeAction"
|
|
:list="list"/>
|
|
</view>
|
|
</template>
|
|
|
|
<script>
|
|
import userListSwipe from '@/components/list/userList/userListSwipe.vue'
|
|
import workListSwipe from '@/components/list/workList/workListSwipe.vue'
|
|
import statisticsNumber from '../components/statistics/statisticsNumber.vue'
|
|
import mixinList from '@/mixins/list.js'
|
|
import { mapState } from 'vuex'
|
|
export default {
|
|
mixins : [mixinList],
|
|
components : {
|
|
userListSwipe,
|
|
statisticsNumber,
|
|
workListSwipe
|
|
},
|
|
data() {
|
|
return {
|
|
options: [
|
|
{
|
|
text: '修改',
|
|
style: {
|
|
backgroundColor: '#ffa12c'
|
|
}
|
|
},
|
|
{
|
|
text: '删除',
|
|
style: {
|
|
backgroundColor: '#FA5A0A'
|
|
}
|
|
},
|
|
],
|
|
mixinsListApi : 'employeeQueryResumeByUserId',
|
|
}
|
|
},
|
|
computed : {
|
|
...mapState([
|
|
'role',
|
|
]),
|
|
},
|
|
onLoad() {
|
|
this.mixinsListApi = this.role ? 'bossQueryJobListByUserId' : 'employeeQueryResumeByUserId'
|
|
},
|
|
methods: {
|
|
clickSwipeAction({e, item}){
|
|
console.log(e, item);
|
|
},
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style scoped lang="scss">
|
|
.page{
|
|
/deep/ .uv-swipe-action{
|
|
width: 100%;
|
|
}
|
|
}
|
|
</style>
|