Skip to content

Commit 98fa8eb

Browse files
committed
fix: update openapi
Signed-off-by: Cleopatra Enjeck M <patrathewhiz@gmail.com>
1 parent 0c34758 commit 98fa8eb

File tree

4 files changed

+197
-108
lines changed

4 files changed

+197
-108
lines changed

lib/Migration/Version000800Date20240828000000.php

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -28,15 +28,15 @@ public function changeSchema(IOutput $output, Closure $schemaClosure, array $opt
2828
/** @var ISchemaWrapper $schema */
2929
$schema = $schemaClosure();
3030

31-
if ($schema->hasTable('tables_columns')) {
32-
if ($schema->hasTable('tables_row_cells_usergroup')) {
33-
$table = $schema->getTable('tables_columns');
34-
if (!$table->hasColumn('usergroup_select_teams')) {
35-
$table->addColumn('usergroup_select_teams', Types::BOOLEAN, [
36-
'notnull' => false,
37-
'default' => 0,
38-
]);
39-
}
31+
if ($schema->hasTable('tables_columns')) {
32+
if ($schema->hasTable('tables_row_cells_usergroup')) {
33+
$table = $schema->getTable('tables_columns');
34+
if (!$table->hasColumn('usergroup_select_teams')) {
35+
$table->addColumn('usergroup_select_teams', Types::BOOLEAN, [
36+
'notnull' => false,
37+
'default' => 0,
38+
]);
39+
}
4040
}
4141
return $schema;
4242
}

openapi.json

Lines changed: 113 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,7 @@
9595
"usergroupMultipleItems",
9696
"usergroupSelectUsers",
9797
"usergroupSelectGroups",
98+
"usergroupSelectTeams",
9899
"showUserStatus"
99100
],
100101
"properties": {
@@ -190,6 +191,9 @@
190191
"usergroupSelectGroups": {
191192
"type": "boolean"
192193
},
194+
"usergroupSelectTeams": {
195+
"type": "boolean"
196+
},
193197
"showUserStatus": {
194198
"type": "boolean"
195199
}
@@ -2763,6 +2767,24 @@
27632767
"basic_auth": []
27642768
}
27652769
],
2770+
"requestBody": {
2771+
"required": false,
2772+
"content": {
2773+
"application/json": {
2774+
"schema": {
2775+
"type": "object",
2776+
"properties": {
2777+
"viewId": {
2778+
"type": "integer",
2779+
"format": "int64",
2780+
"nullable": true,
2781+
"description": "View ID"
2782+
}
2783+
}
2784+
}
2785+
}
2786+
}
2787+
},
27662788
"parameters": [
27672789
{
27682790
"name": "tableId",
@@ -2773,16 +2795,6 @@
27732795
"type": "integer",
27742796
"format": "int64"
27752797
}
2776-
},
2777-
{
2778-
"name": "viewId",
2779-
"in": "query",
2780-
"description": "View ID",
2781-
"schema": {
2782-
"type": "integer",
2783-
"format": "int64",
2784-
"nullable": true
2785-
}
27862798
}
27872799
],
27882800
"responses": {
@@ -2996,6 +3008,11 @@
29963008
"nullable": true,
29973009
"description": "Can select groups, if column type is usergroup"
29983010
},
3011+
"usergroupSelectTeams": {
3012+
"type": "boolean",
3013+
"nullable": true,
3014+
"description": "Can select teams, if column type is usergroup"
3015+
},
29993016
"usergroupShowUserStatus": {
30003017
"type": "boolean",
30013018
"nullable": true,
@@ -3345,6 +3362,11 @@
33453362
"nullable": true,
33463363
"description": "Can select groups, if column type is usergroup"
33473364
},
3365+
"usergroupSelectTeams": {
3366+
"type": "boolean",
3367+
"nullable": true,
3368+
"description": "Can select teams, if column type is usergroup"
3369+
},
33483370
"usergroupShowUserStatus": {
33493371
"type": "boolean",
33503372
"nullable": true,
@@ -3559,6 +3581,11 @@
35593581
"nullable": true,
35603582
"description": "Can select groups, if column type is usergroup"
35613583
},
3584+
"usergroupSelectTeams": {
3585+
"type": "boolean",
3586+
"nullable": true,
3587+
"description": "Can select teams, if column type is usergroup"
3588+
},
35623589
"usergroupShowUserStatus": {
35633590
"type": "boolean",
35643591
"nullable": true,
@@ -3805,6 +3832,30 @@
38053832
"basic_auth": []
38063833
}
38073834
],
3835+
"requestBody": {
3836+
"required": false,
3837+
"content": {
3838+
"application/json": {
3839+
"schema": {
3840+
"type": "object",
3841+
"properties": {
3842+
"limit": {
3843+
"type": "integer",
3844+
"format": "int64",
3845+
"nullable": true,
3846+
"description": "Limit"
3847+
},
3848+
"offset": {
3849+
"type": "integer",
3850+
"format": "int64",
3851+
"nullable": true,
3852+
"description": "Offset"
3853+
}
3854+
}
3855+
}
3856+
}
3857+
}
3858+
},
38083859
"parameters": [
38093860
{
38103861
"name": "tableId",
@@ -3815,26 +3866,6 @@
38153866
"type": "integer",
38163867
"format": "int64"
38173868
}
3818-
},
3819-
{
3820-
"name": "limit",
3821-
"in": "query",
3822-
"description": "Limit",
3823-
"schema": {
3824-
"type": "integer",
3825-
"format": "int64",
3826-
"nullable": true
3827-
}
3828-
},
3829-
{
3830-
"name": "offset",
3831-
"in": "query",
3832-
"description": "Offset",
3833-
"schema": {
3834-
"type": "integer",
3835-
"format": "int64",
3836-
"nullable": true
3837-
}
38383869
}
38393870
],
38403871
"responses": {
@@ -3920,6 +3951,30 @@
39203951
"basic_auth": []
39213952
}
39223953
],
3954+
"requestBody": {
3955+
"required": false,
3956+
"content": {
3957+
"application/json": {
3958+
"schema": {
3959+
"type": "object",
3960+
"properties": {
3961+
"limit": {
3962+
"type": "integer",
3963+
"format": "int64",
3964+
"nullable": true,
3965+
"description": "Limit"
3966+
},
3967+
"offset": {
3968+
"type": "integer",
3969+
"format": "int64",
3970+
"nullable": true,
3971+
"description": "Offset"
3972+
}
3973+
}
3974+
}
3975+
}
3976+
}
3977+
},
39233978
"parameters": [
39243979
{
39253980
"name": "tableId",
@@ -3930,26 +3985,6 @@
39303985
"type": "integer",
39313986
"format": "int64"
39323987
}
3933-
},
3934-
{
3935-
"name": "limit",
3936-
"in": "query",
3937-
"description": "Limit",
3938-
"schema": {
3939-
"type": "integer",
3940-
"format": "int64",
3941-
"nullable": true
3942-
}
3943-
},
3944-
{
3945-
"name": "offset",
3946-
"in": "query",
3947-
"description": "Offset",
3948-
"schema": {
3949-
"type": "integer",
3950-
"format": "int64",
3951-
"nullable": true
3952-
}
39533988
}
39543989
],
39553990
"responses": {
@@ -4136,6 +4171,30 @@
41364171
"basic_auth": []
41374172
}
41384173
],
4174+
"requestBody": {
4175+
"required": false,
4176+
"content": {
4177+
"application/json": {
4178+
"schema": {
4179+
"type": "object",
4180+
"properties": {
4181+
"limit": {
4182+
"type": "integer",
4183+
"format": "int64",
4184+
"nullable": true,
4185+
"description": "Limit"
4186+
},
4187+
"offset": {
4188+
"type": "integer",
4189+
"format": "int64",
4190+
"nullable": true,
4191+
"description": "Offset"
4192+
}
4193+
}
4194+
}
4195+
}
4196+
}
4197+
},
41394198
"parameters": [
41404199
{
41414200
"name": "viewId",
@@ -4146,26 +4205,6 @@
41464205
"type": "integer",
41474206
"format": "int64"
41484207
}
4149-
},
4150-
{
4151-
"name": "limit",
4152-
"in": "query",
4153-
"description": "Limit",
4154-
"schema": {
4155-
"type": "integer",
4156-
"format": "int64",
4157-
"nullable": true
4158-
}
4159-
},
4160-
{
4161-
"name": "offset",
4162-
"in": "query",
4163-
"description": "Offset",
4164-
"schema": {
4165-
"type": "integer",
4166-
"format": "int64",
4167-
"nullable": true
4168-
}
41694208
}
41704209
],
41714210
"responses": {
@@ -7913,6 +7952,10 @@
79137952
"type": "boolean",
79147953
"description": "Whether you can select groups"
79157954
},
7955+
"usergroupSelectTeams": {
7956+
"type": "boolean",
7957+
"description": "Whether you can select teams"
7958+
},
79167959
"showUserStatus": {
79177960
"type": "boolean",
79187961
"description": "Whether to show the user's status"

src/shared/mixins/searchUserGroup.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,13 +60,13 @@ export default {
6060
getShareTypeString() {
6161
const strings = []
6262
if (this.selectUsers) {
63-
strings.push('user')
63+
strings.push('User')
6464
}
6565
if (this.selectGroups) {
66-
strings.push('group')
66+
strings.push('Group')
6767
}
6868
if (this?.selectTeams) {
69-
strings.push('team')
69+
strings.push('Team')
7070
}
7171
return strings.join(' or ')
7272
},

0 commit comments

Comments
 (0)