|
|
@@ -127,7 +127,7 @@
|
|
|
(upsert-property! repo k-name (assoc property-schema :type property-type)
|
|
|
{:property-uuid property-uuid})
|
|
|
(let [block-properties (assoc properties property-uuid values')
|
|
|
- refs (outliner-core/rebuild-block-refs block block-properties)]
|
|
|
+ refs (outliner-core/rebuild-block-refs repo block block-properties)]
|
|
|
(db/transact! repo
|
|
|
[[:db/retract (:db/id block) :block/refs]
|
|
|
{:block/uuid (:block/uuid block)
|
|
|
@@ -222,7 +222,8 @@
|
|
|
(set (remove string/blank? new-value)))
|
|
|
new-value)
|
|
|
block-properties (assoc properties property-uuid new-value)
|
|
|
- refs (outliner-core/rebuild-block-refs block
|
|
|
+ refs (outliner-core/rebuild-block-refs repo
|
|
|
+ block
|
|
|
block-properties)]
|
|
|
(db/transact! repo
|
|
|
[[:db/retract (:db/id block) :block/refs]
|
|
|
@@ -333,7 +334,7 @@
|
|
|
nil))
|
|
|
properties (:block/properties block)
|
|
|
block-properties (assoc properties property-uuid v*)
|
|
|
- refs (outliner-core/rebuild-block-refs block block-properties)]
|
|
|
+ refs (outliner-core/rebuild-block-refs repo block block-properties)]
|
|
|
[[:db/retract (:db/id block) :block/refs]
|
|
|
{:block/uuid (:block/uuid block)
|
|
|
:block/properties block-properties
|
|
|
@@ -353,7 +354,7 @@
|
|
|
(let [origin-properties (:block/properties block)]
|
|
|
(when (contains? (set (keys origin-properties)) property-uuid)
|
|
|
(let [properties' (dissoc origin-properties property-uuid)
|
|
|
- refs (outliner-core/rebuild-block-refs block properties')
|
|
|
+ refs (outliner-core/rebuild-block-refs repo block properties')
|
|
|
property (db/entity [:block/uuid property-uuid])
|
|
|
value (get origin-properties property-uuid)
|
|
|
block-value? (and (= :default (get-in property [:block/schema :type] :default))
|
|
|
@@ -422,7 +423,7 @@
|
|
|
properties' (update properties property-id
|
|
|
(fn [col]
|
|
|
(set (remove #{property-value} col))))
|
|
|
- refs (outliner-core/rebuild-block-refs block properties')]
|
|
|
+ refs (outliner-core/rebuild-block-refs repo block properties')]
|
|
|
(db/transact! repo
|
|
|
[[:db/retract (:db/id block) :block/refs]
|
|
|
{:block/uuid (:block/uuid block)
|