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
f225841
commit 8f203a5
Showing
4 changed files
with
67 additions
and
64 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,44 @@ | ||
<?php | ||
|
||
namespace GeneaLabs\NovaMultiTenantManager\Nova; | ||
|
||
use Hyn\Tenancy\Models\Hostname; | ||
use Illuminate\Http\Request; | ||
use Laravel\Nova\Fields\Boolean; | ||
use Laravel\Nova\Fields\DateTime; | ||
use Laravel\Nova\Fields\ID; | ||
use Laravel\Nova\Fields\Text; | ||
use Laravel\Nova\Resource as NovaResource; | ||
|
||
class Alias extends NovaResource | ||
{ | ||
public static $displayInNavigation = false; | ||
public static $model = Hostname::class; | ||
public static $title = 'fqdn'; | ||
public static $search = [ | ||
'id', | ||
'fqdn', | ||
]; | ||
|
||
public function authorizedToDelete(Request $request) | ||
{ | ||
return false; | ||
} | ||
|
||
public function fields(Request $request) | ||
{ | ||
return [ | ||
ID::make() | ||
->sortable(), | ||
Text::make("Domain", "fqdn"), | ||
Text::make("Redirect To"), | ||
Boolean::make("Force HTTPS", "force_https"), | ||
DateTime::make("Under Maintenance Since"), | ||
]; | ||
} | ||
|
||
public static function label() | ||
{ | ||
return "Alias"; | ||
} | ||
} |
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