feat : 优化文件上传 优化一体机体验
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
<image src="@/static/icon/back.png" @click="navBack"></image>
|
||||
</view>
|
||||
</template>
|
||||
<view v-show="searchFocus" class="search-mask" ></view>
|
||||
<view class="main">
|
||||
<view class="content-title">
|
||||
<view class="title-lf">
|
||||
@@ -74,7 +75,7 @@ const { $api, navBack } = inject('globalFunction');
|
||||
import { storeToRefs } from 'pinia';
|
||||
import useUserStore from '@/stores/useUserStore';
|
||||
const { getUserResume } = useUserStore();
|
||||
const { userInfo, isMiniProgram } = storeToRefs(useUserStore());
|
||||
const { userInfo, isMiniProgram ,hasLogin,isMachineEnv} = storeToRefs(useUserStore());
|
||||
const popup = ref(null);
|
||||
const selectJobsModel = ref(null);
|
||||
|
||||
@@ -83,6 +84,7 @@ const dataSource = ref([]);
|
||||
const filterList = ref([]);
|
||||
const dataItem = ref(null);
|
||||
const inputVal = ref('');
|
||||
const searchFocus = ref(false);
|
||||
|
||||
onLoad(() => {
|
||||
getTree();
|
||||
@@ -93,12 +95,14 @@ function close() {
|
||||
}
|
||||
|
||||
function handleBlur() {
|
||||
searchFocus.value = false
|
||||
setTimeout(() => {
|
||||
filterList.value = [];
|
||||
}, 100);
|
||||
}
|
||||
|
||||
function handleFocus() {
|
||||
searchFocus.value = true
|
||||
const val = inputVal.value.toLowerCase();
|
||||
if (val && dataSource.value) {
|
||||
filterList.value = dataSource.value.filter((item) => item.lable.toLowerCase().search(val) !== -1);
|
||||
@@ -141,6 +145,10 @@ function deleteItem(item, index) {
|
||||
}
|
||||
|
||||
function changeJobs() {
|
||||
if(isMachineEnv.value && !hasLogin.value){
|
||||
useUserStore().logOut()
|
||||
return
|
||||
}
|
||||
selectJobsModel.value?.open({
|
||||
title: '添加岗位',
|
||||
maskClick: true,
|
||||
@@ -217,6 +225,7 @@ function flattenTree(treeData, parentPath = '') {
|
||||
align-items: center;
|
||||
padding: 0 24rpx;
|
||||
position: relative;
|
||||
z-index:10;
|
||||
.search-input{
|
||||
flex: 1;
|
||||
padding: 0 20rpx;
|
||||
@@ -261,6 +270,15 @@ function flattenTree(treeData, parentPath = '') {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
.search-mask{
|
||||
position fixed;
|
||||
width 100vw;
|
||||
height:100vh;
|
||||
top:0;
|
||||
left:0
|
||||
z-index:9;
|
||||
background: #33333355;
|
||||
}
|
||||
.main{
|
||||
padding: 54rpx 28rpx 28rpx 28rpx
|
||||
.content-list{
|
||||
|
||||
Reference in New Issue
Block a user