-
-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
39ffa9e
commit 16acb6a
Showing
24 changed files
with
621 additions
and
330 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace App\Locale\Models; | ||
|
||
use Illuminate\Database\Eloquent\Model; | ||
use Moox\Core\Traits\Base\BaseInModel; | ||
use Moox\Core\Traits\Simple\SingleSimpleInModel; | ||
|
||
class StaticLocale extends Model | ||
{ | ||
use BaseInModel, SingleSimpleInModel; | ||
|
||
protected $table = 'static_locales'; | ||
|
||
protected $fillable = [ | ||
'language_id', | ||
'country_id', | ||
'locale', | ||
'name', | ||
'is_official_language' | ||
]; | ||
|
||
public function language() | ||
{ | ||
return $this->belongsTo(StaticLanguage::class); | ||
} | ||
|
||
public function country() | ||
{ | ||
return $this->belongsTo(StaticCountry::class); | ||
} | ||
|
||
protected $casts = []; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace App\Locale\Plugins; | ||
|
||
use App\Locale\Resources\StaticLocaleResource; | ||
use Filament\Contracts\Plugin; | ||
use Filament\Panel; | ||
use Filament\Support\Concerns\EvaluatesClosures; | ||
|
||
class StaticLocalePlugin implements Plugin | ||
{ | ||
use EvaluatesClosures; | ||
|
||
public function getId(): string | ||
{ | ||
return 'staticlocale'; | ||
} | ||
|
||
public function register(Panel $panel): void | ||
{ | ||
$panel->resources([ | ||
StaticLocaleResource::class, | ||
]); | ||
} | ||
|
||
public function boot(Panel $panel): void | ||
{ | ||
// | ||
} | ||
|
||
public static function make(): static | ||
{ | ||
return app(static::class); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.