53b2f560 by “miaofang

Merge branch 'dev' of http://yun.pashanhoo.com:9090/bdc/bdcdj-web into dev

2 parents 2dd96d43 f66da719
{
"TITLE": "不动产登记系统",
"SERVERAPI": "/bdcdj",
"IDCARDURL": "http://127.0.0.1:33088/function=get_idcard&readnew=0"
"IDCARDURL": "http://127.0.0.1:33088/function=get_idcard&readnew=0",
"adapter": "dysqs"
}
\ No newline at end of file
......
/*
* @Description: 申请书
* @Autor: renchao
* @LastEditTime: 2023-11-20 15:42:45
*/
import Vue from 'vue'
// 创建不同的适配器策略
const strategies = {
dysqs: function (data) {
return data.name;
},
default: function (data) {
return data;
}
};
// 创建适配器函数,并使用策略模式进行数据处理
export default function adapter (data) {
const type = Vue.prototype.BASE_API.adapter;
const selectedStrategy = strategies[type] || strategies['default'];
return selectedStrategy(data);
}
\ No newline at end of file
......@@ -12,6 +12,7 @@
</el-tab-pane>
</el-tabs>
<el-empty description="暂无数据" v-if="headTabBdcqz.length == 0 && noData"></el-empty>
<div v-else>
<div style="height:540px">
<el-form class="zs" :model="bdcqz" v-if="this.bdcqz.bdcqzlx==1" ref="ruleForm" label-width="100px">
<el-row>
......@@ -156,6 +157,7 @@
<el-button type="primary" @click="handleSubmit">保存</el-button>
</div>
</div>
</div>
</template>
<script>
......
/*
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-11-15 11:29:32
* @LastEditTime: 2023-11-20 15:24:10
*/
import Vue from 'vue'
import { getPrintTemplateByCode } from "@/api/print";
import { uploadUndo } from "@/api/clxx";
import { getLodop } from "@/utils/LodopFuncs"
import { getLodop } from "@/utils/LodopFuncs";
import adapter from "@/utils/sqs/adapter";
import {
stepExpandInfo,
record,
......@@ -131,23 +133,21 @@ export default {
case "B-ZSXG":
this.$popupDialog("证书修改", "workflow/components/dialog/zsxg", { bsmSlsq: this.bsmSlsq, }, '55%', true)
break;
case "B-SQD":
break;
case "B6":
//根据编号获取对应信息
getPrintTemplateByCode({ tmpno: 'dysqs' }).then(res => {
if (res.code == 200) {
getPrintApplicationForm(this.currentSelectProps.bsmSldy).then(infoRes => {
getPrintApplicationForm(this.currentSelectProps.bsmSldy).then(async infoRes => {
if (infoRes.code == 200) {
console.log(adapter({ name: 2 }));
//打开模板设计
let LODOP = getLodop(document.getElementById('LODOP_OB'), document.getElementById('LODOP_EM'));
LODOP.ADD_PRINT_DATA("ProgramData", res.result.tmpcontent); //装载模板
//todo 调取后端接口获取数据 循环set
for (let key in infoRes.result) {
LODOP.SET_PRINT_STYLEA(key, "CONTENT", infoRes.result[key]);
}
LODOP.PREVIEW();
// let LODOP = getLodop(document.getElementById('LODOP_OB'), document.getElementById('LODOP_EM'));
// LODOP.ADD_PRINT_DATA("ProgramData", res.result.tmpcontent); //装载模板
// //todo 调取后端接口获取数据 循环set
// for (let key in infoRes.result) {
// LODOP.SET_PRINT_STYLEA(key, "CONTENT", infoRes.result[key]);
// }
// LODOP.PREVIEW();
} else {
this.$message.error(infoRes.message)
}
......