提交
This commit is contained in:
parent
ac0ac2776a
commit
f9ef4f5cd3
|
@ -156,27 +156,13 @@ export const dynamicRoutes = [
|
|||
permissions: ['qualification:vehicleTrain:editForm'],
|
||||
children: [
|
||||
{
|
||||
path: 'operation/:Id(\\d+)?',
|
||||
component: () => import('@/views/qualification/vehicleTrain/addForm'),
|
||||
path: ':Id(\\d+)?',
|
||||
component: () => import('@/views/qualification/vehicleTrain/form'),
|
||||
name: 'vehicleTrainForm',
|
||||
meta: { title: '车型培训记录维护', activeMenu: '/qualification/vehicleTrain' }
|
||||
}
|
||||
]
|
||||
},
|
||||
// {
|
||||
// path: '/qualification/vehicleTrain/editForm',
|
||||
// component: Layout,
|
||||
// hidden: true,
|
||||
// permissions: ['qualification:vehicleTrain:editForm'],
|
||||
// children: [
|
||||
// {
|
||||
// path: '',
|
||||
// component: () => import('@/views/qualification/vehicleTrain/editForm'),
|
||||
// name: 'editForm',
|
||||
// meta: { title: '编辑车型培训记录', activeMenu: '/qualification/vehicleTrain' }
|
||||
// }
|
||||
// ]
|
||||
// },
|
||||
{
|
||||
path: '/qualification/vehicleTrain/importForm',
|
||||
component: Layout,
|
||||
|
|
|
@ -1,323 +0,0 @@
|
|||
<template>
|
||||
<div class="app-page-container">
|
||||
<el-breadcrumb class="app-breadcrumb" separator=">">
|
||||
<transition-group name="breadcrumb">
|
||||
<el-breadcrumb-item v-for="(item, index) in levelList" :key="item.path">
|
||||
<span v-if="index == levelList.length - 1" class="link-redirect">{{
|
||||
item.title }}</span>
|
||||
<span v-else class="no-redirect">{{ item.title }}</span>
|
||||
</el-breadcrumb-item>
|
||||
</transition-group>
|
||||
</el-breadcrumb>
|
||||
<div class="rootContainer clearBoth">
|
||||
<el-card>
|
||||
<template #header>
|
||||
<div class="card-header">
|
||||
<span>编辑</span>
|
||||
</div>
|
||||
</template>
|
||||
<el-form ref="ruleFormRef" :model="ruleForm" :rules="rules" label-position="top">
|
||||
<div class="applyFormContainer">
|
||||
<el-row class="myRow" :gutter="20">
|
||||
<el-col :span="8">
|
||||
<el-form-item label="员工工号" prop="employeeNumber">
|
||||
<el-input v-model="ruleForm.employeeNumber" placeholder="请输入员工工号" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="车型" prop="targetQualification">
|
||||
<el-select v-model="ruleForm.targetQualification" placeholder="请选择车型">
|
||||
<el-option label="Zone one" value="shanghai" />
|
||||
<el-option label="Zone two" value="beijing" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="员工姓名" prop="employeeChineseName">
|
||||
<el-input v-model="ruleForm.employeeChineseName" placeholder="请输入员工姓名(中文)" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="属地" prop="localityName">
|
||||
<el-select v-model="ruleForm.localityName" placeholder="请选择属地">
|
||||
<el-option label="Zone one" value="shanghai" />
|
||||
<el-option label="Zone two" value="beijing" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="部门" prop="departmentName">
|
||||
<el-select v-model="ruleForm.departmentName" placeholder="请选择部门">
|
||||
<el-option label="Zone one" value="shanghai" />
|
||||
<el-option label="Zone two" value="beijing" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="培训时间" prop="officeName">
|
||||
<el-date-picker v-model="ruleForm.trainTime" type="date" placeholder="请选择培训时间" style="width: 100%;" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
</el-form>
|
||||
</el-card>
|
||||
</div>
|
||||
|
||||
<div class="submitTool">
|
||||
<el-button class="cancelApplyBtn" @click="handleCancel">取消</el-button>
|
||||
<el-button class="submitApplyBtn" @click="handleSubmit">提交</el-button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</template>
|
||||
<script setup>
|
||||
import { reactive } from 'vue'
|
||||
import { useRouter } from 'vue-router'
|
||||
|
||||
const router = useRouter()
|
||||
const levelList = ref([
|
||||
{ title: '资质管理', path: '/qualification' },
|
||||
{ title: '车型培训情况', path: '/qualification/vehicleTrain' },
|
||||
{ title: '编辑', path: '/qualification/vehicleTrain/editForm' }
|
||||
])
|
||||
const { proxy } = getCurrentInstance()
|
||||
const data = reactive({
|
||||
ruleForm: {},
|
||||
rules: {
|
||||
targetQualification: [{ required: true, message: "目标资质不能为空", trigger: "change" }],
|
||||
employeeNumber: [{ required: true, message: "员工工号不能为空", trigger: "blur" }],
|
||||
employeeChineseName: [{ required: true, message: "员工姓名(中文)不能为空", trigger: "blur" }],
|
||||
employeeEnglishName: [{ required: true, message: "员工姓名(英文)", trigger: "blur" }],
|
||||
departmentName: [{ required: true, message: "部门不能为空", trigger: "change" }],
|
||||
officeName: [{ required: true, message: "科室不能为空", trigger: "change" }],
|
||||
localityName: [{ required: true, message: "属地不能为空", trigger: "change" }],
|
||||
localityManager: [{ required: true, message: "属地ESC不能为空", trigger: "blur" }],
|
||||
},
|
||||
})
|
||||
const { ruleForm, rules } = toRefs(data)
|
||||
const handleCancel = () => {
|
||||
proxy.resetForm("ruleFormRef")
|
||||
router.push({
|
||||
path: '/qualification/vehicleTrain'
|
||||
})
|
||||
}
|
||||
const handleSubmit = () => {
|
||||
proxy.$refs["ruleFormRef"].validate(valid => {
|
||||
if (valid) {
|
||||
router.push({
|
||||
path: '/qualification/vehicleTrain'
|
||||
})
|
||||
// if (form.value.roleId != undefined) {
|
||||
// form.value.menuIds = getMenuAllCheckedKeys()
|
||||
// updateRole(form.value).then(response => {
|
||||
// proxy.$modal.msgSuccess("修改成功")
|
||||
// open.value = false
|
||||
// getList()
|
||||
// })
|
||||
// } else {
|
||||
// form.value.menuIds = getMenuAllCheckedKeys()
|
||||
// addRole(form.value).then(response => {
|
||||
// proxy.$modal.msgSuccess("新增成功")
|
||||
// open.value = false
|
||||
// getList()
|
||||
// })
|
||||
// }
|
||||
}
|
||||
})
|
||||
}
|
||||
</script>
|
||||
<style lang='scss'>
|
||||
.app-main {
|
||||
height: 100vh;
|
||||
width: 100%;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
background-color: #F8F8F8;
|
||||
}
|
||||
|
||||
.app-breadcrumb.el-breadcrumb {
|
||||
width: 1200px;
|
||||
margin: 0 auto;
|
||||
height: 44px;
|
||||
line-height: 44px;
|
||||
font-size: 18px;
|
||||
background: #f8f8f8;
|
||||
|
||||
.el-breadcrumb__item {
|
||||
.el-breadcrumb__separator {
|
||||
font-family: Microsoft YaHei;
|
||||
font-weight: 400;
|
||||
font-size: 18px;
|
||||
color: #000000 !important;
|
||||
margin: 0 9px;
|
||||
}
|
||||
}
|
||||
|
||||
.no-redirect {
|
||||
font-family: Microsoft YaHei;
|
||||
font-weight: 400;
|
||||
font-size: 18px;
|
||||
color: #000000;
|
||||
cursor: text;
|
||||
}
|
||||
|
||||
.link-redirect {
|
||||
font-family: Microsoft YaHei;
|
||||
font-weight: 400;
|
||||
font-size: 18px;
|
||||
color: #0090FF;
|
||||
cursor: text;
|
||||
text-decoration: underline;
|
||||
text-underline-offset: 4px;
|
||||
}
|
||||
}
|
||||
|
||||
.clearBoth {
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.rootContainer {
|
||||
width: 1200px;
|
||||
margin: 0 auto;
|
||||
height: calc(100vh - 216px);
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
background: #ffffff;
|
||||
}
|
||||
|
||||
.el-card {
|
||||
border: none;
|
||||
}
|
||||
|
||||
.el-card__header {
|
||||
min-height: 50px;
|
||||
font-family: Microsoft YaHei;
|
||||
font-weight: 700;
|
||||
font-size: 20px;
|
||||
text-align: left;
|
||||
color: #000000;
|
||||
border-bottom: 1px solid #DCDCDC;
|
||||
box-sizing: border-box;
|
||||
padding: 10px 20px 17px 20px;
|
||||
}
|
||||
|
||||
.el-card__body {
|
||||
padding: 20px 20px 0 20px !important;
|
||||
}
|
||||
|
||||
.el-card.is-always-shadow {
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
.successText {
|
||||
font-family: Microsoft YaHei;
|
||||
font-weight: 400;
|
||||
font-size: 18px;
|
||||
color: #00B32A;
|
||||
}
|
||||
|
||||
.dangerText {
|
||||
font-family: Microsoft YaHei;
|
||||
font-weight: 400;
|
||||
font-size: 18px;
|
||||
color: #E13434;
|
||||
}
|
||||
|
||||
.applyFormContainer {
|
||||
padding-top: 20px;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.submitTool {
|
||||
width: 100%;
|
||||
height: 76px;
|
||||
position: absolute;
|
||||
top: calc(100% - 76px);
|
||||
background: #ffffff;
|
||||
box-shadow: 1px 2px 10px 0 #93939333;
|
||||
text-align: center;
|
||||
line-height: 76px;
|
||||
}
|
||||
|
||||
.cancelApplyBtn {
|
||||
width: 100px;
|
||||
height: 36px;
|
||||
border-radius: 4px 4px 4px 4px;
|
||||
background: #ea9f0e;
|
||||
font-family: Microsoft YaHei;
|
||||
font-weight: 700;
|
||||
font-size: 16px;
|
||||
text-align: center;
|
||||
color: #FFFFFF;
|
||||
}
|
||||
|
||||
.cancelApplyBtn:hover {
|
||||
background: #ea9f0e;
|
||||
color: #FFFFFF;
|
||||
}
|
||||
|
||||
.submitApplyBtn {
|
||||
width: 100px;
|
||||
height: 36px;
|
||||
border-radius: 4px 4px 4px 4px;
|
||||
background: #4276d1;
|
||||
font-family: Microsoft YaHei;
|
||||
font-weight: 700;
|
||||
font-size: 16px;
|
||||
text-align: center;
|
||||
color: #FFFFFF;
|
||||
}
|
||||
|
||||
.submitApplyBtn:hover {
|
||||
background: #4276d1;
|
||||
color: #FFFFFF;
|
||||
}
|
||||
|
||||
.myRow {
|
||||
margin-left: 0 !important;
|
||||
margin-right: 0 !important;
|
||||
}
|
||||
|
||||
.el-form-item--default {
|
||||
margin-bottom: 20px !important;
|
||||
}
|
||||
|
||||
.el-form-item--label-top .el-form-item__label {
|
||||
font-family: Microsoft YaHei;
|
||||
font-weight: 400;
|
||||
font-size: 18px;
|
||||
text-align: left;
|
||||
color: #666666;
|
||||
}
|
||||
|
||||
.el-input__inner {
|
||||
font-weight: 400;
|
||||
font-size: 18px;
|
||||
text-align: left;
|
||||
color: #000000;
|
||||
}
|
||||
|
||||
.el-select__wrapper {
|
||||
font-weight: 400;
|
||||
font-size: 18px;
|
||||
text-align: left;
|
||||
color: #000000;
|
||||
}
|
||||
|
||||
.el-form-item__error {
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.el-radio__inner {
|
||||
width: 16px !important;
|
||||
height: 16px !important;
|
||||
}
|
||||
|
||||
.el-radio__label {
|
||||
font-weight: 400;
|
||||
font-size: 18px;
|
||||
text-align: left;
|
||||
color: #000000;
|
||||
}
|
||||
</style>
|
|
@ -134,10 +134,10 @@ const getList = () => {
|
|||
})
|
||||
}
|
||||
const handleOpenAddForm = () => {
|
||||
router.push('/qualification/vehicleTrain/Form/operation')
|
||||
router.push('/qualification/vehicleTrain/Form')
|
||||
}
|
||||
const handleEdit = (record) => {
|
||||
router.push("/qualification/vehicleTrain/Form/operation/" + record.id)
|
||||
router.push("/qualification/vehicleTrain/Form/" + record.id)
|
||||
}
|
||||
/** 删除按钮操作 */
|
||||
const handleDelete = (row) => {
|
||||
|
|
Loading…
Reference in New Issue
Block a user