Skip to content

Commit 2b429ee

Browse files
ackintoshwing328
authored andcommitted
[PHP] [Laravel] Fix syntax errors in models (#721)
* Fix syntax errors in Models * Update samples ./bin/php-laravel-petstore-server.sh
1 parent a258cf3 commit 2b429ee

38 files changed

Lines changed: 51 additions & 51 deletions

modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PhpLaravelServerCodegen.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ public PhpLaravelServerCodegen() {
9696
/*
9797
* Model Package. Optional, if needed, this can be used in templates
9898
*/
99-
modelPackage = "app.Models";
99+
modelPackage = "app\\Models";
100100

101101
// template files want to be ignored
102102
apiTestTemplateFiles.clear();
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
3.1.2-SNAPSHOT
1+
3.2.0-SNAPSHOT

samples/server/petstore/php-laravel/lib/app/Http/Controllers/AnotherFakeController.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,14 @@ public function __construct()
3131
}
3232

3333
/**
34-
* Operation testSpecialTags
34+
* Operation 123testSpecialTags
3535
*
3636
* To test special tags.
3737
*
3838
*
3939
* @return Http response
4040
*/
41-
public function testSpecialTags()
41+
public function 123testSpecialTags()
4242
{
4343
$input = Request::all();
4444

@@ -47,11 +47,11 @@ public function testSpecialTags()
4747

4848
//not path params validation
4949
if (!isset($input['client'])) {
50-
throw new \InvalidArgumentException('Missing the required parameter $client when calling testSpecialTags');
50+
throw new \InvalidArgumentException('Missing the required parameter $client when calling 123testSpecialTags');
5151
}
5252
$client = $input['client'];
5353

5454

55-
return response('How about implementing testSpecialTags as a patch method ?');
55+
return response('How about implementing 123testSpecialTags as a patch method ?');
5656
}
5757
}

samples/server/petstore/php-laravel/lib/app/Models/AdditionalPropertiesClass.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/**
33
* AdditionalPropertiesClass
44
*/
5-
namespace app.Models;
5+
namespace app\Models;
66

77
/**
88
* AdditionalPropertiesClass

samples/server/petstore/php-laravel/lib/app/Models/Animal.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/**
33
* Animal
44
*/
5-
namespace app.Models;
5+
namespace app\Models;
66

77
/**
88
* Animal

samples/server/petstore/php-laravel/lib/app/Models/AnimalFarm.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/**
33
* AnimalFarm
44
*/
5-
namespace app.Models;
5+
namespace app\Models;
66

77
/**
88
* AnimalFarm

samples/server/petstore/php-laravel/lib/app/Models/ApiResponse.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/**
33
* ApiResponse
44
*/
5-
namespace app.Models;
5+
namespace app\Models;
66

77
/**
88
* ApiResponse

samples/server/petstore/php-laravel/lib/app/Models/ArrayOfArrayOfNumberOnly.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/**
33
* ArrayOfArrayOfNumberOnly
44
*/
5-
namespace app.Models;
5+
namespace app\Models;
66

77
/**
88
* ArrayOfArrayOfNumberOnly

samples/server/petstore/php-laravel/lib/app/Models/ArrayOfNumberOnly.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/**
33
* ArrayOfNumberOnly
44
*/
5-
namespace app.Models;
5+
namespace app\Models;
66

77
/**
88
* ArrayOfNumberOnly

samples/server/petstore/php-laravel/lib/app/Models/ArrayTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/**
33
* ArrayTest
44
*/
5-
namespace app.Models;
5+
namespace app\Models;
66

77
/**
88
* ArrayTest
@@ -15,7 +15,7 @@ class ArrayTest {
1515
/** @var int[][] $array_array_of_integer */
1616
private $array_array_of_integer;
1717

18-
/** @var \app.Models\ReadOnlyFirst[][] $array_array_of_model */
18+
/** @var \app\Models\ReadOnlyFirst[][] $array_array_of_model */
1919
private $array_array_of_model;
2020

2121
}

0 commit comments

Comments
 (0)