Skip to content

Commit a7de71e

Browse files
authored
Fix name and displayName issues (#19538)
* fix name displayName * fix enum issue * Swagger ModelValidation fixes * fixes * json fix * fix enum * parsing * json fix * dummy commit * adding type * json fix * nextlink fix * remove @ from mgmt * nextlink revert
1 parent 0077b4a commit a7de71e

File tree

7 files changed

+108
-5
lines changed

7 files changed

+108
-5
lines changed

specification/managementgroups/resource-manager/Microsoft.Management/stable/2020-10-01/examples/DeleteManagementGroup.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@
1111
"type": "Microsoft.Management/managementGroups",
1212
"name": "GroupToDelete",
1313
"status": "NotStarted"
14+
},
15+
"headers": {
16+
"azure-asyncoperation": "https://management.azure.com/providers/Microsoft.Management/operationResults/delete/asyncOperation/status/managementGroups/GroupToDelete?api-version=2020-10-01"
1417
}
1518
},
1619
"204": {}

specification/managementgroups/resource-manager/Microsoft.Management/stable/2020-10-01/examples/GetAllSubscriptionsFromManagementGroup.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@
1414
"properties": {
1515
"displayName": "S5",
1616
"parent": {
17-
"id": "/providers/Microsoft.Management/managementGroups/Group"
17+
"id": "/providers/Microsoft.Management/managementGroups/Group",
18+
"name": "name",
19+
"displayName": "displayName"
1820
},
1921
"state": "Active",
2022
"tenant": "e751ac82-623b-4913-8d74-22637c832373"
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{
2+
"parameters": {
3+
"api-version": "2020-10-01"
4+
},
5+
"responses": {
6+
"200": {
7+
"body": {
8+
"value": [
9+
{
10+
"name": "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
11+
"display": {
12+
"provider": "aaaaaaaaaaaaaaaaaaaaa",
13+
"resource": "aaaaaaaaaaaaa",
14+
"operation": "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
15+
"description": "aaaaaaaaaaaaaaaaaaaaaa"
16+
}
17+
}
18+
],
19+
"nextLink": "aaaaaaaaaaaaaaaaaaa"
20+
}
21+
}
22+
}
23+
}

specification/managementgroups/resource-manager/Microsoft.Management/stable/2020-10-01/management.json

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -718,6 +718,11 @@
718718
},
719719
"x-ms-pageable": {
720720
"nextLinkName": "nextLink"
721+
},
722+
"x-ms-examples": {
723+
"List Operations": {
724+
"$ref": "./examples/ListOperations.json"
725+
}
721726
}
722727
}
723728
},
@@ -1168,7 +1173,7 @@
11681173
},
11691174
"parent": {
11701175
"title": "Parent",
1171-
"$ref": "#/definitions/DescendantParentGroupInfo",
1176+
"$ref": "#/definitions/ParentGroupBagInfo",
11721177
"x-nullable": true
11731178
},
11741179
"state": {
@@ -1574,6 +1579,24 @@
15741579
}
15751580
}
15761581
},
1582+
"ParentGroupBagInfo": {
1583+
"description": "The ID, name and displayName of the parent management group.",
1584+
"type": "object",
1585+
"properties": {
1586+
"id": {
1587+
"type": "string",
1588+
"description": "The fully qualified ID for the parent management group. For example, /providers/Microsoft.Management/managementGroups/0000000-0000-0000-0000-000000000000"
1589+
},
1590+
"name": {
1591+
"type": "string",
1592+
"description": "The name of the parent management group. For example, 00000000-0000-0000-0000-000000000000"
1593+
},
1594+
"displayName": {
1595+
"type": "string",
1596+
"description": "The friendly name of the parent management group."
1597+
}
1598+
}
1599+
},
15771600
"EntityListResult": {
15781601
"description": "Describes the result of the request to view entities.",
15791602
"properties": {

specification/managementgroups/resource-manager/Microsoft.Management/stable/2021-04-01/examples/AddManagementGroupSubscription.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@
1414
"properties": {
1515
"displayName": "Group",
1616
"parent": {
17-
"id": "/providers/Microsoft.Management/managementGroups/Group"
17+
"id": "/providers/Microsoft.Management/managementGroups/Group",
18+
"name": "name",
19+
"displayName": "displayName"
1820
},
1921
"state": "Active",
2022
"tenant": "e751ac82-623b-4913-8d74-22637c832373"

specification/managementgroups/resource-manager/Microsoft.Management/stable/2021-04-01/examples/GetAllSubscriptionsFromManagementGroup.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@
1414
"properties": {
1515
"displayName": "S5",
1616
"parent": {
17-
"id": "/providers/Microsoft.Management/managementGroups/Group"
17+
"id": "/providers/Microsoft.Management/managementGroups/Group",
18+
"name": "name",
19+
"displayName": "displayName"
1820
},
1921
"state": "Active",
2022
"tenant": "e751ac82-623b-4913-8d74-22637c832373"

specification/managementgroups/resource-manager/Microsoft.Management/stable/2021-04-01/management.json

Lines changed: 49 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1176,7 +1176,7 @@
11761176
},
11771177
"parent": {
11781178
"title": "Parent",
1179-
"$ref": "#/definitions/DescendantParentGroupInfo",
1179+
"$ref": "#/definitions/ParentGroupBagInfo",
11801180
"x-nullable": true
11811181
},
11821182
"state": {
@@ -1356,6 +1356,18 @@
13561356
"Microsoft.Management/managementGroups",
13571357
"/subscriptions"
13581358
],
1359+
"x-ms-enum": {
1360+
"name": "ManagementGroupChildType",
1361+
"modelAsString": false,
1362+
"values": [
1363+
{
1364+
"value": "Microsoft.Management/managementGroups"
1365+
},
1366+
{
1367+
"value": "/subscriptions"
1368+
}
1369+
]
1370+
},
13591371
"description": "The type of child resource."
13601372
},
13611373
"OperationResults": {
@@ -1596,6 +1608,24 @@
15961608
}
15971609
}
15981610
},
1611+
"ParentGroupBagInfo": {
1612+
"description": "The ID, name and displayName of the parent management group.",
1613+
"type": "object",
1614+
"properties": {
1615+
"id": {
1616+
"type": "string",
1617+
"description": "The fully qualified ID for the parent management group. For example, /providers/Microsoft.Management/managementGroups/0000000-0000-0000-0000-000000000000"
1618+
},
1619+
"name": {
1620+
"type": "string",
1621+
"description": "The name of the parent management group. For example, 00000000-0000-0000-0000-000000000000"
1622+
},
1623+
"displayName": {
1624+
"type": "string",
1625+
"description": "The friendly name of the parent management group."
1626+
}
1627+
}
1628+
},
15991629
"EntityListResult": {
16001630
"description": "Describes the result of the request to view entities.",
16011631
"properties": {
@@ -1926,6 +1956,24 @@
19261956
"edit",
19271957
"delete"
19281958
],
1959+
"x-ms-enum": {
1960+
"name": "Permissions",
1961+
"modelAsString": false,
1962+
"values": [
1963+
{
1964+
"value": "noaccess"
1965+
},
1966+
{
1967+
"value": "view"
1968+
},
1969+
{
1970+
"value": "edit"
1971+
},
1972+
{
1973+
"value": "delete"
1974+
}
1975+
]
1976+
},
19291977
"description": "The users specific permissions to this item."
19301978
},
19311979
"CheckNameAvailabilityRequest": {

0 commit comments

Comments
 (0)