0
Fork 0
mirror of https://github.com/logto-io/logto.git synced 2024-12-16 20:26:19 -05:00
logto/packages/schemas/tables/application_user_consent_resource_scopes.sql
simeng-li 875e948186
feat(schemas): add application permissions relation tables (#5097)
* feat(schemas): add application permissions relation tables

add appliaction permissions relation tables

* refactor(schemas): redesign the application user scope relations table

redesign the application user scope relations table

* refactor(schemas): rename application user consent scopes table name

rename application user consent scopes table name

* fix(schemas): fix dirty char

fix dirty char

* refactor(schemas): rename resource scope column name

rename resource scope column name

* fix(schemas): fix the wrong column name

fix the wrong column name

* refactor(schemas): update the userscope column length

update the userscope column length
2023-12-15 10:18:44 +08:00

14 lines
634 B
SQL

/* init_order = 3 */
/** The resource scopes (permissions) assigned to an application's consent request. */
create table application_user_consent_resource_scopes (
tenant_id varchar(21) not null
references tenants (id) on update cascade on delete cascade,
/** The globally unique identifier of the application. */
application_id varchar(21) not null
references applications (id) on update cascade on delete cascade,
/** The globally unique identifier of the resource scope. */
scope_id varchar(21) not null
references scopes (id) on update cascade on delete cascade,
primary key (application_id, scope_id)
);