Add Users list/detail with ACL toggles and library people update/status APIs. Fix project table layout and ANSI-safe cell rendering, and decode array responses from people/status so saves no longer fail on JSON unmarshal. Co-authored-by: Cursor <cursoragent@cursor.com>
23 lines
467 B
Go
23 lines
467 B
Go
package ui
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"github.com/eslider/go-onlyoffice/cmd/office/model"
|
|
)
|
|
|
|
func TestLayoutProjectTableAllColumnsVisible(t *testing.T) {
|
|
cols := model.BuildColumns(model.SubjectProjects, nil)
|
|
lay := layoutProjectTable(cols, 80)
|
|
if len(lay.indices) != 7 {
|
|
t.Fatalf("got %d visible columns, want 7", len(lay.indices))
|
|
}
|
|
sum := 0
|
|
for _, i := range lay.indices {
|
|
sum += lay.widths[i]
|
|
}
|
|
if sum != 80 {
|
|
t.Fatalf("width sum=%d want 80", sum)
|
|
}
|
|
}
|