feat: 为mcp增加字段示例

This commit is contained in:
piexlMax(奇淼 2026-01-16 16:19:22 +08:00
parent d2e64e618e
commit 755373468c
1 changed files with 7 additions and 7 deletions

View File

@ -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文件、jsonJSON、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": "字典类型,使用字典类型时系统会自动检查并创建字典"},