如何使用 OTRS 6 中的通用接口获取用户相关数据?
How to get user related data with Generic Interface in OTRS 6?
我想知道如何使用通用接口获取用户数据。似乎没有控制器来获取用户数据......
这些是唯一的控制器:
那么如何将用户方法添加到我的网络服务中呢?
我尝试在我的 webservice.yml 中添加一个用户部分并重新导入它:
User:
Description: Search for User Data
MappingInbound: {}
MappingOutbound: {}
Type: Kernel::System::User
但这没有用。 OTRS 说 Kernel::System::User 没有控制器。我也尝试只将类型设置为用户。同样的错误。
由于通用接口取代了已弃用的 RPC.pl API,它至少应该具有相同的方法集。
否则这不会是 API 的改进吧?
您可以自己创建控制器,并不难。
查看 Kernel/GenericInterface/Operation/*
中的现有服务
使用 XML 注册新操作,在此处查找示例:Kernel/Config/Files/XML/GenericInterface.xml
别忘了打电话:
/opt/otrs/bin/otrs.SetPermissions.pl
(作为根用户)
/opt/otrs/bin/otrs.Console.pl Maint::Config::Rebuild
创建新文件后
我想知道如何使用通用接口获取用户数据。似乎没有控制器来获取用户数据......
这些是唯一的控制器:
User:
Description: Search for User Data
MappingInbound: {}
MappingOutbound: {}
Type: Kernel::System::User
但这没有用。 OTRS 说 Kernel::System::User 没有控制器。我也尝试只将类型设置为用户。同样的错误。
由于通用接口取代了已弃用的 RPC.pl API,它至少应该具有相同的方法集。 否则这不会是 API 的改进吧?
您可以自己创建控制器,并不难。
查看 Kernel/GenericInterface/Operation/*
使用 XML 注册新操作,在此处查找示例:Kernel/Config/Files/XML/GenericInterface.xml
别忘了打电话:
/opt/otrs/bin/otrs.SetPermissions.pl
(作为根用户)
/opt/otrs/bin/otrs.Console.pl Maint::Config::Rebuild
创建新文件后