From 755373468cbb88e16d3e3afb55b96089fa2a31b8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?piexlMax=28=E5=A5=87=E6=B7=BC?= Date: Fri, 16 Jan 2026 16:19:22 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E4=B8=BAmcp=E5=A2=9E=E5=8A=A0=E5=AD=97?= =?UTF-8?q?=E6=AE=B5=E7=A4=BA=E4=BE=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server/mcp/gva_execute.go | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/server/mcp/gva_execute.go b/server/mcp/gva_execute.go index e28d2f55..3b2edbc7 100644 --- a/server/mcp/gva_execute.go +++ b/server/mcp/gva_execute.go @@ -112,14 +112,14 @@ func (g *GVAExecutor) New() mcp.Tool { "items": map[string]interface{}{ "type": "object", "properties": map[string]interface{}{ - "package": map[string]interface{}{"type": "string", "description": "包名(小写开头)"}, - "tableName": map[string]interface{}{"type": "string", "description": "数据库表名(蛇形命名法)"}, + "package": map[string]interface{}{"type": "string", "description": "包名(小写开头,示例: userInfo)"}, + "tableName": map[string]interface{}{"type": "string", "description": "数据库表名(蛇形命名法,示例:user_info)"}, "businessDB": map[string]interface{}{"type": "string", "description": "业务数据库(可留空表示默认)"}, - "structName": map[string]interface{}{"type": "string", "description": "结构体名(大驼峰)"}, + "structName": map[string]interface{}{"type": "string", "description": "结构体名(大驼峰示例:UserInfo)"}, "packageName": map[string]interface{}{"type": "string", "description": "文件名称"}, "description": map[string]interface{}{"type": "string", "description": "中文描述"}, "abbreviation": map[string]interface{}{"type": "string", "description": "简称"}, - "humpPackageName": map[string]interface{}{"type": "string", "description": "文件名称(小驼峰),一般是结构体名的小驼峰"}, + "humpPackageName": map[string]interface{}{"type": "string", "description": "文件名称(小驼峰),一般是结构体名的小驼峰示例:userInfo"}, "gvaModel": map[string]interface{}{"type": "boolean", "description": "是否使用GVA模型(固定为true),自动包含ID、CreatedAt、UpdatedAt、DeletedAt字段"}, "autoMigrate": map[string]interface{}{"type": "boolean", "description": "是否自动迁移数据库"}, "autoCreateResource": map[string]interface{}{"type": "boolean", "description": "是否创建资源(默认为false)"}, @@ -138,13 +138,13 @@ func (g *GVAExecutor) New() mcp.Tool { "items": map[string]interface{}{ "type": "object", "properties": map[string]interface{}{ - "fieldName": map[string]interface{}{"type": "string", "description": "字段名(必须大写开头)"}, + "fieldName": map[string]interface{}{"type": "string", "description": "字段名(必须大写开头示例:UserName)"}, "fieldDesc": map[string]interface{}{"type": "string", "description": "字段描述"}, "fieldType": map[string]interface{}{"type": "string", "description": "字段类型:string(字符串)、richtext(富文本)、int(整型)、bool(布尔值)、float64(浮点型)、time.Time(时间)、enum(枚举)、picture(单图片)、pictures(多图片)、video(视频)、file(文件)、json(JSON)、array(数组)"}, - "fieldJson": map[string]interface{}{"type": "string", "description": "JSON标签"}, + "fieldJson": map[string]interface{}{"type": "string", "description": "JSON标签,示例: userName"}, "dataTypeLong": map[string]interface{}{"type": "string", "description": "数据长度"}, "comment": map[string]interface{}{"type": "string", "description": "注释"}, - "columnName": map[string]interface{}{"type": "string", "description": "数据库列名"}, + "columnName": map[string]interface{}{"type": "string", "description": "数据库列名,示例: user_name"}, "fieldSearchType": map[string]interface{}{"type": "string", "description": "搜索类型:=、!=、>、>=、<、<=、LIKE、BETWEEN、IN、NOT IN、NOT BETWEEN"}, "fieldSearchHide": map[string]interface{}{"type": "boolean", "description": "是否隐藏搜索"}, "dictType": map[string]interface{}{"type": "string", "description": "字典类型,使用字典类型时系统会自动检查并创建字典"},