META-INF.dbgenerator.webadmin.helper.ftl Maven / Gradle / Ivy
The newest version!
<#macro generatedFormField table isSearchFormField=false fieldClass='formFieldClass'>
<#list table.columns as column>
<#assign requiredValue = 'true'/>
<#if !column.primaryKey>
<#if isSearchFormField==true>
<#assign requiredValue = 'false'/>
<#else>
<#assign requiredValue = column.nullable?string('false', 'true')/>
#if><#t>
${(column.commentName)!''}:
<#if column.mapping.isNumberType()==true>
<#elseif column.mapping.isSqlTimestamp()==true>
<#elseif column.mapping.isSqlTime()==true>
<#elseif column.mapping.isSqlDate()==true>
<#elseif column.mapping.isBooleanType()==true>
<#elseif column.isDictType()==true>
<#elseif column.isFileType()==true>
<#elseif column.isAssociationType()==true>
<#else>
<#t/>
style="width:185px;height:200px"
#if><#t/>
data-options="required:${requiredValue},
<#if column.columnSize gte 500 ><#t/>
multiline:true,
#if><#t/>
validType:'length[0,${column.columnSize}]' "/>
#if>
#if>
#list>
#macro>
© 2015 - 2025 Weber Informatics LLC | Privacy Policy