diff --git a/opencti-platform/opencti-front/src/private/components/common/stix_nested_ref_relationships/StixNestedRefRelationshipCreationFromEntity.jsx b/opencti-platform/opencti-front/src/private/components/common/stix_nested_ref_relationships/StixNestedRefRelationshipCreationFromEntity.jsx index 5023050c976c..42fd10ac6f14 100644 --- a/opencti-platform/opencti-front/src/private/components/common/stix_nested_ref_relationships/StixNestedRefRelationshipCreationFromEntity.jsx +++ b/opencti-platform/opencti-front/src/private/components/common/stix_nested_ref_relationships/StixNestedRefRelationshipCreationFromEntity.jsx @@ -507,10 +507,14 @@ const StixNestedRefRelationshipCreationFromEntity = ({ const searchPaginationOptions = { search: searchTerm, filters: removeIdFromFilterGroupObject(filters), - orderBy: searchTerm.length > 0 ? null : 'created_at', - orderMode: searchTerm.length > 0 ? null : 'desc', + orderBy: null, + orderMode: null, types: targetStixCoreObjectTypes, }; + if (searchTerm.length === 0) { + searchPaginationOptions.orderBy = sortBy; + searchPaginationOptions.orderMode = orderAsc ? 'asc' : 'desc'; + } const dataColumns = { entity_type: { label: 'Type',