mirror of
https://github.com/anyproto/anytype-kotlin.git
synced 2025-06-08 05:47:05 +09:00
DROID-3601 Primitives | Tech | Storing archived types (#2357)
This commit is contained in:
parent
adc36f1a6b
commit
fd1c45f780
3 changed files with 4 additions and 9 deletions
|
@ -74,11 +74,6 @@ class ObjectTypesSubscriptionManager (
|
|||
condition = DVFilterCondition.EQUAL,
|
||||
value = ObjectType.Layout.OBJECT_TYPE.code.toDouble()
|
||||
),
|
||||
DVFilter(
|
||||
relation = Relations.SPACE_ID,
|
||||
condition = DVFilterCondition.EQUAL,
|
||||
value = config.space
|
||||
),
|
||||
DVFilter(
|
||||
relation = Relations.IS_DELETED,
|
||||
condition = DVFilterCondition.NOT_EQUAL,
|
||||
|
@ -86,8 +81,7 @@ class ObjectTypesSubscriptionManager (
|
|||
),
|
||||
DVFilter(
|
||||
relation = Relations.IS_ARCHIVED,
|
||||
condition = DVFilterCondition.NOT_EQUAL,
|
||||
value = true
|
||||
condition = DVFilterCondition.NONE
|
||||
),
|
||||
DVFilter(
|
||||
relation = Relations.UNIQUE_KEY,
|
||||
|
@ -124,6 +118,7 @@ class ObjectTypesSubscriptionManager (
|
|||
Relations.RECOMMENDED_FEATURED_RELATIONS,
|
||||
Relations.RECOMMENDED_HIDDEN_RELATIONS,
|
||||
Relations.RECOMMENDED_FILE_RELATIONS,
|
||||
Relations.IS_ARCHIVED
|
||||
),
|
||||
ignoreWorkspace = true
|
||||
)
|
||||
|
|
|
@ -181,7 +181,7 @@ class ObjectTypeViewModel(
|
|||
|
||||
//region INIT AND LIFE CYCLE
|
||||
init {
|
||||
Timber.d("init, vmParams: $vmParams")
|
||||
Timber.i("ObjectTypeViewModel init, vmParams: $vmParams")
|
||||
proceedWithObservingSyncStatus()
|
||||
proceedWithObservingObjectType()
|
||||
proceedWithGetObjectTypeConflictingFields()
|
||||
|
|
|
@ -65,7 +65,7 @@ class SpaceTypesViewModel(
|
|||
storeOfObjectTypes.getAll().mapNotNull { objectType ->
|
||||
val resolvedLayout =
|
||||
objectType.recommendedLayout ?: return@mapNotNull null
|
||||
if (notAllowedTypesLayouts.contains(resolvedLayout)) {
|
||||
if (notAllowedTypesLayouts.contains(resolvedLayout) || objectType.isArchived == true) {
|
||||
return@mapNotNull null
|
||||
} else {
|
||||
objectType
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue