mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-18 15:40:12 +01:00
🎨 Database grouping by field https://github.com/siyuan-note/siyuan/issues/10964
This commit is contained in:
parent
59d8db4f24
commit
3c0933beac
1 changed files with 9 additions and 1 deletions
|
|
@ -107,7 +107,7 @@ func removeAttributeViewGroup(avID, blockID string) (err error) {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
view.Group, view.Groups, view.GroupUpdated = nil, nil, 0
|
removeAttributeViewGroup0(view)
|
||||||
err = av.SaveAttributeView(attrView)
|
err = av.SaveAttributeView(attrView)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logging.LogErrorf("save attribute view [%s] failed: %s", avID, err)
|
logging.LogErrorf("save attribute view [%s] failed: %s", avID, err)
|
||||||
|
|
@ -116,6 +116,10 @@ func removeAttributeViewGroup(avID, blockID string) (err error) {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func removeAttributeViewGroup0(view *av.View) {
|
||||||
|
view.Group, view.Groups, view.GroupUpdated = nil, nil, 0
|
||||||
|
}
|
||||||
|
|
||||||
func (tx *Transaction) doSyncAttrViewTableColWidth(operation *Operation) (ret *TxErr) {
|
func (tx *Transaction) doSyncAttrViewTableColWidth(operation *Operation) (ret *TxErr) {
|
||||||
err := syncAttrViewTableColWidth(operation)
|
err := syncAttrViewTableColWidth(operation)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
@ -3911,6 +3915,10 @@ func RemoveAttributeViewKey(avID, keyID string, removeRelationDest bool) (err er
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
for _, view := range attrView.Views {
|
||||||
|
removeAttributeViewGroup0(view)
|
||||||
|
}
|
||||||
|
|
||||||
err = av.SaveAttributeView(attrView)
|
err = av.SaveAttributeView(attrView)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue