From ceab8e8fd43a3b7d689c518567e8bfb8ecd208be Mon Sep 17 00:00:00 2001 From: xbzhu <5430389+xbzhu@user.noreply.gitee.com> Date: Wed, 1 Feb 2023 12:02:40 +0000 Subject: [PATCH] =?UTF-8?q?update=20ZR.Admin.WebApi/wwwroot/CodeGenTemplat?= =?UTF-8?q?e/TplDto.txt.=20=E4=BB=A3=E7=A0=81=E7=94=9F=E6=88=90=E6=97=B6?= =?UTF-8?q?=EF=BC=8C=E5=A6=82=E6=9E=9C=E5=AD=97=E6=AE=B5=E6=98=AFlong?= =?UTF-8?q?=E7=B1=BB=E5=9E=8B=EF=BC=8C=E5=A2=9E=E5=8A=A0=E4=BA=86=E5=B1=9E?= =?UTF-8?q?=E6=80=A7[JsonConverter(typeof(ValueToStringConverter))]?= =?UTF-8?q?=EF=BC=8C=E9=81=BF=E5=85=8D=E5=80=BC=E8=B6=85=E8=BF=87js=20numb?= =?UTF-8?q?er.maxvalue=E5=87=BA=E7=8E=B0=E8=87=AA=E5=8A=A8=E6=88=AA?= =?UTF-8?q?=E5=8F=96=E7=9A=84=E9=97=AE=E9=A2=98=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: xbzhu <5430389+xbzhu@user.noreply.gitee.com> --- ZR.Admin.WebApi/wwwroot/CodeGenTemplate/TplDto.txt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ZR.Admin.WebApi/wwwroot/CodeGenTemplate/TplDto.txt b/ZR.Admin.WebApi/wwwroot/CodeGenTemplate/TplDto.txt index 88b1f8e..2db4e58 100644 --- a/ZR.Admin.WebApi/wwwroot/CodeGenTemplate/TplDto.txt +++ b/ZR.Admin.WebApi/wwwroot/CodeGenTemplate/TplDto.txt @@ -1,6 +1,7 @@ -using System; +using System; using System.Collections.Generic; using System.ComponentModel.DataAnnotations; +using Newtonsoft.Json; using ${options.ModelsNamespace}.Dto; using ${options.ModelsNamespace}.Models; $if(replaceDto.ShowBtnExport) @@ -43,6 +44,9 @@ $if(item.IsExport) $else [ExcelIgnore] $end +$end +$if(item.CsharpType == "long") + [JsonConverter(typeof(ValueToStringConverter))] $end public $item.CsharpType$item.RequiredStr $item.CsharpField { get; set; }