Files
ladill-care/resources/views/care/settings/edit.blade.php
T
isaaccladandCursor 6c8a0e7e9f
Deploy Ladill Care / deploy (push) Successful in 54s
Brand patient emails with organization logo.
Wrap Bird patient mail in a customer-branded layout and show the logo preview in settings.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-12 20:07:34 +00:00

72 lines
4.5 KiB
PHP

<x-app-layout title="Settings">
<x-settings.page title="Facility settings">
<form method="POST" action="{{ route('care.settings.update') }}" enctype="multipart/form-data" class="space-y-6">
@csrf @method('PUT')
<x-settings.card title="Organization" description="Name, facility type, timezone, and branding for your facility.">
<div class="space-y-5">
<div>
<label class="block text-sm font-medium text-slate-700">Organization name</label>
<input type="text" name="name" value="{{ old('name', $organization->name) }}" @disabled(! $canManage) required class="mt-1 w-full rounded-lg border-slate-300 text-sm">
</div>
<div>
<label class="block text-sm font-medium text-slate-700">Facility type</label>
<select name="facility_type" @disabled(! $canManage) class="mt-1 w-full rounded-lg border-slate-300 text-sm">
@foreach ($facilityTypes as $value => $label)
<option value="{{ $value }}" @selected(old('facility_type', data_get($organization->settings, 'facility_type', 'clinic')) === $value)>{{ $label }}</option>
@endforeach
</select>
</div>
<div>
<label class="block text-sm font-medium text-slate-700">Timezone</label>
<select name="timezone" @disabled(! $canManage) class="mt-1 w-full rounded-lg border-slate-300 text-sm">
@foreach (timezone_identifiers_list() as $tz)
<option value="{{ $tz }}" @selected(old('timezone', $organization->timezone) === $tz)>{{ $tz }}</option>
@endforeach
</select>
</div>
@if ($canManage)
<div>
<label class="block text-sm font-medium text-slate-700">Company logo</label>
<p class="mt-1 text-xs text-slate-500">PNG, JPG, WebP, or SVG up to 2&nbsp;MB. Shown in patient emails.</p>
@if (\App\Support\OrganizationBranding::hasCustomLogo($organization))
<img src="{{ \App\Support\OrganizationBranding::logoUrl($organization) }}"
alt="{{ $organization->name }}"
class="mt-3 h-12 w-auto max-w-xs rounded-lg border border-slate-200 bg-white object-contain p-2">
<label class="mt-3 flex items-center gap-2 text-sm text-slate-600">
<input type="checkbox" name="remove_logo" value="1" @checked(old('remove_logo'))>
Remove custom logo
</label>
@endif
<input type="file" name="logo" accept="image/png,image/jpeg,image/webp,image/svg+xml"
class="mt-3 block w-full text-sm text-slate-600 file:mr-3 file:rounded-lg file:border-0 file:bg-teal-50 file:px-3 file:py-2 file:text-sm file:font-medium file:text-teal-700">
</div>
@endif
</div>
</x-settings.card>
@if ($canManage)
<x-settings.card title="Messaging" description="Configure SMS and email credentials for outbound messages.">
<a href="{{ route('care.integrations') }}" class="text-sm font-medium text-teal-700 underline">Open messaging integrations </a>
</x-settings.card>
<x-settings.card title="Integrations" description="Manage service queues and counters in Care. You must also enable Care integration in Ladill Queue settings.">
<label class="flex items-center gap-2 text-sm">
<input type="checkbox" name="queue_integration_enabled" value="1" @checked(data_get($organization->settings, 'queue_integration_enabled'))>
Enable Ladill Queue integration
</label>
</x-settings.card>
<div class="flex justify-end">
<button type="submit" class="btn-primary">Save settings</button>
</div>
@endif
</form>
<p class="text-sm text-slate-500">{{ $branchCount }} branch(es) configured.</p>
</x-settings.page>
</x-app-layout>