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

@@ -262,7 +262,7 @@ func findWorkspaceList(ctx context.Context, tx *sql.Tx, find *api.WorkspaceFind)
where, args = append(where, "name = ?"), append(args, *v)
}
if v := find.MemberID; v != nil {
where, args = append(where, "id IN (SELECT workspace_id FROM workspace_user WHERE user_id = ? )"), append(args, *v)
where, args = append(where, "id IN (SELECT workspace_id FROM workspace_user WHERE user_id = ?)"), append(args, *v)
}
query := `