flat: cityId备份 + 手机号提交

This commit is contained in:
Apcallover
2024-04-22 22:31:50 +08:00
parent ab94467da4
commit b79f0c7fc0
10 changed files with 47 additions and 25 deletions

View File

@@ -1,5 +1,6 @@
import { import {
request request,
transformRepalceString
} from '@/untils/AxiosUtils.js'; } from '@/untils/AxiosUtils.js';
import { import {
baseUrl baseUrl
@@ -34,7 +35,7 @@ export async function uploadFile(file) {
statusCode, statusCode,
data data
}) => { }) => {
const resp = JSON.parse(data) const resp = transformRepalceString(JSON.parse(data))
if (statusCode === 200 && resp.code === 200) { if (statusCode === 200 && resp.code === 200) {
resolve(resp.msg) resolve(resp.msg)
} else { } else {

View File

@@ -4,6 +4,7 @@ import App from './App'
import util from './untils/func.js' import util from './untils/func.js'
import uView from '@/uni_modules/uview-ui' import uView from '@/uni_modules/uview-ui'
import config from './config'; import config from './config';
import tools from '@/untils/tools.js'
import { import {
VueJsonp VueJsonp
} from 'vue-jsonp' } from 'vue-jsonp'
@@ -49,6 +50,7 @@ Vue.prototype.$api = {
msg, msg,
sleep sleep
} }
Vue.prototype.tools = tools
Vue.prototype.$config = config Vue.prototype.$config = config
Vue.prototype.navTo = navTo Vue.prototype.navTo = navTo
Vue.config.productionTip = false Vue.config.productionTip = false

View File

@@ -158,7 +158,8 @@
<view style="font-size: 28rpx;font-weight: bold;">重要提示</view> <view style="font-size: 28rpx;font-weight: bold;">重要提示</view>
<view style="font-size: 24rpx;color:#707070;margin-top:10rpx;">为保障个人基本劳动权益建议通过平台用工的形式就业</view> <view style="font-size: 24rpx;color:#707070;margin-top:10rpx;">为保障个人基本劳动权益建议通过平台用工的形式就业</view>
<view style="text-align: center;font-size:28rpx;margin-top: 30rpx;"> {{ info.callName }} : <view style="text-align: center;font-size:28rpx;margin-top: 30rpx;"> {{ info.callName }} :
{{ info.callTel }} <span style="color: blue"
@click="tools.onDialingPhoneNumber(info.callTel)">{{ info.callTel }}</span>
</view> </view>
</view> </view>
</u-popup> </u-popup>

View File

@@ -158,7 +158,8 @@
<view style="font-size: 28rpx;font-weight: bold;">重要提示</view> <view style="font-size: 28rpx;font-weight: bold;">重要提示</view>
<view style="font-size: 24rpx;color:#707070;margin-top:10rpx;">为保障个人基本劳动权益建议通过平台用工的形式就业</view> <view style="font-size: 24rpx;color:#707070;margin-top:10rpx;">为保障个人基本劳动权益建议通过平台用工的形式就业</view>
<view style="text-align: center;font-size:28rpx;margin-top: 30rpx;"> {{ info.callName }} : <view style="text-align: center;font-size:28rpx;margin-top: 30rpx;"> {{ info.callName }} :
{{ info.callTel }} <span style="color: blue"
@click="tools.onDialingPhoneNumber(info.callTel)">{{ info.callTel }}</span>
</view> </view>
</view> </view>
</u-popup> </u-popup>

View File

@@ -163,7 +163,8 @@
<view style="font-size: 28rpx;font-weight: bold;">重要提示</view> <view style="font-size: 28rpx;font-weight: bold;">重要提示</view>
<view style="font-size: 24rpx;color:#707070;margin-top:10rpx;">为保障个人基本劳动权益建议通过平台用工的形式就业</view> <view style="font-size: 24rpx;color:#707070;margin-top:10rpx;">为保障个人基本劳动权益建议通过平台用工的形式就业</view>
<view style="text-align: center;font-size:28rpx;margin-top: 30rpx;"> {{ info.callName }} : <view style="text-align: center;font-size:28rpx;margin-top: 30rpx;"> {{ info.callName }} :
{{ info.callTel }} <span style="color: blue"
@click="tools.onDialingPhoneNumber(info.callTel)">{{ info.callTel }}</span>
</view> </view>
</view> </view>
</u-popup> </u-popup>

View File

@@ -163,7 +163,8 @@
<view style="font-size: 28rpx;font-weight: bold;">重要提示</view> <view style="font-size: 28rpx;font-weight: bold;">重要提示</view>
<view style="font-size: 24rpx;color:#707070;margin-top:10rpx;">为保障个人基本劳动权益建议通过平台用工的形式就业</view> <view style="font-size: 24rpx;color:#707070;margin-top:10rpx;">为保障个人基本劳动权益建议通过平台用工的形式就业</view>
<view style="text-align: center;font-size:28rpx;margin-top: 30rpx;"> {{ info.callName }} : <view style="text-align: center;font-size:28rpx;margin-top: 30rpx;"> {{ info.callName }} :
{{ info.callTel }} <span style="color: blue"
@click="tools.onDialingPhoneNumber(info.callTel)">{{ info.callTel }}</span>
</view> </view>
</view> </view>
</u-popup> </u-popup>

View File

@@ -116,11 +116,10 @@
<u-form-item label="座机" prop="callNumber" borderBottom labelWidth="80" ref="item1"> <u-form-item label="座机" prop="callNumber" borderBottom labelWidth="80" ref="item1">
<u--input v-model="info.callNumber" border="none" placeholder="请输入座机"></u--input> <u--input v-model="info.callNumber" border="none" placeholder="请输入座机"></u--input>
</u-form-item> </u-form-item>
<u-form-item label="工作地址" labelWidth="70" prop="jobAddress" borderBottom ref="item1" <u-form-item label="工作地址" labelWidth="70" prop="cityId" borderBottom ref="item1"
@click="showjobAddress = true; hideKeyboard()"> @click="showCityId = true; hideKeyboard()">
<PickerTree placeholder="请选择行业" :tree="area.data" valueName="value" :visibel="showjobAddress" <PickerTree placeholder="请选择工作地址" :tree="area.data" valueName="value" :visibel="showCityId"
v-model="info.jobAddress" @cancel="showjobAddress = false" border="none" returnValue="label" v-model="info.cityId" @cancel="showCityId = false" border="none" returnValue="label" :deep="3">
:deep="3">
</PickerTree> </PickerTree>
</u-form-item> </u-form-item>
<u-form-item label="详细地址" prop="address" borderBottom labelWidth="80" ref="item1"> <u-form-item label="详细地址" prop="address" borderBottom labelWidth="80" ref="item1">
@@ -191,7 +190,7 @@
value: '', value: '',
showCalendar: false, showCalendar: false,
showStime: false, showStime: false,
showjobAddress: false, showCityId: false,
showEtime: false, showEtime: false,
info: { info: {
jobName: '', // 招工名称 jobName: '', // 招工名称
@@ -213,7 +212,7 @@
ageDesc: dic.ageArr[0][0].label, // 年龄要求 ageDesc: dic.ageArr[0][0].label, // 年龄要求
education: dic.eduArr[0][0].value, // 学历要求 education: dic.eduArr[0][0].value, // 学历要求
experienceDesc: dic.expeArr[0][0].label, // 经验要求 experienceDesc: dic.expeArr[0][0].label, // 经验要求
jobAddress: '', cityId: '',
jobCompanyName: '', // 企业名称 jobCompanyName: '', // 企业名称
jobCompanyScale: '', // 企业信用代码 jobCompanyScale: '', // 企业信用代码
jobCompanyIndustry: '', // 所属行业 jobCompanyIndustry: '', // 所属行业
@@ -318,7 +317,7 @@
message: '请选择经验要求', message: '请选择经验要求',
trigger: ['change'] trigger: ['change']
}, },
jobAddress: { cityId: {
type: 'string', type: 'string',
required: true, required: true,
message: '请选择工作地址', message: '请选择工作地址',
@@ -658,7 +657,6 @@
'education', 'education',
'educationLabel', 'educationLabel',
'experienceDesc', 'experienceDesc',
'jobAddress',
'jobCompanyName', 'jobCompanyName',
'jobCompanyScale', 'jobCompanyScale',
'jobCompanyIndustry', 'jobCompanyIndustry',

View File

@@ -120,11 +120,10 @@
<u-form-item label="座机" prop="callNumber" borderBottom labelWidth="80" ref="item1"> <u-form-item label="座机" prop="callNumber" borderBottom labelWidth="80" ref="item1">
<u--input v-model="info.callNumber" border="none" placeholder="请输入座机"></u--input> <u--input v-model="info.callNumber" border="none" placeholder="请输入座机"></u--input>
</u-form-item> </u-form-item>
<u-form-item label="工作地址" labelWidth="70" prop="jobAddress" borderBottom ref="item1" <u-form-item label="工作地址" labelWidth="70" prop="cityId" borderBottom ref="item1"
@click="showjobAddress = true; hideKeyboard()"> @click="showCityId = true; hideKeyboard()">
<PickerTree placeholder="请选择行业" :tree="area.data" valueName="value" :visibel="showjobAddress" <PickerTree placeholder="请选择行业" :tree="area.data" valueName="value" :visibel="showCityId"
v-model="info.jobAddress" @cancel="showjobAddress = false" border="none" returnValue="label" v-model="info.cityId" @cancel="showCityId = false" border="none" returnValue="label" :deep="3">
:deep="3">
</PickerTree> </PickerTree>
</u-form-item> </u-form-item>
<u-form-item label="详细地址" prop="address" borderBottom labelWidth="80" ref="item1"> <u-form-item label="详细地址" prop="address" borderBottom labelWidth="80" ref="item1">
@@ -196,7 +195,7 @@
showCalendar: false, showCalendar: false,
showStime: false, showStime: false,
showEtime: false, showEtime: false,
showjobAddress: false, showCityId: false,
info: { info: {
jobName: '', // 招工名称 jobName: '', // 招工名称
stime: '', // 发布时间 stime: '', // 发布时间
@@ -217,7 +216,7 @@
ageDesc: dic.ageArr[0][0].label, // 年龄要求 ageDesc: dic.ageArr[0][0].label, // 年龄要求
education: dic.eduArr[0][0].value, // 学历要求 education: dic.eduArr[0][0].value, // 学历要求
experienceDesc: dic.expeArr[0][0].label, // 经验要求 experienceDesc: dic.expeArr[0][0].label, // 经验要求
jobAddress: '', cityId: '',
jobCompanyName: '', // 企业名称 jobCompanyName: '', // 企业名称
jobCompanyScale: '', // 企业信用代码 jobCompanyScale: '', // 企业信用代码
jobCompanyIndustry: '', // 所属行业 jobCompanyIndustry: '', // 所属行业
@@ -322,7 +321,7 @@
message: '请选择经验要求', message: '请选择经验要求',
trigger: ['change'] trigger: ['change']
}, },
jobAddress: { cityId: {
type: 'string', type: 'string',
required: true, required: true,
message: '请选择工作地址', message: '请选择工作地址',
@@ -663,7 +662,7 @@
'education', 'education',
'educationLabel', 'educationLabel',
'experienceDesc', 'experienceDesc',
'jobAddress', 'cityId',
'jobCompanyName', 'jobCompanyName',
'jobCompanyScale', 'jobCompanyScale',
'jobCompanyIndustry', 'jobCompanyIndustry',

View File

@@ -129,7 +129,7 @@ async function DoAjax(options, config = {}) {
} }
// 递归替换 url // 递归替换 url
function transformRepalceString(props) { export function transformRepalceString(props) {
if (typeof props !== 'object' || props === null) { if (typeof props !== 'object' || props === null) {
for (const key in replaceStr) { for (const key in replaceStr) {
if (typeof props === 'string') { if (typeof props === 'string') {

18
untils/tools.js Normal file
View File

@@ -0,0 +1,18 @@
function onDialingPhoneNumber(phone) {
return new Promise((resolve, reject) => {
uni.makePhoneCall({
phoneNumber: phone, // 电话号码
success: (res) => {
resolve(res)
},
fail: (err) => {
reject(err)
} // 失败
});
})
}
export default {
onDialingPhoneNumber
}