diff --git a/composer.json b/composer.json index 7c94e24..a027261 100644 --- a/composer.json +++ b/composer.json @@ -16,10 +16,9 @@ "laravel/framework": ">=6.0.0 <9" }, "require-dev": { - "roave/security-advisories": "dev-master", - "phpunit/phpunit": "^8.0.0", - "orchestra/testbench": "^4.0.0", - "orchestra/database": "^4.0.0" + "laravel/legacy-factories": "^1.1", + "orchestra/testbench": "^6.0.0", + "phpunit/phpunit": "^8.0.0" }, "autoload": { "psr-4": { @@ -43,5 +42,22 @@ }, "config": { "sort-packages": true + }, + "application": "", + "boundedContext": "", + "boundedContextName": "", + "core": { + "language": "csharp" + }, + "interaction": [], + "resources": { + "readModels": { + "production": "", + "development": "" + }, + "eventStore": { + "production": "", + "development": "" + } } } diff --git a/src/Models/Feature.php b/src/Models/Feature.php index 4aaddd3..519629e 100644 --- a/src/Models/Feature.php +++ b/src/Models/Feature.php @@ -34,7 +34,7 @@ class Feature extends Model protected $table = 'plan_features'; protected $guarded = []; protected $casts = [ - 'limit' => 'Integer' + 'limit' => 'int' ]; public function plan(): BelongsTo @@ -44,31 +44,26 @@ public function plan(): BelongsTo public function scopeCode($query, string $code): Builder { - /** @noinspection PhpUndefinedMethodInspection */ return $query->where('code', $code); } public function scopeLimited($query): Builder { - /** @noinspection PhpUndefinedMethodInspection */ return $query->where('type', self::TYPE_LIMIT)->where('limit', '>', 0); } public function scopeUnlimited($query): Builder { - /** @noinspection PhpUndefinedMethodInspection */ return $query->where('type', self::TYPE_LIMIT)->where('limit', '=', 0); } public function scopeFeature($query): Builder { - /** @noinspection PhpUndefinedMethodInspection */ return $query->where('type', self::TYPE_FEATURE); } public function scopeLimitType($query): Builder { - /** @noinspection PhpUndefinedMethodInspection */ return $query->where('type', self::TYPE_LIMIT); }