+ Update code to v2.7.1.

+ Update translations.
This commit is contained in:
Mohamed Hassan
2024-08-04 13:58:37 +03:00
17 changed files with 189 additions and 78 deletions
+23 -2
View File
@@ -52,8 +52,19 @@ func (autoApi *AutoCodeApi) GetDB(c *gin.Context) {
// @Success 200 {object} response.Response{data=map[string]interface{},msg=string} "获取当前数据库所有表"
// @Router /autoCode/getTables [get]
func (autoApi *AutoCodeApi) GetTables(c *gin.Context) {
dbName := c.DefaultQuery("dbName", global.GVA_CONFIG.Mysql.Dbname)
dbName := c.Query("dbName")
businessDB := c.Query("businessDB")
if dbName == "" {
dbName = global.GVA_CONFIG.Mysql.Dbname
if businessDB != "" {
for _, db := range global.GVA_CONFIG.DBList {
if db.AliasName == businessDB {
dbName = db.Dbname
}
}
}
}
tables, err := autoCodeService.Database(businessDB).GetTables(businessDB, dbName)
if err != nil {
global.GVA_LOG.Error(global.Translate("sys_auto_code.queryTablesFail"), zap.Error(err))
@@ -73,7 +84,17 @@ func (autoApi *AutoCodeApi) GetTables(c *gin.Context) {
// @Router /autoCode/getColumn [get]
func (autoApi *AutoCodeApi) GetColumn(c *gin.Context) {
businessDB := c.Query("businessDB")
dbName := c.DefaultQuery("dbName", global.GVA_CONFIG.Mysql.Dbname)
dbName := c.Query("dbName")
if dbName == "" {
dbName = global.GVA_CONFIG.Mysql.Dbname
if businessDB != "" {
for _, db := range global.GVA_CONFIG.DBList {
if db.AliasName == businessDB {
dbName = db.Dbname
}
}
}
}
tableName := c.Query("tableName")
columns, err := autoCodeService.Database(businessDB).GetColumn(businessDB, tableName, dbName)
if err != nil {
+1 -1
View File
@@ -39,7 +39,7 @@ func RunWindowsServer() {
fmt.Printf(`
%s gin-vue-admin
%s:v2.7.0
%s:v2.7.1
加群方式:微信号:shouzi_1994 QQ群:470239250
项目地址:https://github.com/flipped-aurora/gin-vue-admin
插件市场:https://plugin.gin-vue-admin.com
+1 -1
View File
@@ -8087,7 +8087,7 @@ const docTemplate = `{
// SwaggerInfo holds exported Swagger Info so clients can modify it
var SwaggerInfo = &swag.Spec{
Version: "v2.7.0",
Version: "v2.7.1",
Host: "",
BasePath: "",
Schemes: []string{},
+1 -1
View File
@@ -4,7 +4,7 @@
"description": "使用gin+vue进行极速开发的全栈开发基础平台",
"title": "Gin-Vue-Admin Swagger API接口文档",
"contact": {},
"version": "v2.7.0"
"version": "v2.7.1"
},
"paths": {
"/api/createApi": {
+1 -1
View File
@@ -1634,7 +1634,7 @@ info:
contact: {}
description: 使用gin+vue进行极速开发的全栈开发基础平台
title: Gin-Vue-Admin Swagger API接口文档
version: v2.7.0
version: v2.7.1
paths:
/api/createApi:
post:
+1 -1
View File
@@ -16,7 +16,7 @@ import (
//go:generate go mod download
// @title Gin-Vue-Admin Swagger API接口文档
// @version v2.7.0
// @version v2.7.1
// @description 使用gin+vue进行极速开发的全栈开发基础平台
// @securityDefinitions.apikey ApiKeyAuth
// @in header