I am new to Beego as well as Go. I read its documentation but it puts every ORM operation in the main package instead of model package. I can't understand how to organize the code. I am really very confused.
Asked
Active
Viewed 1,884 times
1 Answers
2
You can feel free to follow steps as below, and try to build your first database program.
- Build [Models] According to the table structure of your database.
- Initialize the ORM
- New an ORM instance
- Operate CRUD as your want
Link:
Guidance for Beego/orm configuration
https://beego.me/docs/mvc/model/orm.md
Guidance for operating CRUD on Beego/orm
https://beego.me/docs/mvc/model/object.md

Dennis Mao
- 54
- 4