From 07ae34b575d7501b29182018af7b138d8d5657be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=96=B5=E4=BD=A0=E4=B8=AA=E6=97=BA=E5=91=80?= Date: Thu, 28 Nov 2024 18:39:18 +0800 Subject: [PATCH 1/3] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E9=95=BF=E6=96=87?= =?UTF-8?q?=E6=9C=AC=E5=9E=8B=E5=AD=97=E6=AE=B5ColumnLength=E4=B8=BA0?= =?UTF-8?q?=E6=97=B6=E7=94=9F=E6=88=90=E4=BB=A3=E7=A0=81=E7=9A=84bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Admin.NET/Admin.NET.Web.Entry/wwwroot/template/Service.cs.vm | 2 +- .../Admin.NET.Web.Entry/wwwroot/template/editDialog.vue.vm | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Admin.NET/Admin.NET.Web.Entry/wwwroot/template/Service.cs.vm b/Admin.NET/Admin.NET.Web.Entry/wwwroot/template/Service.cs.vm index e2d06c947..ca510a8fb 100644 --- a/Admin.NET/Admin.NET.Web.Entry/wwwroot/template/Service.cs.vm +++ b/Admin.NET/Admin.NET.Web.Entry/wwwroot/template/Service.cs.vm @@ -340,7 +340,7 @@ public class @(Model.ClassName)Service : IDynamicApiController, ITransient } else if(column.NetType.EndsWith('?') == true){ @:.SplitError(it => it.Item.@(column.PropertyName) == null, "@(column.ColumnComment)不能为空") }} - if (column.NetType?.TrimEnd('?') == "string"){ + if (column.NetType?.TrimEnd('?') == "string" && column.ColumnLength > 0){ @:.SplitError(it => it.Item.@(column.PropertyName)?.Length > @(column.ColumnLength), "@(column.ColumnComment)长度不能超过@(column.ColumnLength)个字符") }} foreach (var config in Model.TableUniqueConfigList) { diff --git a/Admin.NET/Admin.NET.Web.Entry/wwwroot/template/editDialog.vue.vm b/Admin.NET/Admin.NET.Web.Entry/wwwroot/template/editDialog.vue.vm index 4cccc0557..6b865fc32 100644 --- a/Admin.NET/Admin.NET.Web.Entry/wwwroot/template/editDialog.vue.vm +++ b/Admin.NET/Admin.NET.Web.Entry/wwwroot/template/editDialog.vue.vm @@ -150,8 +150,9 @@ defineExpose({ openDialog }); } else if (column.EffectType == "DatePicker") { @: } else { - var inputType = column.EffectType == "InputTextArea" ? "type=\"textarea\"" : ""; - @: + var inputType = column.EffectType == "InputTextArea" ? "type=\"textarea\" " : ""; + var maxlength = column.ColumnLength > 0 ? $"maxlength=\"{column.ColumnLength}\" " : ""; + @: } @: @: -- Gitee From be88c77296284d557e41aa2735129adf16128ee3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=96=B5=E4=BD=A0=E4=B8=AA=E6=97=BA=E5=91=80?= Date: Thu, 28 Nov 2024 23:04:52 +0800 Subject: [PATCH 2/3] =?UTF-8?q?fixup!=20fix:=20=E4=BF=AE=E5=A4=8D=E5=89=8D?= =?UTF-8?q?=E7=AB=AFTag=E5=88=B7=E6=96=B0=E6=97=A0=E6=95=88=E7=9A=84BUG?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Web/src/layout/routerView/parent.vue | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Web/src/layout/routerView/parent.vue b/Web/src/layout/routerView/parent.vue index 2a679f9ea..d5422836b 100644 --- a/Web/src/layout/routerView/parent.vue +++ b/Web/src/layout/routerView/parent.vue @@ -67,10 +67,12 @@ onBeforeMount(() => { state.keepAliveNameList = keepAliveNames.value; mittBus.on('onTagsViewRefreshRouterView', (fullPath: string) => { state.keepAliveNameList = keepAliveNames.value.filter((name: string) => route.name !== name); + const cachedViewsTemp = cachedViews.value; + cachedViews.value = []; state.refreshRouterViewKey = ''; state.iframeRefreshKey = ''; nextTick(() => { - fullPath = (fullPath.indexOf('?') > 0 ? '&' : '?') + '_$t=' + Math.random(); + cachedViews.value = cachedViewsTemp; state.refreshRouterViewKey = fullPath; state.iframeRefreshKey = fullPath; state.keepAliveNameList = keepAliveNames.value; -- Gitee From 6441f8b3d4bd26967cdc6bd77dd719dd07a69479 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=96=B5=E4=BD=A0=E4=B8=AA=E6=97=BA=E5=91=80?= Date: Thu, 28 Nov 2024 23:38:25 +0800 Subject: [PATCH 3/3] =?UTF-8?q?fix=EF=BC=9A=E4=BF=AE=E5=A4=8D=E6=9D=A5?= =?UTF-8?q?=E5=9B=9E=E5=88=87=E6=8D=A2tag=E5=90=8E=E5=88=B7=E6=96=B0?= =?UTF-8?q?=E5=A4=B1=E8=B4=A5=E7=9A=84bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Web/src/layout/routerView/parent.vue | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/Web/src/layout/routerView/parent.vue b/Web/src/layout/routerView/parent.vue index d5422836b..8894e3e9e 100644 --- a/Web/src/layout/routerView/parent.vue +++ b/Web/src/layout/routerView/parent.vue @@ -67,16 +67,15 @@ onBeforeMount(() => { state.keepAliveNameList = keepAliveNames.value; mittBus.on('onTagsViewRefreshRouterView', (fullPath: string) => { state.keepAliveNameList = keepAliveNames.value.filter((name: string) => route.name !== name); - const cachedViewsTemp = cachedViews.value; - cachedViews.value = []; state.refreshRouterViewKey = ''; state.iframeRefreshKey = ''; - nextTick(() => { - cachedViews.value = cachedViewsTemp; - state.refreshRouterViewKey = fullPath; + cachedViews.value = []; + setTimeout(() => { state.iframeRefreshKey = fullPath; + state.refreshRouterViewKey = fullPath; + cachedViews.value = [route.name]; state.keepAliveNameList = keepAliveNames.value; - }) + }, 10); }); }); // 页面加载时 -- Gitee