fix : srm 修改 提交专利审批和论文同时生成台账

This commit is contained in:
TianyangZhang 2025-11-25 16:47:10 +08:00
parent 5f00dc2b0c
commit 4a6b604e88
5 changed files with 37 additions and 34 deletions

View File

@ -221,7 +221,6 @@ export default {
getTid (){ getTid (){
var that = this; var that = this;
that.$API.ofm.vehicleUse.item.req(that.t_id).then(res=>{ that.$API.ofm.vehicleUse.item.req(that.t_id).then(res=>{
console.log('res', res)
that.form = res; that.form = res;
that.handleEidt(that.t_id); that.handleEidt(that.t_id);
if(res.ticket_.state_.type == 1 && res.create_by == that.$TOOL.data.get("USER_INFO").id ) { if(res.ticket_.state_.type == 1 && res.create_by == that.$TOOL.data.get("USER_INFO").id ) {

View File

@ -26,11 +26,6 @@
<el-main class="nopadding"> <el-main class="nopadding">
<scTable ref="table" :apiObj="apiObj" row-key="id"> <scTable ref="table" :apiObj="apiObj" row-key="id">
<el-table-column label="#" type="index"></el-table-column> <el-table-column label="#" type="index"></el-table-column>
<el-table-column
label="申请部门"
prop="belong_dept_name"
min-width="60"
></el-table-column>
<el-table-column <el-table-column
label="拟发表论文名称" label="拟发表论文名称"
prop="paper_name" prop="paper_name"
@ -44,7 +39,12 @@
<el-table-column <el-table-column
label="作者" label="作者"
prop="author" prop="author"
min-width="120" min-width="60"
></el-table-column>
<el-table-column
label="申请部门"
prop="organization"
min-width="60"
></el-table-column> ></el-table-column>
<el-table-column <el-table-column
label="拟发表文章类型" label="拟发表文章类型"

View File

@ -5,6 +5,9 @@
<el-form-item label="拟发表论文名称" prop="paper_name"> <el-form-item label="拟发表论文名称" prop="paper_name">
<el-input v-model="localForm.paper_name" clearable :disabled="localMode ==='show'"></el-input> <el-input v-model="localForm.paper_name" clearable :disabled="localMode ==='show'"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="申请部门" prop="orginization">
<el-input v-model="localForm.organization" clearable :disabled="localMode ==='show'"></el-input>
</el-form-item>
<el-form-item label="拟投期刊名称" prop="publication_name"> <el-form-item label="拟投期刊名称" prop="publication_name">
<el-input v-model="localForm.publication_name" clearable :disabled="localMode ==='show'"></el-input> <el-input v-model="localForm.publication_name" clearable :disabled="localMode ==='show'"></el-input>
</el-form-item> </el-form-item>
@ -152,6 +155,16 @@ export default {
methods: { methods: {
async submit_b_func() { async submit_b_func() {
let that = this; let that = this;
if(that.localForm.ticket_?.state_?.name == '总经理审批'){
const papertData = {
paper: that.localForm.id,
pa_type: that.localForm.pa_type,
author: that.localForm.author,
organization: that.localForm.organization
};
console.log('7777777777',papertData)
that.$API.srm.paperrecord.create.req(papertData);
}
if(that.localForm?.id){ if(that.localForm?.id){
that.localMode = "edit"; that.localMode = "edit";
} }

View File

@ -28,7 +28,7 @@
<el-table-column label="#" type="index"></el-table-column> <el-table-column label="#" type="index"></el-table-column>
<el-table-column <el-table-column
label="申请部门" label="申请部门"
prop="belong_dept_name" prop="organization"
min-width="60" min-width="60"
></el-table-column> ></el-table-column>
<el-table-column <el-table-column
@ -39,12 +39,12 @@
<el-table-column <el-table-column
label="发明人(设计人)" label="发明人(设计人)"
prop="author" prop="author"
min-width="120" min-width="60"
></el-table-column> ></el-table-column>
<el-table-column <el-table-column
label="拟申请专利类型" label="拟申请专利类型"
prop="type" prop="type"
min-width="120"> min-width="60">
<template #default="scope"> <template #default="scope">
{{patentType[scope.row.type]}} {{patentType[scope.row.type]}}
</template> </template>
@ -69,7 +69,7 @@
prop="other_area" prop="other_area"
min-width="60" min-width="60"
></el-table-column> ></el-table-column>
<el-table-column label="技术状态" prop="tech_status" min-width="200"> <el-table-column label="技术状态" prop="tech_status" min-width="160">
<template #default="{row}"> <template #default="{row}">
<div v-if="row.tech_status && row.tech_status.length"> <div v-if="row.tech_status && row.tech_status.length">
<div v-for="(item, index) in row.tech_status" :key="index"> <div v-for="(item, index) in row.tech_status" :key="index">
@ -87,7 +87,7 @@
<span v-else></span> <span v-else></span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="技术文件" prop="tech_file" min-width="120"> <el-table-column label="技术文件" prop="tech_file" min-width="160">
<template #default="{row}"> <template #default="{row}">
<div v-if="row.tech_file && row.tech_file.length"> <div v-if="row.tech_file && row.tech_file.length">
<div v-for="(item, index) in row.tech_file" :key="index"> <div v-for="(item, index) in row.tech_file" :key="index">
@ -189,27 +189,6 @@ export default {
this.limitedVisible = true; this.limitedVisible = true;
}, },
// getDefaultForm(){
// return {
// name: "",
// author: "",
// type: "",
// is_public: false,
// area: null,
// other_area: null,
// tech_status: [{ name: "", status: "", fileList: [] },
// { name: "", status: "", fileList: [] },
// { name: "", status: "", fileList: [] },
// { name: "/", status: "", fileList: [] },
// { name: "", status: "", fileList: [] }],
// tech_file: [ { name: "", status: "", pages: "" },
// { name: "", pages: "" },
// { name: "", pages: "" },
// { name: "", pages: "" }],
// ticket_:null
// }
// },
//
patentShow(row) { patentShow(row) {
this.mode = "show"; this.mode = "show";
this.t_id = row.id; this.t_id = row.id;

View File

@ -5,6 +5,9 @@
<el-form-item label="拟申请专利名称" prop="name"> <el-form-item label="拟申请专利名称" prop="name">
<el-input v-model="localForm.name" clearable :disabled="localMode ==='show'"></el-input> <el-input v-model="localForm.name" clearable :disabled="localMode ==='show'"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="申请部门" prop="organization">
<el-input v-model="localForm.organization" clearable :disabled="localMode ==='show'"></el-input>
</el-form-item>
<el-form-item label="发明人(设计人)" <el-form-item label="发明人(设计人)"
prop="author" prop="author"
> >
@ -163,6 +166,15 @@ export default {
methods: { methods: {
async submit_b_func() { async submit_b_func() {
let that = this; let that = this;
if(that.localForm.ticket_?.state_?.name == '总经理审批'){
const patentData = {
patent: that.localForm.id,
pc_type: that.localForm.type,
inventors: that.localForm.author,
organization: that.localForm.organization
};
that.$API.srm.patentrecord.create.req(patentData);
}
if(that.localForm?.id){ if(that.localForm?.id){
that.localMode = "edit"; that.localMode = "edit";
} }
@ -170,7 +182,7 @@ export default {
let res = await that.$API.srm.patentinfo.create.req(that.localForm); let res = await that.$API.srm.patentinfo.create.req(that.localForm);
that.localForm.id = res.id; that.localForm.id = res.id;
} else if (that.localMode == "edit") { } else if (that.localMode == "edit") {
await that.$API.srm.patentinfo.update.req(that.localForm.id, that.localForm); that.$API.srm.patentinfo.update.req(that.localForm.id, that.localForm);
} }
}, },
getTid (){ getTid (){