Commit 61205354 by liudx

专利word智能推荐修改

parent 956845e4
No preview for this file type
......@@ -300,7 +300,7 @@ export default {
],
pagination: {
pageSize: 5,
showSizeChanger:false
showSizeChanger: false,
},
};
},
......@@ -308,9 +308,6 @@ export default {
handleAnchorClick(e, link) {
// 阻止点击的默认事件修改路由
e.preventDefault();
// console.log(link)
// var srcolls = document.getElementById(link.href);
// srcolls.scrollIntoView({ block: "start", behavior: "smooth" });
},
},
};
......
......@@ -605,26 +605,30 @@ export default {
doc.attachModule(new ImageModule(opts));
let list = that.list;
let qualif = [];
list.forEach((item) => {
if (item.high_new == 1) {
qualif.push("高新技术企业");
} else if (item.zjtg == 1) {
qualif.push("专精特新企业");
} else if (item.zjtg_sjxjr == 1) {
qualif.push("专精特新小巨人企业");
} else if (item.quoted_company == 1) {
qualif.push("上市企业");
}
// if (item.high_new == 1) {
// qualif.push("高新技术企业");
// } else if (item.zjtg == 1) {
// qualif.push("专精特新企业");
// } else if (item.zjtg_sjxjr == 1) {
// qualif.push("专精特新小巨人企业");
// } else if (item.quoted_company == 1) {
// qualif.push("上市企业");
// }
if(item.patents.length>3){
item.patents.splice(2,item.patents.length-3)
}
});
that.list.qualif = qualif;
// that.list.patents = this.submitInfo.auditResult.split('\n')
// 设置模板变量的值
doc.setData({
...details,
today,
list,
qualif,
// business_scope,
// patent,
image1: myChart1.getDataURL({
......@@ -648,9 +652,9 @@ export default {
"application/vnd.openxmlformats-officedocument.wordprocessingml.document",
});
//formData文件流
that.blobToBase64(out,that.formState.email);
that.blobToBase64(out, that.formState.email);
// 将目标文件对象保存为目标类型的文件,并命名
// saveAs(out, `专利成果转移转化智能推荐报告.docx`);
saveAs(out, `专利成果转移转化智能推荐报告.docx`);
that.visible = false;
}
);
......@@ -662,7 +666,7 @@ export default {
// 处理验证失败的情况
});
},
blobToBase64(blob,email) {
blobToBase64(blob, email) {
return new Promise((resolve, reject) => {
const fileReader = new FileReader();
fileReader.onload = (e) => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment