avatar
$image) :?> <?=$image?> $image) :?>
<?=$image?>
query($query); while ($row = $result->fetchArray(SQLITE3_ASSOC)) { $currencyId = $row['id']; $currencies[$currencyId] = $row; } ?>
query($sql); if ($result) { $household = array(); while ($row = $result->fetchArray(SQLITE3_ASSOC)) { $household[] = $row; } } ?>

query($sql); $rowCount = 0; while ($row = $result->fetchArray(SQLITE3_ASSOC)) { $notifications = $row; $rowCount++; } if ($rowCount == 0) { $notifications['days'] = 1; } // Email notifications $sql = "SELECT * FROM email_notifications LIMIT 1"; $result = $db->query($sql); $rowCount = 0; while ($row = $result->fetchArray(SQLITE3_ASSOC)) { $notificationsEmail['enabled'] = $row['enabled']; $notificationsEmail['smtp_address'] = $row['smtp_address']; $notificationsEmail['smtp_port'] = $row['smtp_port']; $notificationsEmail['encryption'] = $row['encryption']; $notificationsEmail['smtp_username'] = $row['smtp_username']; $notificationsEmail['smtp_password'] = $row['smtp_password']; $notificationsEmail['from_email'] = $row['from_email']; $rowCount++; } if ($rowCount == 0) { $notificationsEmail['enabled'] = 0; $notificationsEmail['smtp_address'] = ""; $notificationsEmail['smtp_port'] = 587; $notificationsEmail['encryption'] = "tls"; $notificationsEmail['smtp_username'] = ""; $notificationsEmail['smtp_password'] = ""; $notificationsEmail['from_email'] = ""; } // Telegram notifications $sql = "SELECT * FROM telegram_notifications LIMIT 1"; $result = $db->query($sql); $rowCount = 0; while ($row = $result->fetchArray(SQLITE3_ASSOC)) { $notificationsTelegram['enabled'] = $row['enabled']; $notificationsTelegram['bot_token'] = $row['bot_token']; $notificationsTelegram['chat_id'] = $row['chat_id']; $rowCount++; } if ($rowCount == 0) { $notificationsTelegram['enabled'] = 0; $notificationsTelegram['bot_token'] = ""; $notificationsTelegram['chat_id'] = ""; } // Webhook notifications $sql = "SELECT * FROM webhook_notifications LIMIT 1"; $result = $db->query($sql); $rowCount = 0; while ($row = $result->fetchArray(SQLITE3_ASSOC)) { $notificationsWebhook['enabled'] = $row['enabled']; $notificationsWebhook['url'] = $row['url']; $notificationsWebhook['request_method'] = $row['request_method']; $notificationsWebhook['headers'] = $row['headers']; $notificationsWebhook['payload'] = $row['payload']; $notificationsWebhook['iterator'] = $row['iterator']; $rowCount++; } if ($rowCount == 0) { $notificationsWebhook['enabled'] = 0; $notificationsWebhook['url'] = ""; $notificationsWebhook['request_method'] = "POST"; $notificationsWebhook['headers'] = ""; $notificationsWebhook['iterator'] = ""; $notificationsWebhook['payload'] = ' { "days_until": "{{days_until}}", "{{subscriptions}}": [ { "name": "{{subscription_name}}", "price": "{{subscription_price}}", "currency": "{{subscription_currency}}", "category": "{{subscription_category}}", "date": "{{subscription_date}}", "payer": "{{subscription_payer}}" } ] }'; } // Gotify notifications $sql = "SELECT * FROM gotify_notifications LIMIT 1"; $result = $db->query($sql); $rowCount = 0; while ($row = $result->fetchArray(SQLITE3_ASSOC)) { $notificationsGotify['enabled'] = $row['enabled']; $notificationsGotify['url'] = $row['url']; $notificationsGotify['token'] = $row['token']; $rowCount++; } if ($rowCount == 0) { $notificationsGotify['enabled'] = 0; $notificationsGotify['url'] = ""; $notificationsGotify['token'] = ""; } ?>

query($sql); if ($result) { $categories = array(); while ($row = $result->fetchArray(SQLITE3_ASSOC)) { $categories[] = $row; } } ?>

query($sql); if ($result) { $currencies = array(); while ($row = $result->fetchArray(SQLITE3_ASSOC)) { $currencies[] = $row; } } $query = "SELECT main_currency FROM user WHERE id = 1"; $stmt = $db->prepare($query); $result = $stmt->execute(); $row = $result->fetchArray(SQLITE3_ASSOC); $mainCurrencyId = $row['main_currency']; $query = "SELECT date FROM last_exchange_update"; $exchange_rates_last_updated = $db->querySingle($query); ?>

query($sql); if ($result) { $row = $result->fetchArray(SQLITE3_ASSOC); if ($row) { $apiKey = $row['api_key']; $provider = $row['provider']; } else { $provider = 0; } } ?>

Fixer API Key

query($sql); if ($result) { $payments = array(); while ($row = $result->fetchArray(SQLITE3_ASSOC)) { $payments[] = $row; } } ?>

query('SELECT id FROM payment_methods WHERE id IN (SELECT DISTINCT payment_method_id FROM subscriptions)'); $paymentsInUse = []; while ($row = $paymentsInUseQuery->fetchArray(SQLITE3_ASSOC)) { $paymentsInUse[] = $row['id']; } foreach ($payments as $payment) { $paymentIconFolder = $payment['id'] <= 31 ? 'images/uploads/icons/' : 'images/uploads/logos/'; $inUse = in_array($payment['id'], $paymentsInUse); ?>
Logo ">
x