Update: 2026-05-04 00:13:56

This commit is contained in:
Hamza-Ayed
2026-05-04 00:13:56 +03:00
parent 8357add763
commit 671db50f16
5 changed files with 42 additions and 2 deletions

View File

@@ -40,11 +40,14 @@ try {
);
// 1. Create Tenant
$encryptedTenantName = \App\Core\Encryption::encrypt($data['name']);
$encryptedTenantEmail = \App\Core\Encryption::encrypt($data['email']);
$stmt = $db->prepare("INSERT INTO tenants (id, name, email, phone, status, created_at) VALUES (?, ?, ?, ?, 'active', NOW())");
$stmt->execute([
$tenantId,
$data['name'],
$data['email'],
$encryptedTenantName,
$encryptedTenantEmail,
$data['phone'] ?? null
]);