|
@@ -0,0 +1,369 @@
|
|
|
+<template>
|
|
|
+ <div class="page">
|
|
|
+ <el-card shadow="never" style="margin-top: 1rem; padding: 1rem">
|
|
|
+ <h1>技术创新需求表填写</h1>
|
|
|
+
|
|
|
+ <el-form
|
|
|
+ :model="patentForm"
|
|
|
+ class="patent-form"
|
|
|
+ label-width="120px"
|
|
|
+ label-position="left"
|
|
|
+ >
|
|
|
+ <div class="page-title">企业信息</div>
|
|
|
+
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item class="form-item" label="企业名称">
|
|
|
+ <el-input
|
|
|
+ class="custom-input"
|
|
|
+ v-model="patentForm.companyIdentification"
|
|
|
+ placeholder="请输入企业名称"
|
|
|
+ ></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item class="form-item" label="社会信用代码">
|
|
|
+ <el-input
|
|
|
+ class="custom-input"
|
|
|
+ v-model="patentForm.socialCreditCode"
|
|
|
+ placeholder="请输入社会信用代码"
|
|
|
+ ></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item class="form-item" label="所在区域省份">
|
|
|
+ <el-cascader
|
|
|
+ style="width: 100%"
|
|
|
+ placeholder="请选择国家地区"
|
|
|
+ v-model="patentForm.provinces"
|
|
|
+ :options="region"
|
|
|
+ :props="{
|
|
|
+ emitPath: false,
|
|
|
+ }"
|
|
|
+ />
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item class="form-item" label="所属行业">
|
|
|
+ <el-input
|
|
|
+ class="custom-input"
|
|
|
+ v-model="patentForm.sector"
|
|
|
+ placeholder="请输入所属行业"
|
|
|
+ ></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item class="form-item" label="联系人">
|
|
|
+ <el-input
|
|
|
+ class="custom-input"
|
|
|
+ v-model="patentForm.associates"
|
|
|
+ placeholder="请输入联系人"
|
|
|
+ ></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item class="form-item" label="联系电话">
|
|
|
+ <el-input
|
|
|
+ class="custom-input"
|
|
|
+ v-model="patentForm.contactNumber"
|
|
|
+ placeholder="请输入联系电话"
|
|
|
+ ></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item class="form-item" label="邮箱">
|
|
|
+ <el-input
|
|
|
+ class="custom-input"
|
|
|
+ v-model="patentForm.email"
|
|
|
+ placeholder="请输入邮箱"
|
|
|
+ ></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+
|
|
|
+ <div class="section-title">需求信息</div>
|
|
|
+
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item class="form-item" label="技术需求名称">
|
|
|
+ <el-input
|
|
|
+ class="custom-input"
|
|
|
+ v-model="patentForm.technologicalNeedsName"
|
|
|
+ placeholder="请输入技术需求名称"
|
|
|
+ ></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item class="form-item" label="需求类型">
|
|
|
+ <el-select
|
|
|
+ v-model="patentForm.technologicalNeedsType"
|
|
|
+ placeholder="请选择需求类型"
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="item in technological_innovation_demand_type"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item class="form-item" label="意向合作大学">
|
|
|
+ <el-input
|
|
|
+ class="custom-input"
|
|
|
+ v-model="patentForm.cooperativeUnit"
|
|
|
+ placeholder="请输入意向合作大学"
|
|
|
+ ></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item class="form-item" label="时间要求">
|
|
|
+ <el-input
|
|
|
+ class="custom-input"
|
|
|
+ v-model="patentForm.timeRequirement"
|
|
|
+ placeholder="请输入时间要求"
|
|
|
+ ></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item class="form-item" label="拟投入资金">
|
|
|
+ <el-input
|
|
|
+ class="custom-input"
|
|
|
+ v-model="patentForm.capital"
|
|
|
+ placeholder="请输入拟投入资金"
|
|
|
+ ></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item class="form-item" label="拟实现的主要技术目标">
|
|
|
+ <el-input
|
|
|
+ class="custom-input"
|
|
|
+ v-model="patentForm.technicalTarget"
|
|
|
+ placeholder="请输入拟实现的主要技术目标"
|
|
|
+ ></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item class="form-item" label="需解决的主要技术问题">
|
|
|
+ <el-input
|
|
|
+ class="custom-input"
|
|
|
+ v-model="patentForm.pointOfPain"
|
|
|
+ placeholder="请输入需解决的主要技术问题"
|
|
|
+ ></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+
|
|
|
+ <div class="button-container">
|
|
|
+ <el-button type="primary" @click="goBack">返回</el-button>
|
|
|
+ <el-button type="primary" @click="submitApplication"
|
|
|
+ >提交申请</el-button
|
|
|
+ >
|
|
|
+ </div>
|
|
|
+ </el-form>
|
|
|
+ </el-card>
|
|
|
+ </div>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script lang="ts" setup>
|
|
|
+import { ref, onMounted } from "vue";
|
|
|
+import { ElMessage } from "element-plus";
|
|
|
+import { useDictStore } from "@/store/modules/useDictStore/index";
|
|
|
+import { postTechnologyInnovationRequirementsCreate } from "@/api";
|
|
|
+import { useRouter } from "vue-router";
|
|
|
+const router = useRouter();
|
|
|
+// 字典
|
|
|
+const dictStore = useDictStore();
|
|
|
+const technological_innovation_demand_type =
|
|
|
+ dictStore.dictData.technological_innovation_demand_type; // 需求类型字典
|
|
|
+const region = dictStore.dictData.region; // 区域省份字典
|
|
|
+
|
|
|
+// 定义 PatentForm 接口
|
|
|
+interface PatentForm {
|
|
|
+ companyIdentification: string; // 企业名称
|
|
|
+ socialCreditCode: string; // 社会信用代码
|
|
|
+ provinces: number; // 所在区域省份
|
|
|
+ sector: string; // 所属行业
|
|
|
+ associates: string; // 联系人
|
|
|
+ contactNumber: string; // 联系电话
|
|
|
+ email: string; // 邮箱
|
|
|
+ technologicalNeedsName: string; // 技术需求名称
|
|
|
+ technologicalNeedsType: string; // 需求类型
|
|
|
+ cooperativeUnit: string; // 意向合作大学
|
|
|
+ timeRequirement: string; // 时间要求
|
|
|
+ capital: string; // 拟投入资金
|
|
|
+ technicalTarget: string; // 拟实现的主要技术目标
|
|
|
+ pointOfPain: string; // 需解决的主要技术问题
|
|
|
+}
|
|
|
+
|
|
|
+// 创建一个新的 patentForm
|
|
|
+const patentForm = ref<PatentForm>({
|
|
|
+ companyIdentification: "企业名称", // 企业名称示例值
|
|
|
+ socialCreditCode: "社会信用代码1", // 社会信用代码示例值
|
|
|
+ provinces: 1101, // 所在区域省份示例值,替换为实际的数字代码
|
|
|
+ sector: "所属行业", // 所属行业示例值
|
|
|
+ associates: "联系人", // 联系人示例值
|
|
|
+ contactNumber: "联系电话", // 联系电话示例值
|
|
|
+ email: "邮箱", // 邮箱示例值
|
|
|
+ technologicalNeedsName: "技术需求名称", // 技术需求名称示例值
|
|
|
+ technologicalNeedsType: "需求类别", // 需求类型示例值,替换为实际字典值
|
|
|
+ cooperativeUnit: "合作单位", // 意向合作大学示例值
|
|
|
+ timeRequirement: "时间要求", // 时间要求示例值
|
|
|
+ capital: "资金", // 拟投入资金示例值
|
|
|
+ technicalTarget: "技术目标", // 拟实现的主要技术目标示例值
|
|
|
+ pointOfPain: "需解决的主要技术问题", // 需解决的主要技术问题示例值
|
|
|
+});
|
|
|
+
|
|
|
+// 初始化数据
|
|
|
+onMounted(() => {
|
|
|
+ // 初始化时的操作(如果有需要)
|
|
|
+});
|
|
|
+
|
|
|
+const goBack = () => {
|
|
|
+ router.push({
|
|
|
+ path: "/demand",
|
|
|
+ });
|
|
|
+};
|
|
|
+
|
|
|
+const submitApplication = async () => {
|
|
|
+ const res = (await postTechnologyInnovationRequirementsCreate(
|
|
|
+ patentForm.value
|
|
|
+ )) as unknown as any;
|
|
|
+
|
|
|
+ if (res.code === 200) {
|
|
|
+ ElMessage({
|
|
|
+ type: "success",
|
|
|
+ message: "申请提交成功",
|
|
|
+ });
|
|
|
+ router.push({
|
|
|
+ path: "/demand",
|
|
|
+ });
|
|
|
+ }
|
|
|
+};
|
|
|
+</script>
|
|
|
+
|
|
|
+<style lang="scss" scoped>
|
|
|
+.page {
|
|
|
+ height: calc(100vh - 4rem);
|
|
|
+ box-sizing: border-box;
|
|
|
+ padding: 2rem 18rem;
|
|
|
+ color: #333;
|
|
|
+ background-image: url("@/assets/pic/bg.png"); /* 设置背景图片 */
|
|
|
+ background-repeat: repeat; /* 上下重复 */
|
|
|
+ background-size: cover; /* 左右满铺 */
|
|
|
+ background-position: center; /* 居中对齐 */
|
|
|
+ .form-item {
|
|
|
+ margin-right: 20px; // 根据需要设置间距
|
|
|
+ .logo {
|
|
|
+ width: 178px;
|
|
|
+ height: 178px;
|
|
|
+ }
|
|
|
+ .logo-uploader {
|
|
|
+ width: 178px;
|
|
|
+ height: 178px;
|
|
|
+ border: 1px dashed var(--el-border-color);
|
|
|
+ border-radius: 6px;
|
|
|
+ cursor: pointer;
|
|
|
+ position: relative;
|
|
|
+ overflow: hidden;
|
|
|
+ transition: var(--el-transition-duration-fast);
|
|
|
+ }
|
|
|
+ .logo-uploader-icon {
|
|
|
+ font-size: 28px;
|
|
|
+ color: #8c939d;
|
|
|
+ width: 178px;
|
|
|
+ height: 178px;
|
|
|
+ text-align: center;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .custom-input {
|
|
|
+ max-width: 20rem;
|
|
|
+ width: 100%; // 可选
|
|
|
+ }
|
|
|
+ .button-container {
|
|
|
+ display: flex;
|
|
|
+ justify-content: flex-end; /* 使按钮靠右对齐 */
|
|
|
+ width: 100%;
|
|
|
+ }
|
|
|
+ .page-title {
|
|
|
+ margin-top: 1rem;
|
|
|
+ margin-bottom: 1rem;
|
|
|
+ font-family: "源黑体 CN", sans-serif;
|
|
|
+ font-weight: 500;
|
|
|
+ font-size: 1.25rem;
|
|
|
+ line-height: 2rem;
|
|
|
+ text-align: left;
|
|
|
+ }
|
|
|
+
|
|
|
+ .trademark-form {
|
|
|
+ margin-bottom: 2rem;
|
|
|
+ }
|
|
|
+
|
|
|
+ .section-title {
|
|
|
+ font-size: 1.2rem;
|
|
|
+ margin: 1.5rem 0 0.5rem;
|
|
|
+ font-weight: 500;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+.trademark {
|
|
|
+ display: flex;
|
|
|
+ width: 100%;
|
|
|
+ height: 500px;
|
|
|
+ border: 1px solid #c1c1c1;
|
|
|
+ .trademark-aside {
|
|
|
+ width: 300px;
|
|
|
+ border-right: 1px solid #c1c1c1;
|
|
|
+ .trademark-aside-search {
|
|
|
+ width: 100%;
|
|
|
+ height: 50px;
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ box-sizing: border-box;
|
|
|
+ padding-left: 10px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .trademark-main {
|
|
|
+ flex: 1;
|
|
|
+ .trademark-main-header {
|
|
|
+ width: 100%;
|
|
|
+ height: 50px;
|
|
|
+ border-bottom: 1px solid #c1c1c1;
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ justify-content: space-between;
|
|
|
+ box-sizing: border-box;
|
|
|
+ padding: 0 20px;
|
|
|
+ }
|
|
|
+ .trademark-main-content {
|
|
|
+ box-sizing: border-box;
|
|
|
+ padding: 20px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+</style>
|