Skip to content

Commit 8f246f6

Browse files
authored
Merge pull request #13 from kaz29/fix/path
fix path error
2 parents 1b5198a + 038f37e commit 8f246f6

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

templates/bake/element/Controller/edit.twig

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@
2626
{% set IdProperty = OpenApiDocBlock.schemaProperty(propertySchema, 'id') %}
2727
#[OA\Put(
2828
{% if prefix %}
29-
path: '/{{ OpenApiText.prefixToPath(prefix) }}/{{ OpenApiText.underscore(pluralName) }}/edit.json',
29+
path: '/{{ OpenApiText.prefixToPath(prefix) }}/{{ OpenApiText.underscore(pluralName) }}/{id}.json',
3030
{% else %}
31-
path: '/{{ pluralName }}/edit.json',
31+
path: '/{{ pluralName }}/{id}.json',
3232
{% endif %}
3333
summary: 'Edit {{ singularName }}',
3434
description: 'Edit {{ singularName }}',

templates/bake/element/Controller/view.twig

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
{% if prefix %}
3434
path: "/{{ OpenApiText.prefixToPath(prefix) }}/{{ OpenApiText.underscore(pluralName) }}/{id}.json",
3535
{% else %}
36-
path: "/{{ pluralName }}.json",
36+
path: "/{{ pluralName }}/{id}.json",
3737
{% endif %}
3838
summary: "Get {{ singularHumanName }}",
3939
description: "Get {{ singularHumanName }}",

0 commit comments

Comments
 (0)