Files
ladill-meet/app/Support/helpers.php
T
isaaccladandCursor 965fb992e9
Deploy Ladill Meet / deploy (push) Failing after 7s
Initial Ladill Meet release.
Phases 0–18: core meetings, webinar, breakouts, team chat, live streaming, town hall, billing, and Ladill Mail calendar wiring.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-30 23:35:29 +00:00

56 lines
1.8 KiB
PHP

<?php
use Illuminate\Support\Facades\Config;
if (! function_exists('ladill_platform_url')) {
/** Absolute URL on the platform root (ladill.com). */
function ladill_platform_url(string $path = '/'): string
{
return 'https://'.Config::get('app.platform_domain', 'ladill.com').'/'.ltrim($path, '/');
}
}
if (! function_exists('ladill_account_url')) {
/** Absolute URL on the unified account portal (account.ladill.com). */
function ladill_account_url(string $path = '/'): string
{
return 'https://'.Config::get('app.account_domain', 'account.ladill.com').'/'.ltrim($path, '/');
}
}
if (! function_exists('ladill_home_url')) {
/** Absolute URL on the signed-in product hub (home.ladill.com). */
function ladill_home_url(string $path = '/'): string
{
$platform = (string) Config::get('app.platform_domain', 'ladill.com');
return 'https://home.'.$platform.'/'.ltrim($path, '/');
}
}
if (! function_exists('ladill_auth_url')) {
/** Absolute URL on the identity provider (auth.ladill.com). */
function ladill_auth_url(string $path = '/'): string
{
return 'https://'.Config::get('app.auth_domain', 'auth.ladill.com').'/'.ltrim($path, '/');
}
}
if (! function_exists('care_money')) {
/** Format integer minor units as a human currency string (e.g. 12500 → GHS 125.00). */
function care_money(?int $minor, ?string $currency = null): string
{
$currency = $currency ?: config('care.billing.currency', 'GHS');
return $currency.' '.number_format(((int) $minor) / 100, 2);
}
}
if (! function_exists('crm_money')) {
/** @deprecated Use care_money() */
function crm_money(?int $minor, ?string $currency = null): string
{
return care_money($minor, $currency);
}
}