mirror of
https://github.com/coollabsio/coolify.git
synced 2026-11-06 13:10:37 -04:00
feat: add import restore options, OAuth confirmation, and fixes
- database import: add keep_owners (restore PostgreSQL owners and privileges) and sqlite_database (pick the target SQLite file) to the API, OpenAPI spec, and import form - oauth: require password confirmation and support team selection on OAuth login - remote process: send team broadcast events to the team of the server that ran the process instead of the causer's user id - servers API: handle the legacy build server setting - compose: support parent bind paths and volume driver options - dns: improve record hints and provider management - notifications: fix throttling and missing backup notifications - ui: rework the confirmation modal - add feature and unit tests for the new behavior
This commit is contained in:
@@ -82,6 +82,23 @@ class OauthSetting extends Model
|
||||
return __("auth.login.{$this->provider}");
|
||||
}
|
||||
|
||||
/**
|
||||
* Human-readable provider name, e.g. for "Confirm with Google".
|
||||
*/
|
||||
public function providerName(): string
|
||||
{
|
||||
if ($this->isOidc()) {
|
||||
return filled($this->custom_label) ? $this->custom_label : 'SSO';
|
||||
}
|
||||
|
||||
return match ($this->provider) {
|
||||
'azure' => 'Microsoft',
|
||||
'github' => 'GitHub',
|
||||
'gitlab' => 'GitLab',
|
||||
default => str($this->provider)->headline()->value(),
|
||||
};
|
||||
}
|
||||
|
||||
public function isOidc(): bool
|
||||
{
|
||||
return $this->provider === 'oidc';
|
||||
|
||||
Reference in New Issue
Block a user