Skip to content

feat: add PUT /api/v2/users/:user-id/suspend endpoint #1154

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 11 commits into from
Apr 26, 2022
Prev Previous commit
Next Next commit
refactor: rename user_status_type to user_status
  • Loading branch information
BrunoQuaresma committed Apr 26, 2022
commit d0d69158a78c4b5fddceea81e23ce86a437e0cec
4 changes: 2 additions & 2 deletions coderd/database/dump.sql

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion coderd/database/migrations/000007_user_status.down.sql
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
DROP TYPE user_status_type;
DROP TYPE user_status;

ALTER TABLE ONLY users
DROP COLUMN IF EXISTS status;
4 changes: 2 additions & 2 deletions coderd/database/migrations/000007_user_status.up.sql
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
CREATE TYPE user_status_type AS ENUM ('active', 'suspended');
CREATE TYPE user_status AS ENUM ('active', 'suspended');

ALTER TABLE ONLY users
ADD COLUMN IF NOT EXISTS status user_status_type NOT NULL DEFAULT 'active';
ADD COLUMN IF NOT EXISTS status user_status NOT NULL DEFAULT 'active';
28 changes: 14 additions & 14 deletions coderd/database/models.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions coderd/database/queries.sql.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.