From be028017a461af4c9745c69c4df084d4c3e6b296 Mon Sep 17 00:00:00 2001
From: zhengyiming <540361168@qq.com>
Date: 星期三, 22 十月 2025 18:08:49 +0800
Subject: [PATCH] fix: bug

---
 src/fabric-editor/hooks/context.ts |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/src/fabric-editor/hooks/context.ts b/src/fabric-editor/hooks/context.ts
index 6406b85..21a9a99 100644
--- a/src/fabric-editor/hooks/context.ts
+++ b/src/fabric-editor/hooks/context.ts
@@ -12,6 +12,7 @@
   checkTemplateParamObjectListNotNull,
   convertJsonMapToTemplateParamObjectList,
 } from '../utils';
+import { CanvasHeight, CanvasWidth } from '../constants';
 
 export interface TemplateDetailContext {
   templateDetail: Ref<API.GetContractTemplateQueryResult>;
@@ -166,6 +167,7 @@
 
   async function saveCustomerTemplateParam() {
     try {
+      console.log('templateEditState: ', templateEditState);
       const templateParamObjectList = convertJsonMapToTemplateParamObjectList(
         templateEditState.jsonMap
       );
@@ -184,6 +186,10 @@
               type: x.templateParamType,
               recorder: x.recorder,
               userType: x.userType,
+              bindProperty: x.bindProperty,
+              x: x.left / CanvasWidth,
+              y: x.top / CanvasHeight,
+              page: x.pageNum + 1,
             } as API.SaveContractTemplateValuesCommandItem)
         ),
         templateJsonData: JSON.stringify(templateEditState.jsonMap),

--
Gitblit v1.9.1