工龄不必填、入职日期默认当天、完成后跳转9100
This commit is contained in:
parent
b823b6f408
commit
814573aa62
@ -101,6 +101,7 @@ if (process.env.CUSTOM_PLATFORM === "dev") {
|
||||
uni_app_web_api_url: "http://localhost", // 请求接口的地址
|
||||
uni_app_web_source_url: "http://localhost:3199", // 资源地址
|
||||
uni_app_web_local_api_url: "http://localhost", // 请求接口的地址
|
||||
uni_app_url: "http://47.122.43.22:9100"
|
||||
}
|
||||
} else if (process.env.CUSTOM_PLATFORM === "test") {
|
||||
//测试环境
|
||||
@ -114,6 +115,7 @@ if (process.env.CUSTOM_PLATFORM === "dev") {
|
||||
uni_app_web_api_url: "http://47.122.43.22", // 请求接口的地址
|
||||
uni_app_web_source_url: "http://47.122.43.22:3199", // 资源地址
|
||||
uni_app_web_local_api_url: "http://47.122.43.22", // 请求接口的地址
|
||||
uni_app_url: "http://47.122.43.22:9100"
|
||||
}
|
||||
} else
|
||||
//生产环境 发布等
|
||||
@ -126,8 +128,9 @@ if (process.env.CUSTOM_PLATFORM === "dev") {
|
||||
uni_app_web_url: "",
|
||||
uni_app_web_api_url: APP_ENV === 'release' ? "http://xmmhe.com" : "http://47.122.43.22",
|
||||
uni_app_web_source_url: APP_ENV === 'release' ? "http://xmmhe.com:3199" : "http://47.122.43.22:3199",
|
||||
uni_app_web_local_api_url: APP_ENV === 'release' ? "http://xmmhe.com" : "http://47.122.43.22" //打包测试: 47.122.43.22 开发可 localhost
|
||||
uni_app_web_local_api_url: APP_ENV === 'release' ? "http://xmmhe.com" : "http://47.122.43.22", //打包测试: 47.122.43.22 开发可 localhost
|
||||
uni_app_url: APP_ENV === 'release' ? "http://xmmhe.com:9100" : "http://47.122.43.22:9100"
|
||||
|
||||
}
|
||||
|
||||
export default configURL
|
||||
export default configURL
|
||||
@ -48,7 +48,8 @@
|
||||
"path": "pages/webview/webview",
|
||||
"style": {
|
||||
"navigationBarTitleText": "",
|
||||
"enablePullDownRefresh": false
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationBarBackgroundColor": "#fff"
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -23,12 +23,14 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import config from '../../config/common.js'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
showSex: false,
|
||||
type: 'success',
|
||||
titleFailes: '提交失败,请稍后重新提交',
|
||||
appurl:config.uni_app_url
|
||||
|
||||
}
|
||||
},
|
||||
@ -49,9 +51,12 @@
|
||||
// uni.navigateBack({
|
||||
// delta:2
|
||||
// })
|
||||
const Company = uni.getStorageSync('Company')
|
||||
// const Company = uni.getStorageSync('Company')
|
||||
// uni.reLaunch({
|
||||
// url: '/pages/index/index?Company='+Company
|
||||
// })
|
||||
uni.reLaunch({
|
||||
url: '/pages/index/index?Company='+Company
|
||||
url: '/pages/webview/webview?url=' + this.appurl
|
||||
})
|
||||
},
|
||||
|
||||
|
||||
@ -60,6 +60,7 @@
|
||||
import {
|
||||
isChinaMobilePhone,
|
||||
easyCheckID,
|
||||
getNowFormatDate
|
||||
} from '../../utils/common.js'
|
||||
export default {
|
||||
data() {
|
||||
@ -75,17 +76,7 @@
|
||||
Sex: '',
|
||||
Phone: '',
|
||||
ID_CARD: '',
|
||||
InTime: '',
|
||||
WORKINGYEAR: '',
|
||||
},
|
||||
},
|
||||
model2: {
|
||||
userInfo: {
|
||||
Name: '',
|
||||
Sex: '',
|
||||
Phone: '',
|
||||
ID_CARD: '',
|
||||
InTime: '',
|
||||
InTime: getNowFormatDate(),
|
||||
WORKINGYEAR: '',
|
||||
},
|
||||
},
|
||||
@ -133,12 +124,6 @@
|
||||
message: '请选择入职时间',
|
||||
trigger: ['blur', 'change']
|
||||
},
|
||||
'userInfo.WORKINGYEAR': {
|
||||
type: 'string',
|
||||
required: true,
|
||||
message: '请选择工龄',
|
||||
trigger: ['blur', 'change']
|
||||
},
|
||||
},
|
||||
radio: '',
|
||||
switchVal: false
|
||||
@ -192,8 +177,7 @@
|
||||
this.model1.userInfo.Sex == '' ||
|
||||
this.model1.userInfo.Phone == '' ||
|
||||
this.model1.userInfo.ID_CARD == '' ||
|
||||
this.model1.userInfo.InTime == '' ||
|
||||
this.model1.userInfo.WORKINGYEAR == '') {
|
||||
this.model1.userInfo.InTime == '') {
|
||||
uni.showToast({
|
||||
icon: 'error',
|
||||
title: '信息不能为空'
|
||||
@ -215,13 +199,14 @@
|
||||
return
|
||||
}
|
||||
this.loading = true
|
||||
this.model2.userInfo = this.model1.userInfo
|
||||
if (this.model1.userInfo.Sex == '男') {
|
||||
this.model2.userInfo.Sex = '1'
|
||||
} else {
|
||||
this.model2.userInfo.Sex = '0'
|
||||
}
|
||||
const json = this.model2.userInfo
|
||||
const json = {
|
||||
Name: this.model1.userInfo.Name,
|
||||
Sex: this.model1.userInfo.Sex == '男'?'1':'0',
|
||||
Phone: this.model1.userInfo.Phone,
|
||||
ID_CARD: this.model1.userInfo.ID_CARD,
|
||||
InTime: this.model1.userInfo.InTime,
|
||||
WORKINGYEAR: this.model1.userInfo.WORKINGYEAR,
|
||||
}
|
||||
// const json = {
|
||||
// Name: '云',
|
||||
// Sex: '0',
|
||||
|
||||
@ -1368,4 +1368,14 @@ export function checkIDCard(code) {
|
||||
|
||||
}
|
||||
return matches
|
||||
}
|
||||
export function getNowFormatDate() {
|
||||
let date = new Date(),
|
||||
year = date.getFullYear(), //获取完整的年份(4位)
|
||||
month = date.getMonth() + 1, //获取当前月份(0-11,0代表1月)
|
||||
strDate = date.getDate() // 获取当前日(1-31)
|
||||
if (month < 10) month = `0${month}` // 如果月份是个位数,在前面补0
|
||||
if (strDate < 10) strDate = `0${strDate}` // 如果日是个位数,在前面补0
|
||||
|
||||
return `${year}-${month}-${strDate}`
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user