organization = $organization; if ($domain?->exists) { $this->domain = $domain; $this->name = $domain->name; $this->registrar = $domain->registrar ?? ''; $this->nameservers = $domain->nameservers ?? ''; $this->expires_at = $domain->expires_at?->format('Y-m-d'); $this->auto_renew = (bool) $domain->auto_renew; $this->notes = $domain->notes ?? ''; } } public function save(): void { $validated = $this->validate([ 'name' => [ 'required', 'string', 'max:255', Rule::unique('domains', 'name')->ignore($this->domain?->id), ], 'registrar' => 'nullable|string|max:255', 'nameservers' => 'nullable|string', 'expires_at' => 'nullable|date', 'auto_renew' => 'boolean', 'notes' => 'nullable|string', ]); if ($this->domain?->exists) { $this->domain->update($validated); session()->flash('status', "Domaine \"{$this->domain->name}\" mis à jour."); } else { $this->organization->domains()->create($validated); session()->flash('status', "Domaine \"{$this->name}\" créé."); } $this->redirectRoute('organizations.domains.index', $this->organization, navigate: true); } }; ?>
{{ $organization->name }}
| Nom | Émetteur | Expiration |
|---|---|---|
| {{ $cert->name }} | {{ $cert->issuer ?? '—' }} | {{ $cert->expires_at?->format('Y-m-d') ?? '—' }} |