Browse Source

fix: pkName should be allawys "id", if not it doesn't match with "/components/parameters"

maybe more a workaround than a fix. Better way would be to fix components
Adnoh 5 years ago
parent
commit
4dfa3ed2ac
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      api.php

+ 1
- 1
api.php View File

@@ -8616,7 +8616,7 @@ namespace Tqdev\PhpCrudApi\OpenApi {
8616 8616
                         $parameters = ['filter', 'include', 'exclude', 'order', 'size', 'page', 'join'];
8617 8617
                     }
8618 8618
                 } else {
8619
-                    $path = sprintf('/records/%s/{%s}', $tableName, $pkName);
8619
+                    $path = sprintf('/records/%s/{%s}', $tableName, 'id'); // $pkName);
8620 8620
                     if ($operation == 'read') {
8621 8621
                         $parameters = ['pk', 'include', 'exclude', 'join'];
8622 8622
                     } else {

Loading…
Cancel
Save