feat: 修改条码生成逻辑

This commit is contained in:
砂糖
2025-08-19 15:39:59 +08:00
parent dc315e90bf
commit 9db9b0ca57
14 changed files with 1209 additions and 289 deletions

View File

@@ -62,6 +62,14 @@
>
另存为图片
</el-button>
<el-button
type="text"
size="mini"
@click="handleDelete(cfg, idx)"
icon="el-icon-delete"
>
删除
</el-button>
</div>
<el-form-item label="二维码内容" label-width="70px" style="margin-bottom: 8px;">
<el-input disabled type="textarea" v-model="cfg.code" size="mini" :autosize="{ minRows: 1, maxRows: 3 }" placeholder="请输入条码内容" />
@@ -196,6 +204,10 @@ export default {
}
return code;
},
handleDelete(cfg, idx) {
// this.barcodeConfigs.splice(idx, 1);
this.$emit('delete', cfg, idx);
},
getPaperPx() {
// mm to px, 1mm ≈ 3.78px
let width, height;