修复bug
This commit is contained in:
		| @@ -196,7 +196,7 @@ | ||||
|           <template v-slot="{ row }"> | ||||
|             <div class="table-options"> | ||||
|               <el-button type="text" @click="showTemplate(row)">模板预览</el-button> | ||||
|               <el-button type="text" @click="updateTempate(row), isShowTemplate = false">使用</el-button> | ||||
|               <el-button type="text" @click="updateTempate(row)">使用</el-button> | ||||
|             </div> | ||||
|           </template> | ||||
|         </el-table-column> | ||||
| @@ -396,6 +396,7 @@ | ||||
|       addField() { | ||||
|         const num = this.dynamicFromList.length > 9 ? this.dynamicFromList.length + 1 : `0${this.dynamicFromList.length + 1}` | ||||
|  | ||||
|         // eslint-disable-next-line no-empty | ||||
|         if (this.dynamicFromList.length && !this.dynamicFromList.at(-1)[`field_${num}`]) { | ||||
|         } else { | ||||
|           this.$set(this.dynamicFrom, `field_${num}`, '') | ||||
| @@ -415,6 +416,9 @@ | ||||
|             const config = JSON.parse(res.data.content) | ||||
|             this.hiprintTemplate.update(config) | ||||
|             this.hiprintTemplate.setPaper(config.panels[0].width, config.panels[0].height) | ||||
|  | ||||
|             this.dynamicFromList = JSON.parse(res.data.params) | ||||
|             this.isShowTemplate = false | ||||
|           } | ||||
|  | ||||
|           this.templateLoading = false | ||||
|   | ||||
		Reference in New Issue
	
	Block a user