This commit is contained in:
2026-08-18 14:46:36 +08:00
parent 9e94385dfc
commit a084fe1fd4
13 changed files with 647 additions and 235 deletions
+4
View File
@@ -125,9 +125,13 @@ export default {
// 更新纸张尺寸
async updatePaperSize({ dispatch }, { width, height }) {
try {
const presetKey = `${width}x${height}`;
// 预设尺寸同步记录 currentPreset,保证补打/生成页布局正确
const currentPreset = ['100x100', '150x150', '200x200'].includes(presetKey) ? presetKey : null;
await dispatch('savePrinterConfig', {
paperWidth: width,
paperHeight: height,
currentPreset,
lastUpdated: new Date().toISOString()
});
return true;