feat: register workspace user api

This commit is contained in:
Steven
2022-09-21 23:26:05 +08:00
parent 3364d1bf39
commit c0699f159e
6 changed files with 197 additions and 21 deletions

View File

@ -292,7 +292,7 @@ func findShortcutList(ctx context.Context, tx *sql.Tx, find *api.ShortcutFind) (
where = append(where, fmt.Sprintf("visibility in (%s)", strings.Join(list, ",")))
}
if v := find.MemberID; v != nil {
where, args = append(where, "workspace_id IN (SELECT workspace_id FROM workspace_user WHERE user_id = ? )"), append(args, *v)
where, args = append(where, "workspace_id IN (SELECT workspace_id FROM workspace_user WHERE user_id = ?)"), append(args, *v)
}
rows, err := tx.QueryContext(ctx, `