fix: share page data;Adapt findLastIndex api (#3147)

* perf: share page data

* perf: adapt findLastIndex
This commit is contained in:
Archer
2024-11-13 13:08:34 +08:00
committed by GitHub
parent 519b519458
commit c3cc51c9a0
9 changed files with 100 additions and 56 deletions

View File

@@ -78,11 +78,15 @@ export const getHistoryPreview = (
};
export const filterPublicNodeResponseData = ({
flowResponses = []
flowResponses = [],
responseDetail = false
}: {
flowResponses?: ChatHistoryItemResType[];
responseDetail?: boolean;
}) => {
const filedList = ['quoteList', 'moduleType', 'pluginOutput', 'runningTime'];
const filedList = responseDetail
? ['quoteList', 'moduleType', 'pluginOutput', 'runningTime']
: ['moduleType', 'pluginOutput', 'runningTime'];
const filterModuleTypeList: any[] = [
FlowNodeTypeEnum.pluginModule,
FlowNodeTypeEnum.datasetSearchNode,