Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/herusdianto/gorm_crud_example
GoLang, GORM & Gin CRUD Example
https://github.com/herusdianto/gorm_crud_example
gin gin-gonic go golang gorm gorm-orm
Last synced: 3 months ago
JSON representation
GoLang, GORM & Gin CRUD Example
- Host: GitHub
- URL: https://github.com/herusdianto/gorm_crud_example
- Owner: herusdianto
- Created: 2019-06-29T05:56:35.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2019-07-23T07:52:36.000Z (over 5 years ago)
- Last Synced: 2024-10-01T01:01:29.325Z (4 months ago)
- Topics: gin, gin-gonic, go, golang, gorm, gorm-orm
- Language: Go
- Homepage:
- Size: 26.4 KB
- Stars: 77
- Watchers: 0
- Forks: 33
- Open Issues: 1
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# Go, GORM & Gin CRUD Example
## Install
1. Clone this repository to `$GOPATH/src/github.com/herusdianto` directory:
git clone https://github.com/herusdianto/gorm_crud_example.git
2. Install `glide`:
https://glide.sh/
3. CD to `gorm_crud_example` folder:
cd $GOPATH/src/github.com/herusdianto/gorm_crud_example
4. Install dependencies using `glide`:
glide install
5. Open `main.go` and modify this variable values:
dbUser, dbPassword, dbName := "root", "root", "gorm_crud_example"
6. Login to `MySQL` and create the database:
create database gorm_crud_example;
7. Run `main.go`:
go run main.go
## Features
- [x] Database Migration
- [x] Create Data
- [x] Read All Data
- [x] Find One Data By ID
- [x] Update Data
- [x] Delete One Data By ID
- [x] Delete Multiple Data By IDs
- [x] Sort & Paginate Data
- [x] Search DataIf you want to watch step by step I'm making this, you can watch this [videos](https://www.youtube.com/playlist?list=PLKmlCa2HUPq-K7hIyHGbDoYs6YZBM8yA-).
Support me with subscribe to my [channel](https://www.youtube.com/channel/UCpKERrPCRQBFaTnJu4xWn5A) on youtube, thank you.