|
@@ -3,7 +3,7 @@
|
|
|
<!--搜索-->
|
|
|
<view class="search">
|
|
|
<view class="usearch">
|
|
|
- <u-search placeholder="请输入职位名称" bgColor="white" :showAction="false"></u-search>
|
|
|
+ <u-search placeholder="搜索工作" :disabled="true" bgColor="white" :showAction="false" @click="go('/pages/job/search')"></u-search>
|
|
|
</view>
|
|
|
<view class="address">
|
|
|
<text class="icon"></text>
|
|
@@ -49,21 +49,25 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
- <!--找工作-->
|
|
|
- <!-- <view class="tab">
|
|
|
- <u-tabs :inactiveStyle="{ fontSize: '15px' }" :activeStyle="{ color: '#3c9cff', fontSize: '17px' }" :list="tab" :current="current" @click="click"></u-tabs>
|
|
|
- </view> -->
|
|
|
- <view class="jobs" v-if="current == 0"></view>
|
|
|
+ <view class="tab">
|
|
|
+ <u-tabs :list="tab" @click="click"></u-tabs>
|
|
|
+ <view class="filters" @click="show = true">
|
|
|
+ <text class="icon"></text>
|
|
|
+ <text>更多</text>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ <view class="list">
|
|
|
+ <job :list="list"></job>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
</template>
|
|
|
<script>
|
|
|
export default {
|
|
|
data() {
|
|
|
return {
|
|
|
- ip: this.http.ip,
|
|
|
- current: 0,
|
|
|
- tab: [{ name: '最新工作' }, { name: '身边工作' }, { name: '现结工作' }],
|
|
|
- user: {},
|
|
|
+ tab: [{ name: '推荐' }, { name: '最新' }, { name: '附近' }],
|
|
|
+ list: [],
|
|
|
+ param: { pageNum: 1, pageSize: 20, orderBy: 'id', type: 0 },
|
|
|
bannerList: [],
|
|
|
noticeList: []
|
|
|
};
|
|
@@ -71,6 +75,7 @@ export default {
|
|
|
onShow() {},
|
|
|
onLoad() {
|
|
|
this.initData();
|
|
|
+ this.getData();
|
|
|
},
|
|
|
methods: {
|
|
|
initData() {
|
|
@@ -92,6 +97,7 @@ export default {
|
|
|
uni.setStorageSync('city_all', res.data.data);
|
|
|
}
|
|
|
});
|
|
|
+ // #ifdef MP-WEIXIN
|
|
|
//授权获取位置
|
|
|
uni.authorize({
|
|
|
scope: 'scope.userLocation',
|
|
@@ -107,6 +113,16 @@ export default {
|
|
|
uni.showModal({ title: '提示', content: '定位失败,请检查是否允许定位', showCancel: false });
|
|
|
}
|
|
|
});
|
|
|
+ // #endif
|
|
|
+ },
|
|
|
+ getData() {
|
|
|
+ this.http.request({
|
|
|
+ url: '/app/position/list',
|
|
|
+ data: this.param,
|
|
|
+ success: (res) => {
|
|
|
+ this.list.push(...res.data.rows);
|
|
|
+ }
|
|
|
+ });
|
|
|
},
|
|
|
click(e) {
|
|
|
this.current = e.index;
|