Skip to content

Latest commit

 

History

History
221 lines (133 loc) · 6.84 KB

README.en.md

File metadata and controls

221 lines (133 loc) · 6.84 KB

go-admin

build license

English | 简体中文

Gin + Vue + Element UI based scaffolding for front and back separation management system

✨ Feature

  • Follow RESTful API design specifications

  • Provides rich middleware support based on GIN WEB API framework (user authentication, cross domain, access log, tracking ID, etc.)

  • Casbin-based RBAC access control model

  • JWT certification

  • Support Swagger documentation (based on swaggo)

  • GORM-based database storage that can expand many types of databases

  • Simple model mapping of configuration files to quickly get the desired configuration

  • Form builder

  • Multi command mode

  • TODO: unit test

🎁 Built-in functions

  1. User management: The user is the system operator. This function mainly completes the system user configuration.
  2. Department management: configure the system organization (company, department, group), and display the tree structure to support data permissions.
  3. Post management: Configure system users to hold positions.
  4. Menu management: configure system menus, operation permissions, button permission labels, etc.
  5. Role management: role menu permissions assignment, setting roles to divide data range permissions by organization.
  6. Dictionary management: to maintain some fixed data often used in the system.
  7. Parameter management: Dynamically configure common parameters for the system.
  8. Operation log: system normal operation log record and query; system exception information log record and query.
  9. Login log: The system login log record query contains login exceptions.
  10. System interface: Automatically generate related api interface documents according to business code.
  11. Multi command mode code generation: according to the data table structure to generate the corresponding business, all visual programming, basic business can be 0 code.
  12. Form construction: Customize page style, drag and drop to achieve page layout.
  13. Service monitoring: view the basic information of some servers.

🗞 System architecture

📦 Local development

Create development directory

mkdir goadmin
cd goadmin

Get code

Key points: two projects must be placed in the same folder;

# Get backend code
git clone https://github.com/go-admin-team/go-admin.git

# Get front end code
git clone https://github.com/go-admin-team/go-admin-ui.git

Start up instructions

Server startup instructions

# Enter the go-admin backend project
cd ./go-admin

# Compile project
go build

# Configuration 
# file path  go-admin/config/settings.yml
vi ./config/setting.yml 

# 1. Modifying database information in configuration file 
# settings.database Corresponding configuration data under
# 2. Confirm log path

Initialize the database and start the service

# The first configuration needs to initialize the database resource information
./go-admin migrate -c config/settings.yml


# Start the project, you can also debug with IDE
./go-admin server -c config/settings.yml

Using docker to compile and start

# Compile image
docker build -t go-admin .

# Start the container. The first go admin is the container name and the second go admin is the image name
docker run --name go-admin -p 8000:8000 -v /config/settings.yml:/config/settings.yml -d go-admin

Document generation

go generate

Cross compiling

env GOOS=windows GOARCH=amd64 go build main.go

# or

env GOOS=linux GOARCH=amd64 go build main.go

UI interactive terminal startup description

# Installation dependency
npm install

# It is recommended that you do not use cnpm to install dependencies directly. There will be all kinds of weird bugs. The problem of slow download speed of NPM can be solved by the following operations
npm install --registry=https://registry.npm.taobao.org

# Start the service
npm run dev

🎬 Online Demo

admin / 123456

Demo:http://www.go-admin.dev

📨 Interaction

WeChat This QQ group is full go-admin技术交流乙号

💎 Member

JetBrains Open source certificate support

The go admin project has always been developed in the GoLand integrated development environment of JetBrains company, based on the * * free JetBrains open source license (s) * * genuine free license. I would like to express my thanks.

🤝 Open source projects used

gin

casbin

spf13/viper

gorm

gin-swagger

jwt-go

vue-element-admin

ruoyi-vue

🤝 Thanks

  1. chengxiao

License

MIT

Copyright (c) 2020 wenjianzhang

[中文]qq technical exchange group: 74520518