2020-08-19 10:41:19 +08:00
|
|
|
package template
|
2020-07-29 17:11:41 +08:00
|
|
|
|
2020-08-19 10:41:19 +08:00
|
|
|
var (
|
2021-02-26 16:11:47 +08:00
|
|
|
// Imports defines a import template for model in cache case
|
2020-08-19 10:41:19 +08:00
|
|
|
Imports = `import (
|
2022-02-17 10:28:55 +08:00
|
|
|
"context"
|
2020-08-19 10:41:19 +08:00
|
|
|
"database/sql"
|
|
|
|
"fmt"
|
2020-07-29 17:11:41 +08:00
|
|
|
"strings"
|
2020-09-03 13:57:28 +08:00
|
|
|
{{if .time}}"time"{{end}}
|
2020-07-29 17:11:41 +08:00
|
|
|
|
2022-01-04 15:51:32 +08:00
|
|
|
"github.com/zeromicro/go-zero/core/stores/builder"
|
|
|
|
"github.com/zeromicro/go-zero/core/stores/cache"
|
|
|
|
"github.com/zeromicro/go-zero/core/stores/sqlc"
|
|
|
|
"github.com/zeromicro/go-zero/core/stores/sqlx"
|
|
|
|
"github.com/zeromicro/go-zero/core/stringx"
|
2020-07-29 17:11:41 +08:00
|
|
|
)
|
|
|
|
`
|
2021-02-26 16:11:47 +08:00
|
|
|
// ImportsNoCache defines a import template for model in normal case
|
2020-08-19 10:41:19 +08:00
|
|
|
ImportsNoCache = `import (
|
2022-02-17 10:28:55 +08:00
|
|
|
"context"
|
2020-10-21 14:59:35 +08:00
|
|
|
"database/sql"
|
2020-10-27 22:42:53 +08:00
|
|
|
"fmt"
|
2020-08-19 10:41:19 +08:00
|
|
|
"strings"
|
2020-09-03 13:57:28 +08:00
|
|
|
{{if .time}}"time"{{end}}
|
2020-08-19 10:41:19 +08:00
|
|
|
|
2022-01-04 15:51:32 +08:00
|
|
|
"github.com/zeromicro/go-zero/core/stores/builder"
|
|
|
|
"github.com/zeromicro/go-zero/core/stores/sqlc"
|
|
|
|
"github.com/zeromicro/go-zero/core/stores/sqlx"
|
|
|
|
"github.com/zeromicro/go-zero/core/stringx"
|
2020-08-19 10:41:19 +08:00
|
|
|
)
|
|
|
|
`
|
|
|
|
)
|