BUG优化

dev
xiepeng 2024-05-16 18:01:12 +08:00
parent 3ac6e233e1
commit b73c4da3c5
5 changed files with 113 additions and 59 deletions

View File

@ -112,7 +112,7 @@
this.loginUserId = loginUser.USER_ID;
this.background = require('@/common/background.json');
await this.getFunc();
this.getData();
this.fnInit();
// setTimeout(function() {
// that.loading = true
// }, 500)
@ -140,8 +140,7 @@
_this.list1 = [];
await this.getFunc();
}
this.getData()
this.fnInit()
},
methods: {
@ -159,6 +158,39 @@
this.list = [];
this.list1 = [];
this.getData()
},
async fnInit() {
uni.request({
url: basePath + '/app/offduty/isRest',
method: 'POST',
dataType: 'json',
header: {
'Content-type': 'application/x-www-form-urlencoded'
},
data: {
USER_NAME: loginUser.NAME,
CORPINFO_ID: loginUser.CORPINFO_ID,
USER_ID: loginUser.USER_ID,
},
success: (res) => {
console.log(res)
if("0" == res.data.ISREST){
this.getData();
}else{
uni.showModal({
title: "温馨提示",
confirmText: "确定",
content:
"重要提醒:您当前处于离岗状态,无法操作。",
success: (res) => {
if (res.cancel || res.confirm) {
uni.navigateBack();
}
},
});
}
}
})
},
getData(){
var _this=this;
@ -170,7 +202,6 @@
title: '加载中'
})
uni.request({
url: basePath + '/app/waybillregistration/listForSecurityWaybillre',
method: 'POST',
dataType: 'json',

View File

@ -45,7 +45,7 @@
<view class="select">
<view @click="checkTrue1({index:index},1)" class="flex align-center">
<radio class='yellow mr10' :class="item.ISNORMAL==1?'checked':''" :checked="item.ISNORMAL==1" disabled ></radio>
<text>不是</text>
<text></text>
</view>
</view>
<view class="select">

View File

@ -19,6 +19,21 @@
<input v-model="formData.PHONE" disabled placeholder="请输入手机证号" maxlength="11" name="input" style="color: #cccccc" />
</view>
<view class="cu-form-group margin-top-xs">
<view class="title">人员类型</view>
<zqs-select
:multiple="true"
:list="dictData.PERSONNEL_TYPE.list"
:show-search="false"
v-model="formData.PERSONNEL_TYPE"
label-key="NAME"
value-key="DICTIONARIES_ID"
placeholder="请选择人员类型"
title="选择人员类型"
clearable
@change="changeSelect($event, 'PERSONNEL_TYPE')"
></zqs-select>
</view>
<!-- <view class="cu-form-group margin-top-xs">
<view class="title">人员类型</view>
<view v-if="forbidEdit" style="color: #cccccc">{{formData.PERSONNEL_TYPE_NAME}}</view>
<picker v-else @change="pickerChangeData($event,'PERSONNEL_TYPE')" :value="dictData.PERSONNEL_TYPE.index" :range="dictData.PERSONNEL_TYPE.list" range-key="NAME">
@ -26,7 +41,7 @@
{{formData.PERSONNEL_TYPE_NAME?formData.PERSONNEL_TYPE_NAME:'请选择'}}
</view>
</picker>
</view>
</view>-->
<view class="cu-form-group margin-top">
<view class="title">文化程度</view>
<view v-if="forbidEdit" style="color: #cccccc">{{formData.DEGREE_OF_EDUCATION_NAME}}</view>
@ -85,8 +100,11 @@
import {
formatDate,validateIdCard,validateMobile,getLevel
} from '../../../../common/tool.js';
import ZqsSelect from "../../../../components/zqs-select/zqs-select.vue";
export default {
name: "register_baseInfo",
components: {ZqsSelect},
props: {
applyStatus: {
type: String,
@ -162,12 +180,15 @@ import {
this.formData[name] = e.detail.value
this.$forceUpdate();//
},
changeSelect(e, name) {
this.$forceUpdate();//
},
pickerChangeData(e,name) {
//
if (name === 'PERSONNEL_TYPE') {
this.dictData.PERSONNEL_TYPE.index = e.detail.value;
this.formData.PERSONNEL_TYPE = this.dictData.PERSONNEL_TYPE.list[this.dictData.PERSONNEL_TYPE.index].DICTIONARIES_ID
this.formData.PERSONNEL_TYPE_NAME = this.dictData.PERSONNEL_TYPE.list[this.dictData.PERSONNEL_TYPE.index].NAME
this.formData.PERSONNEL_TYPENAME = this.dictData.PERSONNEL_TYPE.list[this.dictData.PERSONNEL_TYPE.index].NAME
}
//
if (name === 'POLITICAL_OUTLOOK') {
@ -192,7 +213,7 @@ import {
},
validateData() {
//
if (!this.formData.PERSONNEL_TYPE) {
if (this.formData.PERSONNEL_TYPE.length < 1) {
uni.showToast({
icon: 'none',
title: '请选择人员类型',

View File

@ -20,10 +20,10 @@
</view>
<view class="cu-form-group margin-top-xs">
<view class="title">人员类型</view>
<view v-if="forbidEdit" style="color: #cccccc">{{formData.PERSONNEL_TYPE_NAME}}</view>
<view v-if="forbidEdit" style="color: #cccccc">{{formData.PERSONNEL_TYPENAME}}</view>
<picker v-else @change="pickerChangeData($event,'PERSONNEL_TYPE')" disabled :value="dictData.PERSONNEL_TYPE.index" :range="dictData.PERSONNEL_TYPE.list" range-key="NAME">
<view class="picker" style="color: #cccccc">
{{formData.PERSONNEL_TYPE_NAME?formData.PERSONNEL_TYPE_NAME:'请选择'}}
{{formData.PERSONNEL_TYPE.join()}}
</view>
</picker>
</view>
@ -737,6 +737,7 @@ export default {
}
//
if (this.formData.PERSONNEL_TYPE_NAME.find((item) => item === '驾驶员')) {
if (this.fileData.driverLicense.length < 1) {
uni.showToast({
icon: 'none',
@ -785,6 +786,7 @@ export default {
});
return false;
}
}
//
if (this.fileData.qualificationCertificate.length < 1) {

View File

@ -93,8 +93,8 @@ import Apply from "./components/apply.vue"
SEXNAME: '',
//
PERSONNEL_TYPE: '',
PERSONNEL_TYPE_NAME: '',
PERSONNEL_TYPE: [],
PERSONNEL_TYPENAME: '',
//
POLITICAL_OUTLOOK: '',
POLITICAL_OUTLOOK_NAME: '',