https://github.com/lurenjia528/beegoapidemo
https://github.com/lurenjia528/beegoapidemo
beego go golang mysql
Last synced: 7 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/lurenjia528/beegoapidemo
- Owner: lurenjia528
- Created: 2019-06-02T15:00:49.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-04-12T11:29:35.000Z (over 5 years ago)
- Last Synced: 2025-01-10T08:33:21.219Z (9 months ago)
- Topics: beego, go, golang, mysql
- Language: Go
- Size: 466 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
beego api demo
创建表
```mysql
CREATE TABLE `student` (
`Id` int(11) NOT NULL,
`Name` varchar(10),
`Birthdate` date ,
`Gender` tinyint(1) ,
`Score` int(11),
PRIMARY KEY (`Id`)
);
```
创建项目`bee api beegoapidemo -tables="student" -driver=mysql -conn="root:123123@tcp(127.0.0.1:3306)/test"`
项目目录下运行
```bash
bee run -gendoc=true -downdoc=true
```
会在项目目录下产生swagger目录,访问
`http://127.0.0.1:8080/swagger/`