专家入驻
This commit is contained in:
@ -12,7 +12,7 @@ export function settled() {
|
|||||||
url: '/enterprise/v1/settled'
|
url: '/enterprise/v1/settled'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
// 公司企业入职
|
// 公司企业入驻
|
||||||
export function company(data) {
|
export function company(data) {
|
||||||
return request({
|
return request({
|
||||||
url: '/enterprise/v1/settled/company',
|
url: '/enterprise/v1/settled/company',
|
||||||
@ -20,3 +20,23 @@ export function company(data) {
|
|||||||
data
|
data
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
// 所属单位
|
||||||
|
export function researchSelect() {
|
||||||
|
return request({
|
||||||
|
url: '/enterprise/v1/manage/research/select',
|
||||||
|
});
|
||||||
|
}
|
||||||
|
// 所属单位>实验室
|
||||||
|
export function laboratorySelect() {
|
||||||
|
return request({
|
||||||
|
url: '/enterprise/v1/manage/research/laboratory',
|
||||||
|
});
|
||||||
|
}
|
||||||
|
// 专家入驻
|
||||||
|
export function expert(data) {
|
||||||
|
return request({
|
||||||
|
url: '/enterprise/v1/settled/expert',
|
||||||
|
method:'post',
|
||||||
|
data
|
||||||
|
});
|
||||||
|
}
|
244
src/views/identity/components/EnterpriseForm/index.vue
Normal file
244
src/views/identity/components/EnterpriseForm/index.vue
Normal file
@ -0,0 +1,244 @@
|
|||||||
|
<template>
|
||||||
|
<el-form
|
||||||
|
ref="formRef"
|
||||||
|
:model="modelValue"
|
||||||
|
:rules="rules"
|
||||||
|
:label-width="labelWidth + 'px'"
|
||||||
|
>
|
||||||
|
<div class="form_title" v-if="showTitle">基本信息</div>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="24">
|
||||||
|
<el-form-item label="企业logo:">
|
||||||
|
<ImageUpload v-model="modelValue.image" :fileSize="2" :limit="1" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="24">
|
||||||
|
<el-form-item label="单位名称" prop="name">
|
||||||
|
<el-input v-model="modelValue.name"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="24">
|
||||||
|
<el-form-item label="组织机构代码:" prop="code">
|
||||||
|
<el-row type="flex" justify="space-between">
|
||||||
|
<el-col :span="20">
|
||||||
|
<el-input v-model="modelValue.code"></el-input>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="3">
|
||||||
|
<el-button type="primary" @click="">查找</el-button>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="24">
|
||||||
|
<el-form-item label="企业类型:" prop="kind">
|
||||||
|
<el-select v-model="modelValue.kind" placeholder="请选择">
|
||||||
|
<el-option
|
||||||
|
v-for="item in enterpriseOptions"
|
||||||
|
:key="item.key"
|
||||||
|
:label="item.value"
|
||||||
|
:value="item.key"
|
||||||
|
>
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="24">
|
||||||
|
<el-form-item label="核心成果核心产品:" prop="product">
|
||||||
|
<el-input v-model="modelValue.product"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<CityOptions v-model="modelValue" :labelWidth="labelWidth" ref="cityForm" />
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="24">
|
||||||
|
<el-form-item label="详细地址:">
|
||||||
|
<el-input v-model="modelValue.address"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<FieldOptions
|
||||||
|
v-model="modelValue"
|
||||||
|
:labelWidth="labelWidth"
|
||||||
|
ref="fieldForm"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<InputBoxAdd
|
||||||
|
:labelWidth="labelWidth"
|
||||||
|
v-model="modelValue"
|
||||||
|
title="关键词"
|
||||||
|
placeholder="应用场景关键词+技术产品关键词"
|
||||||
|
fieldKey="keywords"
|
||||||
|
ref="keywordsForm"
|
||||||
|
/>
|
||||||
|
<InputBoxAdd
|
||||||
|
:labelWidth="labelWidth"
|
||||||
|
v-model="modelValue"
|
||||||
|
title="生产方向"
|
||||||
|
placeholder="请输入生产方向"
|
||||||
|
fieldKey="directions"
|
||||||
|
ref="directionsForm"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="24">
|
||||||
|
<el-form-item label="邀请码:">
|
||||||
|
<el-input v-model="modelValue.inviter_code"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="24">
|
||||||
|
<el-form-item label="企业网站:">
|
||||||
|
<el-input v-model="modelValue.url"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="24">
|
||||||
|
<el-form-item label="营业执照:" prop="license">
|
||||||
|
<ImageUpload
|
||||||
|
v-model="modelValue.license"
|
||||||
|
:isShowTip="false"
|
||||||
|
:limit="1"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="24">
|
||||||
|
<el-form-item label="单位简介" prop="introduce">
|
||||||
|
<Editor
|
||||||
|
v-model="modelValue.introduce"
|
||||||
|
:minHeight="150"
|
||||||
|
ref="introduceRef"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-form>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import CityOptions from "../CityOptions";
|
||||||
|
import FieldOptions from "../FieldOptions";
|
||||||
|
import InputBoxAdd from "../InputBoxAdd";
|
||||||
|
// import { researchSelect, laboratorySelect } from "@/api/identity/index";
|
||||||
|
export default {
|
||||||
|
components: {
|
||||||
|
CityOptions,
|
||||||
|
FieldOptions,
|
||||||
|
InputBoxAdd,
|
||||||
|
},
|
||||||
|
props: {
|
||||||
|
modelValue: Object,
|
||||||
|
isAdd: {
|
||||||
|
type: Boolean,
|
||||||
|
default: true,
|
||||||
|
},
|
||||||
|
showTitle: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
},
|
||||||
|
labelWidth: {
|
||||||
|
type: Number,
|
||||||
|
default: 120,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
rules: {
|
||||||
|
product: [{ required: true, message: "请输入", trigger: "blur" }],
|
||||||
|
name: [{ required: true, message: "请输入", trigger: "blur" }],
|
||||||
|
kind: [{ required: true, message: "请选择", trigger: "change" }],
|
||||||
|
code: [{ required: true, message: "请输入", trigger: "blur" }],
|
||||||
|
mobile: [
|
||||||
|
{ required: true, message: "请输入", trigger: "blur" },
|
||||||
|
{
|
||||||
|
pattern: /^1[3|4|5|6|7|8|9][0-9]\d{8}$/,
|
||||||
|
message: "请输入正确的手机号码",
|
||||||
|
trigger: "blur",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
research_id: [{ required: true, message: "请选择", trigger: "change" }],
|
||||||
|
tenant_id: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: "请选择",
|
||||||
|
trigger: ["blur", "change"],
|
||||||
|
},
|
||||||
|
],
|
||||||
|
school: [{ required: true, message: "请输入", trigger: "blur" }],
|
||||||
|
education: [{ required: true, message: "请选择", trigger: "change" }],
|
||||||
|
major: [{ required: true, message: "请输入", trigger: "blur" }],
|
||||||
|
job: [{ required: true, message: "请输入", trigger: "blur" }],
|
||||||
|
title: [{ required: true, message: "请输入", trigger: "blur" }],
|
||||||
|
work_at: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: "从业时间不能为空",
|
||||||
|
trigger: ["change", "blur"],
|
||||||
|
},
|
||||||
|
],
|
||||||
|
license: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: "请上传",
|
||||||
|
trigger: ["blur", "change"],
|
||||||
|
},
|
||||||
|
],
|
||||||
|
introduce: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: "请输入",
|
||||||
|
trigger: ["change", "blur"],
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
};
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
submitForm() {
|
||||||
|
let flag = false;
|
||||||
|
this.$refs["formRef"].validate((valid) => {
|
||||||
|
const cityForm = this.$refs.cityForm.submitForm(); // 城市
|
||||||
|
const fieldForm = this.$refs.fieldForm.submitForm();
|
||||||
|
const keywordsForm = this.$refs.keywordsForm.submitForm();
|
||||||
|
const directionsForm = this.$refs.directionsForm.submitForm();
|
||||||
|
if (valid && cityForm && fieldForm && keywordsForm && directionsForm) {
|
||||||
|
flag = !flag;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
return flag;
|
||||||
|
},
|
||||||
|
},
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.form_title {
|
||||||
|
font-weight: 700;
|
||||||
|
margin-bottom: 30px;
|
||||||
|
}
|
||||||
|
// 上传图片框限制
|
||||||
|
// ::v-deep .el-upload--picture-card {
|
||||||
|
// width: 120px;
|
||||||
|
// height: 120px;
|
||||||
|
// line-height: 120px;
|
||||||
|
// }
|
||||||
|
.el-select,
|
||||||
|
.el-date-editor {
|
||||||
|
display: block;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
</style>
|
@ -16,51 +16,128 @@
|
|||||||
</el-row>
|
</el-row>
|
||||||
|
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="24">
|
<el-col :span="12">
|
||||||
<el-form-item label="单位名称" prop="name">
|
<el-form-item label="姓名:" prop="name">
|
||||||
<el-input v-model="modelValue.name"></el-input>
|
<el-input v-model="modelValue.name"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
<el-col :span="12">
|
||||||
|
<el-form-item label="手机号:" prop="mobile">
|
||||||
<el-row>
|
<el-input v-model="modelValue.mobile"></el-input>
|
||||||
<el-col :span="24">
|
|
||||||
<el-form-item label="组织机构代码:" prop="code">
|
|
||||||
<el-row type="flex" justify="space-between">
|
|
||||||
<el-col :span="20">
|
|
||||||
<el-input v-model="modelValue.code"></el-input>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="3">
|
|
||||||
<el-button type="primary" @click="">查找</el-button>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="24">
|
<el-col :span="12">
|
||||||
<el-form-item label="企业类型:" prop="kind">
|
<el-form-item label="所属单位:" prop="research_id">
|
||||||
<el-select v-model="modelValue.kind" placeholder="请选择">
|
<el-select
|
||||||
|
v-model="modelValue.research_id"
|
||||||
|
filterable
|
||||||
|
placeholder="请选择"
|
||||||
|
@change="setLaboratory"
|
||||||
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in enterpriseOptions"
|
v-for="item in researchOptions"
|
||||||
:key="item.key"
|
:key="item.id"
|
||||||
:label="item.value"
|
:label="item.name"
|
||||||
:value="item.key"
|
:value="item.id"
|
||||||
>
|
>
|
||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="24">
|
<el-col :span="12">
|
||||||
<el-form-item label="核心成果核心产品:" prop="product">
|
<el-form-item label="所属实验室:">
|
||||||
<el-input v-model="modelValue.product"></el-input>
|
<el-select
|
||||||
|
v-model="modelValue.laboratory_id"
|
||||||
|
filterable
|
||||||
|
placeholder="请选择"
|
||||||
|
>
|
||||||
|
<el-option
|
||||||
|
v-for="item in options"
|
||||||
|
:key="item.value"
|
||||||
|
:label="item.label"
|
||||||
|
:value="item.value"
|
||||||
|
>
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
||||||
<CityOptions v-model="modelValue" :labelWidth="labelWidth" ref="cityForm" />
|
<CityOptions v-model="modelValue" :labelWidth="labelWidth" ref="cityForm" />
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="24">
|
||||||
|
<el-form-item label="详细地址:">
|
||||||
|
<el-input v-model="modelValue.address"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="24">
|
||||||
|
<el-form-item label="毕业院校:" prop="school">
|
||||||
|
<el-input v-model="modelValue.school"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="最高学历:" prop="education">
|
||||||
|
<el-select v-model="modelValue.education" placeholder="请选择">
|
||||||
|
<el-option
|
||||||
|
v-for="item in educationOptions"
|
||||||
|
:key="item.text"
|
||||||
|
:label="item.text"
|
||||||
|
:value="item.text"
|
||||||
|
>
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="主修专业:" prop="major">
|
||||||
|
<el-input v-model="modelValue.major"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="职务:" prop="job">
|
||||||
|
<el-input v-model="modelValue.job"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="职称:" prop="title">
|
||||||
|
<el-input v-model="modelValue.title"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="从业时间:" prop="work_at">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="modelValue.work_at"
|
||||||
|
type="date"
|
||||||
|
value-format="YYYY-MM-DD"
|
||||||
|
placeholder="选择日期"
|
||||||
|
>
|
||||||
|
</el-date-picker>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="性别:" prop="gender">
|
||||||
|
<el-radio v-model="modelValue.gender" :label="1">男</el-radio>
|
||||||
|
<el-radio v-model="modelValue.gender" :label="2">女</el-radio>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
<FieldOptions
|
<FieldOptions
|
||||||
v-model="modelValue"
|
v-model="modelValue"
|
||||||
:labelWidth="labelWidth"
|
:labelWidth="labelWidth"
|
||||||
@ -78,44 +155,21 @@
|
|||||||
<InputBoxAdd
|
<InputBoxAdd
|
||||||
:labelWidth="labelWidth"
|
:labelWidth="labelWidth"
|
||||||
v-model="modelValue"
|
v-model="modelValue"
|
||||||
title="生产方向"
|
title="研究方向"
|
||||||
placeholder="请输入生产方向"
|
placeholder="请输入研究方向"
|
||||||
fieldKey="directions"
|
fieldKey="researchs"
|
||||||
ref="directionsForm"
|
ref="researchsForm"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="24">
|
<el-col :span="24">
|
||||||
<el-form-item label="邀请码:">
|
<el-form-item label="个人简介" prop="introduce">
|
||||||
<el-input v-model="modelValue.inviter_code"></el-input>
|
<el-input
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="24">
|
|
||||||
<el-form-item label="企业网站:">
|
|
||||||
<el-input v-model="modelValue.url"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
|
|
||||||
<el-row>
|
|
||||||
<el-col :span="24">
|
|
||||||
<el-form-item label="营业执照:" prop="license">
|
|
||||||
<ImageUpload
|
|
||||||
v-model="modelValue.license"
|
|
||||||
:isShowTip="false"
|
|
||||||
:limit="1"
|
|
||||||
/>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
|
|
||||||
<el-row>
|
|
||||||
<el-col :span="24">
|
|
||||||
<el-form-item label="单位简介" prop="introduce">
|
|
||||||
<Editor
|
|
||||||
v-model="modelValue.introduce"
|
v-model="modelValue.introduce"
|
||||||
:minHeight="150"
|
type="textarea"
|
||||||
ref="introduceRef"
|
:autosize="{ minRows: 2, maxRows: 8 }"
|
||||||
|
maxlength="400"
|
||||||
|
show-word-limit
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
@ -126,7 +180,7 @@
|
|||||||
import CityOptions from "../CityOptions";
|
import CityOptions from "../CityOptions";
|
||||||
import FieldOptions from "../FieldOptions";
|
import FieldOptions from "../FieldOptions";
|
||||||
import InputBoxAdd from "../InputBoxAdd";
|
import InputBoxAdd from "../InputBoxAdd";
|
||||||
// import { researchSelect, laboratorySelect } from "@/api/identity/index";
|
import { researchSelect, laboratorySelect } from "@/api/identity/index";
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
CityOptions,
|
CityOptions,
|
||||||
@ -150,6 +204,8 @@ export default {
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
researchOptions: [],
|
||||||
|
options: [],
|
||||||
rules: {
|
rules: {
|
||||||
product: [{ required: true, message: "请输入", trigger: "blur" }],
|
product: [{ required: true, message: "请输入", trigger: "blur" }],
|
||||||
name: [{ required: true, message: "请输入", trigger: "blur" }],
|
name: [{ required: true, message: "请输入", trigger: "blur" }],
|
||||||
@ -201,20 +257,29 @@ export default {
|
|||||||
};
|
};
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
setLaboratory(e) {
|
||||||
|
// laboratorySelect({ research_id: e }).then((res) => {
|
||||||
|
// console.log(res);
|
||||||
|
// });
|
||||||
|
},
|
||||||
submitForm() {
|
submitForm() {
|
||||||
let flag = false;
|
let flag = false;
|
||||||
this.$refs["formRef"].validate((valid) => {
|
this.$refs["formRef"].validate((valid) => {
|
||||||
const cityForm = this.$refs.cityForm.submitForm(); // 城市
|
const cityForm = this.$refs.cityForm.submitForm(); // 城市
|
||||||
const fieldForm = this.$refs.fieldForm.submitForm();
|
const fieldForm = this.$refs.fieldForm.submitForm();
|
||||||
const keywordsForm = this.$refs.keywordsForm.submitForm();
|
const keywordsForm = this.$refs.keywordsForm.submitForm();
|
||||||
const directionsForm = this.$refs.directionsForm.submitForm();
|
if (valid && cityForm && fieldForm && keywordsForm) {
|
||||||
if (valid && cityForm && fieldForm && keywordsForm && directionsForm) {
|
|
||||||
flag = !flag;
|
flag = !flag;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
return flag;
|
return flag;
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
created() {
|
||||||
|
researchSelect().then(({ data }) => {
|
||||||
|
this.researchOptions = data;
|
||||||
|
});
|
||||||
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
@ -23,7 +23,8 @@ const form = reactive({});
|
|||||||
function submitForm(status) {
|
function submitForm(status) {
|
||||||
if (proxy.$refs.enterpriseForm.submitForm()) {
|
if (proxy.$refs.enterpriseForm.submitForm()) {
|
||||||
company(form).then((res) => {
|
company(form).then((res) => {
|
||||||
console.log(res);
|
proxy.$modal.msgSuccess("新增成功");
|
||||||
|
proxy.$router.go(-1);
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
console.log("校验未通过");
|
console.log("校验未通过");
|
||||||
|
@ -1,3 +1,36 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>expert</div>
|
<div class="app-container">
|
||||||
</template>
|
<el-card shadow="always" style="width: 55%; margin: 0 auto">
|
||||||
|
<ExpertForm
|
||||||
|
v-model="form"
|
||||||
|
:isAdd="false"
|
||||||
|
:labelWidth="labelWidth"
|
||||||
|
ref="expertForm"
|
||||||
|
/>
|
||||||
|
<div :style="{ marginLeft: labelWidth + 'px' }">
|
||||||
|
<el-button @click="$router.go(-1)">取消</el-button>
|
||||||
|
<el-button type="primary" @click="submitForm">提交</el-button>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script setup>
|
||||||
|
import { expert } from "@/api/identity/index";
|
||||||
|
import ExpertForm from "./components/ExpertForm";
|
||||||
|
const { proxy } = getCurrentInstance();
|
||||||
|
const labelWidth = 140;
|
||||||
|
const form = reactive({
|
||||||
|
laboratory_id: undefined, // 所属实验室
|
||||||
|
gender: 1,
|
||||||
|
});
|
||||||
|
function submitForm(status) {
|
||||||
|
if (proxy.$refs.expertForm.submitForm()) {
|
||||||
|
expert(form).then((res) => {
|
||||||
|
proxy.$modal.msgSuccess("新增成功");
|
||||||
|
proxy.$router.go(-1);
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
console.log("校验未通过");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
@ -72,7 +72,7 @@ onMounted(() => {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
function reason(item) {
|
function reason(item) {
|
||||||
alert("拒绝原因\n" + item.remark);
|
alert("拒绝原因:\n" + item.remark);
|
||||||
}
|
}
|
||||||
function noClicking() {
|
function noClicking() {
|
||||||
return identityList.value.some((item) => item.status === 0);
|
return identityList.value.some((item) => item.status === 0);
|
||||||
|
Reference in New Issue
Block a user