flat: 基础修改
This commit is contained in:
@@ -93,14 +93,10 @@ export const findTradeList = () => {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
export const addInviteCompanyAuth = ({
|
export const addInviteCompanyAuth = (params) => {
|
||||||
params,
|
|
||||||
data
|
|
||||||
}) => {
|
|
||||||
return request({
|
return request({
|
||||||
url: '/api/jobslink-api/tenant/company/app/inviteCompany/auth',
|
url: '/api/jobslink-api/tenant/company/app/inviteCompany/auth',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
data,
|
|
||||||
params
|
params
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -65,449 +65,464 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {classifyData, classifyData2} from './classifyData.js';
|
import {
|
||||||
console.log(classifyData, classifyData2)
|
classifyData,
|
||||||
import { getTrade } from '@/api/resume.js'
|
classifyData2
|
||||||
export default {
|
} from './classifyData.js';
|
||||||
props: {
|
console.log(classifyData, classifyData2)
|
||||||
closePopUp: {
|
import {
|
||||||
type: Function,
|
getTrade
|
||||||
required: true
|
} from '@/api/resume.js'
|
||||||
},
|
export default {
|
||||||
subMitPopUp: {
|
props: {
|
||||||
type: Function,
|
closePopUp: {
|
||||||
required: true
|
type: Function,
|
||||||
},
|
required: true
|
||||||
isTask: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
components: {
|
|
||||||
// vTabs,
|
|
||||||
// companyList, verticalMenu
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
scrollTop: 0,
|
|
||||||
oldScrollTop: 0,
|
|
||||||
current: 0,
|
|
||||||
menuHeight: 0,
|
|
||||||
menuItemHeight: 0,
|
|
||||||
itemId: "0",
|
|
||||||
tabbar: classifyData,
|
|
||||||
menuItemPos: 0,
|
|
||||||
arr: [],
|
|
||||||
scrollRightTop: 0,
|
|
||||||
timer: null,
|
|
||||||
|
|
||||||
|
|
||||||
areaModal: {
|
|
||||||
address: '',
|
|
||||||
addressShow: false,
|
|
||||||
title: 'Hello',
|
|
||||||
// indexs: [0, 0, 8],
|
|
||||||
// defaultIds: [1, 110000, 110106],
|
|
||||||
defaultNames: ['四川省', '德阳市', '旌阳区'],
|
|
||||||
labelName: "areaName",
|
|
||||||
isClickAddress: false,
|
|
||||||
},
|
},
|
||||||
industryModal: {
|
subMitPopUp: {
|
||||||
industry: "",
|
type: Function,
|
||||||
industryList: [[]],
|
required: true
|
||||||
industryShow: false,
|
|
||||||
isClickIndustry: false,
|
|
||||||
},
|
},
|
||||||
|
isTask: {
|
||||||
submitData: {},
|
type: Boolean,
|
||||||
canSubmit: false,
|
default: false
|
||||||
|
|
||||||
}
|
|
||||||
},
|
|
||||||
created: function () {
|
|
||||||
if(!this.isTask) {
|
|
||||||
this.tabbar = classifyData2
|
|
||||||
}
|
|
||||||
this.getData()
|
|
||||||
this.getMenuItemTop()
|
|
||||||
},
|
|
||||||
|
|
||||||
|
|
||||||
methods: {
|
|
||||||
getData: function () {
|
|
||||||
getTrade().then(res => {
|
|
||||||
console.log(res.data.data);
|
|
||||||
const newData = this.tabbar;
|
|
||||||
|
|
||||||
newData.map(item => {
|
|
||||||
if (item.name === "行业") {
|
|
||||||
item.data = res.data.data
|
|
||||||
}
|
|
||||||
})
|
|
||||||
this.tabbar = newData;
|
|
||||||
this.industryModal.industry = res.data.data[0]?.name
|
|
||||||
this.industryModal.industryList = [res.data.data]
|
|
||||||
|
|
||||||
})
|
|
||||||
},
|
|
||||||
|
|
||||||
// 点击左边的栏目切换
|
|
||||||
async swichMenu(index) {
|
|
||||||
if (this.arr.length == 0) {
|
|
||||||
await this.getMenuItemTop();
|
|
||||||
}
|
}
|
||||||
if (index == this.current) return;
|
|
||||||
this.scrollRightTop = this.oldScrollTop;
|
|
||||||
this.$nextTick(() => {
|
|
||||||
this.scrollRightTop = this.arr[index];
|
|
||||||
// scrollRightTop = newarrTop
|
|
||||||
this.current = index;
|
|
||||||
this.leftMenuStatus(index);
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
|
components: {
|
||||||
// 获取一个目标元素的高度
|
// vTabs,
|
||||||
getElRect(elClass, dataVal) {
|
// companyList, verticalMenu
|
||||||
new Promise((resolve, reject) => {
|
|
||||||
// const query = uni.createSelectorQuery().in(this);
|
|
||||||
const query = uni.createSelectorQuery()
|
|
||||||
query.select('.' + elClass).fields({
|
|
||||||
size: true
|
|
||||||
}, res => {
|
|
||||||
// 如果节点尚未生成,res值为null,循环调用执行
|
|
||||||
if (!res) {
|
|
||||||
setTimeout(() => {
|
|
||||||
this.getElRect(elClass);
|
|
||||||
}, 10);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (dataVal == 'menuHeight') {
|
|
||||||
this.menuHeight = res.height;
|
|
||||||
}
|
|
||||||
if (dataVal == 'menuItemHeight') {
|
|
||||||
this.menuItemHeight = res.height;
|
|
||||||
}
|
|
||||||
|
|
||||||
resolve();
|
|
||||||
}).exec();
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
scrollTop: 0,
|
||||||
|
oldScrollTop: 0,
|
||||||
|
current: 0,
|
||||||
|
menuHeight: 0,
|
||||||
|
menuItemHeight: 0,
|
||||||
|
itemId: "0",
|
||||||
|
tabbar: classifyData,
|
||||||
|
menuItemPos: 0,
|
||||||
|
arr: [],
|
||||||
|
scrollRightTop: 0,
|
||||||
|
timer: null,
|
||||||
|
|
||||||
// 观测元素相交状态
|
|
||||||
async observer() {
|
|
||||||
this.tabbar.map((val, index) => {
|
|
||||||
let observer = uni.createIntersectionObserver(this);
|
|
||||||
// 检测右边scroll-view的id为itemxx的元素与right-box的相交状态
|
|
||||||
// 如果跟.right-box底部相交,就动态设置左边栏目的活动状态
|
|
||||||
observer.relativeTo('.right-box', {
|
|
||||||
top: 0
|
|
||||||
}).observe('#item' + index, res => {
|
|
||||||
if (res.intersectionRatio > 0) {
|
|
||||||
let id = res.id.substring(4);
|
|
||||||
this.leftMenuStatus(id);
|
|
||||||
}
|
|
||||||
})
|
|
||||||
})
|
|
||||||
},
|
|
||||||
|
|
||||||
// 设置左边菜单的滚动状态
|
areaModal: {
|
||||||
async leftMenuStatus(index) {
|
address: '',
|
||||||
this.current = index;
|
addressShow: false,
|
||||||
// 如果为0,意味着尚未初始化
|
title: 'Hello',
|
||||||
if (this.menuHeight == 0 || this.menuItemHeight == 0) {
|
// indexs: [0, 0, 8],
|
||||||
await this.getElRect('menu-scroll-view', 'menuHeight');
|
// defaultIds: [1, 110000, 110106],
|
||||||
await this.getElRect('u-tab-item', 'menuItemHeight');
|
defaultNames: ['四川省', '德阳市', '旌阳区'],
|
||||||
|
labelName: "areaName",
|
||||||
|
isClickAddress: false,
|
||||||
|
},
|
||||||
|
industryModal: {
|
||||||
|
industry: "",
|
||||||
|
industryList: [
|
||||||
|
[]
|
||||||
|
],
|
||||||
|
industryShow: false,
|
||||||
|
isClickIndustry: false,
|
||||||
|
},
|
||||||
|
|
||||||
|
submitData: {},
|
||||||
|
canSubmit: false,
|
||||||
|
|
||||||
}
|
}
|
||||||
// console.log(index, this.arr[index]);
|
},
|
||||||
// 将菜单活动item垂直居中
|
created: function() {
|
||||||
this.scrollTop = index * this.menuItemHeight + this.menuItemHeight / 2 - this.menuHeight / 2;
|
if (!this.isTask) {
|
||||||
|
this.tabbar = classifyData2
|
||||||
|
}
|
||||||
|
this.getData()
|
||||||
|
this.getMenuItemTop()
|
||||||
},
|
},
|
||||||
|
|
||||||
// 右边菜单滚动
|
|
||||||
async rightScroll(e) {
|
|
||||||
this.oldScrollTop = e.detail.scrollTop;
|
|
||||||
if (this.arr.length == 0) {
|
|
||||||
await this.getMenuItemTop();
|
|
||||||
}
|
|
||||||
if (this.timer) return;
|
|
||||||
if (!this.menuHeight) {
|
|
||||||
await this.getElRect('menu-scroll-view', 'menuHeight');
|
|
||||||
}
|
|
||||||
setTimeout(() => { // 节流
|
|
||||||
this.timer = null;
|
|
||||||
// scrollHeight为右边菜单垂直中点位置
|
|
||||||
let scrollHeight = e.detail.scrollTop + this.menuHeight / 2;
|
|
||||||
for (let i = 0; i < this.arr.length; i++) {
|
|
||||||
let height1 = this.arr[i];
|
|
||||||
let height2 = this.arr[i + 1];
|
|
||||||
|
|
||||||
// 如果不存在height2,意味着数据循环已经到了最后一个,设置左边菜单为最后一项即可
|
methods: {
|
||||||
if (!height2 || scrollHeight >= height1 && scrollHeight < height2) {
|
getData: function() {
|
||||||
this.leftMenuStatus(i - 1);
|
getTrade().then(res => {
|
||||||
return;
|
console.log(res.data.data);
|
||||||
}
|
const newData = this.tabbar;
|
||||||
}
|
|
||||||
}, 50)
|
|
||||||
},
|
|
||||||
|
|
||||||
// 获取右边菜单每个item到顶部的距离
|
newData.map(item => {
|
||||||
getMenuItemTop() {
|
if (item.name === "行业") {
|
||||||
new Promise(resolve => {
|
item.data = res.data.data
|
||||||
let selectorQuery = uni.createSelectorQuery();
|
}
|
||||||
console.log(selectorQuery);
|
|
||||||
selectorQuery.selectAll('.class-item').boundingClientRect((rects) => {
|
|
||||||
console.log(rects);
|
|
||||||
// 如果节点尚未生成,rects值为[](因为用selectAll,所以返回的是数组),循环调用执行
|
|
||||||
if (!rects.length) {
|
|
||||||
setTimeout(() => {
|
|
||||||
this.getMenuItemTop();
|
|
||||||
}, 10);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
rects.forEach((rect) => {
|
|
||||||
// 这里减去rects[0].top,是因为第一项顶部可能不是贴到导航栏(比如有个搜索框的情况)
|
|
||||||
this.arr.push(rect.top - rects[0].top);
|
|
||||||
resolve();
|
|
||||||
})
|
})
|
||||||
}).exec()
|
this.tabbar = newData;
|
||||||
})
|
this.industryModal.industry = res.data.data[0]?.name
|
||||||
},
|
this.industryModal.industryList = [res.data.data]
|
||||||
clickFunc({ type, bigObj, smallObj }) {
|
|
||||||
this.canSubmit = true;
|
|
||||||
switch (type) {
|
|
||||||
case "industry":
|
|
||||||
this.industryModal.industryShow = true;
|
|
||||||
this.industryModal.isClickIndustry = true;
|
|
||||||
this.$set(this.industryModal, 'isClickIndustry', true);
|
|
||||||
break;
|
|
||||||
case "address":
|
|
||||||
this.areaModal.addressShow = true;
|
|
||||||
// this.areaModal.isClickAddress=true;
|
|
||||||
this.$set(this.areaModal, 'isClickAddress', true);
|
|
||||||
break;
|
|
||||||
|
|
||||||
default:
|
})
|
||||||
this.$set(this.submitData, bigObj.name, smallObj.id);
|
},
|
||||||
console.log(this.submitData);
|
|
||||||
break;
|
// 点击左边的栏目切换
|
||||||
|
async swichMenu(index) {
|
||||||
|
if (this.arr.length == 0) {
|
||||||
|
await this.getMenuItemTop();
|
||||||
|
}
|
||||||
|
if (index == this.current) return;
|
||||||
|
this.scrollRightTop = this.oldScrollTop;
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.scrollRightTop = this.arr[index];
|
||||||
|
// scrollRightTop = newarrTop
|
||||||
|
this.current = index;
|
||||||
|
this.leftMenuStatus(index);
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
// 获取一个目标元素的高度
|
||||||
|
getElRect(elClass, dataVal) {
|
||||||
|
new Promise((resolve, reject) => {
|
||||||
|
// const query = uni.createSelectorQuery().in(this);
|
||||||
|
const query = uni.createSelectorQuery()
|
||||||
|
query.select('.' + elClass).fields({
|
||||||
|
size: true
|
||||||
|
}, res => {
|
||||||
|
// 如果节点尚未生成,res值为null,循环调用执行
|
||||||
|
if (!res) {
|
||||||
|
setTimeout(() => {
|
||||||
|
this.getElRect(elClass);
|
||||||
|
}, 10);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (dataVal == 'menuHeight') {
|
||||||
|
this.menuHeight = res.height;
|
||||||
|
}
|
||||||
|
if (dataVal == 'menuItemHeight') {
|
||||||
|
this.menuItemHeight = res.height;
|
||||||
|
}
|
||||||
|
|
||||||
|
resolve();
|
||||||
|
}).exec();
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
// 观测元素相交状态
|
||||||
|
async observer() {
|
||||||
|
this.tabbar.map((val, index) => {
|
||||||
|
let observer = uni.createIntersectionObserver(this);
|
||||||
|
// 检测右边scroll-view的id为itemxx的元素与right-box的相交状态
|
||||||
|
// 如果跟.right-box底部相交,就动态设置左边栏目的活动状态
|
||||||
|
observer.relativeTo('.right-box', {
|
||||||
|
top: 0
|
||||||
|
}).observe('#item' + index, res => {
|
||||||
|
if (res.intersectionRatio > 0) {
|
||||||
|
let id = res.id.substring(4);
|
||||||
|
this.leftMenuStatus(id);
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
// 设置左边菜单的滚动状态
|
||||||
|
async leftMenuStatus(index) {
|
||||||
|
this.current = index;
|
||||||
|
// 如果为0,意味着尚未初始化
|
||||||
|
if (this.menuHeight == 0 || this.menuItemHeight == 0) {
|
||||||
|
await this.getElRect('menu-scroll-view', 'menuHeight');
|
||||||
|
await this.getElRect('u-tab-item', 'menuItemHeight');
|
||||||
|
}
|
||||||
|
// console.log(index, this.arr[index]);
|
||||||
|
// 将菜单活动item垂直居中
|
||||||
|
this.scrollTop = index * this.menuItemHeight + this.menuItemHeight / 2 - this.menuHeight / 2;
|
||||||
|
},
|
||||||
|
|
||||||
|
// 右边菜单滚动
|
||||||
|
async rightScroll(e) {
|
||||||
|
this.oldScrollTop = e.detail.scrollTop;
|
||||||
|
if (this.arr.length == 0) {
|
||||||
|
await this.getMenuItemTop();
|
||||||
|
}
|
||||||
|
if (this.timer) return;
|
||||||
|
if (!this.menuHeight) {
|
||||||
|
await this.getElRect('menu-scroll-view', 'menuHeight');
|
||||||
|
}
|
||||||
|
setTimeout(() => { // 节流
|
||||||
|
this.timer = null;
|
||||||
|
// scrollHeight为右边菜单垂直中点位置
|
||||||
|
let scrollHeight = e.detail.scrollTop + this.menuHeight / 2;
|
||||||
|
for (let i = 0; i < this.arr.length; i++) {
|
||||||
|
let height1 = this.arr[i];
|
||||||
|
let height2 = this.arr[i + 1];
|
||||||
|
|
||||||
|
// 如果不存在height2,意味着数据循环已经到了最后一个,设置左边菜单为最后一项即可
|
||||||
|
if (!height2 || scrollHeight >= height1 && scrollHeight < height2) {
|
||||||
|
this.leftMenuStatus(i - 1);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}, 50)
|
||||||
|
},
|
||||||
|
|
||||||
|
// 获取右边菜单每个item到顶部的距离
|
||||||
|
getMenuItemTop() {
|
||||||
|
new Promise(resolve => {
|
||||||
|
let selectorQuery = uni.createSelectorQuery();
|
||||||
|
console.log(selectorQuery);
|
||||||
|
selectorQuery.selectAll('.class-item').boundingClientRect((rects) => {
|
||||||
|
console.log(rects);
|
||||||
|
// 如果节点尚未生成,rects值为[](因为用selectAll,所以返回的是数组),循环调用执行
|
||||||
|
if (!rects.length) {
|
||||||
|
setTimeout(() => {
|
||||||
|
this.getMenuItemTop();
|
||||||
|
}, 10);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
rects.forEach((rect) => {
|
||||||
|
// 这里减去rects[0].top,是因为第一项顶部可能不是贴到导航栏(比如有个搜索框的情况)
|
||||||
|
this.arr.push(rect.top - rects[0].top);
|
||||||
|
resolve();
|
||||||
|
})
|
||||||
|
}).exec()
|
||||||
|
})
|
||||||
|
},
|
||||||
|
clickFunc({
|
||||||
|
type,
|
||||||
|
bigObj,
|
||||||
|
smallObj
|
||||||
|
}) {
|
||||||
|
this.canSubmit = true;
|
||||||
|
switch (type) {
|
||||||
|
case "industry":
|
||||||
|
this.industryModal.industryShow = true;
|
||||||
|
this.industryModal.isClickIndustry = true;
|
||||||
|
this.$set(this.industryModal, 'isClickIndustry', true);
|
||||||
|
break;
|
||||||
|
case "address":
|
||||||
|
this.areaModal.addressShow = true;
|
||||||
|
// this.areaModal.isClickAddress=true;
|
||||||
|
this.$set(this.areaModal, 'isClickAddress', true);
|
||||||
|
break;
|
||||||
|
|
||||||
|
default:
|
||||||
|
this.$set(this.submitData, bigObj.name, smallObj.id);
|
||||||
|
console.log(this.submitData);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
},
|
||||||
|
changeHandler(e) {
|
||||||
|
const {
|
||||||
|
columnIndex,
|
||||||
|
value,
|
||||||
|
values, // values为当前变化列的数组内容
|
||||||
|
index,
|
||||||
|
// 微信小程序无法将picker实例传出来,只能通过ref操作
|
||||||
|
picker = this.$refs.uPicker
|
||||||
|
} = e
|
||||||
|
// 当第一列值发生变化时,变化第二列(后一列)对应的选项
|
||||||
|
if (columnIndex === 0) {
|
||||||
|
// picker为选择器this实例,变化第二列对应的选项
|
||||||
|
picker.setColumnValues(1, this.columnData[index])
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
confirmAddress(val) {
|
||||||
|
console.log(val, "点击地址");
|
||||||
|
var valArr = val.value;
|
||||||
|
this.areaModal.address = [...new Set(val.value)].join(' / ')
|
||||||
|
this.areaModal.address1 = valArr
|
||||||
|
this.areaModal.addressShow = false
|
||||||
|
},
|
||||||
|
pickerIndustryFunc(val) {
|
||||||
|
console.log(val, "点击行业");
|
||||||
|
this.industryModal.industry = val.value[0].name;
|
||||||
|
this.industryModal.industryShow = false
|
||||||
|
},
|
||||||
|
|
||||||
|
subMitFunc(val) {
|
||||||
|
if (!this.canSubmit) return;
|
||||||
|
|
||||||
|
if (!this.areaModal.isClickAddress) {
|
||||||
|
// this.areaModal.address1 = [null, null, null];
|
||||||
|
this.areaModal.address1 = ["", "", ""];
|
||||||
|
}
|
||||||
|
if (!this.industryModal.isClickIndustry) {
|
||||||
|
this.industryModal.industry = "";
|
||||||
|
}
|
||||||
|
console.log(this.submitData, this.areaModal, this.industryModal);
|
||||||
|
this.subMitPopUp({
|
||||||
|
submitData: this.submitData,
|
||||||
|
areaModal: this.areaModal,
|
||||||
|
industryModal: this.industryModal
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
|
||||||
changeHandler(e) {
|
|
||||||
const {
|
|
||||||
columnIndex,
|
|
||||||
value,
|
|
||||||
values, // values为当前变化列的数组内容
|
|
||||||
index,
|
|
||||||
// 微信小程序无法将picker实例传出来,只能通过ref操作
|
|
||||||
picker = this.$refs.uPicker
|
|
||||||
} = e
|
|
||||||
// 当第一列值发生变化时,变化第二列(后一列)对应的选项
|
|
||||||
if (columnIndex === 0) {
|
|
||||||
// picker为选择器this实例,变化第二列对应的选项
|
|
||||||
picker.setColumnValues(1, this.columnData[index])
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
confirmAddress(val) {
|
|
||||||
console.log(val, "点击地址");
|
|
||||||
var valArr = val.value;
|
|
||||||
this.areaModal.address = [...new Set(val.value)].join(' / ')
|
|
||||||
this.areaModal.address1 = valArr
|
|
||||||
this.areaModal.addressShow = false
|
|
||||||
},
|
|
||||||
pickerIndustryFunc(val) {
|
|
||||||
console.log(val, "点击行业");
|
|
||||||
this.industryModal.industry = val.value[0].name;
|
|
||||||
this.industryModal.industryShow = false
|
|
||||||
},
|
|
||||||
|
|
||||||
subMitFunc(val) {
|
|
||||||
if (!this.canSubmit) return;
|
|
||||||
|
|
||||||
if (!this.areaModal.isClickAddress) {
|
|
||||||
// this.areaModal.address1 = [null, null, null];
|
|
||||||
this.areaModal.address1 = ["", "", ""];
|
|
||||||
}
|
|
||||||
if (!this.industryModal.isClickIndustry) {
|
|
||||||
this.industryModal.industry = "";
|
|
||||||
}
|
|
||||||
console.log(this.submitData, this.areaModal, this.industryModal);
|
|
||||||
this.subMitPopUp({ submitData: this.submitData, areaModal: this.areaModal, industryModal: this.industryModal })
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.u-wrap {
|
.u-wrap {
|
||||||
height: calc(100vh);
|
height: calc(100vh);
|
||||||
/* #ifdef H5 */
|
/* #ifdef H5 */
|
||||||
height: calc(100vh - var(--window-top));
|
height: calc(100vh - var(--window-top));
|
||||||
/* #endif */
|
/* #endif */
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
}
|
}
|
||||||
|
|
||||||
.u-search-box {
|
.u-search-box {
|
||||||
padding: 18rpx 30rpx;
|
padding: 18rpx 30rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.u-menu-wrap {
|
.u-menu-wrap {
|
||||||
flex: 100;
|
flex: 100;
|
||||||
display: flex;
|
display: flex;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
.u-search-inner {
|
.u-search-inner {
|
||||||
background-color: rgb(234, 234, 234);
|
background-color: rgb(234, 234, 234);
|
||||||
border-radius: 100rpx;
|
border-radius: 100rpx;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
padding: 10rpx 16rpx;
|
padding: 10rpx 16rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.u-search-text {
|
.u-search-text {
|
||||||
font-size: 26rpx;
|
font-size: 26rpx;
|
||||||
color: #ccc;
|
color: #ccc;
|
||||||
margin-left: 10rpx;
|
margin-left: 10rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.u-tab-view {
|
.u-tab-view {
|
||||||
width: 200rpx;
|
width: 200rpx;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.u-tab-item {
|
.u-tab-item {
|
||||||
height: 110rpx;
|
height: 110rpx;
|
||||||
background: #f6f6f6;
|
background: #f6f6f6;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
font-size: 26rpx;
|
font-size: 26rpx;
|
||||||
color: #444;
|
color: #444;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
line-height: 1;
|
line-height: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
.u-tab-item-active {
|
.u-tab-item-active {
|
||||||
position: relative;
|
position: relative;
|
||||||
color: #000;
|
color: #000;
|
||||||
font-size: 30rpx;
|
font-size: 30rpx;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
background: #fff;
|
background: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.u-tab-item-active::before {
|
.u-tab-item-active::before {
|
||||||
content: "";
|
content: "";
|
||||||
position: absolute;
|
position: absolute;
|
||||||
border-left: 4px solid skyblue;
|
border-left: 4px solid skyblue;
|
||||||
height: 32rpx;
|
height: 32rpx;
|
||||||
left: 0;
|
left: 0;
|
||||||
top: 39rpx;
|
top: 39rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.u-tab-view {
|
.u-tab-view {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.right-box {
|
.right-box {
|
||||||
background-color: rgb(250, 250, 250);
|
background-color: rgb(250, 250, 250);
|
||||||
}
|
}
|
||||||
|
|
||||||
.page-view {
|
.page-view {
|
||||||
padding: 8rpx;
|
padding: 8rpx;
|
||||||
padding-left: 4rpx;
|
padding-left: 4rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.class-item {
|
.class-item {
|
||||||
margin-bottom: 10rpx;
|
margin-bottom: 10rpx;
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
padding: 16rpx;
|
padding: 16rpx;
|
||||||
border-radius: 8rpx;
|
border-radius: 8rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.class-item:last-child {
|
.class-item:last-child {
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
}
|
}
|
||||||
|
|
||||||
.item-title {
|
.item-title {
|
||||||
font-size: 28rpx;
|
font-size: 28rpx;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
|
||||||
.item-menu-name {
|
.item-menu-name {
|
||||||
font-weight: normal;
|
font-weight: normal;
|
||||||
font-size: 26rpx;
|
font-size: 26rpx;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.item-container {
|
.item-container {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
.thumb-box {
|
.thumb-box {
|
||||||
width: 43%;
|
width: 43%;
|
||||||
line-height: 80rpx;
|
line-height: 80rpx;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
margin-top: 25rpx;
|
margin-top: 25rpx;
|
||||||
margin-left: 20rpx;
|
margin-left: 20rpx;
|
||||||
background-color: #f3f4f8;
|
background-color: #f3f4f8;
|
||||||
border: 1px solid #f3f4f8;
|
border: 1px solid #f3f4f8;
|
||||||
color: #666666;
|
color: #666666;
|
||||||
}
|
}
|
||||||
|
|
||||||
.thumb-box1 {
|
.thumb-box1 {
|
||||||
width: 90%;
|
width: 90%;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.selected-box {
|
.selected-box {
|
||||||
background-color: #e3eafe;
|
background-color: #e3eafe;
|
||||||
border: 1px solid #92adfb;
|
border: 1px solid #92adfb;
|
||||||
color: #92adfb !important;
|
color: #92adfb !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.item-menu-image {
|
.item-menu-image {
|
||||||
width: 120rpx;
|
width: 120rpx;
|
||||||
height: 120rpx;
|
height: 120rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.buttonWrapper {
|
.buttonWrapper {
|
||||||
// position: absolute;
|
// position: absolute;
|
||||||
// bottom: 10px;
|
// bottom: 10px;
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-around;
|
justify-content: space-around;
|
||||||
margin-bottom: -10px;
|
margin-bottom: -10px;
|
||||||
margin-top: 10px;
|
margin-top: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.cancelButton {
|
.cancelButton {
|
||||||
padding: 15rpx 30rpx;
|
padding: 15rpx 120rpx;
|
||||||
background-color: #f3f4f8;
|
background-color: #f3f4f8;
|
||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
color: #9b9b9b;
|
color: #9b9b9b;
|
||||||
}
|
}
|
||||||
|
|
||||||
.sureButton {
|
.sureButton {
|
||||||
padding: 15rpx 150rpx;
|
padding: 15rpx 120rpx;
|
||||||
background-color: #4171f9;
|
background-color: #4171f9;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.noSubMitButton {
|
.noSubMitButton {
|
||||||
background-color: #f3f4f8;
|
background-color: #f3f4f8;
|
||||||
color: #9b9b9b;
|
color: #9b9b9b;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
@@ -1,40 +1,40 @@
|
|||||||
<template>
|
<template>
|
||||||
<view style="background-color: #fff;">
|
<view style="background-color: #fff;">
|
||||||
<view class="head" @click="goUserBase">
|
<view class="head" @click="goUserBase">
|
||||||
<image v-if="userInfo.avatar" :src="userInfo.avatar" mode=""></image>
|
<image v-if="userInfo.avatar" :src="userInfo.avatar" mode=""></image>
|
||||||
<image v-else src="../../../static/img/head.svg" mode=""></image>
|
<image v-else src="../../../static/img/head.svg" mode=""></image>
|
||||||
|
|
||||||
<view class="name">
|
<view class="name">
|
||||||
<view class="userName">
|
<view class="userName">
|
||||||
{{ auth.authInfo.realName }}
|
{{ auth.authInfo.realName }}
|
||||||
</view>
|
</view>
|
||||||
<view class="userInfo">
|
<view class="userInfo">
|
||||||
个人基本信息
|
个人基本信息
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<image src="../../../static/img/right.svg" mode=""></image>
|
<image src="../../../static/img/right.svg" mode=""></image>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="title">
|
<view class="title">
|
||||||
<view class="title_text">
|
<view class="title_text">
|
||||||
我的职业技能
|
我的职业技能
|
||||||
</view>
|
</view>
|
||||||
<image v-if="mySkills.length < 2" src="../../../static/img/add.gray.svg" mode="" @click="goAdd"></image>
|
<image v-if="mySkills.length < 2" src="../../../static/img/add.gray.svg" mode="" @click="goAdd"></image>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="listBody">
|
<view class="listBody">
|
||||||
<m-slide-list @controller-reg="controller.reg" @controller-moving="controller.moving"
|
<m-slide-list @controller-reg="controller.reg" @controller-moving="controller.moving"
|
||||||
@controller-opened="controller.opened" @controller-closed="controller.closed"
|
@controller-opened="controller.opened" @controller-closed="controller.closed"
|
||||||
@remove="removeSkills(item.id, index)" v-for="(item, index) in mySkills" :key="item.id"
|
@remove="removeSkills(item.id, index)" v-for="(item, index) in mySkills" :key="item.id"
|
||||||
:button="buttonList">
|
:button="buttonList">
|
||||||
<view class="list">
|
<view class="list">
|
||||||
<view class="list_text">
|
<view class="list_text">
|
||||||
{{ item.worktypes }}、{{ item.skills }}
|
{{ item.worktypes }}、{{ item.skills }}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</m-slide-list>
|
</m-slide-list>
|
||||||
</view>
|
</view>
|
||||||
<!-- <view class="jobcontent" @click="goSetCity">
|
<!-- <view class="jobcontent" @click="goSetCity">
|
||||||
<view class="jobinfo">
|
<view class="jobinfo">
|
||||||
<view
|
<view
|
||||||
v-bind:class="['jobAddress', { 'input-error': !myResume.city.id && !myResume.city.workplace && isShowBorder }]">
|
v-bind:class="['jobAddress', { 'input-error': !myResume.city.id && !myResume.city.workplace && isShowBorder }]">
|
||||||
@@ -47,463 +47,511 @@
|
|||||||
</view>
|
</view>
|
||||||
<image src="../../../static/img/right.svg" mode=""></image>
|
<image src="../../../static/img/right.svg" mode=""></image>
|
||||||
</view> -->
|
</view> -->
|
||||||
<view class="jobcontent" @click="areaModal.addressShow = true">
|
<view class="jobcontent" @click="areaModal.addressShow = true">
|
||||||
<view class="jobinfo">
|
<view class="jobinfo">
|
||||||
<view
|
<view
|
||||||
v-bind:class="['jobAddress', { 'input-error': !myResume.city.id && !myResume.city.workplace && isShowBorder }]">
|
v-bind:class="['jobAddress', { 'input-error': !myResume.city.id && !myResume.city.workplace && isShowBorder }]">
|
||||||
您想工作的地点
|
我想工作的地点
|
||||||
</view>
|
</view>
|
||||||
<view v-bind:class="['jobText']">
|
<view v-bind:class="['jobText']">
|
||||||
{{ myResume.city !== "{}" ? myResume.city.id ? getCity(myResume.city.id) : myResume.city.workplace :
|
{{ myResume.city !== "{}" ? myResume.city.id ? getCity(myResume.city.id) : myResume.city.workplace :
|
||||||
'请选择'
|
'请选择'
|
||||||
}}
|
}}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<image src="../../../static/img/right.svg" mode=""></image>
|
<image src="../../../static/img/right.svg" mode=""></image>
|
||||||
</view>
|
</view>
|
||||||
<view class="jobcontent" @click="showPickerFunc('education')">
|
<view class="jobcontent" @click="showPickerFunc('education')">
|
||||||
<view class="jobinfo">
|
<view class="jobinfo">
|
||||||
<view v-bind:class="['jobAddress', { 'input-error': !myResume.education.label && isShowBorder }]">
|
<view v-bind:class="['jobAddress', { 'input-error': !myResume.education.label && isShowBorder }]">
|
||||||
您的学历
|
我的学历
|
||||||
</view>
|
</view>
|
||||||
<view v-bind:class="['jobText']">
|
<view v-bind:class="['jobText']">
|
||||||
{{ myResume.education !== "{}" ? myResume.education.label : '请选择' }}
|
{{ myResume.education !== "{}" ? myResume.education.label : '请选择' }}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<image src="../../../static/img/right.svg" mode=""></image>
|
<image src="../../../static/img/right.svg" mode=""></image>
|
||||||
</view>
|
</view>
|
||||||
<view class="jobcontent" @click="showPickerFunc('wage')">
|
<view class="jobcontent" @click="showPickerFunc('wage')">
|
||||||
<view class="jobinfo">
|
<view class="jobinfo">
|
||||||
<view v-bind:class="['jobAddress', { 'input-error': !myResume.wage && isShowBorder }]">
|
<view v-bind:class="['jobAddress', { 'input-error': !myResume.wage && isShowBorder }]">
|
||||||
您的期望薪资
|
我的期望薪资
|
||||||
</view>
|
</view>
|
||||||
<view v-bind:class="['jobText']">
|
<view v-bind:class="['jobText']">
|
||||||
{{ myResume.wage ? myResume.wage : '请选择' }}
|
{{ myResume.wage ? myResume.wage : '请选择' }}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<image src="../../../static/img/right.svg" mode=""></image>
|
<image src="../../../static/img/right.svg" mode=""></image>
|
||||||
</view>
|
</view>
|
||||||
<view class="jobcontent">
|
<view class="jobcontent">
|
||||||
<view class="jobinfo">
|
<view class="jobinfo">
|
||||||
<view v-bind:class="['jobAddress', { 'input-error': !myResume.phone && isShowBorder }]">
|
<view v-bind:class="['jobAddress', { 'input-error': !myResume.phone && isShowBorder }]">
|
||||||
您的联系方式
|
我的联系方式
|
||||||
</view>
|
</view>
|
||||||
<u--input :value="myResume.phone" @focus="setPhoneFunc1" @change="setPhoneFunc" type="number"
|
<u--input :value="myResume.phone" @focus="setPhoneFunc1" @change="setPhoneFunc" type="number"
|
||||||
placeholder="请输入您的电话" border="none" clearable></u--input>
|
placeholder="请输入您的电话" border="none" clearable></u--input>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view v-if="isShowButton" class="saveWrapper">
|
<view v-if="isShowButton" class="saveWrapper">
|
||||||
<u-button @click="subMitResume" type="primary" shape="circle" text="保存"></u-button>
|
<u-button @click="subMitResume" type="primary" shape="circle" text="保存"></u-button>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="border"></view>
|
<view class="border"></view>
|
||||||
|
|
||||||
<u-picker @confirm="pickerButtonFunc" @cancel="showPicker = false" :show="showPicker" :columns="columns"
|
<u-picker @confirm="pickerButtonFunc" @cancel="showPicker = false" :show="showPicker" :columns="columns"
|
||||||
keyName="label"></u-picker>
|
keyName="label"></u-picker>
|
||||||
|
|
||||||
<u-toast ref="uToast"></u-toast>
|
<u-toast ref="uToast"></u-toast>
|
||||||
|
|
||||||
<!-- 省市 -->
|
<!-- 省市 -->
|
||||||
<data-picker :show="areaModal.addressShow" @confirm='confirmAddress' @cancel='areaModal.addressShow = false'
|
<data-picker :show="areaModal.addressShow" @confirm='confirmAddress' @cancel='areaModal.addressShow = false'
|
||||||
@close='areaModal.addressShow = false' :defaultNames="areaModal.defaultNames" :indexs="areaModal.indexs"
|
@close='areaModal.addressShow = false' :defaultNames="areaModal.defaultNames" :indexs="areaModal.indexs"
|
||||||
:defaultIds="areaModal.defaultIds" :showToolbar="false" :showBottombar="true"
|
:defaultIds="areaModal.defaultIds" :showToolbar="false" :showBottombar="true"
|
||||||
:labelName="areaModal.labelName"></data-picker>
|
:labelName="areaModal.labelName"></data-picker>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {
|
import {
|
||||||
mapGetters
|
mapGetters
|
||||||
} from 'vuex'
|
} from 'vuex'
|
||||||
import {
|
import {
|
||||||
mySkills,
|
mySkills,
|
||||||
myResume,
|
myResume,
|
||||||
removeSkills,
|
removeSkills,
|
||||||
setCity,
|
setCity,
|
||||||
setLearn,
|
setLearn,
|
||||||
setResume
|
setResume
|
||||||
} from '@/api/resume.js';
|
} from '@/api/resume.js';
|
||||||
import mSlideList from '@/components/mark-slide-list/mark-slide-list.vue';
|
import mSlideList from '@/components/mark-slide-list/mark-slide-list.vue';
|
||||||
import controller from '@/components/mark-slide-list/controller';
|
import controller from '@/components/mark-slide-list/controller';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
mSlideList
|
mSlideList
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
controller: new controller(),
|
controller: new controller(),
|
||||||
myResume: {
|
myResume: {
|
||||||
city: {},
|
city: {},
|
||||||
education: {},
|
education: {},
|
||||||
wage: "",
|
wage: "",
|
||||||
phone: "",
|
phone: "",
|
||||||
},
|
},
|
||||||
mySkills: [],
|
mySkills: [],
|
||||||
id: undefined,
|
id: undefined,
|
||||||
// id: '',
|
// id: '',
|
||||||
buttonList: [{
|
buttonList: [{
|
||||||
title: '删除',
|
title: '删除',
|
||||||
background: '#ff3b32',
|
background: '#ff3b32',
|
||||||
clickName: 'remove'
|
clickName: 'remove'
|
||||||
}],
|
}],
|
||||||
showPicker: false,
|
showPicker: false,
|
||||||
showType: "",
|
showType: "",
|
||||||
columns: [[]],
|
columns: [
|
||||||
|
[]
|
||||||
|
],
|
||||||
|
|
||||||
canSubMit: false,
|
canSubMit: false,
|
||||||
isShowButton: false,
|
isShowButton: false,
|
||||||
isShowBorder: false,
|
isShowBorder: false,
|
||||||
isShowAddSkill: true,
|
isShowAddSkill: true,
|
||||||
|
|
||||||
areaModal: {
|
areaModal: {
|
||||||
address: '',
|
address: '',
|
||||||
addressShow: false,
|
addressShow: false,
|
||||||
title: 'Hello',
|
title: 'Hello',
|
||||||
// indexs: [0, 0, 8],
|
// indexs: [0, 0, 8],
|
||||||
// defaultIds: [1, 110000, 110106],
|
// defaultIds: [1, 110000, 110106],
|
||||||
defaultNames: ['北京市', '北京市', '东城区'],
|
defaultNames: ['北京市', '北京市', '东城区'],
|
||||||
labelName: "areaName"
|
labelName: "areaName"
|
||||||
|
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onShow() {
|
onShow() {
|
||||||
this.getSkill()
|
this.getSkill()
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.getResume()
|
this.getResume()
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
...mapGetters(['userInfo', 'auth'])
|
...mapGetters(['userInfo', 'auth'])
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
myResume: {
|
myResume: {
|
||||||
handler: function (newVal, oldVal) {
|
handler: function(newVal, oldVal) {
|
||||||
if (newVal.city && newVal.education && newVal.wage && newVal.phone) {
|
if (newVal.city && newVal.education && newVal.wage && newVal.phone) {
|
||||||
this.canSubMit = true;
|
this.canSubMit = true;
|
||||||
} else {
|
} else {
|
||||||
this.canSubMit = false;
|
this.canSubMit = false;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
deep: true
|
deep: true
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getResume() {
|
getResume() {
|
||||||
myResume().then(res => {
|
myResume().then(res => {
|
||||||
const data = res.data.data
|
const data = res.data.data
|
||||||
this.myResume = {
|
this.myResume = {
|
||||||
city: { workplace: data.workplace },
|
city: {
|
||||||
education: { label: data.education },
|
workplace: data.workplace
|
||||||
wage: data.wage,
|
},
|
||||||
phone: data.telephone
|
education: {
|
||||||
}
|
label: data.education
|
||||||
this.isShowButton = false;
|
},
|
||||||
if (data && data.id) {
|
wage: data.wage,
|
||||||
this.id = data.id
|
phone: data.telephone
|
||||||
console.log(this.id,'-----------------------------');
|
}
|
||||||
}
|
this.isShowButton = false;
|
||||||
});
|
if (data && data.id) {
|
||||||
},
|
this.id = data.id
|
||||||
getSkill() {
|
console.log(this.id, '-----------------------------');
|
||||||
mySkills().then(res => {
|
}
|
||||||
this.mySkills = res.data.data;
|
});
|
||||||
})
|
},
|
||||||
},
|
getSkill() {
|
||||||
goWantSkill: function () {
|
mySkills().then(res => {
|
||||||
uni.$off('getWantSkill')
|
this.mySkills = res.data.data;
|
||||||
uni.$once('getWantSkill', (cb) => {
|
})
|
||||||
cb(this.myResume.learnSkill)
|
},
|
||||||
})
|
goWantSkill: function() {
|
||||||
uni.$off('setWantSkill')
|
uni.$off('getWantSkill')
|
||||||
uni.$once('setWantSkill', ({
|
uni.$once('getWantSkill', (cb) => {
|
||||||
skill,
|
cb(this.myResume.learnSkill)
|
||||||
done
|
})
|
||||||
}) => {
|
uni.$off('setWantSkill')
|
||||||
setLearn(this.id, skill).then(res => {
|
uni.$once('setWantSkill', ({
|
||||||
uni.navigateBack()
|
skill,
|
||||||
}).catch(() => {
|
done
|
||||||
done && done()
|
}) => {
|
||||||
})
|
setLearn(this.id, skill).then(res => {
|
||||||
this.getResume()
|
uni.navigateBack()
|
||||||
})
|
}).catch(() => {
|
||||||
uni.navigateTo({
|
done && done()
|
||||||
url: './setWskill?id=' + this.id
|
})
|
||||||
})
|
this.getResume()
|
||||||
},
|
})
|
||||||
goSetCity: function () {
|
uni.navigateTo({
|
||||||
uni.$off('setCity')
|
url: './setWskill?id=' + this.id
|
||||||
uni.$on('setCity', ({ detail }) => {
|
})
|
||||||
console.log(detail, '---------------');
|
},
|
||||||
this.isShowButton = true
|
goSetCity: function() {
|
||||||
this.myResume.city = detail
|
uni.$off('setCity')
|
||||||
// setCity(this.id, detail.parentLabel + '-' + detail.label).then(res => {
|
uni.$on('setCity', ({
|
||||||
// this.myResume.cityId = detail.id
|
detail
|
||||||
// this.getResume()
|
}) => {
|
||||||
// })
|
console.log(detail, '---------------');
|
||||||
})
|
this.isShowButton = true
|
||||||
uni.navigateTo({
|
this.myResume.city = detail
|
||||||
url: `/pages/setCity/setCity?maxLayer=2`
|
// setCity(this.id, detail.parentLabel + '-' + detail.label).then(res => {
|
||||||
})
|
// this.myResume.cityId = detail.id
|
||||||
},
|
// this.getResume()
|
||||||
goAdd: function () {
|
// })
|
||||||
|
})
|
||||||
|
uni.navigateTo({
|
||||||
|
url: `/pages/setCity/setCity?maxLayer=2`
|
||||||
|
})
|
||||||
|
},
|
||||||
|
goAdd: function() {
|
||||||
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: './addSkill'
|
url: './addSkill'
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
goUserBase: function () {
|
goUserBase: function() {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '../userBase'
|
url: '../userBase'
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getCity: function (val) {
|
getCity: function(val) {
|
||||||
if (val) {
|
if (val) {
|
||||||
let areas = this.$store.getters.getAreaParents(val)
|
let areas = this.$store.getters.getAreaParents(val)
|
||||||
if (areas.length) {
|
if (areas.length) {
|
||||||
return areas[0].label + '-' + areas[1].label
|
return areas[0].label + '-' + areas[1].label
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
removeSkills: function (id, index) {
|
removeSkills: function(id, index) {
|
||||||
removeSkills(id).then(res => {
|
removeSkills(id).then(res => {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: '操作成功',
|
title: '操作成功',
|
||||||
icon: 'none'
|
icon: 'none'
|
||||||
});
|
});
|
||||||
this.mySkills.splice(index, 1)
|
this.mySkills.splice(index, 1)
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
showPickerFunc(type) {
|
showPickerFunc(type) {
|
||||||
this.showType = type;
|
this.showType = type;
|
||||||
switch (type) {
|
switch (type) {
|
||||||
case "education":
|
case "education":
|
||||||
this.columns =
|
this.columns = [
|
||||||
[[
|
[{
|
||||||
{ label: 'MBA/EMBA', value: 0 }, { label: '博士', value: 1 }, { label: '硕士', value: 2 }, { label: '本科', value: 3 },
|
label: 'MBA/EMBA',
|
||||||
{ label: '大专', value: 4 }, { label: '高中', value: 5 }, { label: '中专/中技', value: 6 }, { label: '初中及以下,', value: 7 },
|
value: 0
|
||||||
{ label: '不限', value: 8 }
|
}, {
|
||||||
]]
|
label: '博士',
|
||||||
break;
|
value: 1
|
||||||
case "wage":
|
}, {
|
||||||
this.columns = [['10-15元/小时', '16-20元/小时', '21-25元/小时', '26-30元/小时', '30元/小时以上', '100-150元/天', '151-200元/天'
|
label: '硕士',
|
||||||
, '201-250元/天', '251-300元/天', "300元/天以上", "2000元(含)以下/月", "2000-5000元(含)/月", "5000-8000元(含)/月",
|
value: 2
|
||||||
"8000-10000元(含)/月", "10000-15000元(含)/月", "15000-20000元(含)/月", "20000-25000元(含)/月", "25000-30000元(含)/月", "30000元以上/月", "面议、暂无要求"
|
}, {
|
||||||
]]
|
label: '本科',
|
||||||
|
value: 3
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '大专',
|
||||||
|
value: 4
|
||||||
|
}, {
|
||||||
|
label: '高中',
|
||||||
|
value: 5
|
||||||
|
}, {
|
||||||
|
label: '中专/中技',
|
||||||
|
value: 6
|
||||||
|
}, {
|
||||||
|
label: '初中及以下,',
|
||||||
|
value: 7
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '不限',
|
||||||
|
value: 8
|
||||||
|
}
|
||||||
|
]
|
||||||
|
]
|
||||||
|
break;
|
||||||
|
case "wage":
|
||||||
|
this.columns = [
|
||||||
|
['10-15元/小时', '16-20元/小时', '21-25元/小时', '26-30元/小时', '30元/小时以上', '100-150元/天',
|
||||||
|
'151-200元/天', '201-250元/天', '251-300元/天', "300元/天以上", "2000元(含)以下/月",
|
||||||
|
"2000-5000元(含)/月", "5000-8000元(含)/月",
|
||||||
|
"8000-10000元(含)/月", "10000-15000元(含)/月", "15000-20000元(含)/月", "20000-25000元(含)/月",
|
||||||
|
"25000-30000元(含)/月", "30000元以上/月", "面议、暂无要求"
|
||||||
|
]
|
||||||
|
]
|
||||||
|
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
this.isShowButton = true;
|
this.isShowButton = true;
|
||||||
this.showPicker = true;
|
this.showPicker = true;
|
||||||
},
|
},
|
||||||
pickerButtonFunc(e) {
|
pickerButtonFunc(e) {
|
||||||
console.log(e, this.myResume, this.myResume[this.showType]);
|
console.log(e, this.myResume, this.myResume[this.showType]);
|
||||||
this.myResume[this.showType] = e.value[0];
|
this.myResume[this.showType] = e.value[0];
|
||||||
this.showPicker = false;
|
this.showPicker = false;
|
||||||
},
|
},
|
||||||
setPhoneFunc(e) {
|
setPhoneFunc(e) {
|
||||||
this.myResume.phone = e;
|
this.myResume.phone = e;
|
||||||
},
|
},
|
||||||
setPhoneFunc1(e) {
|
setPhoneFunc1(e) {
|
||||||
this.isShowButton = true;
|
this.isShowButton = true;
|
||||||
},
|
},
|
||||||
showToast(text) {
|
showToast(text) {
|
||||||
this.$refs.uToast.show({
|
this.$refs.uToast.show({
|
||||||
type: 'error',
|
type: 'error',
|
||||||
icon: false,
|
icon: false,
|
||||||
title: '失败主题',
|
title: '失败主题',
|
||||||
message: text,
|
message: text,
|
||||||
iconUrl: 'https://cdn.uviewui.com/uview/demo/toast/error.png',
|
iconUrl: 'https://cdn.uviewui.com/uview/demo/toast/error.png',
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
subMitResume() {
|
subMitResume() {
|
||||||
console.log(this.myResume);
|
console.log(this.myResume);
|
||||||
this.isShowBorder = true;
|
this.isShowBorder = true;
|
||||||
if (!this.canSubMit) return;
|
if (!this.canSubMit) return;
|
||||||
const { city, education, phone, wage } = this.myResume
|
const {
|
||||||
// 中国大陆手机号码正则表达式
|
city,
|
||||||
const mobileRegex = /\b(1[3-9]\d{9})\b/;
|
education,
|
||||||
// 中国大陆座机号码正则表达式
|
phone,
|
||||||
const landlineRegex = /\b(0\d{2,3}-\d{7,8}(-\d{1,4})?)\b/;
|
wage
|
||||||
|
} = this.myResume
|
||||||
|
// 中国大陆手机号码正则表达式
|
||||||
|
const mobileRegex = /\b(1[3-9]\d{9})\b/;
|
||||||
|
// 中国大陆座机号码正则表达式
|
||||||
|
const landlineRegex = /\b(0\d{2,3}-\d{7,8}(-\d{1,4})?)\b/;
|
||||||
|
|
||||||
|
|
||||||
if (mobileRegex.test(phone) || landlineRegex.test(phone)) {
|
if (mobileRegex.test(phone) || landlineRegex.test(phone)) {
|
||||||
// 电话号码格式正确
|
// 电话号码格式正确
|
||||||
console.log(phone, "电话号码格式正确");
|
console.log(phone, "电话号码格式正确");
|
||||||
setResume({
|
setResume({
|
||||||
id: this.id, education: education.label, workplace: city.workplace ? city.workplace : city.parentLabel + '-' + city.label, telephone: phone, wage
|
id: this.id,
|
||||||
}).then(res => {
|
education: education.label,
|
||||||
this.isShowButton = false;
|
workplace: city.workplace ? city.workplace : city.parentLabel + '-' + city.label,
|
||||||
this.getResume()
|
telephone: phone,
|
||||||
})
|
wage
|
||||||
} else {
|
}).then(res => {
|
||||||
// 电话号码格式不正确
|
this.isShowButton = false;
|
||||||
console.log(phone, "电话号码格式不正确");
|
this.getResume()
|
||||||
this.showToast("电话号码格式不正确");
|
})
|
||||||
}
|
} else {
|
||||||
return;
|
// 电话号码格式不正确
|
||||||
|
console.log(phone, "电话号码格式不正确");
|
||||||
|
this.showToast("电话号码格式不正确");
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
confirmAddress(val) {
|
confirmAddress(val) {
|
||||||
console.log(val);
|
console.log(val);
|
||||||
var valArr = val.value;
|
var valArr = val.value;
|
||||||
// this.areaModal.address = [...new Set(val.value)].join(' / ')
|
// this.areaModal.address = [...new Set(val.value)].join(' / ')
|
||||||
this.isShowButton = true
|
this.isShowButton = true
|
||||||
this.myResume.city.workplace = [...new Set(val.value)].join('/')
|
this.myResume.city.workplace = [...new Set(val.value)].join('/')
|
||||||
console.log(this.areaModal.address);
|
console.log(this.areaModal.address);
|
||||||
this.areaModal.addressShow = false
|
this.areaModal.addressShow = false
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
.border {
|
.border {
|
||||||
margin-left: 30rpx;
|
margin-left: 30rpx;
|
||||||
width: 720rpx;
|
width: 720rpx;
|
||||||
border: 1rpx solid #f2f2f2;
|
border: 1rpx solid #f2f2f2;
|
||||||
|
|
||||||
/* height: 1rpx;
|
/* height: 1rpx;
|
||||||
background-color: #ddd; */
|
background-color: #ddd; */
|
||||||
}
|
}
|
||||||
|
|
||||||
.jobText {
|
.jobText {
|
||||||
font-family: PingFangSC-Regular;
|
font-family: PingFangSC-Regular;
|
||||||
font-size: 32rpx;
|
font-size: 32rpx;
|
||||||
color: #666666;
|
color: #666666;
|
||||||
}
|
}
|
||||||
|
|
||||||
.jobAddress {
|
.jobAddress {
|
||||||
font-family: PingFangSC-Regular;
|
font-family: PingFangSC-Regular;
|
||||||
font-size: 28rpx;
|
font-size: 28rpx;
|
||||||
color: #999999;
|
color: #999999;
|
||||||
}
|
}
|
||||||
|
|
||||||
.nochoose {
|
.nochoose {
|
||||||
/* color: #ccc; */
|
/* color: #ccc; */
|
||||||
}
|
}
|
||||||
|
|
||||||
.jobcontent {
|
.jobcontent {
|
||||||
padding: 30rpx;
|
padding: 30rpx;
|
||||||
background: #fff;
|
background: #fff;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
line-height: 63rpx;
|
line-height: 63rpx;
|
||||||
border: 1px solid #fff;
|
border: 1px solid #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.jobcontent image {
|
.jobcontent image {
|
||||||
width: 40rpx;
|
width: 40rpx;
|
||||||
height: 40rpx;
|
height: 40rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.listBody {}
|
.listBody {}
|
||||||
|
|
||||||
.list_text {
|
.list_text {
|
||||||
font-family: PingFangSC-Regular;
|
font-family: PingFangSC-Regular;
|
||||||
font-size: 32rpx;
|
font-size: 32rpx;
|
||||||
color: #666666;
|
color: #666666;
|
||||||
background: #ffffff;
|
background: #ffffff;
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
/* white-space: nowrap; */
|
/* white-space: nowrap; */
|
||||||
overflow-wrap: break-word;
|
overflow-wrap: break-word;
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
}
|
}
|
||||||
|
|
||||||
.list image {
|
.list image {
|
||||||
width: 40rpx;
|
width: 40rpx;
|
||||||
height: 40rpx;
|
height: 40rpx;
|
||||||
margin-left: auto;
|
margin-left: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.list {
|
.list {
|
||||||
padding: 0 15px 0 30rpx;
|
padding: 0 15px 0 30rpx;
|
||||||
height: 126rpx;
|
height: 126rpx;
|
||||||
/* line-height: 126rpx; */
|
/* line-height: 126rpx; */
|
||||||
background: #fff;
|
background: #fff;
|
||||||
border-bottom: 1px solid #f2f2f2;
|
border-bottom: 1px solid #f2f2f2;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.title image {
|
.title image {
|
||||||
width: 40rpx;
|
width: 40rpx;
|
||||||
height: 40rpx;
|
height: 40rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.title {
|
.title {
|
||||||
font-family: PingFangSC-Regular;
|
font-family: PingFangSC-Regular;
|
||||||
font-size: 28rpx;
|
font-size: 28rpx;
|
||||||
color: #999999;
|
color: #999999;
|
||||||
display: flex;
|
display: flex;
|
||||||
padding: 25rpx 30rpx;
|
padding: 25rpx 30rpx;
|
||||||
/* padding-top: 30rpx; */
|
/* padding-top: 30rpx; */
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
border: 1rpx solid #f2f2f2;
|
border: 1rpx solid #f2f2f2;
|
||||||
}
|
}
|
||||||
|
|
||||||
.userInfo {
|
.userInfo {
|
||||||
font-family: PingFangSC-Regular;
|
font-family: PingFangSC-Regular;
|
||||||
font-size: 24rpx;
|
font-size: 24rpx;
|
||||||
color: #999999;
|
color: #999999;
|
||||||
}
|
}
|
||||||
|
|
||||||
.name {
|
.name {
|
||||||
margin-left: 20rpx;
|
margin-left: 20rpx;
|
||||||
font-family: PingFangSC-Medium;
|
font-family: PingFangSC-Medium;
|
||||||
font-size: 36rpx;
|
font-size: 36rpx;
|
||||||
color: #333333;
|
color: #333333;
|
||||||
line-height: 50rpx;
|
line-height: 50rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.head image:last-child {
|
.head image:last-child {
|
||||||
width: 40rpx;
|
width: 40rpx;
|
||||||
height: 40rpx;
|
height: 40rpx;
|
||||||
margin-left: auto;
|
margin-left: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.head image {
|
.head image {
|
||||||
width: 100rpx;
|
width: 100rpx;
|
||||||
height: 100rpx;
|
height: 100rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
page {
|
page {
|
||||||
background-color: #FFFFFF;
|
background-color: #FFFFFF;
|
||||||
}
|
}
|
||||||
|
|
||||||
.head {
|
.head {
|
||||||
padding: 30rpx;
|
padding: 30rpx;
|
||||||
width: 690rpx;
|
width: 690rpx;
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: flex-start;
|
justify-content: flex-start;
|
||||||
}
|
}
|
||||||
|
|
||||||
.saveWrapper {
|
.saveWrapper {
|
||||||
width: 80%;
|
width: 80%;
|
||||||
padding: 20rpx;
|
padding: 20rpx;
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
padding-bottom: 60rpx;
|
padding-bottom: 60rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
.input-error {
|
.input-error {
|
||||||
color: red;
|
color: red;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
1476
pages.json
1476
pages.json
File diff suppressed because it is too large
Load Diff
@@ -8,7 +8,7 @@
|
|||||||
<view class="headd_left">
|
<view class="headd_left">
|
||||||
<u-icon name="search" color="#2297fa" size="24"></u-icon>
|
<u-icon name="search" color="#2297fa" size="24"></u-icon>
|
||||||
<input placeholder-class="search_style" type="text" confirm-type="搜索" v-model="keywords"
|
<input placeholder-class="search_style" type="text" confirm-type="搜索" v-model="keywords"
|
||||||
placeholder="搜任务/搜岗位/搜个体户招工/搜政策" />
|
placeholder="搜任务/搜岗位/搜政策" />
|
||||||
</view>
|
</view>
|
||||||
<view class="headd_right">
|
<view class="headd_right">
|
||||||
搜索
|
搜索
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="">
|
<view class="">
|
||||||
<view class="content">
|
<view class="content">
|
||||||
<u--form labelPosition="left" :model="formData" :rules="rules" ref="uForm">
|
<u--form labelPosition="left" :model="formData" :rules="rules" ref="formOne">
|
||||||
<view class="card">
|
<view class="card">
|
||||||
<view class="card_title">企业信息</view>
|
<view class="card_title">企业信息</view>
|
||||||
<u-form-item label="企业名称" labelWidth="100" prop="comname" borderBottom ref="item1">
|
<u-form-item label="企业名称" labelWidth="100" prop="comname" borderBottom ref="item1">
|
||||||
@@ -40,7 +40,8 @@
|
|||||||
</u-form-item>
|
</u-form-item>
|
||||||
<u-form-item label="企业介绍" labelWidth="100" labelPosition="top" prop="companyDesc" borderBottom
|
<u-form-item label="企业介绍" labelWidth="100" labelPosition="top" prop="companyDesc" borderBottom
|
||||||
ref="item1">
|
ref="item1">
|
||||||
<u--textarea v-model="formData.companyDesc" placeholder="请输入内容"></u--textarea>
|
<u--textarea v-model="formData.companyDesc" placeholder="请输入企业介绍" count
|
||||||
|
maxlength="200"></u--textarea>
|
||||||
</u-form-item>
|
</u-form-item>
|
||||||
</view>
|
</view>
|
||||||
<view class="card">
|
<view class="card">
|
||||||
@@ -56,11 +57,18 @@
|
|||||||
<view class="card">
|
<view class="card">
|
||||||
<view class="card_title">相关资料</view>
|
<view class="card_title">相关资料</view>
|
||||||
<view class="card_content">
|
<view class="card_content">
|
||||||
<UploadIdNumber v-model="formData.identityUrl4Id" backImg="/static/img/idcard.png">
|
<u-form-item labelWidth="100" prop="identityUrl4Id">
|
||||||
</UploadIdNumber>
|
<UploadIdNumber v-model="formData.identityUrl4Id" backImg="/static/img/idcard.png">
|
||||||
<UploadIdNumber v-model="formData.identityUrl5Id" backImg="/static/img/backidcard1.png">
|
</UploadIdNumber>
|
||||||
</UploadIdNumber>
|
</u-form-item>
|
||||||
<UploadIdNumber v-model="formData.authUrlId" backImg="/static/img/idcard.png"></UploadIdNumber>
|
<u-form-item labelWidth="100" prop="identityUrl5Id">
|
||||||
|
<UploadIdNumber v-model="formData.identityUrl5Id" backImg="/static/img/backidcard1.png">
|
||||||
|
</UploadIdNumber>
|
||||||
|
</u-form-item>
|
||||||
|
<u-form-item labelWidth="100" prop="authUrlId">
|
||||||
|
<UploadIdNumber v-model="formData.authUrlId" backImg="/static/img/idcard.png">
|
||||||
|
</UploadIdNumber>
|
||||||
|
</u-form-item>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
@@ -80,10 +88,98 @@
|
|||||||
import {
|
import {
|
||||||
addInviteCompanyAuth
|
addInviteCompanyAuth
|
||||||
} from '@/api/userrecruit.js'
|
} from '@/api/userrecruit.js'
|
||||||
const rules = []
|
|
||||||
import {
|
import {
|
||||||
mapState
|
mapState
|
||||||
} from 'vuex'
|
} from 'vuex'
|
||||||
|
const rules = {
|
||||||
|
comname: {
|
||||||
|
type: 'string',
|
||||||
|
required: true,
|
||||||
|
message: '请输入企业名称',
|
||||||
|
trigger: ['change']
|
||||||
|
},
|
||||||
|
companyTid: {
|
||||||
|
type: 'string',
|
||||||
|
required: true,
|
||||||
|
message: '请输入统一信用代码',
|
||||||
|
trigger: ['change']
|
||||||
|
},
|
||||||
|
masterName: {
|
||||||
|
type: 'string',
|
||||||
|
required: true,
|
||||||
|
message: '请输入法人姓名',
|
||||||
|
trigger: ['change']
|
||||||
|
},
|
||||||
|
masterIdentity: {
|
||||||
|
type: 'string',
|
||||||
|
required: true,
|
||||||
|
pattern: /^[1-9]\d{5}(19|20)\d{2}((0[1-9])|(1[0-2]))(([0-2][1-9])|10|20|30|31)\d{3}[Xx\d]$/,
|
||||||
|
message: '请输入法人身份证号',
|
||||||
|
trigger: ['change']
|
||||||
|
},
|
||||||
|
cityId: {
|
||||||
|
type: 'string',
|
||||||
|
required: true,
|
||||||
|
message: '请选择所在地区',
|
||||||
|
trigger: ['change']
|
||||||
|
},
|
||||||
|
companyAddress: {
|
||||||
|
type: 'string',
|
||||||
|
required: true,
|
||||||
|
message: '请输入详细地址',
|
||||||
|
trigger: ['change']
|
||||||
|
},
|
||||||
|
nature: {
|
||||||
|
type: 'string',
|
||||||
|
required: true,
|
||||||
|
message: '请选择企业性质',
|
||||||
|
trigger: ['change']
|
||||||
|
},
|
||||||
|
tradeId: {
|
||||||
|
type: 'string',
|
||||||
|
required: true,
|
||||||
|
message: '请选择行业',
|
||||||
|
trigger: ['change']
|
||||||
|
},
|
||||||
|
companyDesc: {
|
||||||
|
type: 'string',
|
||||||
|
min: 20,
|
||||||
|
required: true,
|
||||||
|
message: '请输入企业介绍(最少20个字符)',
|
||||||
|
trigger: ['change']
|
||||||
|
},
|
||||||
|
manager: {
|
||||||
|
type: 'string',
|
||||||
|
required: true,
|
||||||
|
message: '请输入联系人',
|
||||||
|
trigger: ['change']
|
||||||
|
},
|
||||||
|
telphone: {
|
||||||
|
type: 'string',
|
||||||
|
required: true,
|
||||||
|
pattern: /^1[3-9]{1}[0-9]{9}$/,
|
||||||
|
message: '请输入手机号码',
|
||||||
|
trigger: ['change']
|
||||||
|
},
|
||||||
|
identityUrl4Id: {
|
||||||
|
type: 'string',
|
||||||
|
required: true,
|
||||||
|
message: '请上传法人身份证(人像)',
|
||||||
|
trigger: ['change']
|
||||||
|
},
|
||||||
|
identityUrl5Id: {
|
||||||
|
type: 'string',
|
||||||
|
required: true,
|
||||||
|
message: '请上传法人身份证(国徽)',
|
||||||
|
trigger: ['change']
|
||||||
|
},
|
||||||
|
authUrlId: {
|
||||||
|
type: 'string',
|
||||||
|
required: true,
|
||||||
|
message: '请上传企业营业执照',
|
||||||
|
trigger: ['change']
|
||||||
|
},
|
||||||
|
}
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
UploadIdNumber,
|
UploadIdNumber,
|
||||||
@@ -108,28 +204,29 @@
|
|||||||
created() {
|
created() {
|
||||||
this.formData.manager = this.authInfo.realName
|
this.formData.manager = this.authInfo.realName
|
||||||
this.formData.idNumber = this.authInfo.idNumber
|
this.formData.idNumber = this.authInfo.idNumber
|
||||||
console.log(this.authInfo)
|
|
||||||
console.log(this.userInfo)
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
hideKeyboard() {
|
hideKeyboard() {
|
||||||
uni.hideKeyboard()
|
uni.hideKeyboard()
|
||||||
},
|
},
|
||||||
async submit() {
|
async submit() {
|
||||||
let data = {
|
const _this = this
|
||||||
...this.formData,
|
this.$refs.formOne.validate().then(res => {
|
||||||
nature: Number(this.formData.nature),
|
_this.$api.msg('提交数据')
|
||||||
cityId: Number(this.formData.cityId),
|
}).catch(errors => {
|
||||||
tradeId: Number(this.formData.tradeId),
|
_this.$api.msg('请完善内容')
|
||||||
}
|
|
||||||
let params = {
|
|
||||||
// auth: this.authInfo.authValue
|
|
||||||
}
|
|
||||||
let resData = await addInviteCompanyAuth({
|
|
||||||
params,
|
|
||||||
data
|
|
||||||
})
|
})
|
||||||
console.log(resData)
|
// let params = {
|
||||||
|
// ...this.formData,
|
||||||
|
// nature: Number(this.formData.nature),
|
||||||
|
// cityId: Number(this.formData.cityId),
|
||||||
|
// tradeId: Number(this.formData.tradeId),
|
||||||
|
// }
|
||||||
|
// let resData = await addInviteCompanyAuth(params)
|
||||||
|
// console.log(resData)
|
||||||
|
// if (resData.data.code === 200) {
|
||||||
|
// _this.$api.msg('已完成企业信息认证')
|
||||||
|
// }
|
||||||
},
|
},
|
||||||
reset() {
|
reset() {
|
||||||
const _this = this
|
const _this = this
|
||||||
|
|||||||
@@ -1,110 +1,116 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="mainWrapper">
|
<view class="mainWrapper">
|
||||||
<view v-show="!searchResultShow" class="headSearch">
|
<view v-show="!searchResultShow" class="headSearch">
|
||||||
<view class="search-view">
|
<view class="search-view">
|
||||||
<view class="search-item">
|
<view class="search-item">
|
||||||
<image src="../../static/img/search.svg" style="width: 32rpx;height: 32rpx;" mode=""></image>
|
<image src="../../static/img/search.svg" style="width: 32rpx;height: 32rpx;" mode=""></image>
|
||||||
<input type="text" confirm-type="搜索" v-model="keywords" @confirm="getNewList('search')"
|
<input type="text" confirm-type="搜索" v-model="keywords" @confirm="getNewList('search')"
|
||||||
placeholder="搜任务/搜岗位/搜个体户招工/搜政策" />
|
placeholder="搜任务/搜岗位/搜政策" />
|
||||||
<view @click="getNewList('search')" style="width: 80rpx;height: 50rpx;color:#fff;background-color: #0091ff;font-size:24rpx;text-align: center;line-height: 50rpx;border-radius: 25rpx;;">搜索</view>
|
<view @click="getNewList('search')"
|
||||||
</view>
|
style="width: 80rpx;height: 50rpx;color:#fff;background-color: #0091ff;font-size:24rpx;text-align: center;line-height: 50rpx;border-radius: 25rpx;;">
|
||||||
<!-- <view class="close" @click="closeBack">
|
搜索</view>
|
||||||
|
</view>
|
||||||
|
<!-- <view class="close" @click="closeBack">
|
||||||
取消
|
取消
|
||||||
</view> -->
|
</view> -->
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-show="searchResultShow" class="headSearch">
|
<view v-show="searchResultShow" class="headSearch">
|
||||||
<view class="search-view">
|
<view class="search-view">
|
||||||
<view class="search-item" @click="clearCurrentKeyWords">
|
<view class="search-item" @click="clearCurrentKeyWords">
|
||||||
<!-- <image src="../../static/img/search.svg" style="width: 32rpx;height: 32rpx;" mode=""></image> -->
|
<!-- <image src="../../static/img/search.svg" style="width: 32rpx;height: 32rpx;" mode=""></image> -->
|
||||||
<!-- <input type="text" confirm-type="搜索" v-model="keywords" @confirm="getNewList('search')"
|
<!-- <input type="text" confirm-type="搜索" v-model="keywords" @confirm="getNewList('search')"
|
||||||
placeholder="搜任务/搜岗位/搜政策" /> -->
|
placeholder="搜任务/搜岗位/搜政策" /> -->
|
||||||
<!-- <view @click="getNewList('search')" style="width: 80rpx;height: 50rpx;color:#fff;background-color: #0091ff;font-size:24rpx;text-align: center;line-height: 50rpx;border-radius: 25rpx;;">搜索</view> -->
|
<!-- <view @click="getNewList('search')" style="width: 80rpx;height: 50rpx;color:#fff;background-color: #0091ff;font-size:24rpx;text-align: center;line-height: 50rpx;border-radius: 25rpx;;">搜索</view> -->
|
||||||
<view style="font-size: 24rpx;height: 50rpx;background-color: #ddd;border-radius: 25rpx;line-height: 50rpx;padding: 0 20rpx;padding-right: 40rpx;position:relative;">
|
<view
|
||||||
{{ keywords }}
|
style="font-size: 24rpx;height: 50rpx;background-color: #ddd;border-radius: 25rpx;line-height: 50rpx;padding: 0 20rpx;padding-right: 40rpx;position:relative;">
|
||||||
<u-icon name="close" size="14" style="position:absolute;right:10rpx;top:13rpx;"></u-icon>
|
{{ keywords }}
|
||||||
</view>
|
<u-icon name="close" size="14" style="position:absolute;right:10rpx;top:13rpx;"></u-icon>
|
||||||
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-show="searchResultShow" class="search-result">
|
<view v-show="searchResultShow" class="search-result">
|
||||||
<view class="title">搜索结果</view>
|
<view class="title">搜索结果</view>
|
||||||
<view v-for="(item, index) in searchResultList" class="search-item" @click="toDetail(item)">
|
<view v-for="(item, index) in searchResultList" class="search-item" @click="toDetail(item)">
|
||||||
<image src="../../static/img/search.svg" style="width: 32rpx;height: 32rpx;margin-right: 10rpx;" mode=""></image>
|
<image src="../../static/img/search.svg" style="width: 32rpx;height: 32rpx;margin-right: 10rpx;"
|
||||||
<view style="flex:1;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;">{{ item.name }}</view>
|
mode=""></image>
|
||||||
<view class="type" v-if="item.type == 0">任务</view>
|
<view style="flex:1;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;">{{ item.name }}</view>
|
||||||
<view class="type" v-else-if="item.type == 1">岗位</view>
|
<view class="type" v-if="item.type == 0">任务</view>
|
||||||
<view class="type" v-else-if="item.type == 2">政策</view>
|
<view class="type" v-else-if="item.type == 1">岗位</view>
|
||||||
|
<view class="type" v-else-if="item.type == 2">政策</view>
|
||||||
<view class="type" v-else-if="item.type == 3">招工</view>
|
<view class="type" v-else-if="item.type == 3">招工</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-if="searchResultList.length > 0" style="text-align: center;font-size: 26rpx;margin-top: 20rpx;color:#999;">没有更多数据了</view>
|
<view v-if="searchResultList.length > 0"
|
||||||
<view v-if="searchResultList.length == 0" style="text-align: center;font-size: 26rpx;margin-top: 20rpx;">暂无数据</view>
|
style="text-align: center;font-size: 26rpx;margin-top: 20rpx;color:#999;">没有更多数据了</view>
|
||||||
</view>
|
<view v-if="searchResultList.length == 0" style="text-align: center;font-size: 26rpx;margin-top: 20rpx;">
|
||||||
<view v-show="!searchResultShow" class="search-history">
|
暂无数据</view>
|
||||||
<view class="title">搜索记录</view>
|
</view>
|
||||||
<view class="clear" @click="clearKeyWords">
|
<view v-show="!searchResultShow" class="search-history">
|
||||||
<image src="../../static/img/delete.png" style="width: 24rpx;height: 24rpx;" mode=""></image>
|
<view class="title">搜索记录</view>
|
||||||
<view style="margin-left: 5rpx;">清空</view>
|
<view class="clear" @click="clearKeyWords">
|
||||||
</view>
|
<image src="../../static/img/delete.png" style="width: 24rpx;height: 24rpx;" mode=""></image>
|
||||||
<view class="wrapper" v-if="searchHistoryList.length > 0">
|
<view style="margin-left: 5rpx;">清空</view>
|
||||||
<view class="item" v-for="(item, index) in searchHistoryList" @click="keyWordsClick(item.keywords)">
|
</view>
|
||||||
{{ item.keywords }}
|
<view class="wrapper" v-if="searchHistoryList.length > 0">
|
||||||
</view>
|
<view class="item" v-for="(item, index) in searchHistoryList" @click="keyWordsClick(item.keywords)">
|
||||||
</view>
|
{{ item.keywords }}
|
||||||
<view v-else class="empty">暂无历史记录</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<v-tabs v-show="!searchResultShow" :tabs="['推荐任务', '推荐岗位', '推荐政策']" height="45px" v-model="activeTab" color="#999" activeColor="#000"
|
<view v-else class="empty">暂无历史记录</view>
|
||||||
fontSize="30rpx" activeFontSize="31rpx" @change='changeTab' />
|
</view>
|
||||||
|
<v-tabs v-show="!searchResultShow" :tabs="['推荐任务', '推荐岗位', '推荐政策']" height="45px" v-model="activeTab"
|
||||||
|
color="#999" activeColor="#000" fontSize="30rpx" activeFontSize="31rpx" @change='changeTab' />
|
||||||
|
|
||||||
|
|
||||||
<block v-if="(activeTab == 0)&&!searchResultShow">
|
<block v-if="(activeTab == 0)&&!searchResultShow">
|
||||||
<view v-if="companyList.length > 0">
|
<view v-if="companyList.length > 0">
|
||||||
<block v-for="(item, index) in companyList" :key="item.id">
|
<block v-for="(item, index) in companyList" :key="item.id">
|
||||||
<companyList :companyitem="item"></companyList>
|
<companyList :companyitem="item"></companyList>
|
||||||
</block>
|
</block>
|
||||||
</view>
|
</view>
|
||||||
<view v-else>
|
<view v-else>
|
||||||
<image src="../../static/img/pic_notask.svg" mode="" class="nothing"></image>
|
<image src="../../static/img/pic_notask.svg" mode="" class="nothing"></image>
|
||||||
<view class="nothingContnt">
|
<view class="nothingContnt">
|
||||||
暂无信息
|
暂无信息
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</block>
|
</block>
|
||||||
<block v-if="(activeTab == 1)&&!searchResultShow">
|
<block v-if="(activeTab == 1)&&!searchResultShow">
|
||||||
<view v-if="newList.length > 0">
|
<view v-if="newList.length > 0">
|
||||||
<block v-for="(item, index) in newList" :key="index">
|
<block v-for="(item, index) in newList" :key="index">
|
||||||
<companyList :companyitem="item"></companyList>
|
<companyList :companyitem="item"></companyList>
|
||||||
</block>
|
</block>
|
||||||
</view>
|
</view>
|
||||||
<view v-else>
|
<view v-else>
|
||||||
<image src="../../static/img/pic_notask.svg" class="nothing" mode=""></image>
|
<image src="../../static/img/pic_notask.svg" class="nothing" mode=""></image>
|
||||||
<view class="nothingContnt">暂无信息</view>
|
<view class="nothingContnt">暂无信息</view>
|
||||||
</view>
|
</view>
|
||||||
</block>
|
</block>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<block v-if="(activeTab == 2)&&!searchResultShow">
|
<block v-if="(activeTab == 2)&&!searchResultShow">
|
||||||
<view v-if="recommendList.length > 0">
|
<view v-if="recommendList.length > 0">
|
||||||
<block v-for="(item, index) in recommendList" :key="item.id">
|
<block v-for="(item, index) in recommendList" :key="item.id">
|
||||||
<companyList :companyitem="item"></companyList>
|
<companyList :companyitem="item"></companyList>
|
||||||
</block>
|
</block>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view v-else>
|
<view v-else>
|
||||||
<image src="../../static/img/pic_notask.svg" mode="" class="nothing"></image>
|
<image src="../../static/img/pic_notask.svg" mode="" class="nothing"></image>
|
||||||
<view class="nothingContnt">
|
<view class="nothingContnt">
|
||||||
完善技能,获取精推荐
|
完善技能,获取精推荐
|
||||||
</view>
|
</view>
|
||||||
<!-- <view class="btn" @click="goResume">
|
<!-- <view class="btn" @click="goResume">
|
||||||
完善技能
|
完善技能
|
||||||
</view> -->
|
</view> -->
|
||||||
</view>
|
</view>
|
||||||
</block>
|
</block>
|
||||||
|
|
||||||
<!-- <view v-if="companyList.length > 0">
|
<!-- <view v-if="companyList.length > 0">
|
||||||
<block v-for="(item, index) in companyList" :key="item.id">
|
<block v-for="(item, index) in companyList" :key="item.id">
|
||||||
<companyList :companyitem="item"></companyList>
|
<companyList :companyitem="item"></companyList>
|
||||||
<view class="baddd"></view>
|
<view class="baddd"></view>
|
||||||
@@ -116,311 +122,327 @@
|
|||||||
暂无任务信息
|
暂无任务信息
|
||||||
</view>
|
</view>
|
||||||
</view> -->
|
</view> -->
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { newMissionAll, getSearchKeyWordsList, clearSearchKeyWords, getListByKeyWords } from '@/api/mission.js';
|
import {
|
||||||
import companyList from '@/components/companyList/companyList.vue';
|
newMissionAll,
|
||||||
import vTabs from '@/components/v-tabs/v-tabs.vue';
|
getSearchKeyWordsList,
|
||||||
import testData from '@/common/textdata.js';
|
clearSearchKeyWords,
|
||||||
export default {
|
getListByKeyWords
|
||||||
components: {
|
} from '@/api/mission.js';
|
||||||
companyList,
|
import companyList from '@/components/companyList/companyList.vue';
|
||||||
vTabs,
|
import vTabs from '@/components/v-tabs/v-tabs.vue';
|
||||||
},
|
import testData from '@/common/textdata.js';
|
||||||
data() {
|
export default {
|
||||||
return {
|
components: {
|
||||||
activeTab: 0,
|
companyList,
|
||||||
companyList: [],
|
vTabs,
|
||||||
recommendList: [],
|
},
|
||||||
newList: [],
|
data() {
|
||||||
keywords: '',
|
return {
|
||||||
page: {
|
activeTab: 0,
|
||||||
current: 1,
|
companyList: [],
|
||||||
size: 10,
|
recommendList: [],
|
||||||
total: 0
|
newList: [],
|
||||||
},
|
keywords: '',
|
||||||
searchHistoryList: [],
|
page: {
|
||||||
searchResultShow: false,
|
current: 1,
|
||||||
searchResultList: []
|
size: 10,
|
||||||
};
|
total: 0
|
||||||
},
|
},
|
||||||
onLoad: function (option) {
|
searchHistoryList: [],
|
||||||
this.keywords = option.keywords ? option.keywords : ''
|
searchResultShow: false,
|
||||||
},
|
searchResultList: []
|
||||||
onShow: function () {
|
};
|
||||||
this.getList('search');
|
},
|
||||||
|
onLoad: function(option) {
|
||||||
|
this.keywords = option.keywords ? option.keywords : ''
|
||||||
|
},
|
||||||
|
onShow: function() {
|
||||||
|
this.getList('search');
|
||||||
|
|
||||||
this.getKeyWordsList()
|
this.getKeyWordsList()
|
||||||
},
|
},
|
||||||
/*页面滚动到底部*/
|
/*页面滚动到底部*/
|
||||||
onReachBottom: function () {
|
onReachBottom: function() {
|
||||||
this.upLoad()
|
this.upLoad()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
clearCurrentKeyWords() {
|
clearCurrentKeyWords() {
|
||||||
this.keywords = '';
|
this.keywords = '';
|
||||||
let that = this;
|
let that = this;
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
that.searchResultShow = false;
|
that.searchResultShow = false;
|
||||||
}, 100);
|
}, 100);
|
||||||
|
|
||||||
},
|
},
|
||||||
// 新面板搜索
|
// 新面板搜索
|
||||||
getNewList() {
|
getNewList() {
|
||||||
getListByKeyWords(this.keywords).then(res => {
|
getListByKeyWords(this.keywords).then(res => {
|
||||||
this.searchResultShow = true
|
this.searchResultShow = true
|
||||||
this.searchResultList = res.data.data
|
this.searchResultList = res.data.data
|
||||||
// this.searchResultList.forEach((item, index) => {
|
// this.searchResultList.forEach((item, index) => {
|
||||||
// item.name = this.getInf(item.name, this.keywords);
|
// item.name = this.getInf(item.name, this.keywords);
|
||||||
// })
|
// })
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 获取搜索历史记录
|
// 获取搜索历史记录
|
||||||
getKeyWordsList() {
|
getKeyWordsList() {
|
||||||
getSearchKeyWordsList().then(res => {
|
getSearchKeyWordsList().then(res => {
|
||||||
let response = res.data
|
let response = res.data
|
||||||
if(response.code == 200) {
|
if (response.code == 200) {
|
||||||
this.searchHistoryList = response.data
|
this.searchHistoryList = response.data
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
keyWordsClick(keyWords) {
|
keyWordsClick(keyWords) {
|
||||||
// console.log(keyWords)
|
// console.log(keyWords)
|
||||||
this.searchResultShow = true;
|
this.searchResultShow = true;
|
||||||
this.keywords = keyWords;
|
this.keywords = keyWords;
|
||||||
this.getNewList();
|
this.getNewList();
|
||||||
},
|
},
|
||||||
//最新任务;
|
//最新任务;
|
||||||
getList: function (type) {
|
getList: function(type) {
|
||||||
//改变搜索条件,页码值变为1
|
//改变搜索条件,页码值变为1
|
||||||
if (type === 'search') {
|
if (type === 'search') {
|
||||||
this.page.current = 1;
|
this.page.current = 1;
|
||||||
};
|
};
|
||||||
// if (this.keywords) {
|
// if (this.keywords) {
|
||||||
newMissionAll(this.page.current, this.page.size, this.keywords).then(res => {
|
newMissionAll(this.page.current, this.page.size, this.keywords).then(res => {
|
||||||
if (this.page.current === 1) {
|
if (this.page.current === 1) {
|
||||||
this.companyList = [];
|
this.companyList = [];
|
||||||
}
|
}
|
||||||
this.page.current += 1;
|
this.page.current += 1;
|
||||||
this.page.total = res.data.data.total;
|
this.page.total = res.data.data.total;
|
||||||
if (res.data.data && res.data.data.records.length) {
|
if (res.data.data && res.data.data.records.length) {
|
||||||
this.companyList = this.companyList.concat(res.data.data.records);
|
this.companyList = this.companyList.concat(res.data.data.records);
|
||||||
|
|
||||||
}
|
}
|
||||||
//搜索关键词高亮
|
//搜索关键词高亮
|
||||||
// if (this.companyList.length) {
|
// if (this.companyList.length) {
|
||||||
// this.companyList.forEach((item, index) => {
|
// this.companyList.forEach((item, index) => {
|
||||||
// item.missionTitle = this.getInf(item.missionTitle, this.keywords);
|
// item.missionTitle = this.getInf(item.missionTitle, this.keywords);
|
||||||
// });
|
// });
|
||||||
// }
|
// }
|
||||||
console.log(this.companyList, '----------');
|
console.log(this.companyList, '----------');
|
||||||
})
|
})
|
||||||
// }
|
// }
|
||||||
},
|
},
|
||||||
|
|
||||||
//上拉加载
|
//上拉加载
|
||||||
upLoad: function () {
|
upLoad: function() {
|
||||||
if (this.page.current <= Math.ceil(this.page.total / this.page.size)) {
|
if (this.page.current <= Math.ceil(this.page.total / this.page.size)) {
|
||||||
this.getList();
|
this.getList();
|
||||||
} else {
|
} else {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
icon: "none",
|
icon: "none",
|
||||||
title: '已经是最后一页',
|
title: '已经是最后一页',
|
||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
closeBack() {
|
closeBack() {
|
||||||
uni.navigateBack({
|
uni.navigateBack({
|
||||||
delta: 1
|
delta: 1
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
/**
|
/**
|
||||||
* 指定关键字高亮
|
* 指定关键字高亮
|
||||||
* @param {*} str 字符串
|
* @param {*} str 字符串
|
||||||
* @param {*} key 关键字
|
* @param {*} key 关键字
|
||||||
*/
|
*/
|
||||||
getInf(str, key) {
|
getInf(str, key) {
|
||||||
if (str && key) {
|
if (str && key) {
|
||||||
let replaceReg = new RegExp(key, 'g')// 匹配关键字正则
|
let replaceReg = new RegExp(key, 'g') // 匹配关键字正则
|
||||||
let replaceString = "<span style='color: #1b66ff;'>" + key + "</span>" // 高亮替换
|
let replaceString = "<span style='color: #1b66ff;'>" + key + "</span>" // 高亮替换
|
||||||
return str.replace(replaceReg, replaceString);
|
return str.replace(replaceReg, replaceString);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
toDetail(item) {
|
toDetail(item) {
|
||||||
const no = item.id
|
const no = item.id
|
||||||
// 判断是岗位还是任务 0:任务,1:岗位,2:政策
|
// 判断是岗位还是任务 0:任务,1:岗位,2:政策
|
||||||
if(item.type == 0) {
|
if (item.type == 0) {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: `/pages/projectInfo/projectInfo?missionNo=${encodeURIComponent(no)}&isCan=1`
|
url: `/pages/projectInfo/projectInfo?missionNo=${encodeURIComponent(no)}&isCan=1`
|
||||||
})
|
})
|
||||||
} else if(item.type == 1) {
|
} else if (item.type == 1) {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: `/pages/projectInfo/workInfo?workId=${encodeURIComponent(no)}&isCan=1`
|
url: `/pages/projectInfo/workInfo?workId=${encodeURIComponent(no)}&isCan=1`
|
||||||
})
|
})
|
||||||
} else if(item.type == 2) {
|
} else if (item.type == 2) {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url:`/pages/user/policyContent?id=${no}`
|
url: `/pages/user/policyContent?id=${no}`
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
changeTab: function (e) {
|
changeTab: function(e) {
|
||||||
this.activeTab = e;
|
this.activeTab = e;
|
||||||
},
|
},
|
||||||
// 清空搜索历史
|
// 清空搜索历史
|
||||||
clearKeyWords() {
|
clearKeyWords() {
|
||||||
clearSearchKeyWords().then(res => {
|
clearSearchKeyWords().then(res => {
|
||||||
if(res.data.code == 200) {
|
if (res.data.code == 200) {
|
||||||
this.getKeyWordsList()
|
this.getKeyWordsList()
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.mainWrapper{
|
.mainWrapper {
|
||||||
background-color: #f3f4f8;
|
background-color: #f3f4f8;
|
||||||
min-height: 95vh;
|
min-height: 95vh;
|
||||||
}
|
}
|
||||||
.baddd {
|
|
||||||
background-color: #f6f6f6;
|
|
||||||
height: 20rpx;
|
|
||||||
}
|
|
||||||
|
|
||||||
.close {
|
.baddd {
|
||||||
position: absolute;
|
background-color: #f6f6f6;
|
||||||
right: 24rpx;
|
height: 20rpx;
|
||||||
top: 6rpx;
|
}
|
||||||
height: 60rpx;
|
|
||||||
padding: 5rpx 0;
|
|
||||||
line-height: 60rpx;
|
|
||||||
font-family: PingFangSC-Regular;
|
|
||||||
font-size: 32rpx;
|
|
||||||
color: #333333;
|
|
||||||
}
|
|
||||||
|
|
||||||
.headSearch .search-view {
|
.close {
|
||||||
border-bottom: 1rpx solid #dddddd;
|
position: absolute;
|
||||||
padding: 14rpx 32rpx;
|
right: 24rpx;
|
||||||
background: rgba(255, 255, 255, 1);
|
top: 6rpx;
|
||||||
}
|
height: 60rpx;
|
||||||
|
padding: 5rpx 0;
|
||||||
|
line-height: 60rpx;
|
||||||
|
font-family: PingFangSC-Regular;
|
||||||
|
font-size: 32rpx;
|
||||||
|
color: #333333;
|
||||||
|
}
|
||||||
|
|
||||||
.headSearch .search-item {
|
.headSearch .search-view {
|
||||||
display: flex;
|
border-bottom: 1rpx solid #dddddd;
|
||||||
padding: 0 10rpx;
|
padding: 14rpx 32rpx;
|
||||||
height: 60rpx;
|
background: rgba(255, 255, 255, 1);
|
||||||
line-height: 60rpx;
|
}
|
||||||
background: rgba(249, 249, 249, 1);
|
|
||||||
border-radius: 200px;
|
|
||||||
align-items: center;
|
|
||||||
border: 1px solid #0091ff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.headSearch .search-item input {
|
.headSearch .search-item {
|
||||||
padding: 0 24rpx;
|
display: flex;
|
||||||
height: 80rpx;
|
padding: 0 10rpx;
|
||||||
font-weight: 400;
|
height: 60rpx;
|
||||||
flex: 1;
|
line-height: 60rpx;
|
||||||
text-align: start;
|
background: rgba(249, 249, 249, 1);
|
||||||
font-size: 28rpx;
|
border-radius: 200px;
|
||||||
font-family: PingFang-SC-Bold, PingFang-SC;
|
align-items: center;
|
||||||
color: rgba(51, 51, 51, 1);
|
border: 1px solid #0091ff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.headSearch .search-item .placeholderClass {
|
.headSearch .search-item input {
|
||||||
color: #CCCCCC;
|
padding: 0 24rpx;
|
||||||
}
|
height: 80rpx;
|
||||||
|
font-weight: 400;
|
||||||
|
flex: 1;
|
||||||
|
text-align: start;
|
||||||
|
font-size: 28rpx;
|
||||||
|
font-family: PingFang-SC-Bold, PingFang-SC;
|
||||||
|
color: rgba(51, 51, 51, 1);
|
||||||
|
}
|
||||||
|
|
||||||
.headSearch .search-item image {
|
.headSearch .search-item .placeholderClass {
|
||||||
height: 32rpx;
|
color: #CCCCCC;
|
||||||
width: 32rpx;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
.nothing {
|
.headSearch .search-item image {
|
||||||
width: 400rpx;
|
height: 32rpx;
|
||||||
height: 200rpx;
|
width: 32rpx;
|
||||||
display: block;
|
}
|
||||||
margin: 0 auto;
|
|
||||||
margin-top: 50%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.nothingContnt {
|
.nothing {
|
||||||
font-family: PingFangSC-Regular;
|
width: 400rpx;
|
||||||
font-size: 28rpx;
|
height: 200rpx;
|
||||||
color: #333333;
|
display: block;
|
||||||
margin-top: 30rpx;
|
margin: 0 auto;
|
||||||
text-align: center;
|
margin-top: 50%;
|
||||||
}
|
}
|
||||||
.search-history {
|
|
||||||
background-color: #fff;
|
|
||||||
padding: 10rpx 40rpx;
|
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
.search-history .title {
|
|
||||||
font-size: 28rpx;
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
.search-history .clear {
|
|
||||||
position: absolute;
|
|
||||||
right: 40rpx;
|
|
||||||
top: 10rpx;
|
|
||||||
font-size: 24rpx;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
color: #707070;
|
|
||||||
}
|
|
||||||
.search-history .empty {
|
|
||||||
font-size: 24rpx;
|
|
||||||
text-align: center;
|
|
||||||
color: #707070;
|
|
||||||
}
|
|
||||||
.search-history .wrapper {
|
|
||||||
display: flex;
|
|
||||||
flex-wrap: wrap;
|
|
||||||
margin-top: 10rpx;
|
|
||||||
}
|
|
||||||
.search-history .wrapper .item {
|
|
||||||
font-size: 24rpx;
|
|
||||||
background-color: #f6f6f6;
|
|
||||||
padding: 8rpx 12rpx;
|
|
||||||
border-radius: 20rpx;
|
|
||||||
margin-right: 10rpx;
|
|
||||||
}
|
|
||||||
.search-result {
|
|
||||||
padding: 20rpx 30rpx;
|
|
||||||
background-color: #fff;
|
|
||||||
height: 100vh;
|
|
||||||
}
|
|
||||||
.search-result .title {
|
|
||||||
font-size: 26rpx;
|
|
||||||
font-weight: bold;
|
|
||||||
border-bottom: 1rpx solid #ddd;
|
|
||||||
height: 60rpx;
|
|
||||||
line-height: 60rpx;
|
|
||||||
}
|
|
||||||
.search-result .search-item {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
font-size: 26rpx;
|
|
||||||
border-bottom: 1rpx solid #ddd;
|
|
||||||
height: 80rpx;
|
|
||||||
line-height: 80rpx;
|
|
||||||
|
|
||||||
}
|
.nothingContnt {
|
||||||
.search-result .search-item .type {
|
font-family: PingFangSC-Regular;
|
||||||
font-size: 20rpx;
|
font-size: 28rpx;
|
||||||
color: #707070;
|
color: #333333;
|
||||||
background-color: #dddddd;
|
margin-top: 30rpx;
|
||||||
border-radius: 15rpx;
|
text-align: center;
|
||||||
height: 30rpx;
|
}
|
||||||
line-height: 30rpx;
|
|
||||||
padding: 0 20rpx;
|
.search-history {
|
||||||
}
|
background-color: #fff;
|
||||||
|
padding: 10rpx 40rpx;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-history .title {
|
||||||
|
font-size: 28rpx;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-history .clear {
|
||||||
|
position: absolute;
|
||||||
|
right: 40rpx;
|
||||||
|
top: 10rpx;
|
||||||
|
font-size: 24rpx;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
color: #707070;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-history .empty {
|
||||||
|
font-size: 24rpx;
|
||||||
|
text-align: center;
|
||||||
|
color: #707070;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-history .wrapper {
|
||||||
|
display: flex;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
margin-top: 10rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-history .wrapper .item {
|
||||||
|
font-size: 24rpx;
|
||||||
|
background-color: #f6f6f6;
|
||||||
|
padding: 8rpx 12rpx;
|
||||||
|
border-radius: 20rpx;
|
||||||
|
margin-right: 10rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-result {
|
||||||
|
padding: 20rpx 30rpx;
|
||||||
|
background-color: #fff;
|
||||||
|
height: 100vh;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-result .title {
|
||||||
|
font-size: 26rpx;
|
||||||
|
font-weight: bold;
|
||||||
|
border-bottom: 1rpx solid #ddd;
|
||||||
|
height: 60rpx;
|
||||||
|
line-height: 60rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-result .search-item {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
font-size: 26rpx;
|
||||||
|
border-bottom: 1rpx solid #ddd;
|
||||||
|
height: 80rpx;
|
||||||
|
line-height: 80rpx;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-result .search-item .type {
|
||||||
|
font-size: 20rpx;
|
||||||
|
color: #707070;
|
||||||
|
background-color: #dddddd;
|
||||||
|
border-radius: 15rpx;
|
||||||
|
height: 30rpx;
|
||||||
|
line-height: 30rpx;
|
||||||
|
padding: 0 20rpx;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
@@ -3,7 +3,7 @@ module.exports = {
|
|||||||
port: 1887,
|
port: 1887,
|
||||||
proxy: {
|
proxy: {
|
||||||
'/api': {
|
'/api': {
|
||||||
target: 'http://192.168.1.106:8000',
|
target: 'http://10.165.0.173:8000',
|
||||||
ws: true,
|
ws: true,
|
||||||
pathRewrite: {
|
pathRewrite: {
|
||||||
'^/api': '/'
|
'^/api': '/'
|
||||||
|
|||||||
Reference in New Issue
Block a user