提交 ba786372 作者: 王定

feat: 优化一点点灵活用工地图模式

上级 130f1eff
...@@ -63,10 +63,14 @@ const model = reactive({ ...@@ -63,10 +63,14 @@ const model = reactive({
searchText: '', searchText: '',
// 标记点击事件是否已绑定 // 标记点击事件是否已绑定
clickEventBound: false, clickEventBound: false,
// 用于区分是哪个模块进的
currentEmploymentId:1,
}) })
onLoad((options) => { onLoad((options) => {
model.id = options.id model.id = options.id;
model.currentEmploymentId = options.currentEmploymentId;
console.log("model.currentEmploymentId= "+model.currentEmploymentId)
model.name = decodeURIComponent(options.name) model.name = decodeURIComponent(options.name)
model.search.pageNo = 1 model.search.pageNo = 1
model.search.publishstatu = 1 model.search.publishstatu = 1
...@@ -427,7 +431,11 @@ function getStarsHTML(employment) { ...@@ -427,7 +431,11 @@ function getStarsHTML(employment) {
} }
// 发布用工 // 发布用工
function handlePublish() { function handlePublish() {
Navigate.to('/pages/linghuoyonggong/form') if(model.currentEmploymentId == 2){
Navigate.to('/pages/linghuoyonggong/publishEmployment')
}else{
Navigate.to('/pages/linghuoyonggong/form')
}
} }
onNavigationBarButtonTap((e) => { onNavigationBarButtonTap((e) => {
console.log(e) console.log(e)
...@@ -438,8 +446,8 @@ onNavigationBarButtonTap((e) => { ...@@ -438,8 +446,8 @@ onNavigationBarButtonTap((e) => {
</script> </script>
<template> <template>
<view class="page h-95_dl_5vh bg-#E6F5E8 flex flex-col justify-between"> <view class="page h-95_dl_5vh bg-#E6F5E8 flex flex-col">
<view class="h-200rpx p-3"> <view class="p-3">
<view class="w-full h-60rpx border-rd-3xl!"> <view class="w-full h-60rpx border-rd-3xl!">
<fui-input <fui-input
:bottomLeft="0" :bottomLeft="0"
...@@ -456,7 +464,7 @@ onNavigationBarButtonTap((e) => { ...@@ -456,7 +464,7 @@ onNavigationBarButtonTap((e) => {
</template> </template>
</fui-input> </fui-input>
</view> </view>
<view class="codefun-mt-14 codefun-flex-row group_2 gap-2"> <view v-if="model.currentEmploymentId != 2" class="codefun-mt-14 codefun-flex-row group_2 gap-2">
<view <view
v-for="tab in model.categoryTabs" v-for="tab in model.categoryTabs"
:key="tab.id" :key="tab.id"
...@@ -475,7 +483,6 @@ onNavigationBarButtonTap((e) => { ...@@ -475,7 +483,6 @@ onNavigationBarButtonTap((e) => {
<view class="overflow-hidden map-box" style="height: calc(100vh - 200rpx)"> <view class="overflow-hidden map-box" style="height: calc(100vh - 200rpx)">
<!-- 地图组件 --> <!-- 地图组件 -->
<Mapbox @register="registerMap" /> <Mapbox @register="registerMap" />
<!-- 回到当前位置按钮 --> <!-- 回到当前位置按钮 -->
<view class="location-control" @click="backToUserLocation"> <view class="location-control" @click="backToUserLocation">
<view class="location-button"> <view class="location-button">
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论