From dc59449293db85e7e10385593fa7b2def2a125b0 Mon Sep 17 00:00:00 2001 From: LyricTian Date: Thu, 25 Jan 2024 20:07:23 +0800 Subject: [PATCH] fix: Fix frontend tpl --- Makefile | 2 +- main.go | 2 +- tpls/ant-design-pro-v5/pages.components.form.tsx.tpl | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 6c4075d..749a8cb 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ .PHONY: build -RELEASE_VERSION = v10.3.4 +RELEASE_VERSION = v10.3.5 APP = gin-admin-cli BIN = ${APP} diff --git a/main.go b/main.go index ccd267c..6931091 100644 --- a/main.go +++ b/main.go @@ -13,7 +13,7 @@ import ( //go:embed tpls var f embed.FS -var VERSION = "v10.3.4" +var VERSION = "v10.3.5" func main() { defer func() { diff --git a/tpls/ant-design-pro-v5/pages.components.form.tsx.tpl b/tpls/ant-design-pro-v5/pages.components.form.tsx.tpl index 3df2414..2d6ed9e 100644 --- a/tpls/ant-design-pro-v5/pages.components.form.tsx.tpl +++ b/tpls/ant-design-pro-v5/pages.components.form.tsx.tpl @@ -33,7 +33,7 @@ const {{$name}}Modal: React.FC<{{$name}}ModalProps> = (props: {{$name}}ModalProp const data = res.data; {{- if $includeStatus}} data.statusChecked = data.status === 'enabled'; - {{-end}} + {{- end}} formRef.current?.setFieldsValue(data); } }); @@ -66,7 +66,7 @@ const {{$name}}Modal: React.FC<{{$name}}ModalProps> = (props: {{$name}}ModalProp onFinish={async (values: API.{{$name}}) => { {{- if $includeStatus}} values.status = values.statusChecked ? 'enabled' : 'disabled'; - {{-end}} + {{- end}} if (props.id) { await update{{$name}}(props.id, values); } else {