Documentation ¶
Index ¶
- Constants
- Variables
- func AppImport(path string) *model.Import
- func EnumImports(ts types.Types, pkg string, models model.Models, enums enum.Enums) (model.Imports, error)
- func ImpSlicesForGo(v string) *model.Import
- func ImportsForTypes(ctx string, database string, ts ...types.Type) model.Imports
- func LoadRef(col *model.Column, models model.Models) (*types.Reference, *model.Model, error)
- func SimpleJSON(database string) bool
- func SpecialImports(cols model.Columns, pkg string, models model.Models, enums enum.Enums) (model.Imports, error)
- func ViewImport(path string) *model.Import
Constants ¶
View Source
const ( TextArg = "Arg" TextCommaSpace = ", " TextDrop = "Drop" TextEndAnchor = "</a>" TextEndFunc = "{%% endfunc %%}" TextEndIf = "{%% endif %%}" TextEndIfExtra = "{%%%% endif %%%%}" TextEndIfDash = "{%%- endif -%%}" TextGetBy = "GetBy" TextH3Start = "<h3>" TextH3End = "</h3>" TextIsNull = " is null" TextMenuItem = "menuItem" TextModelPrefix = "model." TextNil = "<nil>" TextNull = "null" TextSQLComment = "-- " TextTDEnd = "</td>" TextTDStart = `<td class="nowrap">` TextTmplEnd = " %%}" )
Variables ¶
View Source
var ( ImpAudit = AppImport("lib/audit") ImpApp = &model.Import{Type: model.ImportTypeApp, Value: "{{{ .Package }}}/app"} ImpAppController = AppImport("controller") ImpAppDatabase = AppImport("lib/database") ImpAppMenu = AppImport("lib/menu") ImpAppSvc = AppImport("lib/svc") ImpAppUtil = AppImport("util") ImpContext = model.NewImport(model.ImportTypeInternal, "context") ImpComponents = ViewImport("components") ImpComponentsView = ViewImport("components/view") ImpComponentsEdit = ViewImport("components/edit") ImpCutil = AppImport("controller/cutil") ImpDBDriver = model.NewImport(model.ImportTypeInternal, "database/sql/driver") ImpErrors = model.NewImport(model.ImportTypeExternal, "github.com/pkg/errors") ImpHTTP = model.NewImport(model.ImportTypeInternal, "net/http") ImpFilter = AppImport("lib/filter") ImpFmt = model.NewImport(model.ImportTypeInternal, "fmt") ImpJSON = model.NewImport(model.ImportTypeInternal, "encoding/json") ImpLayout = ViewImport("layout") ImpLo = model.NewImport(model.ImportTypeExternal, "github.com/samber/lo") ImpMSSQL = model.NewImport(model.ImportTypeExternal, "github.com/denisenkom/go-mssqldb").WithAlias("mssql") ImpPath = model.NewImport(model.ImportTypeInternal, "path") ImpRouter = model.NewImport(model.ImportTypeExternal, "github.com/gorilla/mux") ImpSearchResult = AppImport("lib/search/result") ImpSlices = model.NewImport(model.ImportTypeInternal, "slices") ImpSQLx = model.NewImport(model.ImportTypeExternal, "github.com/jmoiron/sqlx") ImpStrconv = model.NewImport(model.ImportTypeInternal, "strconv") ImpStrings = model.NewImport(model.ImportTypeInternal, "strings") ImpTime = model.NewImport(model.ImportTypeInternal, "time") ImpURL = model.NewImport(model.ImportTypeInternal, "net/url") ImpUUID = model.NewImport(model.ImportTypeExternal, "github.com/google/uuid") ImpXML = model.NewImport(model.ImportTypeInternal, "encoding/xml") )
Functions ¶
func EnumImports ¶ added in v1.0.9
func ImpSlicesForGo ¶ added in v0.11.22
func ImportsForTypes ¶
func SimpleJSON ¶ added in v1.0.23
func SpecialImports ¶ added in v0.6.20
func ViewImport ¶ added in v1.0.11
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.