fix
This commit is contained in:
parent
ecd16de53f
commit
87547d5622
@ -42,6 +42,13 @@ class GithubPrivateRepository extends Component
|
|||||||
public bool $is_static = false;
|
public bool $is_static = false;
|
||||||
public string|null $publish_directory = null;
|
public string|null $publish_directory = null;
|
||||||
|
|
||||||
|
public function mount()
|
||||||
|
{
|
||||||
|
$this->parameters = get_parameters();
|
||||||
|
$this->query = request()->query();
|
||||||
|
$this->repositories = $this->branches = collect();
|
||||||
|
$this->github_apps = GithubApp::private();
|
||||||
|
}
|
||||||
protected function loadRepositoryByPage()
|
protected function loadRepositoryByPage()
|
||||||
{
|
{
|
||||||
$response = Http::withToken($this->token)->get("{$this->github_app->api_url}/installation/repositories?per_page=100&page={$this->page}");
|
$response = Http::withToken($this->token)->get("{$this->github_app->api_url}/installation/repositories?per_page=100&page={$this->page}");
|
||||||
@ -152,11 +159,4 @@ class GithubPrivateRepository extends Component
|
|||||||
}
|
}
|
||||||
$this->emit('saved', 'Application settings updated!');
|
$this->emit('saved', 'Application settings updated!');
|
||||||
}
|
}
|
||||||
public function mount()
|
|
||||||
{
|
|
||||||
$this->parameters = get_parameters();
|
|
||||||
$this->query = request()->query();
|
|
||||||
$this->repositories = $this->branches = collect();
|
|
||||||
$this->github_apps = GithubApp::private();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
@ -41,10 +41,10 @@ class GithubApp extends BaseModel
|
|||||||
}
|
}
|
||||||
static public function public()
|
static public function public()
|
||||||
{
|
{
|
||||||
return GithubApp::where('team_id', session('currentTeam')->id)->where('is_public', true)->get();
|
return GithubApp::whereTeamId(session('currentTeam')->id)->whereisPublic(true)->whereNotNull('app_id')->get();
|
||||||
}
|
}
|
||||||
static public function private()
|
static public function private()
|
||||||
{
|
{
|
||||||
return GithubApp::where('team_id', session('currentTeam')->id)->where('is_public', false)->get();
|
return GithubApp::whereTeamId(session('currentTeam')->id)->whereisPublic(false)->whereNotNull('app_id')->get();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -9,7 +9,11 @@
|
|||||||
<x-git-icon class="text-white w-9 h-9" git="{{ $source->getMorphClass() }}" />
|
<x-git-icon class="text-white w-9 h-9" git="{{ $source->getMorphClass() }}" />
|
||||||
<div class="group-hover:text-white">
|
<div class="group-hover:text-white">
|
||||||
<div>{{ $source->name }}</div>
|
<div>{{ $source->name }}</div>
|
||||||
|
@if (is_null($source->app_id))
|
||||||
|
<span class="text-error">Not registered</span>
|
||||||
|
@endif
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</a>
|
</a>
|
||||||
@endif
|
@endif
|
||||||
@if ($source->getMorphClass() === 'App\Models\GitlabApp')
|
@if ($source->getMorphClass() === 'App\Models\GitlabApp')
|
||||||
@ -18,6 +22,9 @@
|
|||||||
<x-git-icon class="text-white w-9 h-9" git="{{ $source->getMorphClass() }}" />
|
<x-git-icon class="text-white w-9 h-9" git="{{ $source->getMorphClass() }}" />
|
||||||
<div class="group-hover:text-white">
|
<div class="group-hover:text-white">
|
||||||
<div>{{ $source->name }}</div>
|
<div>{{ $source->name }}</div>
|
||||||
|
@if (is_null($source->app_id))
|
||||||
|
<span class="text-error">Not registered</span>
|
||||||
|
@endif
|
||||||
</div>
|
</div>
|
||||||
</a>
|
</a>
|
||||||
@endif
|
@endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user