提交 94c41139 编写于 作者: zhouweidong's avatar zhouweidong

继承属性日期类型format

上级 61020a1d
......@@ -46,13 +46,13 @@ public class ${item.codeName}SearchContext extends QueryWrapperContext<${item.co
<#assign formItemDataType="String">
</#if>
<#if formItemDataType !="String">
<#if defDataType == "DATETIME">
<#if defDataType == "DATETIME" || formItemDataType == "DATETIME">
@JsonFormat(pattern="yyyy-MM-dd HH:mm:ss", timezone="GMT+8")
@JSONField(format="yyyy-MM-dd HH:mm:ss")
<#elseif defDataType == "DATE">
<#elseif defDataType == "DATE" || formItemDataType == "DATETIME">
@JsonFormat(pattern="yyyy-MM-dd", timezone="GMT+8")
@JSONField(format="yyyy-MM-dd")
<#elseif defDataType == "TIME">
<#elseif defDataType == "TIME" || formItemDataType == "DATETIME">
@JsonFormat(pattern="HH:mm", timezone="GMT+8")
@JSONField(format="HH:mm")
</#if>
......@@ -160,13 +160,13 @@ public class ${item.codeName}SearchContext extends QueryBuildContext {
<#assign formItemDataType="String">
</#if>
<#if formItemDataType !="String">
<#if defDataType == "DATETIME">
<#if defDataType == "DATETIME" || formItemDataType == "DATETIME">
@JsonFormat(pattern="yyyy-MM-dd HH:mm:ss", timezone="GMT+8")
@JSONField(format="yyyy-MM-dd HH:mm:ss")
<#elseif defDataType == "DATE">
<#elseif defDataType == "DATE" || formItemDataType == "DATE">
@JsonFormat(pattern="yyyy-MM-dd", timezone="GMT+8")
@JSONField(format="yyyy-MM-dd")
<#elseif defDataType == "TIME">
<#elseif defDataType == "TIME" || formItemDataType == "TIME">
@JsonFormat(pattern="HH:mm", timezone="GMT+8")
@JSONField(format="HH:mm")
</#if>
......@@ -253,14 +253,15 @@ public class ${item.codeName}SearchContext extends SearchContextBase {
<#if defield.getAllPSDEFSearchModes()??>
<#list defield.getAllPSDEFSearchModes() as formitem>
<#if formitem.getPSDEField()??>
<#assign formItemDataType=srfr7javatype(formitem.getPSDEField().stdDataType)>
<#assign defDataType=formitem.getPSDEField().getDataType()>
<#if defDataType == "DATETIME">
<#if defDataType == "DATETIME" || formItemDataType == "DATETIME">
@JsonFormat(pattern="yyyy-MM-dd HH:mm:ss", timezone="GMT+8")
@JSONField(format="yyyy-MM-dd HH:mm:ss")
<#elseif defDataType == "DATE">
<#elseif defDataType == "DATE" || formItemDataType == "DATE">
@JsonFormat(pattern="yyyy-MM-dd", timezone="GMT+8")
@JSONField(format="yyyy-MM-dd")
<#elseif defDataType == "TIME">
<#elseif defDataType == "TIME" || formItemDataType == "TIME">
@JsonFormat(pattern="HH:mm", timezone="GMT+8")
@JSONField(format="HH:mm")
</#if>
......@@ -290,14 +291,15 @@ public class ${item.codeName}SearchContext extends SearchContextBase {
<#if defield.getAllPSDEFSearchModes()??>
<#list defield.getAllPSDEFSearchModes() as formitem>
<#if formitem.getPSDEField()??>
<#assign formItemDataType=srfr7javatype(formitem.getPSDEField().stdDataType)>
<#assign defDataType=formitem.getPSDEField().getDataType()>
<#if defDataType == "DATETIME">
<#if defDataType == "DATETIME" || formItemDataType == "DATETIME">
@JsonFormat(pattern="yyyy-MM-dd HH:mm:ss", timezone="GMT+8")
@JSONField(format="yyyy-MM-dd HH:mm:ss")
<#elseif defDataType == "DATE">
<#elseif defDataType == "DATE" || formItemDataType == "DATE">
@JsonFormat(pattern="yyyy-MM-dd", timezone="GMT+8")
@JSONField(format="yyyy-MM-dd")
<#elseif defDataType == "TIME">
<#elseif defDataType == "TIME" || formItemDataType == "TIME">
@JsonFormat(pattern="HH:mm", timezone="GMT+8")
@JSONField(format="HH:mm")
</#if>
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册