7 Commits

Author SHA1 Message Date
史典卓
1cd5363723 flat:暂存 2025-08-05 18:28:07 +08:00
史典卓
e698f0624f flat: yic 2025-05-06 16:13:25 +08:00
史典卓
23284483c4 flat: 赞存 2025-03-26 09:54:42 +08:00
史典卓
5e3a853a2a flat:暂存 2024-11-14 17:29:54 +08:00
史典卓
7845b6333c flat: 地图 2024-10-24 14:42:47 +08:00
Apcallover
ba14872e89 flat:登录调用顺序 2024-07-24 14:45:29 +08:00
Apcallover
23aaa5a4ab flat:管陶县 2024-07-17 15:49:00 +08:00
118 changed files with 13282 additions and 12693 deletions

199
App.vue
View File

@@ -1,139 +1,92 @@
<style lang="scss">
/* 注意要写在第一行同时给style标签加入lang="scss"属性 */
@import '@/uni_modules/uview-ui/index.scss';
/* 注意要写在第一行同时给style标签加入lang="scss"属性 */
@import "@/uni_modules/uview-ui/index.scss";
</style>
<script>
import website from '@/config/website.js';
import { mapGetters } from 'vuex';
import { GoLogin } from '@/untils/AxiosUtils.js';
// #ifdef H5
import { setPlatformByHostName } from '@/untils/customized.js';
import { reject } from 'lodash';
// #endif
import website from '@/config/website.js'
import {
mapGetters
} from 'vuex'
// #ifdef H5
import {
setPlatformByHostName
} from '@/untils/customized.js'
// #endif
export default {
onLaunch: function (options) {
this.$store.dispatch('InitArea');
if (options.query.token) {
this.tokenlogin(options.query.token).then(() => {
this.$store.dispatch('getUserLocation');
this.$store.dispatch('getNoticeState');
this.$store.dispatch('getMobileIsCms');
this.$store.dispatch('getResumeInfo');
});
} else {
this.$store.dispatch('FedLogOut');
}
// if (options.query.token) {
// // uni.reLaunch({
// // url: '/pages/login/blank?token=' + options.query.token
// // })
// this.tokenlogin(options.query.token)
// } else if (this.$api.haslogin()) {
// this.$store.dispatch('startRefreshTokenTimer')
// this.$store.dispatch('startRefreshNewsTimer')
// this.$store.dispatch('refreshAuthState')
// this.$store.dispatch('getUserLocation')
// this.$store.dispatch('getMobileIsCms')
// }
// #ifdef H5
// 企业定制
setPlatformByHostName(this.$store);
// #endif
},
onShow: function () {},
onHide: function () {},
computed: {
...mapGetters(['news', 'auth']),
allUnread() {
return this.news.allUnread;
export default {
onLaunch: function(options) {
this.$store.dispatch('InitArea')
if (this.$store.state.user.token) {
this.$store.dispatch('startRefreshTokenTimer')
this.$store.dispatch('startRefreshNewsTimer')
this.$store.dispatch('refreshAuthState')
this.$store.dispatch('getUserLocation')
this.$store.dispatch('getMobileIsCms')
}
// #ifdef H5
// 企业定制
setPlatformByHostName(this.$store)
// #endif
},
},
mounted() {
this.$config.showTitle && document.documentElement.style.setProperty('--hide-title', 'block');
},
methods: {
tokenlogin(token) {
return new Promise((resolve, reject) => {
uni.showLoading({
title: '登录中',
});
if (token) {
const that = this;
this.$store
.dispatch('LoginByUsername', {
username: 'admin',
password: 'admin',
key: '',
code: '1111',
type: 'account',
token: token,
tenantId: website.tenantId,
})
.then((resp) => {
this.$store.dispatch('refreshAuthState').then(() => {
uni.hideLoading();
resolve();
});
})
.catch((err) => {
uni.hideLoading();
});
} else {
GoLogin();
}
});
},
},
watch: {
allUnread(value) {
console.log('allUnread', value);
if (!this.$api.haslogin()) {
} else if (value > 0) {
uni.showTabBarRedDot({
index: 2,
});
uni.$once('newsReadChange', () => {
uni.showTabBarRedDot({
index: 2,
});
});
} else {
uni.hideTabBarRedDot({
index: 2,
});
uni.$once('newsReadChange', () => {
uni.hideTabBarRedDot({
index: 2,
});
});
onShow: function() {},
onHide: function() {},
computed: {
...mapGetters(['news']),
allUnread() {
return this.news.allUnread
}
},
},
};
mounted() {
this.$config.showTitle && document.documentElement.style.setProperty('--hide-title', 'block');
},
watch: {
allUnread(value) {
console.log('allUnread', value)
if (!this.$store.state.user.token) {} else if (value > 0) {
uni.showTabBarRedDot({
index: 2
})
uni.$once('newsReadChange', () => {
uni.showTabBarRedDot({
index: 2
})
})
} else {
uni.hideTabBarRedDot({
index: 2
})
uni.$once('newsReadChange', () => {
uni.hideTabBarRedDot({
index: 2
})
})
}
}
}
};
</script>
<style lang="scss">
/*每个页面公共css */
/* tabbar 字体大小 */
/* .uni-tabbar__label{
/*每个页面公共css */
/* tabbar 字体大小 */
/* .uni-tabbar__label{
font-size: 14px !important;
} */
@font-face {
font-family: 'uicon-iconfont';
font-weight: mormal;
font-style: mormal;
src: url('/static/font/font_2225171_8kdcwk4po24.ttf') format('truetype');
}
@font-face {
font-family: 'uicon-iconfont';
font-weight: mormal;
font-style: mormal;
src: url('/static/font/font_2225171_8kdcwk4po24.ttf') format('truetype');
}
:root {
--hide-title: none;
}
:root {
--hide-title: none;
}
/* #ifdef H5 */
uni-page-head {
display: var(--hide-title);
}
/* #ifdef H5 */
uni-page-head {
display: var(--hide-title);
}
/* #endif */
/* #endif */
</style>

View File

@@ -1,144 +1,118 @@
import {
request
request
} from '@/untils/AxiosUtils.js';
import {
decryptJson
} from '@/untils/authService.js'
import website from "@/config/website";
const authUrl = '/api/jobslink-api/user/user/auth/auth'
// export const findAuth = () => request({
// url: '/api/jobslink-api/user/user/find',
// method: 'get'
// });
export const findAuth = async () => {
try {
const encrypted = await request({
url: '/api/jobslink-api/user/user/find',
method: 'get',
responseType: 'text', // 接收纯文本密文
});
const decryptedStr = decryptJson(encrypted.data);
return {
data: JSON.parse(decryptedStr),
};
} catch (error) {
console.error('请求或解密过程中出错:', error);
return null;
}
};
export const findAuth = () => request({
url: '/api/jobslink-api/user/user/find',
method: 'get'
});
export const cheakValue = () => request({
url: authUrl,
method: 'post',
data: {
cheakvalue: 1,
bakvalue: 0
}
url: authUrl,
method: 'post',
data: {
cheakvalue: 1,
bakvalue: 0
}
});
export const realName = (realName, idNumber) => request({
url: authUrl,
method: 'post',
data: {
cheakvalue: 2,
realName,
idNumber
}
url: authUrl,
method: 'post',
data: {
cheakvalue: 2,
realName,
idNumber
}
});
export const bank = (bankName, realName, cardNumber, def, id) => request({
url: authUrl,
method: 'post',
data: {
cheakvalue: 3,
bankName,
cardNumber,
realName,
def,
id
}
url: authUrl,
method: 'post',
data: {
cheakvalue: 3,
bankName,
cardNumber,
realName,
def,
id
}
});
export const insure = (bakvalue) => request({
url: authUrl,
method: 'post',
data: {
cheakvalue: 4,
bakvalue
}
url: authUrl,
method: 'post',
data: {
cheakvalue: 4,
bakvalue
}
});
// 判断当前用户是否采集签名
export const isGather = () => request({
url: "/api/jobslink-api/doc/docUserSeal/isGather",
method: 'get',
url: "/api/jobslink-api/doc/docUserSeal/isGather",
method: 'get',
});
// 个人端签名采集
export const signGather = (signSrcUrl, password, confirmPassword) => request({
url: "/api/jobslink-api/doc/docUserSeal/signGather",
method: 'post',
data: {
signSrcUrl,
password,
confirmPassword
}
url: "/api/jobslink-api/doc/docUserSeal/signGather",
method: 'post',
data: {
signSrcUrl,
password,
confirmPassword
}
});
// 获取短信接口
export const sendValidate = (mobile) => request({
url: "/api/jobslink-api/doc/docUserCert/resetPass/sendValidate",
method: 'get',
data: {
mobile
}
url: "/api/jobslink-api/doc/docUserCert/resetPass/sendValidate",
method: 'get',
data: {
mobile
}
});
// 密码重置接口
export const resetPass = (mobile, code, password) => request({
url: "/api/jobslink-api/doc/docUserCert/resetPass",
method: 'post',
headers: {
'SCaptcha-Key': mobile,
'SCaptcha-Code': code,
'password': password
}
url: "/api/jobslink-api/doc/docUserCert/resetPass",
method: 'post',
headers: {
'SCaptcha-Key': mobile,
'SCaptcha-Code': code,
'password': password
}
});
// 我的合同
export const contractList = (params) => request({
url: "/api/jobslink-api/doc/contract/personal/contractList",
method: 'get',
data: params
url: "/api/jobslink-api/doc/contract/personal/contractList",
method: 'get',
data: params
});
// 签名密码 /jobslink-api/doc/docUserCert/checkPass
export const checkPass = (params) => request({
url: "/api/jobslink-api/doc/docUserCert/checkPass",
method: 'get',
data: params
url: "/api/jobslink-api/doc/docUserCert/checkPass",
method: 'get',
data: params
});
// 返回的是base64格式的pdf
export const viewContract = (params) => request({
url: "/api/jobslink-api/doc/contract/viewContract",
method: 'get',
data: params
url: "/api/jobslink-api/doc/contract/viewContract",
method: 'get',
data: params
});
//新实名认证api
export const newCertification = (bakvalue, realName, idNumber, cardNumber, bankCode, def, bankName) => request({
url: '/api/jobslink-api/user/user/auth/authNew',
method: 'post',
data: {
bakvalue,
realName,
idNumber,
cardNumber,
bankCode,
def,
bankName
}
});
// 电话联系
export const getPhoneCountNumber = (params) => request({
url: "/api/jobslink-api/serve/phone",
method: 'get',
data: params
export const newCertification = (bakvalue, realName, idNumber, cardNumber, bankCode,def,bankName) => request({
url: '/api/jobslink-api/user/user/auth/authNew',
method: 'post',
data: {
bakvalue,
realName,
idNumber,
cardNumber,
bankCode,
def,
bankName
}
});

View File

@@ -1,55 +1,47 @@
import {
request
request
} from '@/untils/AxiosUtils.js';
import website from "../config/website.js"
import store from '@/store/';
// 设置民族政治面貌 jobslink-api/user/user/setInfo
export const setInfo = (params) => request({
url: "/api/jobslink-api/user/user/setInfo",
method: 'post',
data: params
url: "/api/jobslink-api/user/user/setInfo",
method: 'post',
data: params
});
// 获取用户工会状态 /jobslink-api/doc/user/labourUnion/info
export const labourUnionInfo = () => request({
url: "/api/jobslink-api/doc/user/labourUnion/info",
method: 'get'
url: "/api/jobslink-api/doc/user/labourUnion/info",
method: 'get'
});
// 申请入会
export const contract = (params) => request({
url: "/api/jobslink-api/doc/user/labourUnion/apply",
method: 'post',
data: params
url: "/api/jobslink-api/doc/user/labourUnion/apply",
method: 'post',
data: params
});
//会员信息--判断用户是否加入工会
export const labourUnionDetail = (no) => request({
url: "/api/jobslink-api/doc/jkLabourUnionAppl/list",
method: 'get',
params: {
no
}
url: "/api/jobslink-api/doc/jkLabourUnionAppl/list",
method: 'get',
params:{no}
});
//提交会员申请
export const saveApplication = (labourunionId, applType, applComment) => {
applComment = applComment.substring(0, 200)
return request({
url: "/api/jobslink-api/doc/jkLabourUnionDetail/save",
method: 'post',
data: {
labourunionId,
applType,
applComment
}
});
export const saveApplication = (labourunionId,applType,applComment) =>{
applComment=applComment.substring(0,200)
return request({
url: "/api/jobslink-api/doc/jkLabourUnionDetail/save",
method: 'post',
data:{labourunionId,applType,applComment}
});
}
//查询提交的申请内容
export const applicationInfo = (no) => request({
url: "/api/jobslink-api/doc/jkLabourUnionDetail/list",
method: 'get',
params: {
no
}
url: "/api/jobslink-api/doc/jkLabourUnionDetail/list",
method: 'get',
params:{no}
});

View File

@@ -307,9 +307,3 @@ export const getPolicyContentList = (params) => request({
method: 'get',
params
})
export const userWorkSearchListAll = (params) => request({
url: '/api/jobslink-api/user/userWork/searchListAll',
method: 'get',
params
})

View File

@@ -33,8 +33,13 @@ export async function uploadFile(file) {
'Authorization': `Basic ${Base64.encode(`${website.clientId}:${website.clientSecret}`)}`,
}
header[website.tokenName] = "bearer " + token
// 馆陶替换url
let url = `/api/jobslink-api/resource/file/save?bussinessType=5`
if (url.startsWith('/api')) {
url = url.replace(/^\/api/, '/api/gt');
}
uni.uploadFile({
url: `${baseUrl}/api/jobslink-api/resource/file/save?bussinessType=5`,
url: baseUrl + url,
header,
filePath: file.url,
// formData: formdata,

View File

@@ -73,13 +73,3 @@ export const mobileIsCms = () => request({
url: '/api/jobslink-api/mobile/isCms',
method: 'get'
})
export const noticeIsEnable = () => request({
url: "/api/jobslink-api/desk/notice/isEnable",
method: 'get',
});
export const setNoticeIsEnable = (state) => request({
url: "/api/jobslink-api/desk/notice/isEnable/" + state,
method: 'PUT',
});

View File

@@ -367,36 +367,40 @@ const workwageUnitCategoryState = [
const addressColumn = [
[{
value: '95',
label: "绵竹市"
value: '4',
label: "馆陶县"
},
{
value: '185',
label: "广汉市"
value: '5',
label: "馆陶镇"
},
{
value: '143',
label: "旌阳区"
value: '6',
label: "房寨镇"
},
{
value: '150',
label: "罗江区"
value: '7',
label: "魏僧寨镇"
},
{
value: '42',
label: "什邡市"
value: '8',
label: "柴堡镇"
},
{
value: '156',
label: "中江县"
value: '9',
label: "寿山寺"
},
{
value: '44139628',
label: "经济技术开发区"
value: '10',
label: " 王桥乡"
},
{
value: '79194151',
label: "德阳市开发区"
value: '11',
label: "路桥乡"
},
{
value: '12',
label: "南徐村乡"
},
]
]

View File

@@ -34,7 +34,7 @@
</view>
<view style="display: flex;align-items: center;position:absolute;right:0;">
<image src="../../static/img/location_new.png" style="width: 30rpx;height: 30rpx;" mode=""></image>
<view>--km</view>
<view>{{distance(companyitem)}}</view>
</view>
</view>
<view class="comment" v-if='comment' @tap.stop="goComment(companyitem.missionNo)">
@@ -57,7 +57,10 @@
dateFormat
} from "../../untils/format.js";
import dictionary from '@/common/textdata.js';
import {
addZeroPrefix,
getDistanceFromLatLonInKm
} from '@/untils/tools.js'
export default {
beforeCreate: function() {},
props: {
@@ -78,6 +81,9 @@
near: {
type: Boolean,
default: false
},
position: {
default: null
}
},
data() {
@@ -94,6 +100,24 @@
}
},
methods: {
distance(item) {
const {
lon,
lat
} = item
if (this.position && lon > 0) {
const {
longitude,
latitude
} = this.position
const {
m,
km
} = getDistanceFromLatLonInKm(lat, lon, latitude, longitude)
return m > 1000 ? `${km.toFixed(2)}km` : `${m.toFixed(2)}m`
}
return '--km'
},
goComment: function(no) {
uni.navigateTo({
url: `../../pageMy/mycomment/mycomment?missionNo=${encodeURIComponent(no)}`

View File

@@ -57,14 +57,13 @@
dateFormat
} from "../../untils/format.js";
import dictionary from '@/common/textdata.js';
import {
defaults
} from "lodash";
import {
addZeroPrefix,
getDistanceFromLatLonInKm
} from '@/untils/tools.js'
import {
defaults
} from "lodash";
export default {
beforeCreate: function() {},
props: {
@@ -86,7 +85,9 @@
type: Boolean,
default: false
},
location: Object
position: {
default: null
}
},
data() {
return {

View File

@@ -90,8 +90,7 @@
near: {
type: Boolean,
default: false
},
position: Object,
}
},
data() {
return {

View File

@@ -130,7 +130,7 @@
if (this.option && this.option.apikey) {
const script = document.createElement('script')
// view 层的页面运行在 www 根目录,其相对路径相对于 www 计算
script.src = 'https://api.tianditu.gov.cn/api?v=4.0&tk=' + this.option.apikey
script.src = 'http://api.tianditu.gov.cn/api?v=4.0&tk=' + this.option.apikey
script.onload = this.initEcharts.bind(this)
document.head.appendChild(script)
}
@@ -145,7 +145,7 @@
if (this.option.apikey) {
const script = document.createElement('script')
script.src = 'https://api.tianditu.gov.cn/api?v=4.0&tk=' + this.option.apikey
script.src = 'http://api.tianditu.gov.cn/api?v=4.0&tk=' + this.option.apikey
script.onload = this.initEcharts.bind(this)
document.head.appendChild(script)

View File

@@ -193,7 +193,7 @@
if (this.option && this.option.apikey) {
const script = document.createElement('script')
// view 层的页面运行在 www 根目录,其相对路径相对于 www 计算
script.src = 'https://api.tianditu.gov.cn/api?v=4.0&tk=' + this.option.apikey
script.src = 'http://api.tianditu.gov.cn/api?v=4.0&tk=' + this.option.apikey
script.onload = this.initEcharts.bind(this)
document.head.appendChild(script)
@@ -212,7 +212,7 @@
if (this.option.apikey) {
const script = document.createElement('script')
script.src = 'https://api.tianditu.gov.cn/api?v=4.0&tk=' + this.option.apikey
script.src = 'http://api.tianditu.gov.cn/api?v=4.0&tk=' + this.option.apikey
script.onload = this.initEcharts.bind(this)
document.head.appendChild(script)

View File

@@ -133,7 +133,7 @@
mask: true
})
uni.request({
url: 'https://api.tianditu.gov.cn/v2/search',
url: 'http://api.tianditu.gov.cn/v2/search',
method: 'GET',
data: params,
success: res => {
@@ -257,6 +257,7 @@
tk: e.apikey
},
success: res => {
//console.log(res);
if (res.data.result) {
const value = that.formatterAdressLocation(res.data.result, 1)
that.arr_list = [value]
@@ -268,36 +269,7 @@
}
},
fail: () => {
if (window.location.origin.search('localhost') >= 0 || window.location.origin
.search('10.165.0.173') >= 0) { // 测试环境
const value = that.formatterAdressLocation({
"formatted_address": "四川省德阳市广汉市西高镇李家院子东北约95米",
"location": {
"lon": 104.20046,
"lat": 31.0513
},
"addressComponent": {
"address": "李家院子",
"town": "高坪镇",
"nation": "中国",
"city": "德阳市",
"county_code": "156510681",
"poi_position": "东北",
"county": "广汉市",
"city_code": "156510600",
"address_position": "东北",
"poi": "李家院子",
"province_code": "156510000",
"town_code": "156510681103",
"province": "四川省",
"road": "洛小路",
"road_distance": 126,
"address_distance": 95,
"poi_distance": 95
}
}, 1)
that.arr_list = [value]
}
//console.log('获取失败')
},
complete: () => {
uni.hideLoading();

View File

@@ -5,46 +5,6 @@
</template>
<script>
import 'ol/ol.css';
import Map from 'ol/Map';
import View from 'ol/View';
import TileLayer from 'ol/layer/Tile';
import SourceVector from 'ol/source/Vector';
import LayerVector from 'ol/layer/Vector';
import * as control from 'ol/control';
import {
toLonLat
} from 'ol/proj';
import Overlay from 'ol/Overlay';
import {
toStringHDMS
} from 'ol/coordinate';
import {
Select
} from 'ol/interaction'
import {
GeoJSON
} from 'ol/format';
import {
Style,
Circle,
Fill,
Stroke,
Icon,
Text
} from 'ol/style';
import Feature from 'ol/Feature';
import {
Point,
Polygon
} from 'ol/geom';
import {
Logo,
TileSuperMapRest,
FeatureService,
GetFeaturesByGeometryParameters
} from '@supermap/iclient-ol';
const geoJSONParser = new GeoJSON();
let mypoint = require('@/static/img/mypoint.png');
export default {
name: "uMapView",
@@ -114,297 +74,12 @@
};
},
mounted() {
if (this.init) {
this.initMap()
}
},
methods: {
initMap(options) {
let lat, lon;
if (options) {
lat = options.lat
lon = options.lon
} else {
lat = this.latitude
lon = this.longitude
}
this.map = new Map({
target: 'map',
controls: control.defaults({
attribution: false,
zoom: this.ScaleZoom,
}),
layers: [
new TileLayer({ // 使用瓦片
source: new TileSuperMapRest({
url: this.MapUrl,
wrapX: true,
}),
projection: 'EPSG:4326',
}),
],
view: new View({
center: [lon, lat],
maxZoom: this.maxZoom,
minZoom: this.minZoom,
zoom: this.zoom,
projection: 'EPSG:4326',
})
});
//添加查询结果图层
this.vectorSource = new SourceVector({
wrapX: false
});
const resultLayer = new LayerVector({
source: this.vectorSource,
});
//添加点图层
this.addPointsSource = new SourceVector({
wrapX: false
});
const addPointsLayer = new LayerVector({
source: this.addPointsSource,
});
this.map.addLayer(addPointsLayer);
this.map.addLayer(resultLayer);
this.map.on('pointermove', (e) => {
if (this.isShowToolTip) {
this.helpTooltip.setPosition(undefined);
this.helpTooltipElement.classList.add('hidden');
}
this.$emit('regionchange', e.pixel)
});
this.map.on('singleclick', (e) => {
this.$emit('clickMap', e.coordinate)
});
if (this.open) {
this.addFeature([{
id: 1,
latitude: lat,
longitude: lon,
iconPath: mypoint,
title: '',
width: 20,
height: 20
}])
}
if (this.flagTip) {
this.createHelpTooltip()
}
},
addMarker(point) {
console.log('point', point)
// this.ceateMarker([104.404419, 31.133980])
},
addFeature(covers) {
console.log(covers)
const features = covers.map((item) => ({
type: 'Feature',
geometry: {
type: 'Point',
coordinates: [item.longitude, item.latitude],
},
properties: {
iconPath: item.iconPath,
text: item.title,
value: JSON.stringify(item),
scale: item.id === 1 ? [0.15, 0.15] : [0.1, 0.1]
}
}))
this.careateFeature(features)
},
ceateMarker(point) {
// 创建一个坐标点
const pointed = new Point(point); // 这里的[0, 0]应该替换为您的经度和纬度
// 创建一个特征
const pointFeature = new Feature({
geometry: pointed,
name: 'My Point'
});
pointFeature.setStyle(new Style({
image: new Circle({
fill: new Fill({
color: [255, 0, 0, 0.5]
}),
stroke: new Stroke({
color: 'red',
width: 2
}),
radius: 8
})
}));
pointFeature.setProperties({
POP: 1,
CAPITAL: 'test'
});
this.addPointsSource.clear()
// 将特征添加到矢量图层
this.addPointsSource.addFeature(pointFeature);
// 确保更新地图视图以显示新的标点
this.map.getView().fit(this.addPointsSource.getExtent());
// // 或者移动视图
// _this.map.getView().animate({
// duration: 850,
// zoom: 5,
// center: point,
// });
},
careateFeature(result) {
if (this.vectorSourceIcon) {
this.vectorSourceIcon.clear()
const geojsonObject = {
type: 'FeatureCollection',
features: result,
};
this.vectorSourceIcon.addFeatures(geoJSONParser.readFeatures(geojsonObject))
this.vectorSourceIcon.changed()
return
}
const geojsonObject = {
type: 'FeatureCollection',
features: result,
};
// 创建一个图层作为点位
this.vectorSourceIcon = new SourceVector({
features: geoJSONParser.readFeatures(geojsonObject)
});
this.vectorLayerIcon = new LayerVector({
source: this.vectorSourceIcon,
style: feature => {
return new Style({
image: new Icon({
anchor: [0.5, 0.9],
scale: feature.get('scale'),
src: feature.get('iconPath'),
}),
text: new Text({
text: feature.get('text'),
fill: new Fill({
color: '#000'
}),
stroke: new Stroke({
color: '#fff',
width: 3
}),
font: 'normal 12px Calibri, sans-serif',
textAlign: 'center', // 文本对齐
offsetX: 0,
offsetY: 15,
rotation: 0, // 文本旋转
}),
});
}
});
this.map.addLayer(this.vectorLayerIcon);
// 添加事件
this.selectInteraction = new Select({
layers: [this.vectorLayerIcon]
});
this.selectInteraction.on('select', (event) => {
const selectedFeatures = event.selected;
if (selectedFeatures.length) {
const select = selectedFeatures[0].values_
this.$emit('markertap', JSON.parse(select.value))
// tooltip
if (this.flagTip) {
const coordinate = selectedFeatures[0].values_.geometry.flatCoordinates;
this.helpTooltipElement.innerHTML = select.text;
console.log(this.helpTooltip)
this.helpTooltip.setPosition(coordinate);
this.helpTooltipElement.classList.remove('hidden');
this.map.addOverlay(this.helpTooltip);
this.isShowToolTip = true
}
}
});
this.map.addInteraction(this.selectInteraction);
},
createHelpTooltip() {
this.helpTooltipElement
if (this.helpTooltipElement) {
this.helpTooltipElement.parentNode.removeChild(this.helpTooltipElement);
}
this.helpTooltipElement = document.createElement('div');
this.helpTooltipElement.className = 'tooltip hidden';
this.helpTooltip = new Overlay({
element: this.helpTooltipElement,
offset: [-30, 20],
positioning: 'center-left'
});
}
}
methods: {}
}
</script>
<style scoped>
.app-content {}
.editPane {
position: absolute;
right: 65px;
top: 8px;
text-align: center;
background: #FFF;
z-index: 1000;
border-radius: 4px;
}
.ol-popup {
position: absolute;
background-color: white;
-webkit-filter: drop-shadow(0 1px 4px rgba(0, 0, 0, 0.2));
filter: drop-shadow(0 1px 4px rgba(0, 0, 0, 0.2));
padding: 15px;
border-radius: 10px;
border: 1px solid #cccccc;
bottom: 12px;
left: -50px;
min-width: 120px;
white-space: nowrap;
}
.ol-popup:after,
.ol-popup:before {
top: 100%;
border: solid transparent;
content: " ";
height: 0;
width: 0;
position: absolute;
pointer-events: none;
}
.ol-popup:after {
border-top-color: white;
border-width: 10px;
left: 48px;
margin-left: -10px;
}
.ol-popup:before {
border-top-color: #cccccc;
border-width: 11px;
left: 48px;
margin-left: -11px;
}
.tooltip {
position: relative;
background: rgba(0, 0, 0, 0.5);
border-radius: 4px;
color: white;
padding: 4px 8px;
opacity: 0.7;
white-space: nowrap;
}
</style>

View File

@@ -0,0 +1,410 @@
<template>
<view class="app-content">
<view id="map" style="width: 100%;height: 100%;"></view>
</view>
</template>
<script>
import 'ol/ol.css';
import Map from 'ol/Map';
import View from 'ol/View';
import TileLayer from 'ol/layer/Tile';
import SourceVector from 'ol/source/Vector';
import LayerVector from 'ol/layer/Vector';
import * as control from 'ol/control';
import {
toLonLat
} from 'ol/proj';
import Overlay from 'ol/Overlay';
import {
toStringHDMS
} from 'ol/coordinate';
import {
Select
} from 'ol/interaction'
import {
GeoJSON
} from 'ol/format';
import {
Style,
Circle,
Fill,
Stroke,
Icon,
Text
} from 'ol/style';
import Feature from 'ol/Feature';
import {
Point,
Polygon
} from 'ol/geom';
import {
Logo,
TileSuperMapRest,
FeatureService,
GetFeaturesByGeometryParameters
} from '@supermap/iclient-ol';
const geoJSONParser = new GeoJSON();
let mypoint = require('@/static/img/mypoint.png');
export default {
name: "uMapView",
props: {
latitude: {
required: true,
},
longitude: {
required: true,
},
zoom: {
type: Number,
required: false,
default: 10,
},
maxZoom: {
type: Number,
required: false,
default: 20,
},
minZoom: {
type: Number,
required: false,
default: 0,
},
ScaleZoom: {
type: Boolean,
required: false,
default: false,
},
MapUrl: { // 瓦片地图URL
type: String,
required: true,
default: '',
},
flagTip: {
type: Boolean,
required: false,
default: false,
},
open: {
type: Boolean,
required: false,
default: false,
},
init: {
type: Boolean,
required: false,
default: true,
}
},
data() {
return {
// 实例化对象
map: null,
addPointsSource: null,
vectorSource: null,
vectorSourceIcon: null,
vectorLayerIcon: null,
selectInteraction: null,
helpTooltipElement: null,
helpTooltip: null,
isclearPoint: null,
overlay: null,
// 控制参数
isShowToolTip: false,
};
},
mounted() {
if (this.init) {
this.initMap()
}
},
methods: {
initMap(options) {
let lat, lon;
if (options) {
lat = options.lat
lon = options.lon
} else {
lat = this.latitude
lon = this.longitude
}
this.map = new Map({
target: 'map',
controls: control.defaults({
attribution: false,
zoom: this.ScaleZoom,
}),
layers: [
new TileLayer({ // 使用瓦片
source: new TileSuperMapRest({
url: this.MapUrl,
wrapX: true,
}),
projection: 'EPSG:4326',
}),
],
view: new View({
center: [lon, lat],
maxZoom: this.maxZoom,
minZoom: this.minZoom,
zoom: this.zoom,
projection: 'EPSG:4326',
})
});
//添加查询结果图层
this.vectorSource = new SourceVector({
wrapX: false
});
const resultLayer = new LayerVector({
source: this.vectorSource,
});
//添加点图层
this.addPointsSource = new SourceVector({
wrapX: false
});
const addPointsLayer = new LayerVector({
source: this.addPointsSource,
});
this.map.addLayer(addPointsLayer);
this.map.addLayer(resultLayer);
this.map.on('pointermove', (e) => {
if (this.isShowToolTip) {
this.helpTooltip.setPosition(undefined);
this.helpTooltipElement.classList.add('hidden');
}
this.$emit('regionchange', e.pixel)
});
this.map.on('singleclick', (e) => {
this.$emit('clickMap', e.coordinate)
});
if (this.open) {
this.addFeature([{
id: 1,
latitude: lat,
longitude: lon,
iconPath: mypoint,
title: '',
width: 20,
height: 20
}])
}
if (this.flagTip) {
this.createHelpTooltip()
}
},
addMarker(point) {
console.log('point', point)
// this.ceateMarker([104.404419, 31.133980])
},
addFeature(covers) {
console.log(covers)
const features = covers.map((item) => ({
type: 'Feature',
geometry: {
type: 'Point',
coordinates: [item.longitude, item.latitude],
},
properties: {
iconPath: item.iconPath,
text: item.title,
value: JSON.stringify(item),
scale: item.id === 1 ? [0.15, 0.15] : [0.1, 0.1]
}
}))
this.careateFeature(features)
},
ceateMarker(point) {
// 创建一个坐标点
const pointed = new Point(point); // 这里的[0, 0]应该替换为您的经度和纬度
// 创建一个特征
const pointFeature = new Feature({
geometry: pointed,
name: 'My Point'
});
pointFeature.setStyle(new Style({
image: new Circle({
fill: new Fill({
color: [255, 0, 0, 0.5]
}),
stroke: new Stroke({
color: 'red',
width: 2
}),
radius: 8
})
}));
pointFeature.setProperties({
POP: 1,
CAPITAL: 'test'
});
this.addPointsSource.clear()
// 将特征添加到矢量图层
this.addPointsSource.addFeature(pointFeature);
// 确保更新地图视图以显示新的标点
this.map.getView().fit(this.addPointsSource.getExtent());
// // 或者移动视图
// _this.map.getView().animate({
// duration: 850,
// zoom: 5,
// center: point,
// });
},
careateFeature(result) {
if (this.vectorSourceIcon) {
this.vectorSourceIcon.clear()
const geojsonObject = {
type: 'FeatureCollection',
features: result,
};
this.vectorSourceIcon.addFeatures(geoJSONParser.readFeatures(geojsonObject))
this.vectorSourceIcon.changed()
return
}
const geojsonObject = {
type: 'FeatureCollection',
features: result,
};
// 创建一个图层作为点位
this.vectorSourceIcon = new SourceVector({
features: geoJSONParser.readFeatures(geojsonObject)
});
this.vectorLayerIcon = new LayerVector({
source: this.vectorSourceIcon,
style: feature => {
return new Style({
image: new Icon({
anchor: [0.5, 0.9],
scale: feature.get('scale'),
src: feature.get('iconPath'),
}),
text: new Text({
text: feature.get('text'),
fill: new Fill({
color: '#000'
}),
stroke: new Stroke({
color: '#fff',
width: 3
}),
font: 'normal 12px Calibri, sans-serif',
textAlign: 'center', // 文本对齐
offsetX: 0,
offsetY: 15,
rotation: 0, // 文本旋转
}),
});
}
});
this.map.addLayer(this.vectorLayerIcon);
// 添加事件
this.selectInteraction = new Select({
layers: [this.vectorLayerIcon]
});
this.selectInteraction.on('select', (event) => {
const selectedFeatures = event.selected;
if (selectedFeatures.length) {
const select = selectedFeatures[0].values_
this.$emit('markertap', JSON.parse(select.value))
// tooltip
if (this.flagTip) {
const coordinate = selectedFeatures[0].values_.geometry.flatCoordinates;
this.helpTooltipElement.innerHTML = select.text;
console.log(this.helpTooltip)
this.helpTooltip.setPosition(coordinate);
this.helpTooltipElement.classList.remove('hidden');
this.map.addOverlay(this.helpTooltip);
this.isShowToolTip = true
}
}
});
this.map.addInteraction(this.selectInteraction);
},
createHelpTooltip() {
this.helpTooltipElement
if (this.helpTooltipElement) {
this.helpTooltipElement.parentNode.removeChild(this.helpTooltipElement);
}
this.helpTooltipElement = document.createElement('div');
this.helpTooltipElement.className = 'tooltip hidden';
this.helpTooltip = new Overlay({
element: this.helpTooltipElement,
offset: [-30, 20],
positioning: 'center-left'
});
}
}
}
</script>
<style scoped>
.app-content {}
.editPane {
position: absolute;
right: 65px;
top: 8px;
text-align: center;
background: #FFF;
z-index: 1000;
border-radius: 4px;
}
.ol-popup {
position: absolute;
background-color: white;
-webkit-filter: drop-shadow(0 1px 4px rgba(0, 0, 0, 0.2));
filter: drop-shadow(0 1px 4px rgba(0, 0, 0, 0.2));
padding: 15px;
border-radius: 10px;
border: 1px solid #cccccc;
bottom: 12px;
left: -50px;
min-width: 120px;
white-space: nowrap;
}
.ol-popup:after,
.ol-popup:before {
top: 100%;
border: solid transparent;
content: " ";
height: 0;
width: 0;
position: absolute;
pointer-events: none;
}
.ol-popup:after {
border-top-color: white;
border-width: 10px;
left: 48px;
margin-left: -10px;
}
.ol-popup:before {
border-top-color: #cccccc;
border-width: 11px;
left: 48px;
margin-left: -11px;
}
.tooltip {
position: relative;
background: rgba(0, 0, 0, 0.5);
border-radius: 4px;
color: white;
padding: 4px 8px;
opacity: 0.7;
white-space: nowrap;
}
</style>

View File

@@ -3,11 +3,9 @@ module.exports = {
// 图片地址
imageUrl: '',
// 天地图tk
apiKey: 'e4266a5e84fe6c10f60c559967f0a03f',
apiKey: 'aa9b92683ff22363aa17baa16599cff8',
// 显示标题
showTitle: false,
loginURl: 'https://dy12333.org.cn/h5/#/pages/qyPackge/user/login/login',
AESKey: 'mL8na90u+5hoa/HKiMinvA==',
// map 1、黑色模块 2、白色模块
// supperMap: 'http://10.165.0.44:1205/proxy/rest/maps/f346b6c59dc64d5793713cf384fab78d/33cbaa14370449a08588f1074ecfec67',
// supperMap: 'http://10.165.0.44:1205/proxy/rest/maps/c02c6f51f3ab4190bffd5e3e54cf5ac4/111013e9067749488d44841208771768',

View File

Before

Width:  |  Height:  |  Size: 79 KiB

After

Width:  |  Height:  |  Size: 79 KiB

21
main.js
View File

@@ -8,9 +8,6 @@ import tools from '@/untils/tools.js'
import {
VueJsonp
} from 'vue-jsonp'
import {
GoLogin
} from '@/untils/AxiosUtils.js';
// 注册全局组件
// import MescrollBody from "@/components/mescroll-uni/mescroll-body.vue"
// import MescrollUni from "@/components/mescroll-uni/mescroll-uni.vue"
@@ -23,17 +20,9 @@ function haslogin() {
return !!store.state.user.token
}
function hasResume() { // 是否填写简历
const data = store.state.user.resumeInfo
if (!(data.education && data.telephone && data.wage && data.workplace)) {
return false
}
return true
}
function navTo(url, needLogin) {
if (needLogin && !haslogin()) {
GoLogin()
console.log(url)
if (needLogin) {
return
}
uni.navigateTo({
@@ -41,7 +30,6 @@ function navTo(url, needLogin) {
})
}
const msg = (title, duration = 1500, mask = false, icon = 'none') => {
uni.showToast({
title,
@@ -62,13 +50,12 @@ Vue.component('jl-button', JlButton)
Vue.component('jl-form', JlForm)
Vue.component('jl-form-item', JlFormItem)
Vue.component('cs-button', CSButton)
Vue.component('super-map', superMapView)
// Vue.component('super-map', superMapView)
Vue.component('empty', empty)
Vue.prototype.$api = {
msg,
sleep,
haslogin,
hasResume
haslogin
}
Vue.prototype.tools = tools
Vue.prototype.$config = config

5
package-lock.json generated
View File

@@ -1805,11 +1805,6 @@
"resolved": "https://registry.npmmirror.com/core-js/-/core-js-2.6.12.tgz",
"integrity": "sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ=="
},
"crypto-js": {
"version": "4.2.0",
"resolved": "https://registry.npmmirror.com/crypto-js/-/crypto-js-4.2.0.tgz",
"integrity": "sha512-KALDyEYgpY+Rlob/iriUtjV6d5Eq+Y191A5g4UqLAi8CyGP9N1+FdVbkc1SxKc2r4YAYqG8JzO2KGL+AizD70Q=="
},
"csscolorparser": {
"version": "1.0.3",
"resolved": "https://registry.npmmirror.com/csscolorparser/-/csscolorparser-1.0.3.tgz",

View File

@@ -18,7 +18,6 @@
"license": "ISC",
"dependencies": {
"@supermap/iclient-ol": "^11.1.1",
"crypto-js": "^4.2.0",
"decimal.js": "^10.2.0",
"js-base64": "^2.4.9",
"js-md5": "^0.7.3",

View File

@@ -36,7 +36,7 @@
}
},
onShow() {
if (!this.$api.haslogin()){
if (!this.$store.state.user.token){
//modalTitle, content, whetherCancel, confirmText, pageUrl, cancelUrl
showUniModal('提示','您还未登录,点击确认去登录',true,'确定','/pages/login/login','/pages/index/index')
}else{

View File

@@ -171,9 +171,6 @@
</template>
<script>
import {
GoLogin
} from '@/untils/AxiosUtils.js';
import {
mapGetters
} from 'vuex'
@@ -250,10 +247,6 @@
}
},
onShow() {
if (!this.$api.haslogin()) {
GoLogin()
return
}
this.getSkill()
},
created() {
@@ -536,7 +529,6 @@
}).then(res => {
this.isShowButton = false;
this.getResume()
this.$store.dispatch('getResumeInfo')
this.$api.msg('保存成功')
})
} else {

View File

@@ -7,7 +7,7 @@
<block v-for="(page, pIndex) in data" :key="pIndex">
<block v-for="(item, index) in page" :key="item.id">
<view class="probody">
<company-list :companyitem="item" :noApply="false" :location="userLocation"></company-list>
<company-list :companyitem="item" :position="userLocation" :noApply="false"></company-list>
<view class="baddd"></view>
<!-- <block>
<image src="/static/img/tab.orange.svg" mode="" v-if="item.status === 1"></image>

View File

@@ -1,153 +1,158 @@
<template>
<view class="body">
<!-- <view class="tab">
<view class="body">
<!-- <view class="tab">
<v-tabs :tabs="['全部任务','全部岗位']" v-model="activeTab" color="#999" activeColor="#000" fontSize="36rx"
activeFontSize="36rpx" @change='changeTab' />
</view> -->
<block v-for="(page, pIndex) in data" :key="pIndex">
<block v-for="(item, index) in page" :key="item.id">
<view class="probody">
<company-list :companyitem="item" :noApply="false"></company-list>
<view class="baddd"></view>
<!-- <block>
<block v-for="(page, pIndex) in data" :key="pIndex">
<block v-for="(item, index) in page" :key="item.id">
<view class="probody">
<company-list :companyitem="item" :position="userLocation" :noApply="false"></company-list>
<view class="baddd"></view>
<!-- <block>
<image src="/static/img/tab.orange.svg" mode="" v-if="item.status === 1"></image>
<image src="/static/img/tab.blue.svg" mode="" v-else-if="item.status === 2"></image>
<image src="/static/img/tab.green.svg" mode="" v-else-if="item.status === 3"></image>
<image src="/static/img/tab.gray.svg" mode="" v-else></image>
</block> -->
</view>
</block>
</block>
<view class="nothing" v-if="data.length === 0">
<image src="/static/img/pic_notask.svg" mode=""></image>
<view class="nothingContnt">
暂无申请信息
</view>
</view>
</view>
</view>
</block>
</block>
<view class="nothing" v-if="data.length === 0">
<image src="/static/img/pic_notask.svg" mode=""></image>
<view class="nothingContnt">
暂无申请信息
</view>
</view>
</view>
</template>
<script>
import vTabs from '@/components/v-tabs/v-tabs.vue';
import companyList from '@/components/companyList/applyList.vue';
import {
myMission
} from '@/api/mission.js';
export default {
components: {
vTabs,
companyList
},
data() {
return {
data: [],
activeTab: 0,
current: 1,
size: 10,
total: 0
}
},
onLoad: function() {
this.init()
},
/*页面滚动到底部 换页*/
onReachBottom: function() {
if (this.current <= Math.ceil(this.total / this.size)) {
this.getData();
} else {
uni.showToast({
icon: "none",
title: '已经是最后一页',
})
}
},
/*下拉刷新*/
onPullDownRefresh:function(){
this.init()
},
methods: {
init(){
this.current = 1
this.data = []
this.getData()
},
getData() {
var status = Number(this.activeTab) + 1
myMission(this.current, this.size, status).then(res => {
uni.stopPullDownRefresh();
if (this.current === 1) {
this.data = [];
}
this.current += 1;
this.total = res.data.data.total;
if (res.data.data && res.data.data.records.length) {
this.data.push(res.data.data.records);
}
})
},
gomap: function() {
uni.navigateTo({
url: '../mapSeach/mapSeach'
})
},
changeTab: function(e) {
this.activeTab = e;
this.init()
}
}
}
import vTabs from '@/components/v-tabs/v-tabs.vue';
import companyList from '@/components/companyList/applyList.vue';
import {
myMission
} from '@/api/mission.js';
import {
mapGetters
} from 'vuex'
export default {
components: {
vTabs,
companyList
},
data() {
return {
data: [],
activeTab: 0,
current: 1,
size: 10,
total: 0
}
},
onLoad: function() {
this.init()
},
/*页面滚动到底部 换页*/
onReachBottom: function() {
if (this.current <= Math.ceil(this.total / this.size)) {
this.getData();
} else {
uni.showToast({
icon: "none",
title: '已经是最后一页',
})
}
},
/*下拉刷新*/
onPullDownRefresh: function() {
this.init()
},
computed: {
...mapGetters(['userLocation']),
},
methods: {
init() {
this.current = 1
this.data = []
this.getData()
},
getData() {
var status = Number(this.activeTab) + 1
myMission(this.current, this.size, status).then(res => {
uni.stopPullDownRefresh();
if (this.current === 1) {
this.data = [];
}
this.current += 1;
this.total = res.data.data.total;
if (res.data.data && res.data.data.records.length) {
this.data.push(res.data.data.records);
}
})
},
gomap: function() {
uni.navigateTo({
url: '../mapSeach/mapSeach'
})
},
changeTab: function(e) {
this.activeTab = e;
this.init()
}
}
}
</script>
<style scoped>
page {
height: 100%;
}
page {
height: 100%;
}
.tab {
height: 46px;
}
.tab {
height: 46px;
}
.body {
height: 100%;
}
.body {
height: 100%;
}
.probody image {
width: 88rpx;
height: 88rpx;
position: absolute;
right: 0;
top: 0;
}
.probody image {
width: 88rpx;
height: 88rpx;
position: absolute;
right: 0;
top: 0;
}
.probody {
width: 100%;
position: relative;
}
.probody {
width: 100%;
position: relative;
}
.baddd {
background: #f6f6f6;
height: 20rpx;
}
.baddd {
background: #f6f6f6;
height: 20rpx;
}
.nothing {
height: 100%;
padding-top: 50%;
box-sizing: border-box;
}
.nothing {
height: 100%;
padding-top: 50%;
box-sizing: border-box;
}
.nothing image {
width: 400rpx;
height: 200rpx;
display: block;
margin: 0 auto;
}
.nothing image {
width: 400rpx;
height: 200rpx;
display: block;
margin: 0 auto;
}
.nothingContnt {
font-family: PingFangSC-Regular;
font-size: 28rpx;
color: #666;
margin-top: 30rpx;
text-align: center;
}
.nothingContnt {
font-family: PingFangSC-Regular;
font-size: 28rpx;
color: #666;
margin-top: 30rpx;
text-align: center;
}
</style>

View File

@@ -79,7 +79,7 @@
{
"path": "pages/project/newProject",
"style": {
"navigationBarTitleText": "德阳市灵活就业平台",
"navigationBarTitleText": "宜昌市灵活就业平台",
"navigationBarBackgroundColor": "#FFFFFF",
"enablePullDownRefresh": true
}

File diff suppressed because it is too large Load Diff

View File

@@ -7,9 +7,6 @@
import {
mapGetters
} from 'vuex'
import {
GoLogin
} from '@/untils/AxiosUtils.js';
import website from '@/config/website.js'
export default {
data() {
@@ -20,7 +17,7 @@
},
onLoad(options) {
uni.showLoading({
title: '登录中'
title: ''
})
if (options.token) {
const that = this
@@ -42,6 +39,7 @@
if (!auth.bankCardState) {
that.goSign(0)
} else {
uni.switchTab({
url: '/pages/index/index'
})
@@ -52,10 +50,9 @@
// this.$refs.code.refushCode()
});
} else {
// uni.reLaunch({
// url: '/pages/login/login'
// })
GoLogin()
uni.reLaunch({
url: '/pages/login/login'
})
}
},
method: {

View File

@@ -12,10 +12,10 @@
<view v-if="loading" class="btn nocheck" loading="true"></view>
<view v-else-if="validate" class="btn" @click="login">立即登录</view>
<view v-else class="btn nocheck">立即登录</view>
<!-- <view class="changeLogintype">
<view class="" @click="goReg">手机注册</view>
<view class="" @click="goForget">忘记密码</view>
</view> -->
<view class="changeLogintype">
<view class="" @click="goReg">手机注册</view>
<view class="" @click="goForget">忘记密码</view>
</view>
</login-template>
</template>
@@ -59,7 +59,7 @@
wx.hideHomeButton();
//#endif
this.password = ''
if (this.$api.haslogin()) {
if (this.$store.state.user.token) {
this.$store.dispatch('LogOut').then(() => {
this.$store.dispatch('clearAuthState')
this.$store.dispatch('endRefreshNewsTimer')
@@ -74,8 +74,8 @@
},
login(e) {
if (this.validate) {
this.userChecked = true;
console.log(this.userChecked)
// this.userChecked = true;
// console.log(this.userChecked)
// if (!this.userChecked) {
// uni.showToast({
// title:'请先阅读并同意《服务及隐私协议》',
@@ -106,7 +106,8 @@
}).catch((err) => {
this.loading = false
// this.$refs.code.refushCode()
location.href = "https://dy12333.org.cn/h5/"
// location.href = "https://dy12333.org.cn/h5/"
this.$api.msg('登录失败')
});
// }
}
@@ -168,4 +169,15 @@
}
/* #endif */
.changeLogintype {
margin: 0 auto;
font-family: PingFangSC-Regular;
font-size: 14px;
color: #1B66FF;
margin-top: 15px;
display: flex;
align-items: center;
justify-content: space-between;
}
</style>

View File

@@ -1,106 +1,113 @@
<template>
<view class="login-body">
<view class="nothing" style="height: 100rpx;"></view>
<view class="titleText">{{title}}</view>
<slot></slot>
<view v-if="!hideBottom" class="bottomt">
<view class="bottomt-box">
<!-- <view class="check-icon" @click="checkChanged">
<image v-if="userChecked" src="../../static/img/checkOk.png" style="width: 30rpx;height:30rpx;"></image>
<view class="noneCheck" v-else></view>
</view>
已阅读并同意<text class="bottomtText" @click="goMent">服务及隐私协议</text> -->
<view class="login-body">
<view class="nothing" style="height: 100rpx;"></view>
<view class="titleText">{{title}}</view>
<slot></slot>
<view v-if="!hideBottom" class="bottomt">
<view class="bottomt-box">
<view class="check-icon" @click="checkChanged">
<image v-if="userChecked" :src="checked" style="width: 30rpx;height:30rpx;">
</image>
<view class="noneCheck" v-else></view>
</view>
已阅读并同意<text class="bottomtText" @click="goMent">服务及隐私协议</text>
</view>
</view>
</view>
</view>
</view>
</view>
</template>
<script>
import {mapGetters} from 'vuex'
export default {
import checked from '../../static/img/checkOk.png'
import {
mapGetters
} from 'vuex'
export default {
data(){
return{
data() {
return {
checked
}
},
props: {
title: String,
hideBottom: Boolean
},
methods: {
goMent() {
uni.navigateTo({
url: '/pages/user/agreement'
})
},
checkChanged() {
let checkedValue = !this.userChecked;
this.$store.dispatch('UserCheckedBtn', checkedValue)
}
},
props: {
title: String,
hideBottom: Boolean
},
methods: {
goMent() {
uni.navigateTo({
url: '/pages/user/agreement'
})
},
checkChanged(){
let checkedValue=!this.userChecked;
this.$store.dispatch('UserCheckedBtn',checkedValue)
}
},
computed: {
...mapGetters(['userChecked'])
},
mounted() {
}
},
computed:{
...mapGetters(['userChecked'])
},
mounted() {
},
}
},
}
</script>
<style lang="scss">
.login-body {
min-height: 880rpx;
height: 100%;
position: relative;
width: 80%;
margin: 0 auto;
}
.login-body {
min-height: 880rpx;
height: 100%;
position: relative;
width: 80%;
margin: 0 auto;
}
.titleText {
font-family: PingFangSC-Medium;
font-size: 46rpx;
color: #333333;
font-weight: bold;
padding: 30rpx 0;
}
.titleText {
font-family: PingFangSC-Medium;
font-size: 46rpx;
color: #333333;
font-weight: bold;
padding: 30rpx 0;
}
.bottomtText {
color: #151515;
}
.bottomtText {
color: #151515;
}
.bottomt {
font-family: PingFangSC-Regular;
font-size: 24rpx;
color: #999999;
position: absolute;
bottom: 80rpx;
left: 0;
width: 100%;
text-align: center;
.bottomt-box{
display: flex;
justify-content: center;
align-items: center;
}
}
.check-icon{
font-size: 28rpx;
font-weight: 400;
color: #999999;
align-items: center;
width: 30rpx;
height: 30rpx;
margin-right: 12rpx;
.noneCheck{
width: 26rpx;
height: 26rpx;
border-radius: 50%;
border: 2rpx solid #999999;
margin-right:12rpx;
}
}
.bottomt {
font-family: PingFangSC-Regular;
font-size: 24rpx;
color: #999999;
position: absolute;
bottom: 80rpx;
left: 0;
width: 100%;
text-align: center;
.bottomt-box {
display: flex;
justify-content: center;
align-items: center;
}
}
.check-icon {
font-size: 28rpx;
font-weight: 400;
color: #999999;
align-items: center;
width: 30rpx;
height: 30rpx;
margin-right: 12rpx;
.noneCheck {
width: 26rpx;
height: 26rpx;
border-radius: 50%;
border: 2rpx solid #999999;
margin-right: 12rpx;
}
}
</style>

View File

@@ -1,473 +1,470 @@
<template>
<view class="bodys">
<view class="status_bar">
<!-- 这里是状态栏 -->
</view>
<view class="head">
<map id='midMap' ref='midMap' :latitude="latitude" :markers="markList" :longitude="longitude"
@tap="changeMap" scale="10">
</map>
<view class="search">
<view class="head_border">
</view>
<view class="controlss">
<view class="controlss-back">
<image src="../../static/img/left.svg" @click="backView" mode=""></image>
</view>
<view class="controlss-input" @click="goSearch">
<input type="text" placeholder="搜索工作的地点" disabled="true" />
<image src="../../static/img/search.svg" style="margin-left: auto;" mode=""></image>
</view>
</view>
</view>
</view>
<view class="controlsPop">
<view class="listTitle">
附近零工岗位
</view>
<view class="borderbom"></view>
<scroll-view scroll-y lower-threshold="0" style="height: 92%;" @scrolltolower="upLoad"
v-if="companyList.length>0">
<block v-for="(item, index) in companyList" :key="item.id">
<companyList :companyitem="item" :near="true"></companyList>
<view class="baddd"></view>
</block>
</scroll-view>
<view class="nothingArea" v-else>
<image src="../../static/img/pic_notask.svg" mode="" class="nothing"></image>
<view class="nothingContnt">
暂无岗位信息
</view>
</view>
</view>
</view>
<view class="bodys">
<view class="status_bar">
<!-- 这里是状态栏 -->
</view>
<view class="head">
<map id='midMap' ref='midMap' :latitude="latitude" :markers="markList" :longitude="longitude" @tap="changeMap" scale="10">
</map>
<view class="search">
<view class="head_border">
</view>
<view class="controlss">
<view class="controlss-back">
<image src="../../static/img/left.svg" @click="backView" mode=""></image>
</view>
<view class="controlss-input" @click="goSearch">
<input type="text" placeholder="搜索工作的地点" disabled="true" />
<image src="../../static/img/search.svg" style="margin-left: auto;" mode=""></image>
</view>
</view>
</view>
</view>
<view class="controlsPop">
<view class="listTitle">
附近零工岗位
</view>
<view class="borderbom"></view>
<scroll-view scroll-y lower-threshold="0" style="height: 92%;" @scrolltolower="upLoad" v-if="companyList.length>0">
<block v-for="(item, index) in companyList" :key="item.id">
<companyList :companyitem="item" :near="true"></companyList>
<view class="baddd"></view>
</block>
</scroll-view>
<view class="nothingArea" v-else>
<image src="../../static/img/pic_notask.svg" mode="" class="nothing"></image>
<view class="nothingContnt">
暂无岗位信息
</view>
</view>
</view>
</view>
</template>
<script>
import companyList from '@/components/companyList/companyList.vue';
import testData from '@/common/textdata.js';
import {
nearMission
} from '@/api/mission.js';
import {
getcoder,
querySearch
} from "@/api/map.js";
import companyList from '@/components/companyList/companyList.vue';
import testData from '@/common/textdata.js';
import {
nearMission
} from '@/api/mission.js';
import {
getcoder,
querySearch
} from "@/api/map.js";
export default {
components: {
companyList
},
data() {
return {
longitude: 116.40,
latitude: 39.90,
// key: 'FW3BZ-6JTK6-GCUS5-MZCRR-3GPR5-HJFEI',
key: 'MTCBZ-WAAWC-H3M22-AL6XI-G4XN6-YZFK5',
currentPoint: {},
companyList: [],
markList: [],
inpoints: [],
inputValue: '',
searchResult: false,
searchResultList: [],
page: {
current: 1,
size: 10,
total: 0
},
mapCtx: null,
type: ""
};
},
onLoad: function(option) {
if (option.item) {
const item = JSON.parse(decodeURIComponent(option.item));
var point = {
target: {
latitude: item.lat,
longitude: item.lng
}
};
this.currentPoint = point;
this.type = 'search';
}
},
onShow: function() {
if (this.type === 'search') {
this.changeMap(this.currentPoint);
} else {
this.getLocation();
}
// that.inputValue='';
//发起定位授权弹窗
// uni.authorize({
// scope: 'scope.userLocation',
// success() {
// that.getLocation()
// },
// fail() {
// uni.showModal({
// title: '提示',
// content: '获取您的位置,以便为您推荐合适工作信息',
// success: function (res) {
// if (res.confirm) {
// that.getLocation();
// } else if (res.cancel) {
// //默认位置
// var point = {
// target:{
// latitude:that.latitude,
// longitude:that.longitude
// }
// };
// that.currentPoint = point;
// that.changeMap(point);
// }
// }
// });
// }
// });
// that.getLocation();
},
methods: {
/*定位*/
getLocation: function() {
var that = this;
uni.getLocation({
type: 'wgs84',
success: function(res) {
//初始化当前点
var point = {
target: {
latitude: res.latitude,
longitude: res.longitude
}
};
that.currentPoint = point;
// that.latitude = res.latitude;
// that.longitude = res.longitude;
//设置当前点 并逆地址解析和获取任务
that.changeMap(point);
},
fail: function() {
//默认位置
var point = {
target: {
latitude: that.latitude,
longitude: that.longitude
}
};
that.currentPoint = point;
that.changeMap(point);
},
complete: function(e) {}
});
},
/*设置当前点 并逆地址解析和获取任务*/
changeMap: function(e) {
this.page.current = 1;
if (e) {
var point = {
target: {
latitude: e.target.latitude,
longitude: e.target.longitude
}
};
this.currentPoint = point;
this.latitude = e.target.latitude;
this.longitude = e.target.longitude;
this.markList = [];
this.getAddrByPoint(e.target);
this.getData(e.target);
}
},
/*逆地址解析*/
getAddrByPoint: function(point) {
var that = this;
var location = point.latitude + ',' + point.longitude
that.setCurrentMarker(point); //设置当前marker
getcoder(location, encodeURI(that.key), 0).then(res => {
var address = res.data.result.address_component.city + res.data.result
.formatted_addresses.recommend;
this.markList.forEach(ele => { //给当前marker添加label
if (ele.id === 0) {
ele.title = address;
ele['callout'] = {
content: address,
color: '#000000',
fontSize: 12,
borderRadius: 2,
borderWidth: 0,
borderColor: '#ffffff',
bgColor: '#ffffff',
padding: '5',
display: 'ALWAYS',
textAlign: 'center'
}
}
})
});
},
/*设置当前定位点marker*/
setCurrentMarker: function(point) {
this.markList.push({
id: 0,
latitude: point.latitude,
longitude: point.longitude,
title: '',
zIndex: 2,
iconPath: '/static/img/location.png',
// width: 20,
// height: 20
})
},
/*设置任务点*/
setmarkers: function() {
// 设置任务点
var inpoints = [];
inpoints.push({
latitude: this.currentPoint.target.latitude,
longitude: this.currentPoint.target.longitude
})
if (this.companyList.length) {
for (var i = 0; i < this.companyList.length && i < 10; i++) {
inpoints.push({
latitude: this.companyList[i].lat,
longitude: this.companyList[i].lon
})
this.markList.push({
id: i + 1,
latitude: this.companyList[i].lat,
longitude: this.companyList[i].lon,
zIndex: 1,
iconPath: '/static/img/point.png',
// width: 30,
// height: 30
})
}
}
this.inpoints = inpoints;
},
goSearch() {
uni.navigateTo({
url: '../seach/placeSearch'
});
},
// search:function(){
// if(this.inputValue){
// this.querySearch(this.inputValue)
// }else{
// return
// }
// },
// //关键词输入提示
// querySearch:function(queryString) {
// querySearch(queryString, encodeURI(this.key)).then(res => {
// if (res.data.status === 0) {
// this.searchResultList = res.data.data;
// if(this.searchResultList.length){
// this.searchResultList.forEach((item, index) => {
// item.title = this.getInf(item.title, this.inputValue);
// });
// }
// }
// });
// },
// // 8-2、选择地址
// handleSelect:function(item) {
// this.page.current=1;
// this.searchResult=false;
// this.inputValue='';
// this.searchResultList = [];
// var point = {
// target:{
// latitude:item.location.lat,
// longitude:item.location.lng
// }
// };
// this.currentPoint = point;
// this.changeMap(point);
// },
// //高亮
// getInf(str, key) {
// if (str && key) {
// let replaceReg = new RegExp(key, 'g')// 匹配关键字正则
// let replaceString = "<span style='color: #1b66ff;'>" + key + "</span>" // 高亮替换
// return str.replace(replaceReg, replaceString);
// }
// },
// cancel:function(){
// this.inputValue = '';
// this.searchResult = false;
// },
getData: function(obj) {
nearMission(this.page.current, this.page.size, obj.latitude, obj.longitude, 50).then(res => {
if (this.page.current === 1) {
this.companyList = [];
}
this.page.current += 1;
this.page.total = res.data.data.total;
if (res.data.data && res.data.data.records.length) {
this.companyList = this.companyList.concat(res.data.data.records);
}
//非上拉加载 即设置任务点
if (obj !== 'upload') {
this.setmarkers();
}
})
},
//上拉加载
upLoad: function() {
if (this.page.current <= Math.ceil(this.page.total / this.page.size)) {
this.getData('upload');
} else {
uni.showToast({
icon: "none",
title: '已经是最后一页',
})
return
}
},
backView: function() {
uni.navigateBack({
delta: 1
});
}
}
};
export default {
components: {
companyList
},
data() {
return {
longitude: 116.40,
latitude: 39.90,
// key: 'FW3BZ-6JTK6-GCUS5-MZCRR-3GPR5-HJFEI',
key: 'MTCBZ-WAAWC-H3M22-AL6XI-G4XN6-YZFK5',
currentPoint: {},
companyList: [],
markList: [],
inpoints: [],
inputValue: '',
searchResult: false,
searchResultList: [],
page: {
current: 1,
size: 10,
total: 0
},
mapCtx: null,
type: ""
};
},
onLoad: function(option) {
if (option.item) {
const item = JSON.parse(decodeURIComponent(option.item));
var point = {
target: {
latitude: item.lat,
longitude: item.lng
}
};
this.currentPoint = point;
this.type = 'search';
}
},
onShow: function() {
if (this.type === 'search') {
this.changeMap(this.currentPoint);
} else {
this.getLocation();
}
// that.inputValue='';
//发起定位授权弹窗
// uni.authorize({
// scope: 'scope.userLocation',
// success() {
// that.getLocation()
// },
// fail() {
// uni.showModal({
// title: '提示',
// content: '获取您的位置,以便为您推荐合适工作信息',
// success: function (res) {
// if (res.confirm) {
// that.getLocation();
// } else if (res.cancel) {
// //默认位置
// var point = {
// target:{
// latitude:that.latitude,
// longitude:that.longitude
// }
// };
// that.currentPoint = point;
// that.changeMap(point);
// }
// }
// });
// }
// });
// that.getLocation();
},
methods: {
/*定位*/
getLocation: function() {
var that = this;
uni.getLocation({
type: 'wgs84',
success: function(res) {
//初始化当前点
var point = {
target: {
latitude: res.latitude,
longitude: res.longitude
}
};
that.currentPoint = point;
// that.latitude = res.latitude;
// that.longitude = res.longitude;
//设置当前点 并逆地址解析和获取任务
that.changeMap(point);
},
fail: function() {
//默认位置
var point = {
target: {
latitude: that.latitude,
longitude: that.longitude
}
};
that.currentPoint = point;
that.changeMap(point);
},
complete: function(e) {}
});
},
/*设置当前点 并逆地址解析和获取任务*/
changeMap: function(e) {
this.page.current = 1;
if (e) {
var point = {
target: {
latitude: e.target.latitude,
longitude: e.target.longitude
}
};
this.currentPoint = point;
this.latitude = e.target.latitude;
this.longitude = e.target.longitude;
this.markList = [];
this.getAddrByPoint(e.target);
this.getData(e.target);
}
},
/*逆地址解析*/
getAddrByPoint: function(point) {
var that = this;
var location = point.latitude + ',' + point.longitude
that.setCurrentMarker(point); //设置当前marker
getcoder(location, encodeURI(that.key), 0).then(res => {
var address = res.data.result.address_component.city + res.data.result.formatted_addresses.recommend;
this.markList.forEach(ele => { //给当前marker添加label
if (ele.id === 0) {
ele.title = address;
ele['callout'] = {
content: address,
color: '#000000',
fontSize: 12,
borderRadius: 2,
borderWidth: 0,
borderColor: '#ffffff',
bgColor: '#ffffff',
padding: '5',
display: 'ALWAYS',
textAlign: 'center'
}
}
})
});
},
/*设置当前定位点marker*/
setCurrentMarker: function(point) {
this.markList.push({
id: 0,
latitude: point.latitude,
longitude: point.longitude,
title: '',
zIndex: 2,
iconPath: '/static/img/location.png',
// width: 20,
// height: 20
})
},
/*设置任务点*/
setmarkers: function() {
// 设置任务点
var inpoints = [];
inpoints.push({
latitude: this.currentPoint.target.latitude,
longitude: this.currentPoint.target.longitude
})
if (this.companyList.length) {
for (var i = 0; i < this.companyList.length && i < 10; i++) {
inpoints.push({
latitude: this.companyList[i].lat,
longitude: this.companyList[i].lon
})
this.markList.push({
id: i + 1,
latitude: this.companyList[i].lat,
longitude: this.companyList[i].lon,
zIndex: 1,
iconPath: '/static/img/point.png',
// width: 30,
// height: 30
})
}
}
this.inpoints = inpoints;
},
goSearch() {
uni.navigateTo({
url: '../seach/placeSearch'
});
},
// search:function(){
// if(this.inputValue){
// this.querySearch(this.inputValue)
// }else{
// return
// }
// },
// //关键词输入提示
// querySearch:function(queryString) {
// querySearch(queryString, encodeURI(this.key)).then(res => {
// if (res.data.status === 0) {
// this.searchResultList = res.data.data;
// if(this.searchResultList.length){
// this.searchResultList.forEach((item, index) => {
// item.title = this.getInf(item.title, this.inputValue);
// });
// }
// }
// });
// },
// // 8-2、选择地址
// handleSelect:function(item) {
// this.page.current=1;
// this.searchResult=false;
// this.inputValue='';
// this.searchResultList = [];
// var point = {
// target:{
// latitude:item.location.lat,
// longitude:item.location.lng
// }
// };
// this.currentPoint = point;
// this.changeMap(point);
// },
// //高亮
// getInf(str, key) {
// if (str && key) {
// let replaceReg = new RegExp(key, 'g')// 匹配关键字正则
// let replaceString = "<span style='color: #1b66ff;'>" + key + "</span>" // 高亮替换
// return str.replace(replaceReg, replaceString);
// }
// },
// cancel:function(){
// this.inputValue = '';
// this.searchResult = false;
// },
getData: function(obj) {
nearMission(this.page.current, this.page.size, obj.latitude, obj.longitude, 50).then(res => {
if (this.page.current === 1) {
this.companyList = [];
}
this.page.current += 1;
this.page.total = res.data.data.total;
if (res.data.data && res.data.data.records.length) {
this.companyList = this.companyList.concat(res.data.data.records);
}
//非上拉加载 即设置任务点
if (obj !== 'upload') {
this.setmarkers();
}
})
},
//上拉加载
upLoad: function() {
if (this.page.current <= Math.ceil(this.page.total / this.page.size)) {
this.getData('upload');
} else {
uni.showToast({
icon: "none",
title: '已经是最后一页',
})
return
}
},
backView: function() {
uni.navigateBack({
delta: 1
});
}
}
};
</script>
<style>
.status_bar {
height: var(--status-bar-height);
width: 100%;
}
.status_bar {
height: var(--status-bar-height);
width: 100%;
}
.locationimg {
width: 40rpx;
height: 40rpx;
position: fixed;
left: 355rpx;
top: 250rpx;
}
.locationimg {
width: 40rpx;
height: 40rpx;
position: fixed;
left: 355rpx;
top: 250rpx;
}
.baddd {
background: #f6f6f6;
height: 20rpx;
}
.baddd {
background: #f6f6f6;
height: 20rpx;
}
.head_border {
width: 60rpx;
height: 8rpx;
border-radius: 30rpx;
margin: 0 auto;
background-color: #ddd;
margin-bottom: 10rpx;
}
.head_border {
width: 60rpx;
height: 8rpx;
border-radius: 30rpx;
margin: 0 auto;
background-color: #ddd;
margin-bottom: 10rpx;
}
.head {
font-family: PingFangSC-Medium;
font-size: 30rpx;
font-weight: bold;
color: #333333;
text-align: center;
height: 50%;
position: relative;
/* border-bottom: 20rpx solid #f6f6f6; */
}
.head {
font-family: PingFangSC-Medium;
font-size: 30rpx;
font-weight: bold;
color: #333333;
text-align: center;
height: 50%;
position: relative;
/* border-bottom: 20rpx solid #f6f6f6; */
}
map {
width: 100%;
height: 100%;
position: relative;
}
map {
width: 100%;
height: 100%;
position: relative;
}
.head .search {
position: absolute;
top: 10rpx;
left: 0;
right: 0;
}
.head .search {
position: absolute;
top: 10rpx;
left: 0;
right: 0;
}
.head .search .controlss {
display: flex;
justify-content: center;
flex-direction: row;
margin: 0rpx 20rpx;
}
.head .search .controlss {
display: flex;
justify-content: center;
flex-direction: row;
margin: 0rpx 20rpx;
}
.head .search .controlss .controlss-back {
display: flex;
justify-content: center;
align-items: center;
margin-right: 20rpx;
padding: 5rpx;
background-color: #ffffff;
}
.head .search .controlss .controlss-back {
display: flex;
justify-content: center;
align-items: center;
margin-right: 20rpx;
padding: 5rpx;
background-color: #ffffff;
}
.head .search .controlss .controlss-input {
flex: 1;
padding: 10rpx 30rpx;
background-color: #ffffff;
border-radius: 200rpx;
display: flex;
align-items: center;
justify-content: flex-start;
}
.head .search .controlss .controlss-input {
flex: 1;
padding: 10rpx 30rpx;
background-color: #ffffff;
border-radius: 200rpx;
display: flex;
align-items: center;
justify-content: flex-start;
}
.head .search .controlss input {
text-align: left;
font-size: 28rpx;
color: rgba(51, 51, 51, 1);
font-weight: normal;
}
.head .search .controlss input {
text-align: left;
font-size: 28rpx;
color: rgba(51, 51, 51, 1);
font-weight: normal;
}
.head .search .controlss image {
width: 40rpx;
height: 40rpx;
}
.head .search .controlss image {
width: 40rpx;
height: 40rpx;
}
.controlsPop {
position: fixed;
bottom: 0;
left: 0;
width: 750rpx;
height: 50%;
background-color: #fefefe;
display: flex;
flex-direction: column;
}
.controlsPop {
position: fixed;
bottom: 0;
left: 0;
width: 750rpx;
height: 50%;
background-color: #fefefe;
display: flex;
flex-direction: column;
}
.controlsPop .listTitle {
padding: 10rpx 20rpx;
font-size: 24rpx;
}
.controlsPop .listTitle {
padding: 10rpx 20rpx;
font-size: 24rpx;
}
.controlsPop .nothingArea {
flex: 1;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}
.controlsPop .nothingArea {
flex: 1;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}
.controlsPop .nothingContnt {
font-family: PingFangSC-Regular;
font-size: 28rpx;
color: #333333;
margin-top: 30rpx;
text-align: center;
}
.controlsPop .nothingContnt {
font-family: PingFangSC-Regular;
font-size: 28rpx;
color: #333333;
margin-top: 30rpx;
text-align: center;
}
.controlsPop .nothing {
width: 400rpx;
height: 200rpx;
display: block;
margin: 0 auto;
}
.controlsPop .nothing {
width: 400rpx;
height: 200rpx;
display: block;
margin: 0 auto;
}
/*
/*
.searchPage .headSearch .search-view {
border-bottom: 1rpx solid #dddddd;
padding: 10rpx 30rpx;
@@ -535,29 +532,29 @@
font-size:32rpx;
} */
.highlight {
color: #1b66ff;
}
.highlight {
color: #1b66ff;
}
.searchPage .search-result li .address {
font-size: 24rpx;
color: #999999
}
.searchPage .search-result li .address {
font-size: 24rpx;
color: #999999
}
.borderbom {
width: 100%;
height: 1rpx;
border-bottom: 1rpx solid #f2f2f2;
}
.borderbom {
width: 100%;
height: 1rpx;
border-bottom: 1rpx solid #f2f2f2;
}
page {
width: 100%;
height: 100%;
}
page {
width: 100%;
height: 100%;
}
.bodys {
width: 100%;
height: 100%;
position: relative;
}
.bodys {
width: 100%;
height: 100%;
position: relative;
}
</style>

View File

@@ -31,13 +31,14 @@
</view>
<view class="conatiner_card">
<view class="row blod fs_34">德阳市智慧就业市场</view>
<view class="row blod fs_34">宜昌市智慧就业市场</view>
<view class="row color_666 fs_30 marT_30">
<u-icon style="margin-right: 10rpx;" name="calendar" color="#666666" size="16"></u-icon>营业时间
<u-icon style="margin-right: 10rpx" name="calendar" color="#666666" size="16"></u-icon>
营业时间
</view>
<view class="row color_666 fs_30">上午9:00-12:00 下午14:00-18:00</view>
<view class="row color_666 fs_30 marT_30">
<u-icon style="margin-right: 10rpx;" name="map" color="#666666" size="16"></u-icon>
<u-icon style="margin-right: 10rpx" name="map" color="#666666" size="16"></u-icon>
四川省德阳市旌阳区天山南路1段108号
<!-- <u-icon style="margin-left: 10rpx;" name="arrow-right" color="#666666" size="16"></u-icon> -->
</view>
@@ -64,164 +65,161 @@
</template>
<script>
export default {
data() {
return {
}
},
methods: {
}
}
export default {
data() {
return {};
},
methods: {},
};
</script>
<style lang="scss" scoped>
@function designTo($num) {
@return ($num / 620rpx) * 750rpx
@function designTo($num) {
@return ($num / 620rpx) * 750rpx;
}
@for $i from 10 to 60 {
.fs_#{$i} {
font-size: #{$i}rpx;
}
}
@for $i from 10 to 60 {
.fs_#{$i} {
font-size : #{$i}rpx;
}
@for $i from 1 to 60 {
.marT_#{$i} {
margin-top: #{$i}rpx;
}
}
@for $i from 1 to 60 {
.marT_#{$i} {
margin-top : #{$i}rpx;
}
}
.color_666 {
color: #666666;
}
.color_666 {
color: #666666;
}
.bold {
font-weight: bold;
}
.bold {
font-weight: bold;
}
image {
width: 100%;
height: 100%;
}
image {
width: 100%;
height: 100%;
}
.app_container {
background-color: #f3f4f8;
min-height: calc(100vh - var(--window-top) - var(--status-bar-height) - var(--window-bottom));
.app_container {
background-color: #f3f4f8;
min-height: calc(100vh - var(--window-top) - var(--status-bar-height) - var(--window-bottom));
.container_head {
min-height: 300rpx;
padding: 28rpx;
background: linear-gradient(to bottom, rgba(69, 112, 250, 1), rgba(69, 112, 250, 0));
.container_head {
min-height: 300rpx;
padding: 28rpx;
background: linear-gradient(to bottom, rgba(69, 112, 250, 1), rgba(69, 112, 250, .0));
.row {
display: flex;
align-content: center;
justify-content: space-between;
.row {
.head_left {
color: #ffffff;
display: flex;
align-content: center;
justify-content: space-between;
align-items: flex-start;
flex-direction: column;
.head_left {
color: #FFFFFF;
.left_title {
}
.left_content {
height: designTo(87rpx);
width: designTo(313rpx);
background-color: rgba(69, 104, 252, 0.4);
border-radius: 20rpx;
margin-top: 20rpx;
display: flex;
align-items: flex-start;
flex-direction: column;
justify-content: space-around;
align-items: center;
flex-wrap: nowrap;
.left_title {}
.left_content {
height: designTo(87rpx);
width: designTo(313rpx);
background-color: rgba(69, 104, 252, 0.4);
border-radius: 20rpx;
margin-top: 20rpx;
display: flex;
justify-content: space-around;
align-items: center;
flex-wrap: nowrap;
.content_item {
text-align: center;
white-space: nowrap;
}
.content_item {
text-align: center;
white-space: nowrap;
}
}
.head_right {
width: designTo(220rpx);
height: designTo(148rpx);
border-radius: 20rpx;
overflow: hidden;
}
}
.broadcast {
margin-top: designTo(65rpx);
height: designTo(77rpx);
background-color: rgba(244, 230, 224, 1);
.head_right {
width: designTo(220rpx);
height: designTo(148rpx);
border-radius: 20rpx;
display: flex;
justify-content: space-between;
align-items: center;
padding: 0 24rpx;
.cast-l {
font-size: 32rpx;
display: flex;
}
overflow: hidden;
}
}
.conatiner_card {
margin: 28rpx;
background-color: #FFFFFF;
height: fit-content;
.broadcast {
margin-top: designTo(65rpx);
height: designTo(77rpx);
background-color: rgba(244, 230, 224, 1);
border-radius: 20rpx;
padding: designTo(28rpx);
.row {
display: flex;
align-items: center;
}
.column {
padding: 10rpx 20rpx;
border-radius: 40rpx;
background-color: #f3f4f8;
}
}
.container_chioe {
position: fixed;
bottom: 0;
left: 0;
right: 0;
display: flex;
justify-content: space-around;
justify-content: space-between;
align-items: center;
background-color: #FFFFFF;
height: designTo(108rpx);
padding: 0 28rpx designTo(30rpx) 28rpx;
padding: 0 24rpx;
.chioe_share {
.cast-l {
font-size: 32rpx;
display: flex;
align-items: center;
flex-direction: column;
justify-content: center;
}
.chioe_btn {
color: #FFFFFF;
background: linear-gradient(to right, #fbaf1a, #fbaf1a);
height: designTo(66rpx);
width: designTo(228rpx);
text-align: center;
line-height: designTo(66rpx);
border-radius: designTo(33rpx);
}
.btn_Blue {
background: linear-gradient(to right, #95aefb, #4b74f7);
}
}
}
.conatiner_card {
margin: 28rpx;
background-color: #ffffff;
height: fit-content;
border-radius: 20rpx;
padding: designTo(28rpx);
.row {
display: flex;
align-items: center;
}
.column {
padding: 10rpx 20rpx;
border-radius: 40rpx;
background-color: #f3f4f8;
}
}
.container_chioe {
position: fixed;
bottom: 0;
left: 0;
right: 0;
display: flex;
justify-content: space-around;
align-items: center;
background-color: #ffffff;
height: designTo(108rpx);
padding: 0 28rpx designTo(30rpx) 28rpx;
.chioe_share {
display: flex;
align-items: center;
flex-direction: column;
justify-content: center;
}
.chioe_btn {
color: #ffffff;
background: linear-gradient(to right, #fbaf1a, #fbaf1a);
height: designTo(66rpx);
width: designTo(228rpx);
text-align: center;
line-height: designTo(66rpx);
border-radius: designTo(33rpx);
}
.btn_Blue {
background: linear-gradient(to right, #95aefb, #4b74f7);
}
}
}
</style>

View File

@@ -6,13 +6,12 @@
<image v-else src="../../static/img/head.svg" mode=""></image>
<view class="userRight">
<view class="userTel" v-if="userInfo.user_name">
{{ auth.authInfo.realName ? auth.authInfo.realName : phoneFilter(userInfo.user_name) }}
{{ auth.authInfo.realName ? auth.authInfo.realName :
phoneFilter(userInfo.user_name) }}
</view>
<view class="userTel" v-else></view>
<view class="userTel" v-else> </view>
<view class="userContent">
<view style="margin-right: 40rpx">
实名认证{{ auth.realNameState ? '已认证' : '未认证' }}
</view>
<view style="margin-right: 40rpx;">实名认证{{ auth.realNameState ? '已认证' : '未认证' }}</view>
<!-- <view>银行卡核验{{auth.bankCardState?'已认证':'未认证'}}</view> -->
</view>
</view>
@@ -40,7 +39,7 @@
</view> -->
</view>
</view>
<view style="height: 104rpx"></view>
<view style="height: 104rpx;"></view>
<!-- <view class="federation">
<view>新业态职工工会联合会</view>
<view v-if="!federationStatus" class="forMembership" @click="go('/pageMy/federation/forMembership/Notice')">申请入会</view>
@@ -78,11 +77,6 @@
投诉建议
<image src="../../static/img/right.svg" mode=""></image>
</view>
<view class="btnList">
<image src="../../static/img/vip.svg" mode=""></image>
消息提醒
<switch class="imgswitch" :checked="user.isEnbleNotice" @change="switch1Change" />
</view>
<template v-if="user.userIsCms">
<view class="btnList" @click="navTo('/pageMy/admin/check')">
<image src="../../static/img/check1.png" mode=""></image>
@@ -119,249 +113,235 @@
<!-- <view class="btn-out" @click="logout">
退出登录
</view> -->
<view class="bottom" @click="makePhoneCall">
<!-- <view class="bottom" @click="makePhoneCall">
<view>德阳市人社局 电话0838-2505580</view>
<view>地址德阳市旌阳区天山南路1段-102</view>
</view>
</view> -->
<cs-button></cs-button>
</view>
</template>
<script>
import { GoLogin } from '@/untils/AxiosUtils.js';
import { mapState, mapGetters } from 'vuex';
import { phoneFilter, stringFilterNum } from '@/untils/format.js';
import { labourUnionInfo } from '@/api/federation.js';
export default {
data() {
return {
federationStatus: false,
};
},
onLoad() {
// this.$store.dispatch('getMobileIsCms')
// if (this.$api.haslogin() && this.authPass) {
// this.$store.dispatch('getVipCode')
// }
},
onShow() {
if (/token/g.test(location.href)) {
this.$api.sleep(2000).then(() => {
if (!this.$api.haslogin()) {
GoLogin();
} else {
uni.$emit('newsReadChange');
this.$store.dispatch('refreshAuthState');
}
});
} else {
if (!this.$api.haslogin()) {
GoLogin();
} else {
uni.$emit('newsReadChange');
this.$store.dispatch('refreshAuthState');
}
}
// this.labourUnionInfoInit()
},
methods: {
switch1Change(e) {
if (e.detail.value) {
this.$store.dispatch('setNoticeOpen');
} else {
this.$store.dispatch('setNoticeClose');
}
},
labourUnionInfoInit() {
labourUnionInfo().then((e) => {
this.federationStatus = e.data.data.joined;
});
},
// logout() {
// this.$store.dispatch('LogOut').then(() => {
// // uni.reLaunch({
// // url: '/pages/login/login'
// // })
// this.$store.dispatch('clearAuthState')
// this.$store.dispatch('endRefreshNewsTimer')
// location.href = "https://dy12333.org.cn/h5/"
// })
// },
go(url) {
uni.navigateTo({
url,
});
},
makePhoneCall: function () {
uni.makePhoneCall({
phoneNumber: '18500206848',
});
},
import {
mapState,
mapGetters
} from 'vuex'
import {
phoneFilter,
stringFilterNum,
},
computed: {
...mapState(['user']),
...mapGetters(['userInfo', 'auth', 'authPass']),
},
};
stringFilterNum
} from '@/untils/format.js'
import {
labourUnionInfo
} from '@/api/federation.js'
export default {
data() {
return {
federationStatus: false
}
},
onLoad() {
this.$store.dispatch('getMobileIsCms')
// if (this.$store.state.user.token && this.authPass) {
// this.$store.dispatch('getVipCode')
// }
},
onShow() {
if (!this.$store.state.user.token) {
uni.redirectTo({
url: '/pages/login/login'
})
} else {
uni.$emit('newsReadChange')
this.$store.dispatch('refreshAuthState')
}
// this.labourUnionInfoInit()
},
methods: {
labourUnionInfoInit() {
labourUnionInfo().then(e => {
this.federationStatus = e.data.data.joined
})
},
// logout() {
// this.$store.dispatch('LogOut').then(() => {
// // uni.reLaunch({
// // url: '/pages/login/login'
// // })
// this.$store.dispatch('clearAuthState')
// this.$store.dispatch('endRefreshNewsTimer')
// location.href = "https://dy12333.org.cn/h5/"
// })
// },
go(url) {
uni.navigateTo({
url
})
},
makePhoneCall: function() {
uni.makePhoneCall({
phoneNumber: "18500206848"
})
},
phoneFilter,
stringFilterNum
},
computed: {
...mapState(['user']),
...mapGetters(['userInfo', 'auth', 'authPass'])
}
}
</script>
<style>
page {
height: 100%;
background: #f6f6f6;
}
page {
height: 100%;
background: #f6f6f6;
}
.federation {
height: 48rpx;
border-radius: 10rpx;
padding: 28rpx 30rpx;
margin: 30rpx;
font-size: 32rpx;
font-weight: 400;
color: #6f5931;
display: flex;
justify-content: space-between;
align-items: center;
background: url(../../static/img/my/mybanner.png) no-repeat;
background-size: cover;
}
.federation {
height: 48rpx;
border-radius: 10rpx;
padding: 28rpx 30rpx;
margin: 30rpx;
font-size: 32rpx;
font-weight: 400;
color: #6F5931;
display: flex;
justify-content: space-between;
align-items: center;
background: url(../../static/img/my/mybanner.png) no-repeat;
background-size: cover;
}
.forMembership {
width: 140rpx;
height: 50rpx;
background: linear-gradient(112deg, #efe0bc 0%, #d29a5a 100%, #ddba88 100%);
box-shadow: 0px 0px 2px 1px rgba(231, 174, 85, 0.39);
border-radius: 25rpx;
font-size: 26rpx;
font-weight: 400;
color: #6f5931;
line-height: 48rpx;
text-align: center;
}
.forMembership {
width: 140rpx;
height: 50rpx;
background: linear-gradient(112deg, #EFE0BC 0%, #D29A5A 100%, #DDBA88 100%);
box-shadow: 0px 0px 2px 1px rgba(231, 174, 85, 0.39);
border-radius: 25rpx;
font-size: 26rpx;
font-weight: 400;
color: #6F5931;
line-height: 48rpx;
text-align: center;
}
.bottom {
font-family: PingFangSC-Regular;
font-size: 24rpx;
color: #999999;
/* position: absolute; */
/* bottom: 120rpx; */
/* width: 100%; */
margin: 120rpx 0;
text-align: center;
}
.bottom {
font-family: PingFangSC-Regular;
font-size: 24rpx;
color: #999999;
/* position: absolute; */
/* bottom: 120rpx; */
/* width: 100%; */
margin: 120rpx 0;
text-align: center;
}
.btnList image:last-child {
width: 19rpx;
height: 32rpx;
margin-left: auto;
margin-right: 0;
}
.btnList image:last-child {
width: 19rpx;
height: 32rpx;
margin-left: auto;
margin-right: 0;
}
.imgswitch {
margin-left: auto;
margin-right: 0;
}
.btnList image {
width: 52rpx;
height: 52rpx;
margin-right: 10rpx;
}
.btnList image {
width: 52rpx;
height: 52rpx;
margin-right: 10rpx;
}
.btnList {
font-family: PingFangSC-Regular;
font-size: 32rpx;
color: #333333;
display: flex;
align-items: center;
justify-content: flex-start;
padding: 30rpx 20rpx;
}
.btnList {
font-family: PingFangSC-Regular;
font-size: 32rpx;
color: #333333;
display: flex;
align-items: center;
justify-content: flex-start;
padding: 30rpx 20rpx;
}
.btn {
width: 690rpx;
margin: 0 auto;
border-radius: 15rpx;
background: #fefefe;
}
.btn {
width: 690rpx;
margin: 0 auto;
border-radius: 15rpx;
background: #fefefe;
}
.BarList {
font-family: PingFangSC-Regular;
font-size: 28rpx;
color: #666666;
float: left;
width: 25%;
text-align: center;
padding: 30rpx 0rpx;
}
.BarList {
font-family: PingFangSC-Regular;
font-size: 28rpx;
color: #666666;
float: left;
width: 25%;
text-align: center;
padding: 30rpx 0rpx;
}
.BarList image {
width: 52rpx;
height: 52rpx;
display: block;
margin: 0 auto;
}
.BarList image {
width: 52rpx;
height: 52rpx;
display: block;
margin: 0 auto;
}
.centerBar {
width: 690rpx;
background-color: #fefefe;
border-radius: 15rpx;
overflow: hidden;
position: absolute;
bottom: -70rpx;
left: 30rpx;
}
.centerBar {
width: 690rpx;
background-color: #fefefe;
border-radius: 15rpx;
overflow: hidden;
position: absolute;
bottom: -70rpx;
left: 30rpx;
}
.userContent {
font-family: PingFangSC-Regular;
font-size: 26rpx;
color: #FFFFFF;
display: flex;
}
.userContent {
font-family: PingFangSC-Regular;
font-size: 26rpx;
color: #ffffff;
display: flex;
}
.userTel {
font-family: PingFangSC-Medium;
font-size: 36rpx;
color: #FFFFFF;
}
.userTel {
font-family: PingFangSC-Medium;
font-size: 36rpx;
color: #ffffff;
}
.userRight {
float: left;
height: 50rpx;
line-height: 50rpx;
}
.userRight {
float: left;
height: 50rpx;
line-height: 50rpx;
}
.userTitle image {
width: 100rpx;
height: 100rpx;
margin-right: 20rpx;
float: left;
border-radius: 200rpx;
background-color: rgba(255, 255, 255, .3);
}
.userTitle image {
width: 100rpx;
height: 100rpx;
margin-right: 20rpx;
float: left;
border-radius: 200rpx;
background-color: rgba(255, 255, 255, 0.3);
}
.userTitle {
padding: 0 30rpx;
}
.userTitle {
padding: 0 30rpx;
}
.head {
background-color: #1B66FF;
width: 100%;
height: 200rpx;
padding-top: 200rpx;
position: relative;
}
.head {
background-color: #1b66ff;
width: 100%;
height: 200rpx;
padding-top: 200rpx;
position: relative;
}
.body {
background: #f6f6f6;
height: 100%;
position: relative;
overflow: auto;
}
.body {
background: #f6f6f6;
height: 100%;
position: relative;
overflow: auto;
}
/* .btn-out {
/* .btn-out {
background-color: #fefefe;
margin-top: 20rpx;
padding: 20rpx 0;

View File

@@ -27,9 +27,7 @@
import {
mapGetters
} from 'vuex'
import {
GoLogin
} from '@/untils/AxiosUtils.js';
export default {
data() {
return {
@@ -38,21 +36,14 @@
},
onLoad() {},
onShow() {
if (/token/g.test(location.href)) {
this.$api.sleep(2000).then(() => {
if (!this.$api.haslogin()) {
GoLogin()
} else {
uni.$emit('newsReadChange')
}
if (!this.$store.state.user.token) {
uni.redirectTo({
url: "/pages/login/login"
})
} else {
if (!this.$api.haslogin()) {
GoLogin()
} else {
uni.$emit('newsReadChange')
}
uni.$emit('newsReadChange')
}
console.log(this.news)
},
onPullDownRefresh() {
this.loading = true

View File

@@ -3,16 +3,27 @@
<view class="app-top">
<view class="top-search">
<view class="top-input">
<input class="put" type="text" placeholder-class="put-pla" v-model="searchValue"
placeholder="搜索附近岗位或任务">
<input
class="put"
type="text"
placeholder-class="put-pla"
v-model="searchValue"
placeholder="搜索附近岗位或任务"
/>
<button class="input-btn" @tap="search">搜索</button>
</view>
</view>
</view>
<view class="view-map">
<super-map ref="uMap" style="width: 100%;height: 100%;" :latitude="latitude" :longitude="longitude"
<!-- <super-map ref="uMap" style="width: 100%;height: 100%;" :latitude="latitude" :longitude="longitude"
:zoom="14" :min-zoom="10" :max-zoom="20" @markertap="clickmark" @regionchange="show = false"
:MapUrl="$config.supperMap" :flag-tip="false"></super-map>
:MapUrl="$config.supperMap" :flag-tip="false"></super-map> -->
<zhuo-tianditu-MultiPoint-Mapper
ref="tMap"
@onSelect="clickmark"
:api-key="$config.apiKey"
></zhuo-tianditu-MultiPoint-Mapper>
<!-- <view id="map" ></view> -->
<!-- <map style="width: 100%;height: 100%;" scale="16" :latitude="latitude" :longitude="longitude"
:markers="covers" @markertap="clickmark" @regionchange="show = false"></map> -->
@@ -22,21 +33,22 @@
<swiper-item class="wiperItem">
<view class="swiper-item uni-bg-red">
<view class="item-content">
<view class="content-title"> {{productInfo.missionTitle}} </view>
<view class="content-title">{{ productInfo.missionTitle }}</view>
<view class="color_999999 fs_12 mar_top5">
<uni-icons type="location" color="#999999" size="12"></uni-icons>
{{ productInfo.cityId }} {{productInfo.address}} 距离{{distance}}
{{ productInfo.cityId }} {{ productInfo.address }} 距离{{ distance }}
</view>
<view class="color_999999 fs_12 mar_top5">
<uni-icons type="map-pin-ellipse" color="#999999" size="12"></uni-icons>
招聘时间: {{productInfo.stime}}-{{productInfo.etime}}
招聘时间: {{ productInfo.stime }}-{{ productInfo.etime }}
</view>
<view class="color_999999 fs_12 mar_top5">
<uni-icons type="map-pin-ellipse" color="#999999" size="12"></uni-icons>
{{productInfo.experienceDesc}} | {{education[productInfo.education]}}
{{ productInfo.experienceDesc }} | {{ education[productInfo.education] }}
</view>
<button class="btns" hover-class="active" @tap="openMap">
<image class="btn-img" src="../../static/img/direction2.png" />查看详情
<image class="btn-img" src="../../static/img/direction2.png" />
查看详情
</button>
</view>
</view>
@@ -49,342 +61,357 @@
</template>
<script>
import {
addZeroPrefix,
getDistanceFromLatLonInKm
} from '@/untils/tools.js'
import testData from '@/common/textdata.js';
import {
geQueryJobsByNearby
} from '@/api/map.js'
let taskpoint = require('../../static/img/taskpoint.png');
let gwpoint = require('../../static/img/gwpoint.png');
let mypoint = require('../../static/img/mypoint.png');
export default {
data() {
return {
education: testData.education,
show: false,
ID: 1,
searchValue: '',
latitude: 31.133980,
longitude: 104.404419,
covers: [],
rateValue: 2,
productInfo: {},
};
},
computed: {
distance() {
const {
lon,
lat
} = this.productInfo
if (lon) {
const {
m,
km
} = getDistanceFromLatLonInKm(lat, lon, this.latitude, this.longitude)
return m > 1000 ? `${km.toFixed(2)}km` : `${m.toFixed(2)}m`
}
return '无'
import { addZeroPrefix, getDistanceFromLatLonInKm } from '@/untils/tools.js';
import testData from '@/common/textdata.js';
import { geQueryJobsByNearby } from '@/api/map.js';
import { mapGetters } from 'vuex';
let taskpoint = require('../../static/img/taskpoint.png');
let gwpoint = require('../../static/img/gwpoint.png');
let mypoint = require('../../static/img/mypoint.png');
export default {
data() {
return {
education: testData.education,
show: false,
ID: 1,
searchValue: '',
latitude: 31.13398,
longitude: 104.404419,
covers: [],
rateValue: 2,
productInfo: {},
};
},
computed: {
...mapGetters(['userLocation']),
distance() {
const { lon, lat } = this.productInfo;
if (lon) {
const { m, km } = getDistanceFromLatLonInKm(lat, lon, this.latitude, this.longitude);
return m > 1000 ? `${km.toFixed(2)}km` : `${m.toFixed(2)}m`;
}
return '无';
},
mounted() {
const _this = this
console.log(this.$store.state.user.userLocation)
if (this.$store.state.user.userLocation) {
const {
latitude,
longitude
} = this.$store.state.user.userLocation
},
mounted() {
const _this = this;
uni.getLocation({
type: 'wgs84',
success: function (res) {
console.log(res, '成功获得周边信息');
const { longitude, latitude } = res;
_this.latitude = latitude;
_this.longitude = longitude;
_this.getList(longitude, latitude).then((covers) => {
_this.$refs.uMap.addFeature(covers)
})
} else {
_this.$api.msg('无法获得周边信息')
_this.covers = covers;
_this.$nextTick(() => {
_this.$refs.tMap.addFeature(covers);
});
});
},
fail: function (err) {
console.log(err, '无法获得周边信息');
_this.$api.msg('无法获得周边信息');
},
complete: function (e) {},
});
console.log('userLocation', this.userLocation);
if (this.userLocation) {
const { longitude, latitude } = this.userLocation;
this.$refs.tMap.open(longitude, latitude);
} else {
this.$store.dispatch('getUserLocation');
}
},
onShow() {
// const _this = this
// this.mockGetLocation().then((myPoint) => {
// this.latitude = myPoint.latitude
// this.longitude = myPoint.longitude
// _this.getList(_this.longitude, _this.latitude).then((covers) => {
// _this.$api.msg('成功获得周边信息')
// console.log(covers)
// _this.$refs.uMap.addFeature(covers)
// })
// })
},
methods: {
onSelect(item) {},
openMap(lon, lat) {
//打开地图,并将门店位置传入
// type: post 岗位 mission 任务
switch (this.productInfo.type) {
case 'post':
const no = encodeURIComponent(this.productInfo.id);
uni.navigateTo({
url: `/pages/projectInfo/workInfo?workId=${encodeURIComponent(no)}&isCan=${1}`,
});
break;
case 'mission':
const no1 = encodeURIComponent(this.productInfo.missionNo);
uni.navigateTo({
url: `/pages/projectInfo/projectInfo?missionNo=${no1}&isCan=${1}`,
});
break;
}
},
onShow() {
// const _this = this
// this.mockGetLocation().then((myPoint) => {
// this.latitude = myPoint.latitude
// this.longitude = myPoint.longitude
// _this.getList(_this.longitude, _this.latitude).then((covers) => {
// _this.$api.msg('成功获得周边信息')
// console.log(covers)
// _this.$refs.uMap.addFeature(covers)
// })
search() {
const _this = this;
uni.getLocation({
type: 'wgs84',
success: function (res) {
const { longitude, latitude } = res;
_this.latitude = latitude;
_this.longitude = longitude;
_this.getList(longitude, latitude).then((covers) => {
_this.$api.msg('成功获得周边信息');
_this.$refs.uMap.addFeature(covers);
});
},
fail: function (err) {
_this.$api.msg('无法获得周边信息');
},
complete: function (e) {},
});
// this.getList(this.longitude, this.latitude).then((covers) => {
// this.$api.msg('成功获得周边信息')
// console.log(covers)
// this.$refs.uMap.addFeature(covers)
// })
},
methods: {
openMap(lon, lat) {
//打开地图,并将门店位置传入
// type: post 岗位 mission 任务
switch (this.productInfo.type) {
case 'post':
const no = encodeURIComponent(1)
uni.navigateTo({
url: `/pages/projectInfo/workInfo?workId=${encodeURIComponent(no)}&isCan=${1}`
})
break
case 'mission':
const no1 = encodeURIComponent(this.productInfo.missionNo)
uni.navigateTo({
url: `/pages/projectInfo/projectInfo?missionNo=${no1}&isCan=${1}`
})
break
clickmark(cover) {
if (cover.markerId === 1) return;
this.show = true;
this.productInfo = cover.info;
},
mockGetLocation() {
return new Promise((resolve) => {
resolve({
longitude: 104.40632,
latitude: 31.122989,
altitude: null,
accuracy: 25.998,
altitudeAccuracy: null,
heading: null,
speed: null,
errMsg: 'getLocation:ok',
verticalAccuracy: 0,
horizontalAccuracy: 25.998,
});
});
},
async getList(lon, lat) {
return new Promise(async (resolve) => {
let params = {
lon,
lat,
distanceRange: 20,
taskTitle: this.searchValue,
};
let resData = await geQueryJobsByNearby(params);
if (resData.data.code === 200) {
const arr = resData.data.data.map((item) => ({
id: item.id,
longitude: item.lon,
latitude: item.lat,
lon: item.lon,
lat: item.lat,
label: item.missionTitle,
iconPath: item.type === 'post' ? gwpoint : taskpoint,
width: 20,
height: 20,
title: item.missionTitle,
callout: {
content: item.missionTitle,
fontSize: 10,
borderColor: 'blue',
},
info: item,
}));
arr.push({
id: 1,
latitude: lat,
longitude: lon,
iconPath: mypoint,
title: '我的位置',
width: 20,
height: 20,
lon: lat,
lat: lon,
label: '我的位置',
});
resolve(arr);
}
},
search() {
const _this = this
if (this.$store.state.user.userLocation) {
const {
latitude,
longitude
} = this.$store.state.user.userLocation
_this.getList(longitude, latitude).then((covers) => {
_this.$refs.uMap.addFeature(covers)
})
} else {
_this.$api.msg('无法获得周边信息')
}
// this.getList(this.longitude, this.latitude).then((covers) => {
// this.$api.msg('成功获得周边信息')
// console.log(covers)
// this.$refs.uMap.addFeature(covers)
// })
},
clickmark(cover) {
if (cover.markerId === 1) return
this.show = true;
this.productInfo = cover.info
},
mockGetLocation() {
return new Promise((resolve) => {
resolve({
"longitude": 104.40632,
"latitude": 31.122989,
"altitude": null,
"accuracy": 25.998,
"altitudeAccuracy": null,
"heading": null,
"speed": null,
"errMsg": "getLocation:ok",
"verticalAccuracy": 0,
"horizontalAccuracy": 25.998
})
})
},
async getList(lon, lat) {
return new Promise(async (resolve) => {
let params = {
lon,
lat,
distanceRange: 20,
taskTitle: this.searchValue
}
let resData = await geQueryJobsByNearby(params)
if (resData.data.code === 200) {
const arr = resData.data.data.map((item) => ({
id: item.id,
longitude: item.lon,
latitude: item.lat,
iconPath: item.type === 'post' ? gwpoint : taskpoint,
width: 20,
height: 20,
title: item.missionTitle,
callout: {
content: item.missionTitle,
fontSize: 10,
borderColor: 'blue',
},
info: item
}))
arr.push({
id: 1,
latitude: lat,
longitude: lon,
iconPath: mypoint,
title: '我的位置',
width: 20,
height: 20
})
resolve(arr)
}
})
}
}
}
});
},
},
};
</script>
<style lang="scss" scoped>
.color_999999 {
color: #999999;
}
.color_999999 {
color: #999999;
}
.fs_12 {
font-size: 24rpx;
}
.fs_12 {
font-size: 24rpx;
}
.mar_top5 {
margin-top: 10rpx;
}
.mar_top5 {
margin-top: 10rpx;
}
.active {
background: #EAEAEA !important;
color: #AFAFAF;
}
.active {
background: #eaeaea !important;
color: #afafaf;
}
.card_mark {
.mark_l {
width: 56rpx;
height: 28rpx;
border-radius: 12rpx 0 12rpx 12rpx;
background: linear-gradient(157deg, #A043C1 0%, #4133A2 100%);
font-size: 28rpx;
font-family: PingFang-SC-Bold, PingFang-SC;
font-weight: bold;
color: #FFFFFF;
.card_mark {
.mark_l {
width: 56rpx;
height: 28rpx;
border-radius: 12rpx 0 12rpx 12rpx;
background: linear-gradient(157deg, #a043c1 0%, #4133a2 100%);
font-size: 28rpx;
font-family: PingFang-SC-Bold, PingFang-SC;
font-weight: bold;
color: #ffffff;
display: flex;
align-items: center;
justify-content: center;
}
}
.position-bottom {
position: absolute;
left: 0;
right: 0;
height: 406rpx;
bottom: 50rpx;
.uni-margin-wrap {
height: 406rpx;
.swiper {
height: 406rpx;
.wiperItem {
padding-left: 50rpx;
height: 406rpx;
width: 660rpx !important;
.swiper-item {
width: 660rpx;
height: 406rpx;
background: #ffffff;
box-shadow: 0rpx 2rpx 4rpx 0rpx rgba(0, 0, 0, 0.5);
border-radius: 27rpx;
overflow: hidden;
.item-top {
display: flex;
align-content: center;
justify-content: space-between;
.top-img {
width: 215rpx;
height: 120rpx;
}
}
.item-content {
padding: 15rpx 33rpx;
.content-title {
font-size: 32rpx;
}
.btns {
margin-top: 20rpx;
display: flex;
align-items: center;
justify-content: center;
width: 223rpx;
height: 64rpx;
background: linear-gradient(to right, #a043c1 0%, #4133a2 100%);
border-radius: 15rpx;
color: #ffffff;
font-size: 26rpx;
font-weight: 800;
color: #ffffff;
line-height: 64rpx;
.btn-img {
width: 32rpx;
height: 32rpx;
}
}
}
}
}
}
}
}
.app_container {
position: fixed;
left: 0;
top: 0;
right: 0;
bottom: 0;
display: flex;
flex-direction: column;
.app-top {
display: flex;
background: linear-gradient(to right, #e8e8e8, #e8e8e8);
padding-bottom: 16rpx;
padding-top: 24rpx;
.top-search {
position: relative;
width: 100%;
display: flex;
align-items: center;
justify-content: center;
}
}
.position-bottom {
position: absolute;
left: 0;
right: 0;
height: 406rpx;
bottom: 50rpx;
.top-input {
width: 710rpx;
.uni-margin-wrap {
height: 406rpx;
.swiper {
height: 406rpx;
.wiperItem {
padding-left: 50rpx;
height: 406rpx;
width: 660rpx !important;
.swiper-item {
width: 660rpx;
height: 406rpx;
background: #FFFFFF;
box-shadow: 0rpx 2rpx 4rpx 0rpx rgba(0, 0, 0, 0.5);
border-radius: 27rpx;
overflow: hidden;
.item-top {
display: flex;
align-content: center;
justify-content: space-between;
.top-img {
width: 215rpx;
height: 120rpx;
}
}
.item-content {
padding: 15rpx 33rpx;
.content-title {
font-size: 32rpx;
}
.btns {
margin-top: 20rpx;
display: flex;
align-items: center;
justify-content: center;
width: 223rpx;
height: 64rpx;
background: linear-gradient(to right, #A043C1 0%, #4133A2 100%);
border-radius: 15rpx;
color: #FFFFFF;
font-size: 26rpx;
font-weight: 800;
color: #FFFFFF;
line-height: 64rpx;
.btn-img {
width: 32rpx;
height: 32rpx;
}
}
}
}
.put {
padding-left: 30rpx;
height: 72rpx;
background: #ffffff;
border-radius: 36rpx;
}
}
/deep/ .put-pla {
height: 33rpx;
font-size: 24rpx;
font-weight: 400;
color: #999999;
line-height: 33rpx;
}
}
}
.app_container {
position: fixed;
left: 0;
top: 0;
right: 0;
bottom: 0;
display: flex;
flex-direction: column;
.app-top {
display: flex;
background: linear-gradient(to right, #e8e8e8, #e8e8e8);
padding-bottom: 16rpx;
padding-top: 24rpx;
.top-search {
position: relative;
width: 100%;
display: flex;
align-items: center;
justify-content: center;
.top-input {
width: 710rpx;
.put {
padding-left: 30rpx;
height: 72rpx;
background: #FFFFFF;
border-radius: 36rpx;
}
/deep/ .put-pla {
height: 33rpx;
font-size: 24rpx;
font-weight: 400;
color: #999999;
line-height: 33rpx;
}
.input-btn {
position: absolute;
right: 30rpx;
top: 50%;
transform: translate(0, -50%);
color: #FFFFFF;
width: 120rpx;
height: 56rpx;
line-height: 56rpx;
font-size: 28rpx;
background: linear-gradient(157deg, #A043C1 0%, #4133A2 100%);
border-radius: 29rpx;
}
.input-btn {
position: absolute;
right: 30rpx;
top: 50%;
transform: translate(0, -50%);
color: #ffffff;
width: 120rpx;
height: 56rpx;
line-height: 56rpx;
font-size: 28rpx;
background: linear-gradient(157deg, #a043c1 0%, #4133a2 100%);
border-radius: 29rpx;
}
}
}
.view-map {
flex: 1;
}
}
.view-map {
flex: 1;
}
}
</style>

View File

@@ -181,7 +181,7 @@
this.getPolicy()
},
onShow: function() {
if (this.$api.haslogin()) {
if (this.$store.state.user.token) {
this.$store.dispatch('refreshAuthState').then((e) => {
var auth = this.$store.state.auth
if (!auth.bankCardState) {
@@ -202,7 +202,7 @@
},
/*下拉刷新*/
onPullDownRefresh: function() {
if (!this.$api.haslogin()) {
if (!this.$store.state.user.token) {
uni.redirectTo({
url: "/pages/login/login"
});
@@ -455,7 +455,7 @@
}
},
getData: function() {
if (!this.$api.haslogin()) {
if (!this.$store.state.user.token) {
uni.redirectTo({
url: "/pages/login/login"
});
@@ -588,7 +588,7 @@
.positionText {
margin: 0 10rpx;
font-weight: bold;
font-weight: bold;
}
}
@@ -610,8 +610,7 @@
.content {
background-color: #f3f4f8;
padding-top: 20rpx;
/* min-height: 80vh; */
min-height: calc(100vh - var(--window-top) - var(--status-bar-height) - var(--window-bottom));
min-height: 80vh;
}

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

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -1,312 +1,307 @@
<template>
<view class="body">
<CustomNavbar @back="back" titke="申请消息"></CustomNavbar>
<view v-for="(value, key) in messageList" class="newsList" @click="goList(value)" :key="key">
<view class="newsIcon">
<image :src="value.icon" mode=""></image>
<!-- <view v-if="news_recruit.unread[value.id] > 0" class="point"></view> -->
</view>
<view class="newsListRight">
<view class="head">
<view class="head_left">
{{ value.title }}
</view>
<!-- <view class="head_right" v-if="value.data.length > 0">
<view class="body">
<CustomNavbar @back="back" titke="申请消息"></CustomNavbar>
<view v-for="(value, key) in messageList" class="newsList" @click="goList(value)" :key="key">
<view class="newsIcon">
<image :src="value.icon" mode=""></image>
<!-- <view v-if="news_recruit.unread[value.id] > 0" class="point"></view> -->
</view>
<view class="newsListRight">
<view class="head">
<view class="head_left">
{{ value.title }}
</view>
<!-- <view class="head_right" v-if="value.data.length > 0">
{{value.data[0][0][value.prop.time]}}
</view> -->
</view>
<!-- <view class="content" v-if="value.data.length > 0">
</view>
<!-- <view class="content" v-if="value.data.length > 0">
{{value.prop.desc(value)}}
</view> -->
</view>
</view>
<cs-button></cs-button>
<CustomTabbar :currentpage="2"></CustomTabbar>
</view>
</view>
</view>
<cs-button></cs-button>
<CustomTabbar :currentpage="2"></CustomTabbar>
</view>
</template>
<script>
import CustomTabbar from '@/components/CustomTabbar/custom_tabbar.vue'
import CustomNavbar from '@/components/CustomNavbar/navbar.vue';
import CustomTabbar from '@/components/CustomTabbar/custom_tabbar.vue'
import CustomNavbar from '@/components/CustomNavbar/navbar.vue';
export default {
components: {
CustomTabbar,
CustomNavbar
},
data() {
return {
loading: false,
size: 20,
messageList: [{
id: "0",
title: "消息通知",
icon: "../../../static/img/notice.svg",
page: {
current: 0,
size: this.size,
total: this.size,
},
data: [],
prop: {
title: "title",
desc: (value) => {
if (value.data[0]) return value.data[0][0]["desc"];
},
time: "createTime",
isRead: "isRead",
listDesc: "desc",
},
navigateTo(item) {
uni.$once("getNewsDetail", (cb) => {
cb(item);
});
uni.navigateTo({
url: "/pages/news/newsDetail?type=0",
});
},
}
// , {
// id: "1",
// title: "任务申请",
// icon: "../../../static/img/renwu.png",
// page: {
// current: 0,
// size: this.size,
// total: this.size,
// },
// data: [],
// prop: {
// title: "missionTitle",
// desc: (value) => {
// if (value.data[0])
// return `您收到${value.data[0][0]["companyName"]}的任务`;
// },
// time: "createTime",
// isRead: "status",
// listDesc: "companyName",
// },
// navigateTo(item, dispatch) {
// // dispatch("readNew", {
// // key: "1",
// // id: item.id,
// // });
// uni.navigateTo({
// url: `/pages/projectInfo/projectInfo?type=1&missionNo=${encodeURIComponent(
// item.missionNo
// )}&id=${encodeURIComponent(item.id)}`,
// });
// },
// }, {
// id: "1",
// title: "岗位申请",
// icon: "../../../static/img/job_recruit.svg",
// page: {
// current: 0,
// size: this.size,
// total: this.size,
// },
// data: [],
// prop: {
// title: "missionTitle",
// desc: (value) => {
// if (value.data[0])
// return `您收到${value.data[0][0]["companyName"]}的任务`;
// },
// time: "createTime",
// isRead: "status",
// listDesc: "companyName",
// },
// navigateTo(item, dispatch) {
// // dispatch("readNew", {
// // key: "1",
// // id: item.id,
// // });
// uni.navigateTo({
// url: `/pages/projectInfo/projectInfo?type=1&missionNo=${encodeURIComponent(
// item.missionNo
// )}&id=${encodeURIComponent(item.id)}`,
// });
// },
// }, {
// id: "1",
// title: "个体户申请",
// icon: "../../../static/img/own_recruit.svg",
// page: {
// current: 0,
// size: this.size,
// total: this.size,
// },
// data: [],
// prop: {
// title: "missionTitle",
// desc: (value) => {
// if (value.data[0])
// return `您收到${value.data[0][0]["companyName"]}的任务`;
// },
// time: "createTime",
// isRead: "status",
// listDesc: "companyName",
// },
// navigateTo(item, dispatch) {
// // dispatch("readNew", {
// // key: "1",
// // id: item.id,
// // });
// uni.navigateTo({
// url: `/pages/projectInfo/projectInfo?type=1&missionNo=${encodeURIComponent(
// item.missionNo
// )}&id=${encodeURIComponent(item.id)}`,
// });
// },
// },
]
}
},
onLoad() {},
onShow() {
if (!this.$api.haslogin()) {
uni.redirectTo({
url: "/pages/login/login"
})
} else {
uni.$emit('newsReadChange')
}
},
// onPullDownRefresh() {
// this.loading = true
// this.$store.dispatch("newsInit").then(() => {
// this.loading = false
// uni.stopPullDownRefresh();
// }).catch(() => {
// this.loading = false
// uni.stopPullDownRefresh();
// })
// },
methods: {
goList(item) {
// if (item.data.length === 0) {
// uni.showToast({
// title: '暂无消息',
// icon: 'none'
// });
// return
// }
console.log(item.data)
// 任务推送、岗位推送、政策推送
if (item.title == '岗位申请') {
console.log('岗位申请')
uni.navigateTo({
url: './taskProjectList'
})
} else if (item.title == '岗位申请') {
console.log('岗位申请')
uni.navigateTo({
url: './jobProjectList'
})
} else if (item.title == '个体户申请') {
uni.navigateTo({
url: './policyList'
})
} else {
uni.navigateTo({
url: './newsList?type=' + item.id
})
}
},
back() {
uni.reLaunch({
url: '/pages/my/my'
})
},
},
}
export default {
components: { CustomTabbar, CustomNavbar },
data() {
return {
loading: false,
size: 20,
messageList: [{
id: "0",
title: "消息通知",
icon: "../../../static/img/notice.svg",
page: {
current: 0,
size: this.size,
total: this.size,
},
data: [],
prop: {
title: "title",
desc: (value) => {
if (value.data[0]) return value.data[0][0]["desc"];
},
time: "createTime",
isRead: "isRead",
listDesc: "desc",
},
navigateTo(item) {
uni.$once("getNewsDetail", (cb) => {
cb(item);
});
uni.navigateTo({
url: "/pages/news/newsDetail?type=0",
});
},
}
// , {
// id: "1",
// title: "任务申请",
// icon: "../../../static/img/renwu.png",
// page: {
// current: 0,
// size: this.size,
// total: this.size,
// },
// data: [],
// prop: {
// title: "missionTitle",
// desc: (value) => {
// if (value.data[0])
// return `您收到${value.data[0][0]["companyName"]}的任务`;
// },
// time: "createTime",
// isRead: "status",
// listDesc: "companyName",
// },
// navigateTo(item, dispatch) {
// // dispatch("readNew", {
// // key: "1",
// // id: item.id,
// // });
// uni.navigateTo({
// url: `/pages/projectInfo/projectInfo?type=1&missionNo=${encodeURIComponent(
// item.missionNo
// )}&id=${encodeURIComponent(item.id)}`,
// });
// },
// }, {
// id: "1",
// title: "岗位申请",
// icon: "../../../static/img/job_recruit.svg",
// page: {
// current: 0,
// size: this.size,
// total: this.size,
// },
// data: [],
// prop: {
// title: "missionTitle",
// desc: (value) => {
// if (value.data[0])
// return `您收到${value.data[0][0]["companyName"]}的任务`;
// },
// time: "createTime",
// isRead: "status",
// listDesc: "companyName",
// },
// navigateTo(item, dispatch) {
// // dispatch("readNew", {
// // key: "1",
// // id: item.id,
// // });
// uni.navigateTo({
// url: `/pages/projectInfo/projectInfo?type=1&missionNo=${encodeURIComponent(
// item.missionNo
// )}&id=${encodeURIComponent(item.id)}`,
// });
// },
// }, {
// id: "1",
// title: "个体户申请",
// icon: "../../../static/img/own_recruit.svg",
// page: {
// current: 0,
// size: this.size,
// total: this.size,
// },
// data: [],
// prop: {
// title: "missionTitle",
// desc: (value) => {
// if (value.data[0])
// return `您收到${value.data[0][0]["companyName"]}的任务`;
// },
// time: "createTime",
// isRead: "status",
// listDesc: "companyName",
// },
// navigateTo(item, dispatch) {
// // dispatch("readNew", {
// // key: "1",
// // id: item.id,
// // });
// uni.navigateTo({
// url: `/pages/projectInfo/projectInfo?type=1&missionNo=${encodeURIComponent(
// item.missionNo
// )}&id=${encodeURIComponent(item.id)}`,
// });
// },
// },
]
}
},
onLoad() { },
onShow() {
if (!this.$store.state.user.token) {
uni.redirectTo({
url: "/pages/login/login"
})
} else {
uni.$emit('newsReadChange')
}
},
// onPullDownRefresh() {
// this.loading = true
// this.$store.dispatch("newsInit").then(() => {
// this.loading = false
// uni.stopPullDownRefresh();
// }).catch(() => {
// this.loading = false
// uni.stopPullDownRefresh();
// })
// },
methods: {
goList(item) {
// if (item.data.length === 0) {
// uni.showToast({
// title: '暂无消息',
// icon: 'none'
// });
// return
// }
console.log(item.data)
// 任务推送、岗位推送、政策推送
if (item.title == '岗位申请') {
console.log('岗位申请')
uni.navigateTo({
url: './taskProjectList'
})
} else if (item.title == '岗位申请') {
console.log('岗位申请')
uni.navigateTo({
url: './jobProjectList'
})
} else if (item.title == '个体户申请') {
uni.navigateTo({
url: './policyList'
})
} else {
uni.navigateTo({
url: './newsList?type=' + item.id
})
}
},
back() {
uni.reLaunch({ url: '/pages/my/my' })
},
},
}
</script>
<style>
.content {
font-family: PingFangSC-Regular;
font-size: 28rpx;
color: #666666;
width: 560rpx;
overflow: hidden;
white-space: nowrap;
/*不换行*/
text-overflow: ellipsis;
/*超出部分文字以...显示*/
}
.content {
font-family: PingFangSC-Regular;
font-size: 28rpx;
color: #666666;
width: 560rpx;
overflow: hidden;
white-space: nowrap;
/*不换行*/
text-overflow: ellipsis;
/*超出部分文字以...显示*/
}
.head_right {
float: right;
font-family: PingFangSC-Regular;
font-size: 24rpx;
color: #CCCCCC;
}
.head_right {
float: right;
font-family: PingFangSC-Regular;
font-size: 24rpx;
color: #CCCCCC;
}
.head_left {
float: left;
font-family: PingFangSC-Regular;
font-size: 36rpx;
color: #333333;
}
.head_left {
float: left;
font-family: PingFangSC-Regular;
font-size: 36rpx;
color: #333333;
}
.head {
overflow: hidden;
width: 560rpx;
}
.head {
overflow: hidden;
width: 560rpx;
}
.newsListRight {
float: left;
width: 560rpx;
height: 50rpx;
line-height: 50rpx;
padding-left: 30rpx;
}
.newsListRight {
float: left;
width: 560rpx;
height: 50rpx;
line-height: 50rpx;
padding-left: 30rpx;
}
.newsList .newsIcon {
position: relative;
width: 100rpx;
height: 100rpx;
display: inline-block;
float: left;
}
.newsList .newsIcon {
position: relative;
width: 100rpx;
height: 100rpx;
display: inline-block;
float: left;
}
.newsList image {
width: 100rpx;
height: 100rpx;
}
.newsList image {
width: 100rpx;
height: 100rpx;
}
.newsList .point {
position: absolute;
top: 5rpx;
right: 10rpx;
width: 20rpx;
height: 20rpx;
background: red;
border-radius: 50%;
}
.newsList .point {
position: absolute;
top: 5rpx;
right: 10rpx;
width: 20rpx;
height: 20rpx;
background: red;
border-radius: 50%;
}
.newsList {
border-bottom: 1rpx solid #dddddd;
padding-bottom: 30rpx;
padding-right: 30rpx;
padding-top: 30rpx;
padding-left: 30rpx;
overflow: hidden;
display: flex;
align-items: center;
}
.newsList {
border-bottom: 1rpx solid #dddddd;
padding-bottom: 30rpx;
padding-right: 30rpx;
padding-top: 30rpx;
padding-left: 30rpx;
overflow: hidden;
display: flex;
align-items: center;
}
.body {
background-color: #fefefe;
/* padding-left: 30rpx;
.body {
background-color: #fefefe;
/* padding-left: 30rpx;
width: 720rpx; */
}
}
page {
background: #f6f6f6;
}
page {
background: #f6f6f6;
}
</style>

View File

@@ -16,33 +16,84 @@
<u-form-item label="法人身份证号" labelWidth="100" prop="masterIdentity" borderBottom ref="item1">
<u--input v-model="formData.masterIdentity" placeholder="请输入法人身份证号"></u--input>
</u-form-item>
<u-form-item label="所在地区" labelWidth="100" prop="cityId" borderBottom ref="item1"
@click="showAddress = true; hideKeyboard()">
<PickerList placeholder="请选择所在地区" :columns="dic.addressColumn" :visibel="showAddress"
v-model="formData.cityId" @cancel="showAddress = false">
</PickerList>
<u-form-item
label="所属机构"
labelWidth="100"
prop="cityId"
borderBottom
ref="item1"
@click="
showAddress = true;
hideKeyboard();
"
>
<PickerList
placeholder="请选择所属机构"
:columns="dic.addressColumn"
:visibel="showAddress"
v-model="formData.cityId"
@cancel="showAddress = false"
></PickerList>
</u-form-item>
<u-form-item label="详细地址" labelWidth="100" prop="companyAddress" borderBottom ref="item1">
<u--input v-model="formData.companyAddress" placeholder="请输入详细地址"></u--input>
</u-form-item>
<u-form-item label="用工单位性质" labelWidth="100" prop="nature" borderBottom ref="item1"
@click="showJobCompanyNature = true; hideKeyboard()">
<PickerList placeholder="请选择企业性质" :columns="[xzDic]" :visibel="showJobCompanyNature"
labelName="dictValue" valueName="dictKey" v-model="formData.nature"
@cancel="showJobCompanyNature = false">
</PickerList>
<u-form-item
label="用工单位性质"
labelWidth="100"
prop="nature"
borderBottom
ref="item1"
@click="
showJobCompanyNature = true;
hideKeyboard();
"
>
<PickerList
placeholder="请选择企业性质"
:columns="[xzDic]"
:visibel="showJobCompanyNature"
labelName="dictValue"
valueName="dictKey"
v-model="formData.nature"
@cancel="showJobCompanyNature = false"
></PickerList>
</u-form-item>
<u-form-item label="所属行业" labelWidth="100" prop="tradeId" borderBottom ref="item1"
@click="showjobCompanyIndustry = true; hideKeyboard()">
<PickerList placeholder="请选择所属行业" :columns="dic.tradeArr" labelName="name" valueName="id"
:visibel="showjobCompanyIndustry" v-model="formData.tradeId"
@cancel="showjobCompanyIndustry = false">
</PickerList>
<u-form-item
label="所属行业"
labelWidth="100"
prop="tradeId"
borderBottom
ref="item1"
@click="
showjobCompanyIndustry = true;
hideKeyboard();
"
>
<PickerList
placeholder="请选择所属行业"
:columns="dic.tradeArr"
labelName="name"
valueName="id"
:visibel="showjobCompanyIndustry"
v-model="formData.tradeId"
@cancel="showjobCompanyIndustry = false"
></PickerList>
</u-form-item>
<u-form-item label="用工单位介绍" labelWidth="100" labelPosition="top" prop="companyDesc" borderBottom
ref="item1">
<u--textarea v-model="formData.companyDesc" placeholder="请输入用工单位介绍" count
maxlength="200"></u--textarea>
<u-form-item
label="用工单位介绍"
labelWidth="100"
labelPosition="top"
prop="companyDesc"
borderBottom
ref="item1"
>
<u--textarea
v-model="formData.companyDesc"
placeholder="请输入用工单位介绍"
count
maxlength="200"
></u--textarea>
</u-form-item>
</view>
<view class="card">
@@ -59,17 +110,23 @@
<view class="card_title">证件资料</view>
<view class="card_content">
<u-form-item labelWidth="100" prop="identityUrl4Id">
<UploadIdNumber v-model="formData.identityUrl4Id" contentStyle="marginTop: 30rpx"
backImg="/static/img/idcard.png">
</UploadIdNumber>
<UploadIdNumber
v-model="formData.identityUrl4Id"
contentStyle="marginTop: 30rpx"
backImg="/static/img/idcard.png"
></UploadIdNumber>
</u-form-item>
<u-form-item labelWidth="100" prop="identityUrl5Id">
<UploadIdNumber v-model="formData.identityUrl5Id" backImg="/static/img/backidcard1.png">
</UploadIdNumber>
<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/businessLicense.jpg">
</UploadIdNumber>
<UploadIdNumber
v-model="formData.authUrlId"
backImg="/static/img/businessLicense.jpg"
></UploadIdNumber>
</u-form-item>
</view>
</view>
@@ -84,153 +141,149 @@
</template>
<script>
import UploadIdNumber from './uploadIdNumber.vue';
import dic from '@/common/dic.js'
import PickerList from './pickerList.vue';
import {
addInviteCompanyAuth,
getInviteCompanyAuthInfo,
getDictionary2
} from '@/api/userrecruit.js'
import {
mapState
} from 'vuex'
const rules = {
comname: {
type: 'string',
required: true,
message: '请输入用工单位',
trigger: ['change']
import UploadIdNumber from './uploadIdNumber.vue';
import dic from '@/common/dic.js';
import PickerList from './pickerList.vue';
import { addInviteCompanyAuth, getInviteCompanyAuthInfo, getDictionary2 } from '@/api/userrecruit.js';
import { mapState } from 'vuex';
const rules = {
comname: {
type: 'string',
required: true,
message: '请输入用工单位',
trigger: ['change'],
},
companyTid: {
type: 'string',
required: true,
max: 18,
min: 18,
message: '请输入18位统一信用代码',
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 {
components: {
UploadIdNumber,
PickerList,
},
data() {
return {
showAddress: false,
showJobCompanyNature: false,
showjobCompanyIndustry: false,
dic,
xzDic: [],
formData: {},
rules,
};
},
onLoad(options) {
if (options.reviewStatus === '9') {
this.getInfo();
}
this.getDictInfo();
},
computed: {
...mapState({
authInfo: (state) => state.auth.authInfo,
userInfo: (state) => state.user.userInfo,
}),
},
created() {
this.formData.manager = this.authInfo.realName;
this.formData.idNumber = this.authInfo.idNumber;
},
methods: {
hideKeyboard() {
uni.hideKeyboard();
},
companyTid: {
type: 'string',
required: true,
max: 18,
min: 18,
message: '请输入18位统一信用代码',
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 {
components: {
UploadIdNumber,
PickerList
},
data() {
return {
showAddress: false,
showJobCompanyNature: false,
showjobCompanyIndustry: false,
dic,
xzDic: [],
formData: {},
rules
async submit() {
let params = {
...this.formData,
nature: Number(this.formData.nature),
cityId: Number(this.formData.cityId),
tradeId: Number(this.formData.tradeId),
};
},
onLoad(options) {
if (options.reviewStatus === '9') {
this.getInfo()
}
this.getDictInfo()
},
computed: {
...mapState({
authInfo: (state) => state.auth.authInfo,
userInfo: (state) => state.user.userInfo
}),
},
created() {
this.formData.manager = this.authInfo.realName
this.formData.idNumber = this.authInfo.idNumber
},
methods: {
hideKeyboard() {
uni.hideKeyboard()
},
async submit() {
let params = {
...this.formData,
nature: Number(this.formData.nature),
cityId: Number(this.formData.cityId),
tradeId: Number(this.formData.tradeId),
}
const _this = this
this.$refs.formOne.validate().then(async (res) => {
const _this = this;
this.$refs.formOne
.validate()
.then(async (res) => {
let params = {
..._this.formData,
nature: Number(_this.formData.nature),
@@ -238,73 +291,74 @@
tradeId: Number(_this.formData.tradeId),
manager: _this.authInfo.realName,
idNumber: _this.authInfo.idNumber,
companyName: dic.addressColumn[0].filter((item) => item.value == _this
.formData.cityId)[0].label
}
console.log(params)
let resData = await addInviteCompanyAuth(params)
companyName: dic.addressColumn[0].filter((item) => item.value == _this.formData.cityId)[0]
.label,
};
console.log(params);
let resData = await addInviteCompanyAuth(params);
if (resData.data.code === 200) {
uni.navigateBack(1)
uni.navigateBack(1);
_this.$api.sleep(1000).then(() => {
_this.$api.msg('已完成企业信息认证')
})
_this.$api.msg('已完成企业信息认证');
});
}
}).catch(errors => {
})
.catch((errors) => {
if (/[\u4e00-\u9fff]/.test(errors.message)) {
_this.$api.msg(errors.message)
_this.$api.msg(errors.message);
}
})
},
async getInfo() {
let params = {
idNumber: this.authInfo.idNumber
}
let resData = await getInviteCompanyAuthInfo(params)
if (resData.data.code === 200) {
console.log(resData.data.data)
this.formData = {
...resData.data.data,
nature: String(resData.data.data.nature),
cityId: String(resData.data.data.cityId),
tradeId: String(resData.data.data.tradeId),
}
}
},
reset() {
const _this = this
uni.showModal({
content: '重置将清空表单,确定重置吗?',
success() {
_this.formData = {}
},
})
},
async getDictInfo() {
let resData = await getDictionary2()
if (resData.data.code === 200) {
this.xzDic = resData.data.data
}
});
},
async getInfo() {
let params = {
idNumber: this.authInfo.idNumber,
};
let resData = await getInviteCompanyAuthInfo(params);
if (resData.data.code === 200) {
console.log(resData.data.data);
this.formData = {
...resData.data.data,
nature: String(resData.data.data.nature),
cityId: String(resData.data.data.cityId),
tradeId: String(resData.data.data.tradeId),
};
}
},
}
reset() {
const _this = this;
uni.showModal({
content: '重置将清空表单,确定重置吗?',
success() {
_this.formData = {};
},
});
},
async getDictInfo() {
let resData = await getDictionary2();
if (resData.data.code === 200) {
this.xzDic = resData.data.data;
}
},
},
};
</script>
<style lang="scss" scoped>
.content {
padding: 24rpx;
.content {
padding: 24rpx;
.card {
.card_title {
font-weight: bold;
margin-top: 20rpx;
}
.card {
.card_title {
font-weight: bold;
margin-top: 20rpx;
}
.card_content {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}
.card_content {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}
}
}
</style>

View File

@@ -1,77 +1,86 @@
<template>
<view class="content_upload" :style="contentStyle">
<u-upload :fileList="ImgUrl" @afterRead="afterRead" :deletable="true" @delete="deletePic" name="6" :maxCount="1"
:width="width" :height="height">
<image :src="backImg" :style="`width: ${width}px;height: ${height}px;`"></image>
<image class="iconimg" src="/static/img/Takingpictures.png"
:style="`width: ${width/4}px;height: ${width/4}px;`"></image>
<u-upload
:fileList="ImgUrl"
@afterRead="afterRead"
:deletable="true"
@delete="deletePic"
name="6"
:maxCount="1"
:width="width"
:height="height"
>
<image :src="backImg" :style="{ width: width + 'px', height: height + 'px' }"></image>
<image
class="iconimg"
src="/static/img/Takingpictures.png"
:style="{ width: width / 4 + 'px', height: height / 4 + 'px' }"
></image>
</u-upload>
</view>
</template>
<script>
import {
uploadFile
} from '@/api/upload.js'
export default {
name: 'UploadIdNumber',
props: {
backImg: {
type: String,
require: true,
},
value: {
type: String,
default: null
},
width: {
type: Number,
default: 280
},
height: {
type: Number,
default: 150
},
contentStyle: {
type: String,
default: ''
}
import { uploadFile } from '@/api/upload.js';
export default {
name: 'UploadIdNumber',
props: {
backImg: {
type: String,
require: true,
},
computed: {
ImgUrl(val) {
return this.value ? [{
name: 'img.jpg',
url: this.value
}] : []
}
value: {
type: String,
default: null,
},
methods: {
afterRead({
file,
index,
name
}) {
// this.$emit("input", file);
uploadFile(file).then((url) => {
this.$emit("input", url);
})
},
deletePic() {
this.$emit("input", null);
},
}
}
width: {
type: Number,
default: 280,
},
height: {
type: Number,
default: 150,
},
contentStyle: {
type: String,
default: '',
},
},
computed: {
ImgUrl(val) {
return this.value
? [
{
name: 'img.jpg',
url: this.value,
},
]
: [];
},
},
methods: {
afterRead({ file, index, name }) {
// this.$emit("input", file);
uploadFile(file).then((url) => {
this.$emit('input', url);
});
},
deletePic() {
this.$emit('input', null);
},
},
};
</script>
<style scoped>
.content_upload {
position: relative;
}
.content_upload {
position: relative;
}
.iconimg {
position: absolute;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
}
.iconimg {
position: absolute;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
}
</style>

View File

@@ -87,9 +87,10 @@
任务地址{{ info.address }}
</view>
<view class="map">
<super-map ref="uMap" style="width: 100%;height: 100%;" :latitude="latitude" :longitude="longitude"
<!-- <super-map ref="uMap" style="width: 100%;height: 100%;" :latitude="latitude" :longitude="longitude"
:open="true" :zoom="14" :min-zoom="10" :max-zoom="20" :MapUrl="$config.supperMap"
:flag-tip="false"></super-map>
:flag-tip="false"></super-map> -->
<zhuo-tianditu-MultiPoint-Mapper ref="tMap" :api-key="$config.apiKey"></zhuo-tianditu-MultiPoint-Mapper>
</view>
<!-- <map class="map" :latitude="latitude" :longitude="longitude" :markers="covers"></map> -->
</view>
@@ -282,10 +283,23 @@
recruit_missionDetail(self.missionNo, self.type).then(res => {
self.info = res.data.data;
self.status = res.data.data.detailStatus;
self.latitude = self.info.lat;
self.longitude = self.info.lon;
self.covers[0].latitude = self.info.lat;
self.covers[0].longitude = self.info.lon;
// self.latitude = self.info.lat;
// self.longitude = self.info.lon;
// self.covers[0].latitude = self.info.lat;
// self.covers[0].longitude = self.info.lon;
this.$refs.tMap.open(self.info.lon, self.info.lat)
if (self.info.lon > 1 && self.info.lat > 1) {
self.$nextTick(() => {
self.$api.sleep(1000).then(() => {
this.$refs.tMap.addFeature([{
id: self.info.id,
label: self.info.missionTitle,
lat: self.info.lat,
lon: self.info.lon,
}])
})
})
}
self.showDetail = true;
if (self.type === 1) {
// 设置已读

View File

@@ -7,27 +7,45 @@
<!-- <view class="prolist">
任务编码{{info.missionNo}}
</view> -->
<view class="prolist">发布日期{{ info.stime ? dateFormat(info.stime) : null }}</view>
<view class="prolist">招聘人数{{ info.peopleNum }}</view>
<view class="prolist">行业类型{{ info.tradeNames ? info.tradeNames : info.jobCompanyIndustry }}</view>
<view class="prolist">工种类型{{ info.skillNames }}</view>
<view class="prolist">
发布日期{{ info.stime ? dateFormat((info.stime)) : null }}
</view>
<view class="prolist">
招聘人数{{ info.peopleNum }}
</view>
<view class="prolist">
行业类型{{ info.tradeNames ? info.tradeNames : info.jobCompanyIndustry }}
</view>
<view class="prolist">
工种类型{{ info.skillNames }}
</view>
<!-- <view class="fee">
{{info.wage}}{{wageUnit[info.wageUnitCategory]}}
</view> -->
</view>
<view class="head">
<view class="proname proneed">招工要求</view>
<view class="proname proneed">
招工要求
</view>
<!-- <view class="prolist">
<view class="protype">
年龄要求{{age[info.ageDesc]}}
</view>
</view> -->
<view class="prolist">
<view class="protype">学历要求{{ info.education }}</view>
<view class="protype">经验要求{{ info.experienceDesc }}</view>
<view class="protype">
学历要求{{ info.education }}
</view>
<view class="protype">
经验要求{{ info.experienceDesc }}
</view>
</view>
<view class="prolist">
招工地址{{ info.jobAddress }}
</view>
<view class="prolist proint" style="font-weight: bold;color:#333;">
招工描述
</view>
<view class="prolist">招工地址{{ info.jobAddress }}</view>
<view class="prolist proint" style="font-weight: bold; color: #333">招工描述</view>
<view class="prolist description">
{{ info.jobDescription }}
</view>
@@ -52,17 +70,16 @@
<!-- <view class="prolist">
用工单位{{info.jobCompanyName}}
</view> -->
<view style="display: flex; align-items: center">
<image
src="../../../../static/img/city.png"
style="width: 40rpx; height: 40rpx; margin-right: 20rpx"
mode=""
></image>
<view style="font-size: 30rpx">{{ info.jobCompanyName }}</view>
<view style="display: flex;align-items: center;">
<image src="../../../../static/img/city.png" style="width: 40rpx;height: 40rpx;margin-right: 20rpx;"
mode=""></image>
<view style="font-size: 30rpx;">{{ info.jobCompanyName }}</view>
</view>
</view>
<view class="head">
<view class="proname proneed">地址</view>
<view class="proname proneed">
地址
</view>
<!-- <view class="prolist">
<view class="protype">
联系人{{info.callName}}
@@ -74,48 +91,39 @@
<!-- <view class="prolist" v-if="info.callNumber">
座机号{{info.callNumber}}
</view> -->
<view class="prolist">岗位地址{{ info.address }}</view>
<view class="prolist">
岗位地址{{ info.address }}
</view>
<view class="map">
<super-map
ref="uMap"
style="width: 100%; height: 100%"
:latitude="latitude"
:longitude="longitude"
:open="true"
:zoom="14"
:min-zoom="10"
:max-zoom="20"
:MapUrl="$config.supperMap"
:flag-tip="false"
></super-map>
<!-- <super-map ref="uMap" style="width: 100%;height: 100%;" :latitude="latitude" :longitude="longitude"
:open="true" :zoom="14" :min-zoom="10" :max-zoom="20" :MapUrl="$config.supperMap"
:flag-tip="false"></super-map> -->
<zhuo-tianditu-MultiPoint-Mapper ref="tMap" :api-key="$config.apiKey"></zhuo-tianditu-MultiPoint-Mapper>
</view>
<!-- <map class="map" :latitude="latitude" :longitude="longitude" :markers="covers"></map> -->
</view>
<view class="" style="height: 200rpx; background-color: #f6f6f6" v-if="isShow !== '0'"></view>
<view class="" style="height:200rpx;background-color: #f6f6f6;" v-if="isShow !== '0'"></view>
<view class="btn">
<view
@click="callPhone"
class="bottombtn flexbtn"
style="margin-right: 10rpx; background-color: #fbad17; border-radius: 45rpx"
>
<view @click="callPhone" class="bottombtn flexbtn"
style="margin-right: 10rpx;background-color: #FBAD17;border-radius: 45rpx;">
电话联系
</view>
</view>
<uniMask :maskShow="maskShow">
<view class="contractMask">
<!-- #ifdef H5 || APP-PLUS -->
<view class="close" @click="close" style="top: 124rpx">+</view>
<view class="close" @click="close" style="top: 124rpx;">+</view>
<!-- #endif -->
<!-- #ifdef MP-WEIXIN -->
<view class="close" @click="close">+</view>
<!-- #endif -->
<view style="height: 30px"></view>
<img :src="src" alt="" style="width: 100%; height: 1000px" />
<view style="height: 30px;"></view>
<img :src="src" alt="" style="width:100%;height: 1000px;">
<view v-if="nextBtn" class="down" @click="next">下一步</view>
</view>
</uniMask>
<u-popup closeable :show="showPopUp" mode="bottom" @close="closePopUp">
<view style="min-height: 100rpx; padding: 60rpx 40rpx">
<view style="min-height: 100rpx;padding: 60rpx 40rpx;">
<view class="contactWrapper" v-for="(item, index) in info.applyList" :key="index">
<view>{{ item.realName }} : {{ item.telphone }}</view>
<view class="applyTime">申请时间{{ item.applyTime }}</view>
@@ -126,7 +134,7 @@
<view v-else-if="showCode" class="codeSealBox">
<!-- #ifdef H5 || APP-PLUS -->
<view class="closeCode" @click="closeShowCode" style="top: 124rpx">+</view>
<view class="closeCode" @click="closeShowCode" style="top: 124rpx;">+</view>
<!-- #endif -->
<!-- #ifdef MP-WEIXIN -->
<view class="closeCode" @click="closeShowCode">+</view>
@@ -136,390 +144,413 @@
<view class="name">签名密码</view>
<view class="tip">6位数字签名密码</view>
</view>
<view style="height: 36px"></view>
<view style="height: 36px;"></view>
<valid-code ref="validCode" @finish="getInpCode" :maxlength="maxlength"></valid-code>
<view style="height: 36px"></view>
<view style="height: 36px;"></view>
<view class="forget" @click="forget">忘记密码</view>
</view>
</template>
<script>
import { mapGetters } from 'vuex';
import { recruit_missionDetail } from '@/api/mission.js';
import { GoLogin } from '@/untils/AxiosUtils.js';
import { setRead } from '@/api/news.js';
import { checkPass, getPhoneCountNumber } from '@/api/auth.js';
import dictionary from '@/common/textdata.js';
import { dateFormat } from '../../../../untils/format.js';
import uniMask from '@/components/uni-mask/mask.vue';
import validCode from '@/components/p-valid-code/p-valid-code.vue';
import { getuserrecruitDetailApp } from '@/api/userrecruit.js';
export default {
data() {
return {
...dictionary,
info: {},
status: null,
showDetail: false,
showCode: false,
maskShow: false,
nextBtn: false,
loading: false,
latitude: 39.909, //中心点
longitude: 116.39742,
covers: [
{
//marker标记位置
import {
mapGetters
} from 'vuex'
import {
recruit_missionDetail,
} from '@/api/mission.js';
import {
GoLogin
} from '@/untils/AxiosUtils.js';
import {
setRead
} from '@/api/news.js';
import {
checkPass
} from '@/api/auth.js';
import dictionary from '@/common/textdata.js';
import {
dateFormat
} from "../../../../untils/format.js";
import uniMask from '@/components/uni-mask/mask.vue'
import validCode from '@/components/p-valid-code/p-valid-code.vue'
import {
getuserrecruitDetailApp
} from '@/api/userrecruit.js'
export default {
data() {
return {
...dictionary,
info: {},
status: null,
showDetail: false,
showCode: false,
maskShow: false,
nextBtn: false,
loading: false,
latitude: 39.909, //中心点
longitude: 116.39742,
covers: [{ //marker标记位置
id: 0,
latitude: 0,
longitude: 0,
// width:30,
// height:30,
iconPath: '../../../../static/img/location.png',
},
],
missionNo: '',
isShow: '',
type: '',
id: '',
src: 'https://jlfiles.oss-cn-zhangjiakou.aliyuncs.com/jobslink-api/doc/%E7%94%B5%E5%AD%90%E5%90%88%E5%90%8C%E9%A2%84%E8%A7%88%E5%9B%BE%E7%89%87.png',
maxlength: 6,
collectStatus: 0, // 收藏状态
showPopUp: false,
jobType: null,
};
},
components: {
uniMask,
validCode,
},
onLoad: function (option) {
//option为object类型会序列化上个页面传递的参数
// this.$store.dispatch('setAutograph')
if (option.workId) {
this.workId = decodeURIComponent(option.workId);
}
if (option.isCan) {
this.isShow = option.isCan; //isShow为'0'则为我的任务、我的评价过来的,需要隐藏抢任务按钮
}
if (option.type) {
this.type = option.type; //type为1则为消息邀请过来的,需要设置消息已读;
}
if (option.id) {
this.id = option.id; //消息id
}
if (option.jobType) {
this.jobType = option.jobType;
}
},
onShow: function () {
this.showDetail = true;
this.getData();
},
onShareAppMessage(obj) {
return {
title: this.info.missionTitle,
path: `/pages/projectInfo/projectInfo?missionNo=${this.info.missionNo}`,
};
},
methods: {
dateFormat,
async callPhone() {
this.showPopUp = true;
await getPhoneCountNumber();
iconPath: '../../../../static/img/location.png'
}],
missionNo: "",
isShow: '',
type: '',
id: '',
src: 'https://jlfiles.oss-cn-zhangjiakou.aliyuncs.com/jobslink-api/doc/%E7%94%B5%E5%AD%90%E5%90%88%E5%90%8C%E9%A2%84%E8%A7%88%E5%9B%BE%E7%89%87.png',
maxlength: 6,
collectStatus: 0, // 收藏状态
showPopUp: false,
jobType: null
}
},
components: {
uniMask,
validCode
},
onLoad: function(option) { //option为object类型会序列化上个页面传递的参数
// this.$store.dispatch('setAutograph')
if (option.workId) {
this.workId = decodeURIComponent(option.workId);
}
if (option.isCan) {
this.isShow = option.isCan; //isShow为'0'则为我的任务、我的评价过来的,需要隐藏抢任务按钮
}
if (option.type) {
this.type = option.type; //type为1则为消息邀请过来的,需要设置消息已读;
}
if (option.id) {
this.id = option.id; //消息id
}
if (option.jobType) {
this.jobType = option.jobType
}
},
onShow: function() {
this.showDetail = true
this.getData();
this.showPopUp = true;
},
closePopUp() {
this.showPopUp = false;
},
async getData() {
const self = this;
let resData = null;
if (this.jobType) {
resData = await getuserrecruitDetailApp({
id: this.id,
jobType: this.jobType,
});
} else {
resData = await recruit_missionDetail(self.workId, self.type);
}
if (resData.data?.code === 200) {
self.info = resData.data.data;
self.status = resData.data.data.status;
self.missionNo = resData.data.data.missionNo;
self.latitude = self.info.lat;
self.longitude = self.info.lon;
self.covers[0].latitude = self.info.lat;
self.covers[0].longitude = self.info.lon;
self.showDetail = true;
onShareAppMessage(obj) {
return {
title: this.info.missionTitle,
path: `/pages/projectInfo/projectInfo?missionNo=${this.info.missionNo}`
}
},
// 查看合同
lookMask() {
this.maskShow = true;
},
// 关闭弹窗
close() {
this.maskShow = false;
},
// 合同下一步
next() {
this.maskShow = false;
this.showDetail = false;
this.showCode = true;
},
// 输入签名密码
getInpCode(password) {
uni.showLoading({
title: '请求中...',
});
this.loading = true;
var obj = {
pass: password,
};
checkPass(obj)
.then((res) => {
this.submitTask();
this.closeShowCode();
methods: {
dateFormat,
callPhone() {
this.showPopUp = true;
},
closePopUp() {
this.showPopUp = false;
},
async getData() {
const self = this;
let resData = null
if (this.jobType) {
resData = await getuserrecruitDetailApp({
id: this.id,
jobType: this.jobType
})
} else {
resData = await recruit_missionDetail(self.workId, self.type)
}
if (resData.data?.code === 200) {
self.info = resData.data.data;
self.status = resData.data.data.status;
self.missionNo = resData.data.data.missionNo;
// self.latitude = self.info.lat;
// self.longitude = self.info.lon;
// self.covers[0].latitude = self.info.lat;
// self.covers[0].longitude = self.info.lon;
this.$refs.tMap.open(self.info.lon, self.info.lat)
if (self.info.lon > 1 && self.info.lat > 1) {
self.$nextTick(() => {
self.$api.sleep(1000).then(() => {
this.$refs.tMap.addFeature([{
id: self.info.id,
label: self.info.jobName,
lat: self.info.lat,
lon: self.info.lon,
}])
})
})
}
self.showDetail = true;
}
},
// 查看合同
lookMask() {
this.maskShow = true
},
// 关闭弹窗
close() {
this.maskShow = false
},
// 合同下一步
next() {
this.maskShow = false
this.showDetail = false
this.showCode = true
},
// 输入签名密码
getInpCode(password) {
uni.showLoading({
title: "请求中..."
})
this.loading = true
var obj = {
pass: password
}
checkPass(obj).then(res => {
this.submitTask()
this.closeShowCode()
}).catch(err => {
this.loading = false
})
},
// 关闭签名密码弹窗
closeShowCode() {
this.showCode = false
this.showDetail = true
},
// 忘记密码
forget() {
uni.navigateTo({
url: `/pageMy/setUserBase/seal/forget?forget=true`
})
.catch((err) => {
this.loading = false;
});
},
// 关闭签名密码弹窗
closeShowCode() {
this.showCode = false;
this.showDetail = true;
},
// 忘记密码
forget() {
uni.navigateTo({
url: `/pageMy/setUserBase/seal/forget?forget=true`,
});
},
},
computed: {
...mapGetters(['auth', 'autograph']),
skillNames() {
if (this.info.skillNames) {
return this.info.skillNames.split(',');
}
},
},
};
computed: {
...mapGetters(['auth', 'autograph']),
skillNames() {
if (this.info.skillNames) {
return this.info.skillNames.split(',')
}
}
}
}
</script>
<style lang="scss">
.codeSealBox {
padding: 285rpx 72rpx 0 72rpx;
.codeSealBox {
padding: 285rpx 72rpx 0 72rpx;
.closeCode {
position: absolute;
right: 36rpx;
top: 120rpx;
color: #1B66FF;
transform: rotate(45deg);
font-size: 40px;
}
.title {
display: flex;
align-items: center;
}
.name {
height: 46rpx;
font-size: 46rpx;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #333333;
line-height: 46rpx;
margin-right: 28rpx;
}
.tip {
height: 38rpx;
font-size: 28rpx;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #999999;
line-height: 38rpx;
}
.forget {
height: 38rpx;
font-size: 28rpx;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #5AA0FA;
line-height: 38rpx;
text-align: right;
}
.closeCode {
position: absolute;
right: 36rpx;
top: 120rpx;
color: #1b66ff;
transform: rotate(45deg);
font-size: 40px;
}
.title {
display: flex;
align-items: center;
.contractMask {
background-color: #FFFFFF;
margin: 30rpx;
position: relative;
border-radius: 4px;
height: 96%;
overflow: auto;
.close {
width: 23px;
height: 23px;
color: #1B66FF;
position: fixed;
right: 60rpx;
top: 60rpx;
transform: rotate(45deg);
font-size: 40px;
}
.down {
position: fixed;
bottom: 30px;
left: 14%;
width: 545rpx;
height: 90rpx;
line-height: 90rpx;
text-align: center;
background: #1B66FF;
font-size: 36rpx;
font-weight: 400;
color: #FFFFFF;
}
}
.name {
height: 46rpx;
font-size: 46rpx;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #333333;
line-height: 46rpx;
margin-right: 28rpx;
.lookContract {
width: 30%;
margin-right: 30rpx;
}
.tip {
height: 38rpx;
font-size: 28rpx;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #999999;
line-height: 38rpx;
.flexbtn {
flex: 1;
}
.forget {
height: 38rpx;
font-size: 28rpx;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #5aa0fa;
line-height: 38rpx;
text-align: right;
}
}
.contractMask {
background-color: #ffffff;
margin: 30rpx;
position: relative;
border-radius: 4px;
height: 96%;
overflow: auto;
.close {
width: 23px;
height: 23px;
color: #1b66ff;
position: fixed;
right: 60rpx;
top: 60rpx;
transform: rotate(45deg);
font-size: 40px;
}
.down {
position: fixed;
bottom: 30px;
left: 14%;
width: 545rpx;
.bottombtn {
background-color: #1B66FF;
color: #fff;
text-align: center;
border-radius: 10rpx;
font-family: PingFangSC-Medium;
font-size: 32rpx;
height: 90rpx;
line-height: 90rpx;
text-align: center;
background: #1b66ff;
font-size: 36rpx;
font-weight: 400;
color: #ffffff;
}
}
.lookContract {
width: 30%;
margin-right: 30rpx;
}
.btn {
background-color: #fefefe;
width: 690rpx;
padding: 30rpx;
padding-bottom: 80rpx;
position: fixed;
bottom: 0;
left: 0;
display: flex;
}
.flexbtn {
flex: 1;
}
.disabledBtn {
background-color: #c8c9cc;
}
.bottombtn {
background-color: #1b66ff;
color: #fff;
text-align: center;
border-radius: 10rpx;
font-family: PingFangSC-Medium;
font-size: 32rpx;
height: 90rpx;
line-height: 90rpx;
}
.map {
width: 100%;
height: 350rpx;
margin-top: 30rpx;
}
.btn {
background-color: #fefefe;
width: 690rpx;
padding: 30rpx;
padding-bottom: 80rpx;
position: fixed;
bottom: 0;
left: 0;
display: flex;
}
.askList {
font-family: PingFangSC-Regular;
font-size: 24rpx;
color: #666666;
background-color: #f6f6f6;
padding: 5rpx 15rpx;
margin-right: 10rpx;
margin-top: 15rpx;
}
.disabledBtn {
background-color: #c8c9cc;
}
.ask {
overflow: hidden;
width: 100%;
display: flex;
align-items: center;
flex-wrap: wrap;
justify-content: flex-start;
margin: 20rpx 0;
.map {
width: 100%;
height: 350rpx;
margin-top: 30rpx;
}
}
.askList {
font-family: PingFangSC-Regular;
font-size: 24rpx;
color: #666666;
background-color: #f6f6f6;
padding: 5rpx 15rpx;
margin-right: 10rpx;
margin-top: 15rpx;
}
.proint {
margin-top: 30rpx;
font-size: 30rpx !important;
}
.ask {
overflow: hidden;
width: 100%;
display: flex;
align-items: center;
flex-wrap: wrap;
justify-content: flex-start;
margin: 20rpx 0;
}
.proneed {
font-size: 32rpx !important;
.proint {
margin-top: 30rpx;
font-size: 30rpx !important;
}
}
.proneed {
font-size: 32rpx !important;
}
.fee {
font-family: PingFangSC-Medium;
font-size: 32rpx;
color: #F46161;
margin-top: 30rpx;
}
.fee {
font-family: PingFangSC-Medium;
font-size: 32rpx;
color: #f46161;
margin-top: 30rpx;
}
.protype {
width: 50%;
}
.protype {
width: 50%;
}
.prolist {
font-family: PingFangSC-Regular;
font-size: 28rpx;
color: #666666;
display: flex;
align-items: center;
justify-content: space-between;
text-align: left;
padding: 5rpx 0;
}
.prolist {
font-family: PingFangSC-Regular;
font-size: 28rpx;
color: #666666;
display: flex;
align-items: center;
justify-content: space-between;
text-align: left;
padding: 5rpx 0;
}
.proname {
font-weight: bold;
font-family: PingFangSC-Medium;
font-size: 40rpx;
color: #333333;
width: 90%;
overflow: hidden;
padding-bottom: 20rpx;
}
.proname {
font-weight: bold;
font-family: PingFangSC-Medium;
font-size: 40rpx;
color: #333333;
width: 90%;
overflow: hidden;
padding-bottom: 20rpx;
}
.head {
padding: 30rpx;
background: #fefefe;
border-bottom: 20rpx solid #f6f6f6;
}
.head {
padding: 30rpx;
background: #fefefe;
border-bottom: 20rpx solid #f6f6f6;
}
.description {
word-break: break-all;
white-space: pre-line;
}
.description {
word-break: break-all;
white-space: pre-line;
}
.contactWrapper {
box-sizing: border-box;
text-align: center;
font-size: 28rpx;
margin-top: 10rpx;
border: 1px solid #e0e0e0;
border-radius: 5px;
padding: 20rpx;
display: flex;
justify-content: space-between;
align-items: center;
.contactWrapper {
box-sizing: border-box;
text-align: center;
font-size: 28rpx;
margin-top: 10rpx;
border: 1px solid #e0e0e0;
border-radius: 5px;
padding: 20rpx;
display: flex;
justify-content: space-between;
align-items: center;
}
}
.applyTime {
font-size: 24rpx;
color: #666666;
}
.applyTime {
font-size: 24rpx;
color: #666666;
}
</style>

View File

@@ -7,27 +7,45 @@
<!-- <view class="prolist">
任务编码{{info.missionNo}}
</view> -->
<view class="prolist">发布日期{{ dateFormat(info.stime) }}</view>
<view class="prolist">招聘人数{{ info.peopleNum }}</view>
<view class="prolist">行业类型{{ info.tradeNames ? info.tradeNames : info.jobCompanyIndustry }}</view>
<view class="prolist">工种类型{{ info.skillNames }}</view>
<view class="prolist">
发布日期{{ dateFormat((info.stime)) }}
</view>
<view class="prolist">
招聘人数{{ info.peopleNum }}
</view>
<view class="prolist">
行业类型{{ info.tradeNames ? info.tradeNames : info.jobCompanyIndustry }}
</view>
<view class="prolist">
工种类型{{ info.skillNames }}
</view>
<!-- <view class="fee">
{{info.wage}}{{wageUnit[info.wageUnitCategory]}}
</view> -->
</view>
<view class="head">
<view class="proname proneed">岗位要求</view>
<view class="proname proneed">
岗位要求
</view>
<!-- <view class="prolist">
<view class="protype">
年龄要求{{age[info.ageDesc]}}
</view>
</view> -->
<view class="prolist">
<view class="protype">学历要求{{ info.education }}</view>
<view class="protype">经验要求{{ info.experienceDesc }}</view>
<view class="protype">
学历要求{{ info.education }}
</view>
<view class="protype">
经验要求{{ info.experienceDesc }}
</view>
</view>
<view class="prolist">
岗位地址{{ info.jobAddress }}
</view>
<view class="prolist proint" style="font-weight: bold;color:#333;">
任务描述
</view>
<view class="prolist">岗位地址{{ info.jobAddress }}</view>
<view class="prolist proint" style="font-weight: bold; color: #333">任务描述</view>
<view class="prolist description">
{{ info.jobDescription }}
</view>
@@ -38,7 +56,9 @@
</view>
</view>
<!-- 技能标签 end -->
<view v-if="info.jobSources" class="prolist">来源{{ info.jobSources }}</view>
<view v-if="info.jobSources" class="prolist">
来源{{ info.jobSources }}
</view>
</view>
<view class="head">
<!-- <view class="proname proneed">
@@ -50,17 +70,16 @@
<!-- <view class="prolist">
用工单位{{info.jobCompanyName}}
</view> -->
<view style="display: flex; align-items: center">
<image
src="../../../../static/img/city.png"
style="width: 40rpx; height: 40rpx; margin-right: 20rpx"
mode=""
></image>
<view style="font-size: 30rpx">{{ info.jobCompanyName }}</view>
<view style="display: flex;align-items: center;">
<image src="../../../../static/img/city.png" style="width: 40rpx;height: 40rpx;margin-right: 20rpx;"
mode=""></image>
<view style="font-size: 30rpx;">{{ info.jobCompanyName }}</view>
</view>
</view>
<view class="head">
<view class="proname proneed">地址</view>
<view class="proname proneed">
地址
</view>
<!-- <view class="prolist">
<view class="protype">
联系人{{info.callName}}
@@ -72,48 +91,39 @@
<!-- <view class="prolist" v-if="info.callNumber">
座机号{{info.callNumber}}
</view> -->
<view class="prolist">岗位地址{{ info.address }}</view>
<view class="prolist">
岗位地址{{ info.address }}
</view>
<view class="map">
<super-map
ref="uMap"
style="width: 100%; height: 100%"
:latitude="latitude"
:longitude="longitude"
:open="true"
:zoom="14"
:min-zoom="10"
:max-zoom="20"
:MapUrl="$config.supperMap"
:flag-tip="false"
></super-map>
<!-- <super-map ref="uMap" style="width: 100%;height: 100%;" :latitude="latitude" :longitude="longitude"
:open="true" :zoom="14" :min-zoom="10" :max-zoom="20" :MapUrl="$config.supperMap"
:flag-tip="false"></super-map> -->
<zhuo-tianditu-MultiPoint-Mapper ref="tMap" :api-key="$config.apiKey"></zhuo-tianditu-MultiPoint-Mapper>
</view>
<!-- <map class="map" :latitude="latitude" :longitude="longitude" :markers="covers"></map> -->
</view>
<view class="" style="height: 200rpx; background-color: #f6f6f6" v-if="isShow !== '0'"></view>
<view class="" style="height:200rpx;background-color: #f6f6f6;" v-if="isShow !== '0'"></view>
<view class="btn">
<view
@click="callPhone"
class="bottombtn flexbtn"
style="margin-right: 10rpx; background-color: #fbad17; border-radius: 45rpx"
>
<view @click="callPhone" class="bottombtn flexbtn"
style="margin-right: 10rpx;background-color: #FBAD17;border-radius: 45rpx;">
电话联系
</view>
</view>
<uniMask :maskShow="maskShow">
<view class="contractMask">
<!-- #ifdef H5 || APP-PLUS -->
<view class="close" @click="close" style="top: 124rpx">+</view>
<view class="close" @click="close" style="top: 124rpx;">+</view>
<!-- #endif -->
<!-- #ifdef MP-WEIXIN -->
<view class="close" @click="close">+</view>
<!-- #endif -->
<view style="height: 30px"></view>
<img :src="src" alt="" style="width: 100%; height: 1000px" />
<view style="height: 30px;"></view>
<img :src="src" alt="" style="width:100%;height: 1000px;">
<view v-if="nextBtn" class="down" @click="next">下一步</view>
</view>
</uniMask>
<u-popup closeable :show="showPopUp" mode="bottom" @close="closePopUp">
<view style="min-height: 100rpx; padding: 60rpx 40rpx">
<view style="min-height: 100rpx;padding: 60rpx 40rpx;">
<view class="contactWrapper" v-for="(item, index) in info.applyList" :key="index">
<view>{{ item.realName }} : {{ item.telphone }}</view>
<view class="applyTime">申请时间{{ item.applyTime }}</view>
@@ -124,7 +134,7 @@
<view v-else-if="showCode" class="codeSealBox">
<!-- #ifdef H5 || APP-PLUS -->
<view class="closeCode" @click="closeShowCode" style="top: 124rpx">+</view>
<view class="closeCode" @click="closeShowCode" style="top: 124rpx;">+</view>
<!-- #endif -->
<!-- #ifdef MP-WEIXIN -->
<view class="closeCode" @click="closeShowCode">+</view>
@@ -134,380 +144,402 @@
<view class="name">签名密码</view>
<view class="tip">6位数字签名密码</view>
</view>
<view style="height: 36px"></view>
<view style="height: 36px;"></view>
<valid-code ref="validCode" @finish="getInpCode" :maxlength="maxlength"></valid-code>
<view style="height: 36px"></view>
<view style="height: 36px;"></view>
<view class="forget" @click="forget">忘记密码</view>
</view>
</template>
<script>
import { mapGetters } from 'vuex';
import { recruit_missionDetail } from '@/api/mission.js';
import { GoLogin } from '@/untils/AxiosUtils.js';
import { setRead } from '@/api/news.js';
import { checkPass, getPhoneCountNumber } from '@/api/auth.js';
import dictionary from '@/common/textdata.js';
import { dateFormat } from '../../../../untils/format.js';
import { userrecruitDetail } from '@/api/userrecruit.js';
import uniMask from '@/components/uni-mask/mask.vue';
import validCode from '@/components/p-valid-code/p-valid-code.vue';
export default {
data() {
return {
...dictionary,
info: {},
status: null,
showDetail: false,
showCode: false,
maskShow: false,
nextBtn: false,
loading: false,
latitude: 39.909, //中心点
longitude: 116.39742,
covers: [
{
//marker标记位置
import {
mapGetters
} from 'vuex'
import {
recruit_missionDetail
} from '@/api/mission.js';
import {
GoLogin
} from '@/untils/AxiosUtils.js';
import {
setRead
} from '@/api/news.js';
import {
checkPass
} from '@/api/auth.js';
import dictionary from '@/common/textdata.js';
import {
dateFormat
} from "../../../../untils/format.js";
import {
userrecruitDetail
} from '@/api/userrecruit.js'
import uniMask from '@/components/uni-mask/mask.vue'
import validCode from '@/components/p-valid-code/p-valid-code.vue'
export default {
data() {
return {
...dictionary,
info: {},
status: null,
showDetail: false,
showCode: false,
maskShow: false,
nextBtn: false,
loading: false,
latitude: 39.909, //中心点
longitude: 116.39742,
covers: [{ //marker标记位置
id: 0,
latitude: 0,
longitude: 0,
// width:30,
// height:30,
iconPath: '../../../../static/img/location.png',
},
],
missionNo: '',
isShow: '',
type: '',
id: '',
src: 'https://jlfiles.oss-cn-zhangjiakou.aliyuncs.com/jobslink-api/doc/%E7%94%B5%E5%AD%90%E5%90%88%E5%90%8C%E9%A2%84%E8%A7%88%E5%9B%BE%E7%89%87.png',
maxlength: 6,
collectStatus: 0, // 收藏状态
showPopUp: false,
};
},
components: {
uniMask,
validCode,
},
onLoad: function (option) {
//option为object类型会序列化上个页面传递的参数
// this.$store.dispatch('setAutograph')
if (option.workId) {
this.workId = decodeURIComponent(option.workId);
}
if (option.isCan) {
this.isShow = option.isCan; //isShow为'0'则为我的任务、我的评价过来的,需要隐藏抢任务按钮
}
if (option.type) {
this.type = option.type; //type为1则为消息邀请过来的,需要设置消息已读;
}
if (option.id) {
this.id = option.id; //消息id
}
},
onShow: function () {
this.showDetail = true;
this.getData();
},
onShareAppMessage(obj) {
return {
title: this.info.missionTitle,
path: `/pages/projectInfo/projectInfo?missionNo=${this.info.missionNo}`,
};
},
methods: {
dateFormat,
async callPhone() {
this.showPopUp = true;
await getPhoneCountNumber();
iconPath: '../../../../static/img/location.png'
}],
missionNo: "",
isShow: '',
type: '',
id: '',
src: 'https://jlfiles.oss-cn-zhangjiakou.aliyuncs.com/jobslink-api/doc/%E7%94%B5%E5%AD%90%E5%90%88%E5%90%8C%E9%A2%84%E8%A7%88%E5%9B%BE%E7%89%87.png',
maxlength: 6,
collectStatus: 0, // 收藏状态
showPopUp: false,
}
},
closePopUp() {
this.showPopUp = false;
components: {
uniMask,
validCode
},
getData: function () {
const self = this;
recruit_missionDetail(self.workId, self.type).then(
(res) => {
onLoad: function(option) { //option为object类型会序列化上个页面传递的参数
// this.$store.dispatch('setAutograph')
if (option.workId) {
this.workId = decodeURIComponent(option.workId);
}
if (option.isCan) {
this.isShow = option.isCan; //isShow为'0'则为我的任务、我的评价过来的,需要隐藏抢任务按钮
}
if (option.type) {
this.type = option.type; //type为1则为消息邀请过来的,需要设置消息已读;
}
if (option.id) {
this.id = option.id; //消息id
}
},
onShow: function() {
this.showDetail = true
this.getData();
},
onShareAppMessage(obj) {
return {
title: this.info.missionTitle,
path: `/pages/projectInfo/projectInfo?missionNo=${this.info.missionNo}`
}
},
methods: {
dateFormat,
callPhone() {
this.showPopUp = true;
},
closePopUp() {
this.showPopUp = false;
},
getData: function() {
const self = this;
recruit_missionDetail(self.workId, self.type).then(res => {
self.info = res.data.data;
self.status = res.data.data.status;
self.missionNo = res.data.data.missionNo;
self.latitude = self.info.lat;
self.longitude = self.info.lon;
self.covers[0].latitude = self.info.lat;
self.covers[0].longitude = self.info.lon;
// self.latitude = self.info.lat;
// self.longitude = self.info.lon;
// self.covers[0].latitude = self.info.lat;
// self.covers[0].longitude = self.info.lon;
this.$refs.tMap.open(self.info.lon, self.info.lat)
if (self.info.lon > 1 && self.info.lat > 1) {
self.$nextTick(() => {
self.$api.sleep(1000).then(() => {
this.$refs.tMap.addFeature([{
id: self.info.id,
label: self.info.jobName,
lat: self.info.lat,
lon: self.info.lon,
}])
})
})
}
self.showDetail = true;
},
(error) => {
}, error => {
console.log(error);
}
);
},
// 查看合同
lookMask() {
this.maskShow = true;
},
// 关闭弹窗
close() {
this.maskShow = false;
},
// 合同下一步
next() {
this.maskShow = false;
this.showDetail = false;
this.showCode = true;
},
// 输入签名密码
getInpCode(password) {
uni.showLoading({
title: '请求中...',
});
this.loading = true;
var obj = {
pass: password,
};
checkPass(obj)
.then((res) => {
this.submitTask();
this.closeShowCode();
})
.catch((err) => {
this.loading = false;
});
},
// 关闭签名密码弹窗
closeShowCode() {
this.showCode = false;
this.showDetail = true;
},
// 忘记密码
forget() {
uni.navigateTo({
url: `/pageMy/setUserBase/seal/forget?forget=true`,
});
},
},
computed: {
...mapGetters(['auth', 'autograph']),
skillNames() {
if (this.info.skillNames) {
return this.info.skillNames.split(',');
},
// 查看合同
lookMask() {
this.maskShow = true
},
// 关闭弹窗
close() {
this.maskShow = false
},
// 合同下一步
next() {
this.maskShow = false
this.showDetail = false
this.showCode = true
},
// 输入签名密码
getInpCode(password) {
uni.showLoading({
title: "请求中..."
})
this.loading = true
var obj = {
pass: password
}
checkPass(obj).then(res => {
this.submitTask()
this.closeShowCode()
}).catch(err => {
this.loading = false
})
},
// 关闭签名密码弹窗
closeShowCode() {
this.showCode = false
this.showDetail = true
},
// 忘记密码
forget() {
uni.navigateTo({
url: `/pageMy/setUserBase/seal/forget?forget=true`
})
}
},
},
};
computed: {
...mapGetters(['auth', 'autograph']),
skillNames() {
if (this.info.skillNames) {
return this.info.skillNames.split(',')
}
}
}
}
</script>
<style lang="scss">
.codeSealBox {
padding: 285rpx 72rpx 0 72rpx;
.codeSealBox {
padding: 285rpx 72rpx 0 72rpx;
.closeCode {
position: absolute;
right: 36rpx;
top: 120rpx;
color: #1B66FF;
transform: rotate(45deg);
font-size: 40px;
}
.title {
display: flex;
align-items: center;
}
.name {
height: 46rpx;
font-size: 46rpx;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #333333;
line-height: 46rpx;
margin-right: 28rpx;
}
.tip {
height: 38rpx;
font-size: 28rpx;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #999999;
line-height: 38rpx;
}
.forget {
height: 38rpx;
font-size: 28rpx;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #5AA0FA;
line-height: 38rpx;
text-align: right;
}
.closeCode {
position: absolute;
right: 36rpx;
top: 120rpx;
color: #1b66ff;
transform: rotate(45deg);
font-size: 40px;
}
.title {
display: flex;
align-items: center;
.contractMask {
background-color: #FFFFFF;
margin: 30rpx;
position: relative;
border-radius: 4px;
height: 96%;
overflow: auto;
.close {
width: 23px;
height: 23px;
color: #1B66FF;
position: fixed;
right: 60rpx;
top: 60rpx;
transform: rotate(45deg);
font-size: 40px;
}
.down {
position: fixed;
bottom: 30px;
left: 14%;
width: 545rpx;
height: 90rpx;
line-height: 90rpx;
text-align: center;
background: #1B66FF;
font-size: 36rpx;
font-weight: 400;
color: #FFFFFF;
}
}
.name {
height: 46rpx;
font-size: 46rpx;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #333333;
line-height: 46rpx;
margin-right: 28rpx;
.lookContract {
width: 30%;
margin-right: 30rpx;
}
.tip {
height: 38rpx;
font-size: 28rpx;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #999999;
line-height: 38rpx;
.flexbtn {
flex: 1;
}
.forget {
height: 38rpx;
font-size: 28rpx;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #5aa0fa;
line-height: 38rpx;
text-align: right;
}
}
.contractMask {
background-color: #ffffff;
margin: 30rpx;
position: relative;
border-radius: 4px;
height: 96%;
overflow: auto;
.close {
width: 23px;
height: 23px;
color: #1b66ff;
position: fixed;
right: 60rpx;
top: 60rpx;
transform: rotate(45deg);
font-size: 40px;
}
.down {
position: fixed;
bottom: 30px;
left: 14%;
width: 545rpx;
.bottombtn {
background-color: #1B66FF;
color: #fff;
text-align: center;
border-radius: 10rpx;
font-family: PingFangSC-Medium;
font-size: 32rpx;
height: 90rpx;
line-height: 90rpx;
text-align: center;
background: #1b66ff;
font-size: 36rpx;
font-weight: 400;
color: #ffffff;
}
}
.lookContract {
width: 30%;
margin-right: 30rpx;
}
.btn {
background-color: #fefefe;
width: 690rpx;
padding: 30rpx;
padding-bottom: 80rpx;
position: fixed;
bottom: 0;
left: 0;
display: flex;
}
.flexbtn {
flex: 1;
}
.disabledBtn {
background-color: #c8c9cc;
}
.bottombtn {
background-color: #1b66ff;
color: #fff;
text-align: center;
border-radius: 10rpx;
font-family: PingFangSC-Medium;
font-size: 32rpx;
height: 90rpx;
line-height: 90rpx;
}
.map {
width: 100%;
height: 350rpx;
margin-top: 30rpx;
}
.btn {
background-color: #fefefe;
width: 690rpx;
padding: 30rpx;
padding-bottom: 80rpx;
position: fixed;
bottom: 0;
left: 0;
display: flex;
}
.askList {
font-family: PingFangSC-Regular;
font-size: 24rpx;
color: #666666;
background-color: #f6f6f6;
padding: 5rpx 15rpx;
margin-right: 10rpx;
margin-top: 15rpx;
}
.disabledBtn {
background-color: #c8c9cc;
}
.ask {
overflow: hidden;
width: 100%;
display: flex;
align-items: center;
flex-wrap: wrap;
justify-content: flex-start;
margin: 20rpx 0;
.map {
width: 100%;
height: 350rpx;
margin-top: 30rpx;
}
}
.askList {
font-family: PingFangSC-Regular;
font-size: 24rpx;
color: #666666;
background-color: #f6f6f6;
padding: 5rpx 15rpx;
margin-right: 10rpx;
margin-top: 15rpx;
}
.proint {
margin-top: 30rpx;
font-size: 30rpx !important;
}
.ask {
overflow: hidden;
width: 100%;
display: flex;
align-items: center;
flex-wrap: wrap;
justify-content: flex-start;
margin: 20rpx 0;
}
.proneed {
font-size: 32rpx !important;
.proint {
margin-top: 30rpx;
font-size: 30rpx !important;
}
}
.proneed {
font-size: 32rpx !important;
}
.fee {
font-family: PingFangSC-Medium;
font-size: 32rpx;
color: #F46161;
margin-top: 30rpx;
}
.fee {
font-family: PingFangSC-Medium;
font-size: 32rpx;
color: #f46161;
margin-top: 30rpx;
}
.protype {
width: 50%;
}
.protype {
width: 50%;
}
.prolist {
font-family: PingFangSC-Regular;
font-size: 28rpx;
color: #666666;
display: flex;
align-items: center;
justify-content: space-between;
text-align: left;
padding: 5rpx 0;
}
.prolist {
font-family: PingFangSC-Regular;
font-size: 28rpx;
color: #666666;
display: flex;
align-items: center;
justify-content: space-between;
text-align: left;
padding: 5rpx 0;
}
.proname {
font-weight: bold;
font-family: PingFangSC-Medium;
font-size: 40rpx;
color: #333333;
width: 90%;
overflow: hidden;
padding-bottom: 20rpx;
}
.proname {
font-weight: bold;
font-family: PingFangSC-Medium;
font-size: 40rpx;
color: #333333;
width: 90%;
overflow: hidden;
padding-bottom: 20rpx;
}
.head {
padding: 30rpx;
background: #fefefe;
border-bottom: 20rpx solid #f6f6f6;
}
.head {
padding: 30rpx;
background: #fefefe;
border-bottom: 20rpx solid #f6f6f6;
}
.description {
word-break: break-all;
white-space: pre-line;
}
.description {
word-break: break-all;
white-space: pre-line;
}
.contactWrapper {
box-sizing: border-box;
text-align: center;
font-size: 28rpx;
margin-top: 10rpx;
border: 1px solid #e0e0e0;
border-radius: 5px;
padding: 20rpx;
display: flex;
justify-content: space-between;
align-items: center;
.contactWrapper {
box-sizing: border-box;
text-align: center;
font-size: 28rpx;
margin-top: 10rpx;
border: 1px solid #e0e0e0;
border-radius: 5px;
padding: 20rpx;
display: flex;
justify-content: space-between;
align-items: center;
}
}
.applyTime {
font-size: 24rpx;
color: #666666;
}
.applyTime {
font-size: 24rpx;
color: #666666;
}
</style>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -1,18 +1,54 @@
<template>
<view class="mainWrapper">
<view class="headSearch">
<view v-show="!searchResultShow" class="headSearch">
<view class="search-view">
<view class="search-item">
<image src="../../static/img/search.svg" style="width: 32rpx;height: 32rpx;" mode=""></image>
<input type="text" confirm-type="搜索" v-model="keywords" @confirm="getList"
<input type="text" confirm-type="搜索" v-model="keywords" @confirm="getNewList('search')"
placeholder="搜零工岗位/搜全职岗位/搜政策" />
<view @click="getList"
<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>
<!-- <view class="close" @click="closeBack">
取消
</view> -->
</view>
</view>
<view class="search-history">
<view v-show="searchResultShow" class="headSearch">
<view class="search-view">
<view class="search-item" @click="clearCurrentKeyWords">
<!-- <image src="../../static/img/search.svg" style="width: 32rpx;height: 32rpx;" mode=""></image> -->
<!-- <input type="text" confirm-type="搜索" v-model="keywords" @confirm="getNewList('search')"
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
style="font-size: 24rpx;height: 50rpx;background-color: #ddd;border-radius: 25rpx;line-height: 50rpx;padding: 0 20rpx;padding-right: 40rpx;position:relative;">
{{ keywords }}
<u-icon name="close" size="14" style="position:absolute;right:10rpx;top:13rpx;"></u-icon>
</view>
</view>
</view>
</view>
<view v-show="searchResultShow" class="search-result">
<view class="title">搜索结果</view>
<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>
<view style="flex:1;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;">{{ item.name }}</view>
<view class="type" v-if="item.type == 0">零工岗位</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>
<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" style="text-align: center;font-size: 26rpx;margin-top: 20rpx;">
暂无数据</view>
</view>
<view v-show="!searchResultShow" class="search-history">
<view class="title">搜索记录</view>
<view class="clear" @click="clearKeyWords">
<image src="../../static/img/delete.png" style="width: 24rpx;height: 24rpx;" mode=""></image>
@@ -24,14 +60,15 @@
</view>
</view>
<view v-else class="empty">暂无历史记录</view>
<v-tabs :tabs="tabList" height="45px" v-model="activeTab" color="#999" activeColor="#000" fontSize="30rpx"
activeFontSize="31rpx" @change='changeTab' />
</view>
<block v-if="activeTab === 0">
<view v-if="companyList.length ">
<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">
<view v-if="companyList.length > 0">
<block v-for="(item, index) in companyList" :key="item.id">
<companyList :companyitem="item" :location="userLocation"></companyList>
<companyList :companyitem="item"></companyList>
</block>
</view>
<view v-else>
@@ -41,10 +78,10 @@
</view>
</view>
</block>
<block v-if="activeTab === 1">
<view v-if="newList.length">
<block v-if="(activeTab == 1)&&!searchResultShow">
<view v-if="newList.length > 0">
<block v-for="(item, index) in newList" :key="item.id">
<workList :companyitem="item" :near="activeTab === 0" :location="userLocation"></workList>
<workList :companyitem="item" :near="activeTab === 0"></workList>
</block>
</view>
<view v-else>
@@ -55,8 +92,8 @@
<block v-if="activeTab == 2">
<view v-if="recommendList.length">
<block v-if="(activeTab == 2)&&!searchResultShow">
<view v-if="recommendList.length > 0">
<!-- <block v-for="(item, index) in recommendList" :key="item.id">
<companyList :companyitem="item"></companyList>
</block> -->
@@ -72,86 +109,94 @@
<view v-else>
<image src="../../static/img/pic_notask.svg" mode="" class="nothing"></image>
<view class="nothingContnt">
暂无信息
完善技能获取精推荐
</view>
<!-- <view class="btn" @click="goResume">
完善技能
</view> -->
完善技能
</view> -->
</view>
</block>
<block v-if="activeTab == -1">
<view>
<image src="../../static/img/pic_notask.svg" mode="" class="nothing"></image>
<view class="nothingContnt">
没有更多数据
</view>
</view>
</block>
<!-- <view v-if="companyList.length > 0">
<block v-for="(item, index) in companyList" :key="item.id">
<companyList :companyitem="item"></companyList>
<view class="baddd"></view>
</block>
</view>
<view v-else>
<image src="../../static/img/pic_notask.svg" mode="" class="nothing"></image>
<view class="nothingContnt">
暂无任务信息
</view>
</view> -->
</view>
</template>
<script>
import {
cloneDeep
} from 'lodash';
import {
newMissionAll,
getSearchKeyWordsList,
clearSearchKeyWords,
getListByKeyWords,
nearMission,
getPolicyContentList,
userWorkSearchListAll
getPolicyContentList
} from '@/api/mission.js';
import {
mapGetters
} from 'vuex'
import companyList from '@/components/companyList/companyList.vue';
import vTabs from '@/components/v-tabs/v-tabs.vue';
import testData from '@/common/textdata.js';
import workList from '@/components/companyList/workList.vue'
const titleStatus = {
'mission': {
title: '零工岗位',
val: 0,
},
'work': {
title: '全职岗位',
val: 1,
},
'policy': {
title: '政策',
val: 2,
},
}
export default {
components: {
companyList,
vTabs,
workList
},
data() {
return {
activeTab: 0,
keywords: '',
searchHistoryList: [],
companyList: [],
newList: [],
recommendList: [],
tabList: ['零工岗位', '全职岗位', '政策']
}
newList: [],
keywords: '',
page: {
current: 1,
size: 10,
total: 0
},
searchHistoryList: [],
searchResultShow: false,
searchResultList: []
};
},
computed: {
...mapGetters(['userLocation']),
onLoad: function(option) {
this.keywords = option.keywords ? option.keywords : ''
},
onShow: function() {
this.getList('refresh');
this.getKeyWordsList()
},
/*页面滚动到底部*/
onReachBottom: function() {
this.upLoad()
},
methods: {
goPolicyInfo(data) {
if (data) {
uni.navigateTo({
url: `/pages/user/policyContent?id=${data}`
})
}
clearCurrentKeyWords() {
this.keywords = '';
let that = this;
setTimeout(function() {
that.searchResultShow = false;
}, 100);
},
// 新面板搜索
getNewList() {
getListByKeyWords(this.keywords).then(res => {
this.searchResultShow = true
this.searchResultList = res.data.data
// this.searchResultList.forEach((item, index) => {
// item.name = this.getInf(item.name, this.keywords);
// })
})
},
// 获取搜索历史记录
getKeyWordsList() {
@@ -166,6 +211,142 @@
// console.log(keyWords)
this.searchResultShow = true;
this.keywords = keyWords;
this.getNewList();
},
//最新任务;
getList: function(type = 'add') {
//改变搜索条件页码值变为1
if (type === 'refresh') {
this.page.current = 1;
};
// if (this.keywords) {
newMissionAll(this.page.current, this.page.size, this.keywords).then(res => {
this.page.total = res.data.data.total;
if (type === 'refresh') {
this.companyList = res.data.data.records
} else if (res.data.data && res.data.data.records.length) {
this.companyList = this.companyList.concat(res.data.data.records);
}
this.page.current += 1;
})
},
getgwList(type = 'add') {
if (type === 'refresh') {
this.page.current = 1;
};
nearMission(this.page.current, this.page.size).then(res => {
this.page.total = res.data.data.total;
if (type === 'refresh') {
this.newList = res.data.data.records
} else if (res.data.data && res.data.data.records.length) {
this.newList = this.newList.concat(res.data.data.records);
}
this.page.current += 1;
})
},
getPoliyList(type = 'add') {
if (type === 'refresh') {
this.page.current = 1;
};
let params = {
current: this.page.current,
size: this.page.size,
type: 1
}
getPolicyContentList(params).then(res => {
this.page.total = res.data.data.total;
if (type === 'refresh') {
this.recommendList = res.data.data.records
} else if (res.data.data && res.data.data.records.length) {
this.recommendList = this.recommendList.concat(res.data.data.records);
}
this.page.current += 1;
})
},
goPolicyInfo(data) {
if (data) {
uni.navigateTo({
url: `/pages/user/policyContent?id=${data}`
})
} else {
// uni.showToast({
// title:'暂无内容',
// icon:'none'
// })
}
},
//上拉加载
upLoad: function() {
if (this.page.current <= Math.ceil(this.page.total / this.page.size)) {
switch (this.activeTab) {
case 0:
this.getList();
break;
case 1:
this.getgwList();
break;
case 2:
this.getPoliyList()
break;
}
} else {
uni.showToast({
icon: "none",
title: '已经是最后一页',
})
return
}
},
closeBack() {
uni.navigateBack({
delta: 1
})
},
/**
* 指定关键字高亮
* @param {*} str 字符串
* @param {*} key 关键字
*/
getInf(str, key) {
if (str && key) {
let replaceReg = new RegExp(key, 'g') // 匹配关键字正则
let replaceString = "<span style='color: #1b66ff;'>" + key + "</span>" // 高亮替换
return str.replace(replaceReg, replaceString);
}
},
toDetail(item) {
const no = item.id
// 判断是岗位还是任务 0任务1岗位2政策
if (item.type == 0) {
uni.navigateTo({
url: `/pages/projectInfo/projectInfo?missionNo=${encodeURIComponent(no)}&isCan=1`
})
} else if (item.type == 1) {
uni.navigateTo({
url: `/pages/projectInfo/workInfo?workId=${encodeURIComponent(no)}&isCan=1`
})
} else if (item.type == 2) {
uni.navigateTo({
url: `/pages/user/policyContent?id=${no}`
})
}
},
changeTab: function(e) {
this.activeTab = e;
switch (e) {
case 0:
this.getList('refresh');
break;
case 1:
this.getgwList('refresh');
break;
case 2:
this.getPoliyList('refresh')
break;
}
},
// 清空搜索历史
clearKeyWords() {
@@ -174,55 +355,15 @@
this.getKeyWordsList()
}
})
},
changeTab: function(e) {
this.activeTab = e;
// const tab = cloneDeep(this.tabList[e])
// Object.keys(titleStatus).map((key) => {
// if (titleStatus[key].title === tab) {
// this.activeTab = titleStatus[key].val;
// }
// })
},
async getList() {
const params = {
keywords: this.keywords
}
let resData = await userWorkSearchListAll(params)
if (resData.data.code === 200) {
const {
mission,
policy,
work
} = resData.data.data
const tabVal = []
Object.keys(titleStatus).map((key) => {
if (resData.data.data[key].length) {
tabVal.push(titleStatus[key].title)
}
})
if (tabVal.length) {
let count = 0
Object.keys(titleStatus).map((key) => {
if (!count && titleStatus[key].title === tabVal[0]) {
this.activeTab = titleStatus[key].val;
count++
}
})
}
this.companyList = mission
this.recommendList = policy
this.newList = work
}
}
}
}
};
</script>
<style scoped>
.mainWrapper {
background-color: #f3f4f8;
min-height: calc(100vh - var(--window-top) - var(--status-bar-height) - var(--window-bottom));
min-height: 95vh;
}
.baddd {
@@ -334,7 +475,6 @@
padding: 8rpx 12rpx;
border-radius: 20rpx;
margin-right: 10rpx;
position: relative;
}
.search-result {

View File

@@ -1,517 +0,0 @@
<template>
<view class="mainWrapper">
<view v-show="!searchResultShow" class="headSearch">
<view class="search-view">
<view class="search-item">
<image src="../../static/img/search.svg" style="width: 32rpx;height: 32rpx;" mode=""></image>
<input type="text" confirm-type="搜索" v-model="keywords" @confirm="getNewList('search')"
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>
<!-- <view class="close" @click="closeBack">
取消
</view> -->
</view>
</view>
<view v-show="searchResultShow" class="headSearch">
<view class="search-view">
<view class="search-item" @click="clearCurrentKeyWords">
<!-- <image src="../../static/img/search.svg" style="width: 32rpx;height: 32rpx;" mode=""></image> -->
<!-- <input type="text" confirm-type="搜索" v-model="keywords" @confirm="getNewList('search')"
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
style="font-size: 24rpx;height: 50rpx;background-color: #ddd;border-radius: 25rpx;line-height: 50rpx;padding: 0 20rpx;padding-right: 40rpx;position:relative;">
{{ keywords }}
<u-icon name="close" size="14" style="position:absolute;right:10rpx;top:13rpx;"></u-icon>
</view>
</view>
</view>
</view>
<view v-show="searchResultShow" class="search-result">
<view>
<view>岗位/任务</view>
<view>政策</view>
</view>
<view class="title">搜索结果</view>
<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>
<view style="flex:1;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;">{{ item.name }}</view>
<view class="type" v-if="item.type == 0">零工岗位</view>
<view class="type" v-else-if="item.type == 1">全职岗位</view>
<view class="type" v-else-if="item.type1 == 2">政策</view>
<view class="type" v-else-if="item.type == 3">招工</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" style="text-align: center;font-size: 26rpx;margin-top: 20rpx;">
暂无数据</view>
</view>
<view v-show="!searchResultShow" class="search-history">
<view class="title">搜索记录</view>
<view class="clear" @click="clearKeyWords">
<image src="../../static/img/delete.png" style="width: 24rpx;height: 24rpx;" mode=""></image>
<view style="margin-left: 5rpx;">清空</view>
</view>
<view class="wrapper" v-if="searchHistoryList.length > 0">
<view class="item" v-for="(item, index) in searchHistoryList" @click="keyWordsClick(item.keywords)">
{{ item.keywords }}
</view>
</view>
<view v-else class="empty">暂无历史记录</view>
</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">
<view v-if="companyList.length > 0">
<block v-for="(item, index) in companyList" :key="item.id">
<companyList :companyitem="item"></companyList>
</block>
</view>
<view v-else>
<image src="../../static/img/pic_notask.svg" mode="" class="nothing"></image>
<view class="nothingContnt">
暂无信息
</view>
</view>
</block>
<block v-if="(activeTab == 1)&&!searchResultShow">
<view v-if="newList.length > 0">
<block v-for="(item, index) in newList" :key="item.id">
<workList :companyitem="item" :near="activeTab === 0"></workList>
</block>
</view>
<view v-else>
<image src="../../static/img/pic_notask.svg" class="nothing" mode=""></image>
<view class="nothingContnt">暂无信息</view>
</view>
</block>
<block v-if="(activeTab == 2)&&!searchResultShow">
<view v-if="recommendList.length > 0">
<!-- <block v-for="(item, index) in recommendList" :key="item.id">
<companyList :companyitem="item"></companyList>
</block> -->
<view v-for="(item, index) in recommendList" :key="index"
style="width: 90%;height: 100rpx;background-color: #fff;border-radius: 10rpx;margin:20rpx 5% 20rpx 5%;display: flex;align-items: center"
@click="goPolicyInfo(item.id)">
<image :src="item.headPic" style="width: 60rpx;height: 60rpx;margin: 0 20rpx;"></image>
<view style="font-size: 26rpx;">{{ item.articleTitle }}</view>
</view>
</view>
<view v-else>
<image src="../../static/img/pic_notask.svg" mode="" class="nothing"></image>
<view class="nothingContnt">
完善技能获取精推荐
</view>
<!-- <view class="btn" @click="goResume">
完善技能
</view> -->
</view>
</block>
<!-- <view v-if="companyList.length > 0">
<block v-for="(item, index) in companyList" :key="item.id">
<companyList :companyitem="item"></companyList>
<view class="baddd"></view>
</block>
</view>
<view v-else>
<image src="../../static/img/pic_notask.svg" mode="" class="nothing"></image>
<view class="nothingContnt">
暂无任务信息
</view>
</view> -->
</view>
</template>
<script>
import {
newMissionAll,
getSearchKeyWordsList,
clearSearchKeyWords,
getListByKeyWords,
nearMission,
getPolicyContentList
} from '@/api/mission.js';
import companyList from '@/components/companyList/companyList.vue';
import vTabs from '@/components/v-tabs/v-tabs.vue';
import testData from '@/common/textdata.js';
import workList from '@/components/companyList/workList.vue'
export default {
components: {
companyList,
vTabs,
workList
},
data() {
return {
activeTab: 0,
companyList: [],
recommendList: [],
newList: [],
keywords: '',
page: {
current: 1,
size: 10,
total: 0
},
searchHistoryList: [],
searchResultShow: false,
searchResultList: []
};
},
onLoad: function(option) {
this.keywords = option.keywords ? option.keywords : ''
},
onShow: function() {
this.getList('refresh');
this.getKeyWordsList()
},
/*页面滚动到底部*/
onReachBottom: function() {
this.upLoad()
},
methods: {
clearCurrentKeyWords() {
this.keywords = '';
let that = this;
setTimeout(function() {
that.searchResultShow = false;
}, 100);
},
// 新面板搜索
getNewList() {
getListByKeyWords(this.keywords).then(res => {
this.searchResultShow = true
this.searchResultList = res.data.data
// this.searchResultList.forEach((item, index) => {
// item.name = this.getInf(item.name, this.keywords);
// })
})
},
// 获取搜索历史记录
getKeyWordsList() {
getSearchKeyWordsList().then(res => {
let response = res.data
if (response.code == 200) {
this.searchHistoryList = response.data
}
})
},
keyWordsClick(keyWords) {
// console.log(keyWords)
this.searchResultShow = true;
this.keywords = keyWords;
this.getNewList();
},
//最新任务;
getList: function(type = 'add') {
//改变搜索条件页码值变为1
if (type === 'refresh') {
this.page.current = 1;
};
// if (this.keywords) {
newMissionAll(this.page.current, this.page.size, this.keywords).then(res => {
this.page.total = res.data.data.total;
if (type === 'refresh') {
this.companyList = res.data.data.records
} else if (res.data.data && res.data.data.records.length) {
this.companyList = this.companyList.concat(res.data.data.records);
}
this.page.current += 1;
})
},
getgwList(type = 'add') {
if (type === 'refresh') {
this.page.current = 1;
};
nearMission(this.page.current, this.page.size).then(res => {
this.page.total = res.data.data.total;
if (type === 'refresh') {
this.newList = res.data.data.records
} else if (res.data.data && res.data.data.records.length) {
this.newList = this.newList.concat(res.data.data.records);
}
this.page.current += 1;
})
},
getPoliyList(type = 'add') {
if (type === 'refresh') {
this.page.current = 1;
};
let params = {
current: this.page.current,
size: this.page.size,
type: 1
}
getPolicyContentList(params).then(res => {
this.page.total = res.data.data.total;
if (type === 'refresh') {
this.recommendList = res.data.data.records
} else if (res.data.data && res.data.data.records.length) {
this.recommendList = this.recommendList.concat(res.data.data.records);
}
this.page.current += 1;
})
},
goPolicyInfo(data) {
if (data) {
uni.navigateTo({
url: `/pages/user/policyContent?id=${data}`
})
} else {
// uni.showToast({
// title:'暂无内容',
// icon:'none'
// })
}
},
//上拉加载
upLoad: function() {
if (this.page.current <= Math.ceil(this.page.total / this.page.size)) {
switch (this.activeTab) {
case 0:
this.getList();
break;
case 1:
this.getgwList();
break;
case 2:
this.getPoliyList()
break;
}
} else {
uni.showToast({
icon: "none",
title: '已经是最后一页',
})
return
}
},
closeBack() {
uni.navigateBack({
delta: 1
})
},
/**
* 指定关键字高亮
* @param {*} str 字符串
* @param {*} key 关键字
*/
getInf(str, key) {
if (str && key) {
let replaceReg = new RegExp(key, 'g') // 匹配关键字正则
let replaceString = "<span style='color: #1b66ff;'>" + key + "</span>" // 高亮替换
return str.replace(replaceReg, replaceString);
}
},
toDetail(item) {
const no = item.id
// 判断是岗位还是任务 0任务1岗位2政策
if (item.type == 0) {
uni.navigateTo({
url: `/pages/projectInfo/projectInfo?missionNo=${encodeURIComponent(no)}&isCan=1`
})
} else if (item.type == 1) {
uni.navigateTo({
url: `/pages/projectInfo/workInfo?workId=${encodeURIComponent(no)}&isCan=1`
})
} else if (item.type == 2) {
uni.navigateTo({
url: `/pages/user/policyContent?id=${no}`
})
}
},
changeTab: function(e) {
this.activeTab = e;
switch (e) {
case 0:
this.getList('refresh');
break;
case 1:
this.getgwList('refresh');
break;
case 2:
this.getPoliyList('refresh')
break;
}
},
// 清空搜索历史
clearKeyWords() {
clearSearchKeyWords().then(res => {
if (res.data.code == 200) {
this.getKeyWordsList()
}
})
}
}
};
</script>
<style scoped>
.mainWrapper {
background-color: #f3f4f8;
min-height: 95vh;
}
.baddd {
background-color: #f6f6f6;
height: 20rpx;
}
.close {
position: absolute;
right: 24rpx;
top: 6rpx;
height: 60rpx;
padding: 5rpx 0;
line-height: 60rpx;
font-family: PingFangSC-Regular;
font-size: 32rpx;
color: #333333;
}
.headSearch .search-view {
border-bottom: 1rpx solid #dddddd;
padding: 14rpx 32rpx;
background: rgba(255, 255, 255, 1);
}
.headSearch .search-item {
display: flex;
padding: 0 10rpx;
height: 60rpx;
line-height: 60rpx;
background: rgba(249, 249, 249, 1);
border-radius: 200px;
align-items: center;
border: 1px solid #0091ff;
}
.headSearch .search-item input {
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 .placeholderClass {
color: #CCCCCC;
}
.headSearch .search-item image {
height: 32rpx;
width: 32rpx;
}
.nothing {
width: 400rpx;
height: 200rpx;
display: block;
margin: 0 auto;
margin-top: 50%;
}
.nothingContnt {
font-family: PingFangSC-Regular;
font-size: 28rpx;
color: #333333;
margin-top: 30rpx;
text-align: center;
}
.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>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.9 KiB

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 269 B

After

Width:  |  Height:  |  Size: 563 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.6 KiB

After

Width:  |  Height:  |  Size: 7.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.5 KiB

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 401 B

After

Width:  |  Height:  |  Size: 809 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 389 B

After

Width:  |  Height:  |  Size: 888 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 766 B

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 679 B

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 560 B

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 489 B

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 64 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 508 B

After

Width:  |  Height:  |  Size: 531 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 538 B

After

Width:  |  Height:  |  Size: 565 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 628 B

After

Width:  |  Height:  |  Size: 637 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 766 B

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.7 KiB

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 856 B

After

Width:  |  Height:  |  Size: 881 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 864 B

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 843 B

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 50 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 55 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 962 B

After

Width:  |  Height:  |  Size: 975 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 808 B

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 KiB

After

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 857 B

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 865 B

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1007 B

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 462 B

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 798 B

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 142 B

After

Width:  |  Height:  |  Size: 538 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 478 B

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 636 B

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

After

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 481 B

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 421 B

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 463 B

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 417 B

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 660 B

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 522 B

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 3.8 KiB

Some files were not shown because too many files have changed in this diff Show More