Compare commits
2 Commits
639fa29412
...
b9fb9bf81c
| Author | SHA1 | Date | |
|---|---|---|---|
| b9fb9bf81c | |||
| 7f86461227 |
@ -42,11 +42,10 @@
|
|||||||
<view class="text-wrapper_4 flex-col">
|
<view class="text-wrapper_4 flex-col">
|
||||||
<view style="display: flex">
|
<view style="display: flex">
|
||||||
<text class="text_13"
|
<text class="text_13"
|
||||||
style="background-color: rgba(223, 235, 255, 1);padding: 5rpx 15rpx">{{
|
style="background-color: rgba(223, 235, 255, 1);padding: 5rpx 15rpx"
|
||||||
item.tittle
|
v-if="item.tittle">{{ item.tittle }}
|
||||||
}}
|
|
||||||
</text>
|
</text>
|
||||||
<text class="text-wrapper_3 text_13"
|
<text class="text-wrapper_3 text_13" v-if="item.type"
|
||||||
style="color: black;padding: 5rpx 10rpx">{{ item.type }}</text>
|
style="color: black;padding: 5rpx 10rpx">{{ item.type }}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@ -78,7 +77,7 @@
|
|||||||
<image class="label_3" referrerpolicy="no-referrer" :src="imagesUrl + '/' + item.image" />
|
<image class="label_3" referrerpolicy="no-referrer" :src="imagesUrl + '/' + item.image" />
|
||||||
<view class="text-group_4 flex-col justify-between">
|
<view class="text-group_4 flex-col justify-between">
|
||||||
<text class="text_25">{{ item.name }}</text>
|
<text class="text_25">{{ item.name }}</text>
|
||||||
<text class="text_27">教龄 {{ item.seniority }}年</text>
|
<text class="text_27" v-if="item.seniority">教龄 {{ item.seniority }}年</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|||||||
@ -20,10 +20,7 @@
|
|||||||
</headers>
|
</headers>
|
||||||
</view>
|
</view>
|
||||||
<view>
|
<view>
|
||||||
<scroll-view
|
<scroll-view :style="{ height: scrollHeight + 'px' }" scroll-y="true" class="scroll-view">
|
||||||
:style="{ height: scrollHeight + 'px' }"
|
|
||||||
scroll-y="true" class="scroll-view"
|
|
||||||
>
|
|
||||||
<view class="group_4 flex-col">
|
<view class="group_4 flex-col">
|
||||||
<view class="block_1 flex-row justify-between" @click="show = true">
|
<view class="block_1 flex-row justify-between" @click="show = true">
|
||||||
<text class="text_19">是否通过</text>
|
<text class="text_19">是否通过</text>
|
||||||
@ -37,28 +34,17 @@
|
|||||||
<view class="text-wrapper_7 flex-row justify-between">
|
<view class="text-wrapper_7 flex-row justify-between">
|
||||||
<text class="text_4">分数</text>
|
<text class="text_4">分数</text>
|
||||||
<view class="text_5_1 ">
|
<view class="text_5_1 ">
|
||||||
<u--input
|
<u--input placeholder="请输入分数" border="none" v-model="process.examScore" maxlength="3"
|
||||||
placeholder="请输入分数"
|
inputAlign="right">分
|
||||||
border="none"
|
|
||||||
v-model="process.examScore"
|
|
||||||
maxlength="3"
|
|
||||||
inputAlign="right"
|
|
||||||
>分
|
|
||||||
</u--input>
|
</u--input>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="text-wrapper_8 flex-row justify-between">
|
<view class="text-wrapper_8 flex-row justify-between">
|
||||||
<text class="text_20">时间</text>
|
<text class="text_20">时间</text>
|
||||||
<view>
|
<view>
|
||||||
<u-datetime-picker
|
<u-datetime-picker :show="showTimePicker" v-model="process.examTime" mode="datetime"
|
||||||
:show="showTimePicker"
|
:minDate="minTime" :maxDate="maxTime" @confirm="onConfirmExamTime"
|
||||||
v-model="process.examTime"
|
@cancel="showTimePicker = false"></u-datetime-picker>
|
||||||
mode="datetime"
|
|
||||||
:minDate="minTime"
|
|
||||||
:maxDate="maxTime"
|
|
||||||
@confirm="onConfirmExamTime"
|
|
||||||
@cancel="showTimePicker = false"
|
|
||||||
></u-datetime-picker>
|
|
||||||
<text class="text_3" @click="showTimePicker = true">
|
<text class="text_3" @click="showTimePicker = true">
|
||||||
{{ process.examTime ? formatDate(process.examTime) : '选择时间' }}
|
{{ process.examTime ? formatDate(process.examTime) : '选择时间' }}
|
||||||
</text>
|
</text>
|
||||||
@ -111,14 +97,8 @@
|
|||||||
<u--textarea class="text_17" v-model="process.remark" placeholder="请输入内容" count></u--textarea>
|
<u--textarea class="text_17" v-model="process.remark" placeholder="请输入内容" count></u--textarea>
|
||||||
<text class="text_18">图片</text>
|
<text class="text_18">图片</text>
|
||||||
<view class="image-wrapper_4 flex-row justify-between">
|
<view class="image-wrapper_4 flex-row justify-between">
|
||||||
<u-upload
|
<u-upload :fileList="displayFileList" @afterRead="afterRead" @delete="deletePic" multiple
|
||||||
|
:maxCount="2"></u-upload>
|
||||||
:fileList="displayFileList"
|
|
||||||
@afterRead="afterRead"
|
|
||||||
@delete="deletePic"
|
|
||||||
multiple
|
|
||||||
:maxCount="2"
|
|
||||||
></u-upload>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</scroll-view>
|
</scroll-view>
|
||||||
@ -133,7 +113,9 @@
|
|||||||
<script>
|
<script>
|
||||||
import upload from '@/utils/upload.js'
|
import upload from '@/utils/upload.js'
|
||||||
import request from '@/utils/request.js'
|
import request from '@/utils/request.js'
|
||||||
import {getLocalUserInfo} from '../../utils/auth';
|
import {
|
||||||
|
getLocalUserInfo
|
||||||
|
} from '../../utils/auth';
|
||||||
import headers from "@/components/header/headers.vue";
|
import headers from "@/components/header/headers.vue";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
@ -145,8 +127,12 @@ export default {
|
|||||||
show: false,
|
show: false,
|
||||||
showTimePicker: false,
|
showTimePicker: false,
|
||||||
subjectShow: false,
|
subjectShow: false,
|
||||||
ifPassColumns: [['已通过', '未通过']],
|
ifPassColumns: [
|
||||||
subjectColumns: [['科目一']],
|
['已通过', '未通过']
|
||||||
|
],
|
||||||
|
subjectColumns: [
|
||||||
|
['科目一']
|
||||||
|
],
|
||||||
selectedValue: '',
|
selectedValue: '',
|
||||||
subjectValue: '',
|
subjectValue: '',
|
||||||
fileList: [],
|
fileList: [],
|
||||||
@ -186,6 +172,7 @@ export default {
|
|||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
console.log('options', options)
|
console.log('options', options)
|
||||||
this.userInfo = getLocalUserInfo()
|
this.userInfo = getLocalUserInfo()
|
||||||
|
console.log('userInfo', this.userInfo)
|
||||||
// this.getUserOrderDetails()
|
// this.getUserOrderDetails()
|
||||||
this.process.subject = options.subject
|
this.process.subject = options.subject
|
||||||
this.opTenantId = options.tenantId
|
this.opTenantId = options.tenantId
|
||||||
@ -216,9 +203,9 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const prefix = this.$imagesUrl.endsWith('/') ? this.$imagesUrl : `${this.$imagesUrl}/`;
|
const prefix = this.$imagesUrl.endsWith('/') ? this.$imagesUrl : `${this.$imagesUrl}/`;
|
||||||
const fullUrl = item.url.startsWith('/')
|
const fullUrl = item.url.startsWith('/') ?
|
||||||
? `${prefix}${item.url.slice(1)}`
|
`${prefix}${item.url.slice(1)}` :
|
||||||
: `${prefix}${item.url}`;
|
`${prefix}${item.url}`;
|
||||||
|
|
||||||
return {
|
return {
|
||||||
...item,
|
...item,
|
||||||
@ -284,9 +271,12 @@ export default {
|
|||||||
|
|
||||||
formatSubject(subject) {
|
formatSubject(subject) {
|
||||||
switch (Number(subject)) {
|
switch (Number(subject)) {
|
||||||
case 2: return '科目二';
|
case 2:
|
||||||
case 3: return '科目三';
|
return '科目二';
|
||||||
default: return '未知科目';
|
case 3:
|
||||||
|
return '科目三';
|
||||||
|
default:
|
||||||
|
return '未知科目';
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -372,13 +362,16 @@ export default {
|
|||||||
if (this.courseCompleteStatusList.length > 0) {
|
if (this.courseCompleteStatusList.length > 0) {
|
||||||
const subject2 = this.courseCompleteStatusList.find(item => item.subject === 2)
|
const subject2 = this.courseCompleteStatusList.find(item => item.subject === 2)
|
||||||
const subject3 = this.courseCompleteStatusList.find(item => item.subject === 3)
|
const subject3 = this.courseCompleteStatusList.find(item => item.subject === 3)
|
||||||
const subject1Or4 = this.courseCompleteStatusList.find(item => item.subject === 1 || item.subject === 4)
|
const subject1Or4 = this.courseCompleteStatusList.find(item => item.subject === 1 || item
|
||||||
|
.subject === 4)
|
||||||
if (subject1Or4) {
|
if (subject1Or4) {
|
||||||
this.courseType = subject1Or4.courseType
|
this.courseType = subject1Or4.courseType
|
||||||
}
|
}
|
||||||
|
|
||||||
if (subject2?.status === '2' && subject3?.status === '2') {
|
if (subject2?.status === '2' && subject3?.status === '2') {
|
||||||
this.subjectColumns = [['科目一', '科目四']]
|
this.subjectColumns = [
|
||||||
|
['科目一', '科目四']
|
||||||
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@ -394,8 +387,12 @@ export default {
|
|||||||
|
|
||||||
saveData() {
|
saveData() {
|
||||||
console.log('process', this.process)
|
console.log('process', this.process)
|
||||||
if (!this.process.userId || !this.process.subject || this.process.examScore === null || this.process.examStatus === null || !this.process.examTime) {
|
if (!this.process.userId || !this.process.subject || this.process.examScore === null || this.process
|
||||||
uni.showToast({title: '信息填写不完整', icon: 'none'});
|
.examStatus === null || !this.process.examTime) {
|
||||||
|
uni.showToast({
|
||||||
|
title: '信息填写不完整',
|
||||||
|
icon: 'none'
|
||||||
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (this.process.subject == 1 || this.process.subject == 4) {
|
if (this.process.subject == 1 || this.process.subject == 4) {
|
||||||
@ -407,24 +404,35 @@ export default {
|
|||||||
},
|
},
|
||||||
saveDataOne() {
|
saveDataOne() {
|
||||||
if (this.process.subject === 1 && this.courseCompleteStatusList.length <= 0) {
|
if (this.process.subject === 1 && this.courseCompleteStatusList.length <= 0) {
|
||||||
uni.showToast({title: '请联系驾校人员!', icon: 'none'});
|
uni.showToast({
|
||||||
|
title: '请联系驾校人员!',
|
||||||
|
icon: 'none'
|
||||||
|
});
|
||||||
return;
|
return;
|
||||||
|
|
||||||
}
|
}
|
||||||
if (this.process.subject === 4 && this.courseCompleteStatusList.length <= 0) {
|
if (this.process.subject === 4 && this.courseCompleteStatusList.length <= 0) {
|
||||||
uni.showToast({title: '请联系驾校人员!', icon: 'none'});
|
uni.showToast({
|
||||||
|
title: '请联系驾校人员!',
|
||||||
|
icon: 'none'
|
||||||
|
});
|
||||||
return;
|
return;
|
||||||
|
|
||||||
}
|
}
|
||||||
const postData = {
|
const postData = {
|
||||||
...this.process, // 先拷贝 process 原有数据
|
...this.process, // 先拷贝 process 原有数据
|
||||||
remark: this.process.remark,
|
remark: this.process.remark,
|
||||||
|
userName: this.userInfo.nickname,
|
||||||
images: this.fileList?.map(item => item.url).join(',') || '',
|
images: this.fileList?.map(item => item.url).join(',') || '',
|
||||||
}
|
}
|
||||||
// this.process.images = this.fileList?.map(item => item.url).join(',') || '';
|
// this.process.images = this.fileList?.map(item => item.url).join(',') || '';
|
||||||
|
|
||||||
if (!this.process.userId || !this.process.subject || this.process.examScore === null || this.process.examStatus === null || !this.process.examTime) {
|
if (!this.process.userId || !this.process.subject || this.process.examScore === null || this.process
|
||||||
uni.showToast({title: '信息填写不完整', icon: 'none'});
|
.examStatus === null || !this.process.examTime) {
|
||||||
|
uni.showToast({
|
||||||
|
title: '信息填写不完整',
|
||||||
|
icon: 'none'
|
||||||
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
console.log('postData', postData)
|
console.log('postData', postData)
|
||||||
@ -446,7 +454,10 @@ export default {
|
|||||||
});
|
});
|
||||||
}, 1500);
|
}, 1500);
|
||||||
} else {
|
} else {
|
||||||
uni.showToast({title: res.data?.message || '保存失败', icon: 'none'});
|
uni.showToast({
|
||||||
|
title: res.data?.message || '保存失败',
|
||||||
|
icon: 'none'
|
||||||
|
});
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
@ -455,18 +466,24 @@ export default {
|
|||||||
...this.process, // 先拷贝 process 原有数据
|
...this.process, // 先拷贝 process 原有数据
|
||||||
tenantId: this.opTenantId,
|
tenantId: this.opTenantId,
|
||||||
fraction: this.process.examScore,
|
fraction: this.process.examScore,
|
||||||
ifPass: this.process.examStatus,
|
ifPass: this.process.examStatus === 1,
|
||||||
id: this.batchItemId,
|
id: this.batchItemId,
|
||||||
remark: this.process.remark,
|
remark: this.process.remark,
|
||||||
|
userName: this.userInfo.nickname,
|
||||||
images: this.fileList?.map(item => item.url).join(',') || '',
|
images: this.fileList?.map(item => item.url).join(',') || '',
|
||||||
}
|
}
|
||||||
|
console.log('postData', postData)
|
||||||
/* this.process.userId = this.userInfo.id
|
/* this.process.userId = this.userInfo.id
|
||||||
this.process.tenantId = this.opTenantId
|
this.process.tenantId = this.opTenantId
|
||||||
this.process.fraction = this.process.examScore
|
this.process.fraction = this.process.examScore
|
||||||
this.process.ifPass = this.process.examStatus
|
this.process.ifPass = this.process.examStatus
|
||||||
this.process.images = this.fileList?.map(item => item.url).join(',') || ''; */
|
this.process.images = this.fileList?.map(item => item.url).join(',') || ''; */
|
||||||
if (!this.process.userId || !this.process.subject || this.process.examScore === null || this.process.examStatus === null || !this.process.examTime) {
|
if (!this.process.userId || !this.process.subject || this.process.examScore === null || this.process
|
||||||
uni.showToast({title: '信息填写不完整', icon: 'none'});
|
.examStatus === null || !this.process.examTime) {
|
||||||
|
uni.showToast({
|
||||||
|
title: '信息填写不完整',
|
||||||
|
icon: 'none'
|
||||||
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
request({
|
request({
|
||||||
@ -487,7 +504,10 @@ export default {
|
|||||||
});
|
});
|
||||||
}, 1500);
|
}, 1500);
|
||||||
} else {
|
} else {
|
||||||
uni.showToast({title: res.data?.message || '保存失败', icon: 'none'});
|
uni.showToast({
|
||||||
|
title: res.data?.message || '保存失败',
|
||||||
|
icon: 'none'
|
||||||
|
});
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -498,5 +518,4 @@ export default {
|
|||||||
<style lang='scss'>
|
<style lang='scss'>
|
||||||
@import '../common/common.scss';
|
@import '../common/common.scss';
|
||||||
@import './assets/style/index.rpx.scss';
|
@import './assets/style/index.rpx.scss';
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
@ -13,9 +13,8 @@
|
|||||||
<view class="block_3 flex-row justify-between">
|
<view class="block_3 flex-row justify-between">
|
||||||
<view class="text-group_1 flex-col justify-between">
|
<view class="text-group_1 flex-col justify-between">
|
||||||
|
|
||||||
<text class="text_2" v-if="item.subject == 1 || item.subject == 4">{{
|
<text class="text_2"
|
||||||
formatDate(item.examTime)
|
v-if="item.subject == 1 || item.subject == 4">{{ formatDate(item.examTime) }}
|
||||||
}}
|
|
||||||
</text>
|
</text>
|
||||||
<text class="text_2" v-else>{{ formatDate(item.startTime) }}</text>
|
<text class="text_2" v-else>{{ formatDate(item.startTime) }}</text>
|
||||||
<text class="text_3">{{ item.courseName }}</text>
|
<text class="text_3">{{ item.courseName }}</text>
|
||||||
@ -23,7 +22,9 @@
|
|||||||
<view class="text-group_2 flex-col justify-between">
|
<view class="text-group_2 flex-col justify-between">
|
||||||
<text class="text_4" v-if="item.examScore">{{ item.examScore }}</text>
|
<text class="text_4" v-if="item.examScore">{{ item.examScore }}</text>
|
||||||
<text class="text_4" v-else>{{ '--' }}</text>
|
<text class="text_4" v-else>{{ '--' }}</text>
|
||||||
<text class="text_5">{{ getStatusText(item.examStatus) }}</text>
|
<text class="text_5"
|
||||||
|
v-if="item.ifPassStatus === '9'">{{ getStatusText(item.ifPassStatus) }}</text>
|
||||||
|
<text class="text_5" v-else>{{ getStatusText(item.examStatus) }}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="block_4 flex-row justify-between">
|
<view class="block_4 flex-row justify-between">
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user