fixed missing features
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use App\Actions\Git\Data\GitRepository;
|
||||
use App\Actions\Git\GitProviderKey;
|
||||
use Database\Factories\RepositoryConnectionFactory;
|
||||
use Illuminate\Database\Eloquent\Attributes\Fillable;
|
||||
@@ -38,4 +39,18 @@ class RepositoryConnection extends Model
|
||||
{
|
||||
return $this->belongsTo(Project::class);
|
||||
}
|
||||
|
||||
public function toGitRepository(): GitRepository
|
||||
{
|
||||
return new GitRepository(
|
||||
baseUrl: $this->base_url,
|
||||
providerRepositoryId: $this->provider_repository_id,
|
||||
owner: $this->owner_name,
|
||||
name: $this->repository_name,
|
||||
fullName: $this->repository_full_name,
|
||||
htmlUrl: $this->repository_url,
|
||||
defaultBranch: null,
|
||||
isPrivate: false,
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use App\Enums\TicketWorklogEntryType;
|
||||
use Database\Factories\TicketWorklogEntryFactory;
|
||||
use Illuminate\Database\Eloquent\Attributes\Fillable;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
@@ -27,6 +28,7 @@ class TicketWorklogEntry extends Model
|
||||
{
|
||||
return [
|
||||
'changes' => 'array',
|
||||
'entry_type' => TicketWorklogEntryType::class,
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user