Skip to content

Commit ae0bc07

Browse files
committed
modified json for category and subcategory struct
Signed-off-by: pransh62390 <63577123+pransh62390@users.noreply.github.com>
1 parent dbae28e commit ae0bc07

2 files changed

Lines changed: 37 additions & 1 deletion

File tree

models/v1beta1/category/category.go

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

schemas/constructs/v1beta1/model.json

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,13 @@
8484
"json": "name"
8585
}
8686
},
87+
"subcategory_ids": {
88+
"type": "array",
89+
"x-oapi-codegen-extra-tags": {
90+
"yaml": "subcategory_ids",
91+
"json": "subcategory_ids"
92+
}
93+
},
8794
"metadata": {
8895
"type": "object",
8996
"x-oapi-codegen-extra-tags": {
@@ -103,6 +110,35 @@
103110
"description": "Sub-category of the model.",
104111
"minLength": 1,
105112
"maxLength": 100,
113+
"properties": {
114+
"id": {
115+
"$ref": "../core.json#/definitions/uuid"
116+
},
117+
"name": {
118+
"type": "string",
119+
"minLength": 1,
120+
"maxLength": 100,
121+
"x-oapi-codegen-extra-tags": {
122+
"yaml": "name",
123+
"json": "name"
124+
}
125+
},
126+
"category_id": {
127+
"x-go-name": "CategoryID",
128+
"$ref": "../core.json#/definitions/uuid",
129+
"x-oapi-codegen-extra-tags": {
130+
"yaml": "category_id",
131+
"json": "category_id"
132+
}
133+
},
134+
"metadata": {
135+
"type": "object",
136+
"x-oapi-codegen-extra-tags": {
137+
"yaml": "metadata",
138+
"json": "metadata"
139+
}
140+
}
141+
},
106142
"x-oapi-codegen-extra-tags": {
107143
"yaml": "subCategory",
108144
"json": "subCategory"

0 commit comments

Comments
 (0)