mirror of
https://github.com/go-admin-team/go-admin.git
synced 2026-09-30 20:58:33 +00:00
13 lines
570 B
Plaintext
13 lines
570 B
Plaintext
package dto
|
|
|
|
type {{.ClassName}}Search struct {
|
|
{{ $tablename := .TBName -}}
|
|
{{ range .Columns -}}
|
|
{{$z := .IsQuery}}
|
|
{{- if ($z) -}}
|
|
{{.GoField}} {{.GoType}} `form:"{{.JsonField}}" search:"type:{{if eq .QueryType "EQ"}}exact{{ else if eq .QueryType "NE"}}iexact{{ else if eq .QueryType "LIKE"}}contains{{ else if eq .QueryType "GT"}}gt{{ else if eq .QueryType "GTE"}}gte{{ else if eq .QueryType "LT"}}lt{{ else if eq .QueryType "LTE"}}lte{{- end }};column:{{.ColumnName}};table:{{$tablename}}"` // {{.ColumnComment}}
|
|
|
|
{{end -}}
|
|
{{- end }}
|
|
}
|