refactor: DateTimeTool 注入为单例依赖
为 DateTimeTool 实现 ISingletonDependency,统一生命周期管理,便于依赖注入使用
This commit is contained in:
@@ -1,10 +1,11 @@
|
||||
using System.ComponentModel;
|
||||
using Volo.Abp.DependencyInjection;
|
||||
using Yi.Framework.AiHub.Domain.Shared.Attributes;
|
||||
|
||||
namespace Yi.Framework.AiHub.Domain.Mcp;
|
||||
|
||||
[YiAgentTool]
|
||||
public class DateTimeTool
|
||||
public class DateTimeTool:ISingletonDependency
|
||||
{
|
||||
[YiAgentTool("时间"), DisplayName("DateTime"), Description("获取当前日期与时间")]
|
||||
public DateTime DateTime()
|
||||
|
||||
Reference in New Issue
Block a user