diff --git a/yuthon_ai_agent/models/ai_agent.py b/yuthon_ai_agent/models/ai_agent.py index 02871506a..7115255c9 100644 --- a/yuthon_ai_agent/models/ai_agent.py +++ b/yuthon_ai_agent/models/ai_agent.py @@ -765,6 +765,7 @@ class AiConversation(models.Model): '1. 张三 / 研发部 / 2025-03-01\n' '2. 李四 / 财务部 / 2025-03-15\n' '【报表与推送】当用户要求查看列表/报表/明细时,' + '只生成一个链接即可,不要生成多个链接或过多说明。\n' '优先调用 get_report_link 工具:\n' ' 1) 从"可用报表模板"中找到匹配的 template_id\n' ' 2) 调用 get_report_link({"template_id": XX}) 获取固定链接\n' @@ -778,9 +779,8 @@ class AiConversation(models.Model): '报表链接只能从 get_report_link 或 generate_report 工具返回的 url 字段中获取,' '直接用工具返回的 URL,不要做任何修改。' '如果你自己拼一个 /ai/report/xxx 或任何自创的链接格式,用户点击后会看到"报表不存在"。\n' - '生成报表后系统会自动尝试推送到用户的企微。无论推送是否成功,' - '回复时都要说明查询结果并附上工具返回的真实链接,如:\n' - '已为您生成报表,共查询到 XX 条记录:\n' + '生成报表后系统会自动尝试推送到用户的企微。回复时保持简洁,' + '只发送一条包含链接的简短消息即可,不要添加过多说明。如:\n' 'https://oa.thtzjt.com/ai/report/xxxxxxxxxxxxxxxxxxxxxxxx\n' '查询结果中的时间已经转换为北京时间(UTC+8),直接展示即可,无需再做时区转换。\n\n' '【重要】你具有记忆能力。当对话中发现用户的新偏好、工作内容、习惯等值得长期记住的信息时,' diff --git a/yuthon_ai_agent/views/ai_report_views.xml b/yuthon_ai_agent/views/ai_report_views.xml index adebd8b33..447fb4b64 100644 --- a/yuthon_ai_agent/views/ai_report_views.xml +++ b/yuthon_ai_agent/views/ai_report_views.xml @@ -29,7 +29,7 @@
+ bg_color="text-bg-danger" invisible="active"/>

@@ -40,7 +40,7 @@ + options="{'no_create': True}"/> @@ -70,15 +70,15 @@ + domain="[('active','=',True),('expire_date','>=', context_today().strftime('%Y-%m-%d'))]"/> + domain="[('expire_date','<', context_today().strftime('%Y-%m-%d'))]"/> + context="{'group_by': 'model_name'}"/> + context="{'group_by': 'create_uid'}"/> @@ -93,8 +93,8 @@ + parent="menu_system_config" action="action_ai_report" sequence="4" + groups="yuthon_ai_agent.group_ai_agent_admin"/> @@ -124,28 +124,28 @@ + bg_color="text-bg-danger" invisible="active"/>
@@ -155,72 +155,75 @@ + placeholder="选择数据模型" + options="{'no_create': True}"/> + placeholder="描述此模板用途,AI 会根据描述判断何时使用"/> + domain="[('id', 'in', column_field_ids)]" + placeholder="添加分组字段..."/> + domain="[('id', 'in', column_field_ids)]" + placeholder="添加筛选器..."/> - - - - + + + + + placeholder="date_order desc"/> - + placeholder="[('state','=','sale')]"/> + + - - - - - - - - - - - - - + - - - - + placeholder="选择字段..." + options="{'no_create': True}"/> + + + + + + + + + + + + + + + + + + @@ -229,8 +232,8 @@ + placeholder="选择映射字段..." + options="{'no_create': True}"/> @@ -254,7 +257,7 @@ + parent="menu_system_config" action="action_ai_report_template" sequence="5" + groups="yuthon_ai_agent.group_ai_agent_admin"/>
-

+

+ +