🎨 Imporve database image browsing (#15548)

This commit is contained in:
Jiangshuon 2025-08-12 18:06:05 +08:00 committed by GitHub
parent 5becccc176
commit b1c0365e56
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1826,9 +1826,14 @@ func GetCurrentAttributeViewImages(avID, viewID, query string) (ret []string, er
av.Filter(table, attrView)
av.Sort(table, attrView)
ids:= map[string]bool{}
for _, column := range table.Columns {
ids[column.ID] = column.Hidden
}
for _, row := range table.Rows {
for _, cell := range row.Cells {
if nil != cell.Value && av.KeyTypeMAsset == cell.Value.Type && nil != cell.Value.MAsset {
if nil != cell.Value && av.KeyTypeMAsset == cell.Value.Type && nil != cell.Value.MAsset && !ids[cell.Value.KeyID]{
for _, a := range cell.Value.MAsset {
if av.AssetTypeImage == a.Type {
ret = append(ret, a.Content)