1
0
Fork 0
mirror of https://github.com/anyproto/anytype-kotlin.git synced 2025-06-08 13:57:10 +09:00

DROID-3483 Global search | Filter type property meta in search (#2277)

This commit is contained in:
Konstantin Ivanov 2025-04-10 11:55:07 +02:00 committed by GitHub
parent 9a83482449
commit 2b633cf69a
Signed by: github
GPG key ID: B5690EEEBB952194
2 changed files with 3 additions and 2 deletions

View file

@ -586,7 +586,7 @@ suspend fun Command.SearchWithMeta.Result.view(
is Command.SearchWithMeta.Result.Meta.Source.Relation -> {
val relation = storeOfRelations.getByKey(source.key)
val dep = meta.dependencies.firstOrNull()
if (relation != null && relation.map.isNotEmpty() && dep != null && dep.map.isNotEmpty()) {
if (relation != null && relation.map.isNotEmpty() && relation.key != Relations.TYPE && dep != null && dep.map.isNotEmpty()) {
when(relation.format) {
SHORT_TEXT, LONG_TEXT, URL, EMAIL, PHONE -> {
GlobalSearchItemView.Meta.Default(

View file

@ -240,7 +240,8 @@ class ObjectSetNavigationTest : ObjectSetViewModelTestSetup() {
ObjectType.Layout.PROFILE,
ObjectType.Layout.SET,
ObjectType.Layout.COLLECTION,
ObjectType.Layout.DATE
ObjectType.Layout.DATE,
ObjectType.Layout.OBJECT_TYPE,
)
val unsupportedLayout = unsupportedLayouts.random()
val objectUnsupportedLayout = ObjectWrapper.Basic(