Skip to content

Commit

Permalink
Add description to plans
Browse files Browse the repository at this point in the history
  • Loading branch information
Mythicaeda committed Sep 19, 2023
1 parent 3aa7da3 commit a0d2e30
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -111,13 +111,13 @@ insert_permissions:
update_permissions:
- role: aerie_admin
permission:
columns: [name, owner, duration, model_id, parent_id, start_time]
columns: [name, owner, duration, model_id, parent_id, start_time, description]
filter: {}
set:
updated_by: "x-hasura-user-id"
- role: user
permission:
columns: [name, owner]
columns: [name, owner, description]
filter: {"owner":{"_eq":"X-Hasura-User-Id"}}
set:
updated_by: "x-hasura-user-id"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
alter table plan drop column description;

call migrations.mark_migration_rolled_back('27');
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
alter table plan
add column description text;
comment on column plan.description is e''
'A human-readable description for this plan and its contents.';

call migrations.mark_migration_applied('27');
1 change: 1 addition & 0 deletions merlin-server/sql/merlin/applied_migrations.sql
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,4 @@ call migrations.mark_migration_applied('23');
call migrations.mark_migration_applied('24');
call migrations.mark_migration_applied('25');
call migrations.mark_migration_applied('26');
call migrations.mark_migration_applied('27');
3 changes: 3 additions & 0 deletions merlin-server/sql/merlin/tables/plan.sql
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ create table plan (

owner text,
updated_by text,
description text,

constraint plan_synthetic_key
primary key (id),
Expand Down Expand Up @@ -72,6 +73,8 @@ comment on column plan.owner is e''
'The user who owns the plan.';
comment on column plan.updated_by is e''
'The user who last updated the plan.';
comment on column plan.description is e''
'A human-readable description for this plan and its contents.';


create function increment_revision_on_update_plan()
Expand Down

0 comments on commit a0d2e30

Please sign in to comment.