├── version ├── README.md ├── static ├── img │ ├── ipad.png │ ├── bg-signup.jpg │ ├── bg-masthead.jpg │ ├── demo-image-01.jpg │ └── demo-image-02.jpg ├── webfonts │ ├── fa-brands-400.woff2 │ ├── fa-solid-900.woff2 │ └── fa-regular-400.woff2 ├── js │ ├── grayscale.min.js │ └── jquery.easing.min.js └── css │ ├── grayscale.min.css │ └── all.min.css ├── auth ├── consts.go ├── casbin.go └── jwt.go ├── utils ├── common.go └── char.go ├── models ├── common.go ├── user.go └── types.go ├── templates ├── rbac.html └── index.html ├── middleware ├── recovery.go ├── log.go ├── jwt.go ├── rbac.go ├── session.go └── middleware.go ├── .gitignore ├── cache ├── gocache.go └── redis.go ├── Dockerfile ├── routers ├── health.go ├── swagger.go ├── static.go ├── templates.go ├── web.go ├── router.go └── user.go ├── ginengine └── engine.go ├── Makefile ├── db └── mysql.go ├── version.go ├── go.mod ├── conf └── conf.go ├── main.go ├── docs ├── swagger.yaml ├── swagger.json └── docs.go ├── LICENSE └── go.sum /version: -------------------------------------------------------------------------------- 1 | v1.0.0 -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # ginmvc 2 | Gin mvc template 3 | -------------------------------------------------------------------------------- /static/img/ipad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mritd/ginmvc/HEAD/static/img/ipad.png -------------------------------------------------------------------------------- /static/img/bg-signup.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mritd/ginmvc/HEAD/static/img/bg-signup.jpg -------------------------------------------------------------------------------- /static/img/bg-masthead.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mritd/ginmvc/HEAD/static/img/bg-masthead.jpg -------------------------------------------------------------------------------- /static/img/demo-image-01.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mritd/ginmvc/HEAD/static/img/demo-image-01.jpg -------------------------------------------------------------------------------- /static/img/demo-image-02.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mritd/ginmvc/HEAD/static/img/demo-image-02.jpg -------------------------------------------------------------------------------- /static/webfonts/fa-brands-400.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mritd/ginmvc/HEAD/static/webfonts/fa-brands-400.woff2 -------------------------------------------------------------------------------- /static/webfonts/fa-solid-900.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mritd/ginmvc/HEAD/static/webfonts/fa-solid-900.woff2 -------------------------------------------------------------------------------- /static/webfonts/fa-regular-400.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mritd/ginmvc/HEAD/static/webfonts/fa-regular-400.woff2 -------------------------------------------------------------------------------- /auth/consts.go: -------------------------------------------------------------------------------- 1 | package auth 2 | 3 | const JWTClaimsKey = "JWT_CLAIMS" 4 | const UserKey = "LOGIN_USER" 5 | const SaltLength = 8 6 | -------------------------------------------------------------------------------- /utils/common.go: -------------------------------------------------------------------------------- 1 | package utils 2 | 3 | import "github.com/sirupsen/logrus" 4 | 5 | func CheckAndExit(err error) { 6 | if err != nil { 7 | logrus.Panic(err) 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /models/common.go: -------------------------------------------------------------------------------- 1 | package models 2 | 3 | type CommonResp struct { 4 | Message string `json:"message"` 5 | Timestamp int64 `json:"timestamp"` 6 | Data interface{} `json:"data,omitempty"` 7 | } 8 | -------------------------------------------------------------------------------- /templates/rbac.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |
4 | 5 |Grayscale is a free Bootstrap theme created by Start Bootstrap. It can be yours right now, simply download the template on 70 | the preview page. The theme is open source, and you can use it for any purpose, personal or commercial.
71 |
74 |
85 | Grayscale is open source and MIT licensed. This means you can use it for any project - even commercial projects! Download it, customize it, and publish your website!
90 |
98 | An example of where you can put an image of a project, or anything else, along with a description.
105 |
116 | Another example of a project with its respective description. These sections work well responsively as well, try this theme on a small screen!
123 |