coolify/resources/views/livewire/project/new/github-private-repository.blade.php

46 lines
1.9 KiB
PHP
Raw Normal View History

2023-05-08 11:51:03 +02:00
<div>
@if ($github_apps->count() > 0)
<h1>Choose a GitHub App</h1>
@foreach ($github_apps as $ghapp)
2023-05-25 14:05:44 +02:00
<x-forms.button wire:key="{{ $ghapp->id }}" wire:click="loadRepositories({{ $ghapp->id }})">
2023-05-09 11:33:50 +02:00
{{ $ghapp->name }}
2023-05-25 14:05:44 +02:00
</x-forms.button>
2023-05-08 11:51:03 +02:00
@endforeach
<div>
@if ($repositories->count() > 0)
<h3>Choose a Repository</h3>
<select wire:model.defer="selected_repository_id">
@foreach ($repositories as $repo)
@if ($loop->first)
<option selected value="{{ data_get($repo, 'id') }}">{{ data_get($repo, 'name') }}</option>
@else
<option value="{{ data_get($repo, 'id') }}">{{ data_get($repo, 'name') }}</option>
@endif
@endforeach
</select>
2023-05-25 14:05:44 +02:00
<x-forms.button wire:click="loadBranches">Select Repository</x-forms.button>
2023-05-08 11:51:03 +02:00
@endif
</div>
<div>
@if ($branches->count() > 0)
<h3>Choose a Branch</h3>
<select wire:model.defer="selected_branch_name">
<option disabled>Choose a branch</option>
@foreach ($branches as $branch)
@if ($loop->first)
<option selected value="{{ data_get($branch, 'name') }}">{{ data_get($branch, 'name') }}
</option>
@else
<option value="{{ data_get($branch, 'name') }}">{{ data_get($branch, 'name') }}</option>
@endif
@endforeach
</select>
2023-05-25 14:05:44 +02:00
<x-forms.button wire:click="submit">Save</x-forms.button>
2023-05-08 11:51:03 +02:00
@endif
</div>
@else
Add new github app
@endif
</div>