style:打印申请书
Showing
1 changed file
with
13 additions
and
24 deletions
| ... | @@ -137,32 +137,21 @@ export default { | ... | @@ -137,32 +137,21 @@ export default { |
| 137 | //根据编号获取对应信息 | 137 | //根据编号获取对应信息 |
| 138 | getPrintTemplateByCode({ tmpno: Vue.prototype.BASE_API.adapter }).then(res => { | 138 | getPrintTemplateByCode({ tmpno: Vue.prototype.BASE_API.adapter }).then(res => { |
| 139 | if (res.code === 200) { | 139 | if (res.code === 200) { |
| 140 | getPrintTemplateByCode({ tmpno: Vue.prototype.BASE_API.adapter + '-2' }).then(res1 => { | 140 | getPrintApplicationForm(this.currentSelectProps.bsmSldy).then(infoRes => { |
| 141 | getPrintApplicationForm(this.currentSelectProps.bsmSldy).then(infoRes => { | 141 | if (infoRes.code === 200) { |
| 142 | if (infoRes.code === 200) { | 142 | let LODOP = getLodop(document.getElementById('LODOP_OB'), document.getElementById('LODOP_EM')); |
| 143 | let LODOP = getLodop(document.getElementById('LODOP_OB'), document.getElementById('LODOP_EM')); | ||
| 144 | 143 | ||
| 145 | // 装载第一个模板并设置数据 | 144 | // 装载第一个模板并设置数据 |
| 146 | LODOP.ADD_PRINT_DATA("ProgramData", res.result.tmpcontent); | 145 | LODOP.ADD_PRINT_DATA("ProgramData", res.result.tmpcontent); |
| 147 | for (let key in infoRes.result) { | 146 | for (let key in infoRes.result) { |
| 148 | LODOP.SET_PRINT_STYLEA(key, "CONTENT", infoRes.result[key]); | 147 | LODOP.SET_PRINT_STYLEA(key, "CONTENT", infoRes.result[key]); |
| 149 | } | ||
| 150 | |||
| 151 | // 手动分页 | ||
| 152 | LODOP.NewPage(); | ||
| 153 | |||
| 154 | // 装载第二个模板并设置数据 | ||
| 155 | LODOP.ADD_PRINT_DATA("ProgramData", res1.result.tmpcontent); | ||
| 156 | for (let key in res1.result) { | ||
| 157 | LODOP.SET_PRINT_STYLEA(key, "CONTENT", res1.result[key]); | ||
| 158 | } | ||
| 159 | |||
| 160 | // 进行预览 | ||
| 161 | LODOP.PREVIEW(); | ||
| 162 | } else { | ||
| 163 | this.$message.error(infoRes.message); | ||
| 164 | } | 148 | } |
| 165 | }); | 149 | |
| 150 | // 进行预览 | ||
| 151 | LODOP.PREVIEW(); | ||
| 152 | } else { | ||
| 153 | this.$message.error(infoRes.message); | ||
| 154 | } | ||
| 166 | }); | 155 | }); |
| 167 | } else { | 156 | } else { |
| 168 | this.$message.error(res.message); | 157 | this.$message.error(res.message); | ... | ... |
-
Please register or sign in to post a comment