123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463 |
- <template>
- <view>
- <u-navbar back-text="荆州经开区共享用工平台" :customBack="customBack" :background="background"
- :back-text-style="backColor"></u-navbar>
- <!-- 头部 -->
- <view class="top">
- <!-- 搜索框 -->
- <view class="search">
- <u-search placeholder="请输入找工关键字" @focus="gotoUrl('pages/packages/search/search')"
- :show-action="false"></u-search>
- </view>
- </view>
- <!-- 幻灯片 -->
- <view class="swiper">
- <u-swiper :list="bannerlist"></u-swiper>
- </view>
- <!-- 功能区 -->
- <view class="function">
- <view class="function-item" @click="gotoUrl('pages/tab/choreInformation/choreInformation')">
- <view class="icon-box icon-box3">
- <view class="icon">
- <img src="@/assets/img/riFill-contacts-book-2-fill@1x.png" alt="">
- </view>
- </view>
- <view class="item-text">
- 零工驿站
- </view>
- </view>
- <view class="function-item" @click="gotoUrl('pages/packages/news/news?t=3&title=爱心驿站')">
- <view class="icon-box icon-box2">
- <view class="icon">
- <img src="@/assets/img/riFill-heart-2-fill@1x.png" alt="">
- </view>
- </view>
- <view class="item-text">
- 爱心驿站
- </view>
- </view>
- <view class="function-item" @click="gotoUrl('pages/packages/shareEmployment/shareEmployment')">
- <view class="icon-box">
- <view class="icon">
- <img src="@/assets/img/riFill-cloud-fill@1x.png" alt="">
- </view>
- </view>
- <view class="item-text">
- 共享用工
- </view>
- </view>
- <view class="function-item" @click="gotoUrl('pages/packages/skillTraining/skillTraining')">
- <view class="icon-box icon-box4">
- <view class="icon">
- <img src="@/assets/img/riFill-tools-fill@1x.png" alt="">
- </view>
- </view>
- <view class="item-text">
- 技能培训
- </view>
- </view>
- <view class="function-item" @click="gotoUrl('pages/packages/news/news?t=1&title=政策发布')">
- <view class="icon-box icon-box5">
- <view class="icon">
- <img src="@/assets/img/riFill-newspaper-fill@1x.png" alt="">
- </view>
- </view>
- <view class="item-text">
- 政策发布
- </view>
- </view>
- </view>
- <!-- 标签 -->
- <view class="tabs">
- <view class="title">
- <u-tabs bg-color="#F0F0F2" :list="tabList" :is-scroll="false" :current="current"
- @change="change"></u-tabs>
- <view class="more" @click="gotoUrl('pages/tab/jobInformation/jobInformation')">
- 更多
- <u-icon name="arrow-right"></u-icon>
- </view>
- </view>
- <!-- 卡片 -->
- <view class="classify-card">
- <view class="item" v-for="(item,i) in showList" :key="i"
-
- @click="gotoUrl('pages/packages/jobInformation/jobDetails?id='+item.id)">
- <view class="content-1">
- <!-- 职位 -->
- <view class="position">
- <b>{{item.positionName}}</b>
- </view>
- <!-- 薪水 -->
- <view class="salary">
- {{item.salary}}元/天
- </view>
- </view>
- <view class="content-2">
- <!-- 标签 -->
- <view class="tag">
- <!-- <view class="tag-item">
- 个人
- </view> -->
- <view class="tag-item">
- {{item.settlementMethodN}}
- </view>
- </view>
- <!-- 日期 -->
- <view class="date">
- {{item.createTime}}
- </view>
- </view>
- <view class="content-3">
- <view class="issuer">
- {{item.contacts}}
- </view>
- <view class="address">
- {{item.workArea}}{{item.address}}
- </view>
- </view>
- </view>
- </view>
-
- <u-divider style="margin-top: 10px;"
- :isnone="showList.length==0" nonetext="没有找到相关内容"
- @click="gotoUrl('pages/tab/jobInformation/jobInformation')"
- border-color="#CFD2D5">点击查看更多</u-divider>
- </view>
-
- <tabbar :current="0"></tabbar>
- </view>
- </template>
- <script>
- import * as API from '@/apis/pagejs/main.js'
- import tabbar from "@/components/Tabbar.vue"
- import * as API_weixin from '@/apis/weixin.js'
- export default {
- components: {
- tabbar
- },
- data() {
- return {
- keyword: '',
- // 导航栏背景
- background: {
- backgroundColor: '#2795FD',
- },
- backColor: {
- color: '#ffffff'
- },
- bannerlist: [{
- image: 'https://cdn.uviewui.com/uview/swiper/1.jpg',
- },
- {
- image: 'https://cdn.uviewui.com/uview/swiper/2.jpg',
- },
- {
- image: 'https://cdn.uviewui.com/uview/swiper/3.jpg',
- }
- ],
- tabList: [{
- name: '最新',
- value:"",
- list:[],
- recordsTotal:0
- }, {
- name: '日结',
- unit:"日",
- value:"1",
- list:[],
- recordsTotal:0
- }, {
- name: '周结',
- unit:"周",
- value:"2",
- list:[],
- recordsTotal:0
- }, {
- name: '月结',
- unit:"月",
- value:"3",
- list:[],
- recordsTotal:0
- }],
-
- current: 0,
- homeList:[],
-
- }
- },
- onLoad(op) {
- if(op.shareMP){
- if(op.t=='jobDetails'){
- uni.navigateTo({
- url:"/pages/packages/jobInformation/jobDetails?id="+op.id
- })
- }
- }
- this.findRecruitHomePage();
- this.findByOpenId();
- },
- computed:{
- showRecordsTotal(){
- return this.tabList[this.current].recordsTotal
- },
- showList(){
- return this.tabList[this.current].list
- }
- },
- methods: {
- findByOpenId(){
-
- API_weixin.findByOpenId({
- openId:this.carhelp.getOpenId(),
- noerror:true
- }).then((res) => {
-
- this.carhelp.setPersonInfo(res.data.regUser );
- this.carhelp.setToken(res.data.token);
- this.carhelp.setPersonInfoPlus(res.data);
-
- }).catch(error => {
-
- })
-
- },
- findRecruitHomePage(){
- uni.showLoading({
- title: "加载中",
- mask: true,
- })
- API.findRecruitHomePage({
- pageIndex:1,
- pageSize:5,
- type:this.tabList[this.current].value,
- }).then((res) => {
- uni.hideLoading();
- this.tabList[this.current].list=res.data.data
- this.tabList[this.current].recordsTotal=res.data.recordsTotal
-
- }).catch(error => {
-
- uni.showToast({
- title: error
- })
- //this.getPhone()
-
- })
- },
- customBack() {},
- change(index) {
- this.current = index;
- this.findRecruitHomePage()
- }
- }
- }
- </script>
- <style>
- page {
- background: #F0F0F2;
- padding-bottom: 50px;
- }
- </style>
- <style scoped lang="scss">
- /deep/.u-navbar {
- .u-icon--right {
- display: none !important;
- }
- }
- // 头部
- .top {
- // 搜索框
- .search {
- background-color: rgba(39, 149, 253, 1);
- padding: 16rpx 32rpx;
- }
- }
- // 功能区
- .function {
- background-color: #fff;
- padding: 32rpx 46rpx;
- display: flex;
- justify-content: space-between;
- .function-item {
- display: flex;
- flex-direction: column;
- justify-content: center;
- align-items: center;
- .icon-box {
- width: 96rpx;
- height: 96rpx;
- background-color: rgba(240, 233, 255, 1);
- text-align: center;
- border-radius: 999px;
- display: flex;
- justify-content: center;
- align-items: center;
- }
- .icon-box2 {
- background-color: rgba(255, 234, 230, 1);
- }
- .icon-box3 {
- background-color: rgba(227, 246, 255, 1);
- }
- .icon-box4 {
- background-color: rgba(255, 242, 224, 1);
- }
- .icon-box5 {
- background-color: rgba(221, 247, 238, 1);
- }
- .icon {
- width: 48rpx;
- height: 48rpx;
- img {
- width: 100%;
- height: 100%;
- }
- }
- .item-text {
- color: rgba(51, 51, 51, 1);
- margin-top: 8rpx;
- font-family: 'PingFang Medium';
- }
- }
- }
- // 标签
- .tabs {
- margin-top: 32rpx;
- .title {
- display: flex;
- justify-content: space-between;
- align-items: center;
- padding: 0rpx 24rpx;
- /deep/.u-tabs {
- width: 400rpx;
- }
- .more {
- color: rgba(119, 119, 119, 1);
- }
- }
- .classify-card {
- background-color: #fff;
- .item {
- padding: 24rpx 0;
- margin: 0 32rpx;
- border-bottom: 1px solid #F0F0F2;
- .content-1 {
- display: flex;
- justify-content: space-between;
- align-items: center;
- // 职位
- .position {
- color: rgba(16, 16, 16, 1);
- font-size: 36rpx;
- font-family: 'PingFang Medium';
- }
- // 薪水
- .salary {
- color: rgba(255, 61, 0, 1);
- font-size: 32rpx;
- font-family: 'PingFang Medium';
- }
- }
- .content-2 {
- margin-top: 12rpx;
- display: flex;
- justify-content: space-between;
- // 标签
- .tag {
- display: flex;
- .tag-item {
- width: 64rpx;
- height: 36rpx;
- line-height: 36rpx;
- border-radius: 8rpx;
- background-color: rgba(241, 241, 247, 1);
- color: rgba(129, 127, 153, 1);
- font-size: 24rpx;
- text-align: center;
- margin-right: 12rpx;
- }
- }
- // 日期
- .date {
- color: rgba(153, 153, 153, 1);
- font-size: 24rpx;
- }
- }
- .content-3 {
- margin-top: 20rpx;
- display: flex;
- justify-content: space-between;
- align-items: center;
- .issuer {
- color: rgba(51, 51, 51, 1);
- font-size: 24rpx;
- }
- .address {
- color: rgba(51, 51, 51, 1);
- font-size: 24rpx;
- }
- }
- }
- }
- }
- </style>
|