Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
P
poc-api
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
poc
poc-api
Commits
d537bf8e
Commit
d537bf8e
authored
Jun 21, 2025
by
alex yao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat:门户页对话添加Agent对话选择
parent
2569edab
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
34 additions
and
4 deletions
+34
-4
PortalServiceImpl.java
...a/cn/com/poc/portal/aggregate/impl/PortalServiceImpl.java
+6
-4
PortalConvert.java
src/main/java/cn/com/poc/portal/convert/PortalConvert.java
+1
-0
PortalDialoguesDto.java
src/main/java/cn/com/poc/portal/dto/PortalDialoguesDto.java
+14
-0
PortalDialoguesCallEntity.java
...a/cn/com/poc/portal/entity/PortalDialoguesCallEntity.java
+13
-0
No files found.
src/main/java/cn/com/poc/portal/aggregate/impl/PortalServiceImpl.java
View file @
d537bf8e
...
...
@@ -4,6 +4,7 @@ import cn.com.poc.agent_application.aggregate.AgentApplicationService;
import
cn.com.poc.agent_application.constant.AgentApplicationDialoguesRecordConstants
;
import
cn.com.poc.agent_application.entity.*
;
import
cn.com.poc.agent_application.service.BizAgentApplicationDialoguesRecordService
;
import
cn.com.poc.agent_application.service.BizAgentApplicationInfoService
;
import
cn.com.poc.agent_application.service.BizAgentApplicationPublishService
;
import
cn.com.poc.agent_application.utils.AgentApplicationTools
;
import
cn.com.poc.ai_dialogues.entity.BizAiDialoguesEntity
;
...
...
@@ -62,7 +63,8 @@ public class PortalServiceImpl implements PortalService {
private
KnowledgeService
knowledgeService
;
@Resource
private
BizAgentApplicationPublishService
bizAgentApplicationPublishService
;
private
BizAgentApplicationInfoService
bizAgentApplicationInfoService
;
@Resource
private
BizAgentApplicationDialoguesRecordService
bizAgentApplicationDialoguesRecordService
;
...
...
@@ -70,16 +72,16 @@ public class PortalServiceImpl implements PortalService {
@Override
public
void
call
(
PortalDialoguesCallEntity
callEntity
,
Long
userId
)
throws
Exception
{
String
agentId
=
fmxParamConfigService
.
getParam
(
FMX_PARAM_AGENT_ID_CODE
);
String
agentId
=
StringUtils
.
isBlank
(
callEntity
.
getAgentId
())
?
fmxParamConfigService
.
getParam
(
FMX_PARAM_AGENT_ID_CODE
)
:
callEntity
.
getAgentId
(
);
if
(
StringUtils
.
isBlank
(
agentId
))
{
logger
.
error
(
"获取门户首页对话agentId失败"
);
throw
new
BusinessException
(
"对话异常"
);
}
// 获取Agent基本信息
BizAgentApplication
PublishEntity
infoEntity
=
bizAgentApplicationPublish
Service
.
getByAgentId
(
agentId
);
BizAgentApplication
InfoEntity
infoEntity
=
bizAgentApplicationInfo
Service
.
getByAgentId
(
agentId
);
if
(
infoEntity
==
null
)
{
logger
.
error
(
"获取
门户首页
对话agent信息失败"
);
logger
.
error
(
"获取对话agent信息失败"
);
throw
new
BusinessException
(
"对话异常"
);
}
...
...
src/main/java/cn/com/poc/portal/convert/PortalConvert.java
View file @
d537bf8e
...
...
@@ -13,6 +13,7 @@ public class PortalConvert {
PortalDialoguesCallEntity
portalDialoguesCallEntity
=
new
PortalDialoguesCallEntity
();
portalDialoguesCallEntity
.
setDialoguesId
(
dto
.
getDialoguesId
());
portalDialoguesCallEntity
.
setInput
(
dto
.
getInput
());
portalDialoguesCallEntity
.
setAgentId
(
dto
.
getAgentId
());
portalDialoguesCallEntity
.
setEnableSearchEngine
(
dto
.
getEnableSearchEngine
());
portalDialoguesCallEntity
.
setEnableDeepThinking
(
dto
.
getEnableDeepThinking
());
portalDialoguesCallEntity
.
setFileUrl
(
dto
.
getFileUrl
());
...
...
src/main/java/cn/com/poc/portal/dto/PortalDialoguesDto.java
View file @
d537bf8e
...
...
@@ -14,6 +14,12 @@ public class PortalDialoguesDto {
*/
private
String
dialoguesId
;
/**
* agentId
*/
private
String
agentId
;
/**
* 问题
*/
...
...
@@ -39,6 +45,14 @@ public class PortalDialoguesDto {
*/
private
Integer
[]
knowledgeIds
;
public
String
getAgentId
()
{
return
agentId
;
}
public
void
setAgentId
(
String
agentId
)
{
this
.
agentId
=
agentId
;
}
public
String
getInput
()
{
return
input
;
}
...
...
src/main/java/cn/com/poc/portal/entity/PortalDialoguesCallEntity.java
View file @
d537bf8e
...
...
@@ -13,6 +13,11 @@ public class PortalDialoguesCallEntity {
*/
private
String
dialoguesId
;
/**
* AgentId
*/
private
String
agentId
;
/**
* 问题
*/
...
...
@@ -38,6 +43,14 @@ public class PortalDialoguesCallEntity {
*/
private
Integer
[]
knowledgeIds
;
public
String
getAgentId
()
{
return
agentId
;
}
public
void
setAgentId
(
String
agentId
)
{
this
.
agentId
=
agentId
;
}
public
String
getDialoguesId
()
{
return
dialoguesId
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment