Main functions

This commit is contained in:
2025-10-26 14:44:10 +09:00
parent 6ff35e26f4
commit 291fc63a4c
901 changed files with 79783 additions and 201383 deletions

View File

@@ -130,7 +130,8 @@ router.get('/dashboard', requireAuth, async (req, res) => {
user: req.session.user,
stats,
recentContacts,
recentPortfolio
recentPortfolio,
currentPage: 'dashboard'
});
} catch (error) {
console.error('Dashboard error:', error);

View File

@@ -193,7 +193,7 @@ router.get('/services', async (req, res) => {
}
});
// Calculator page
// Modern Calculator page (new UX-polished version)
router.get('/calculator', async (req, res) => {
try {
const [settings, services] = await Promise.all([
@@ -205,14 +205,15 @@ router.get('/calculator', async (req, res) => {
})
]);
res.render('calculator', {
title: 'Project Calculator - SmartSolTech',
res.render('calculator-modern', {
title: 'Калькулятор стоимости услуг - SmartSolTech',
settings: settings || {},
services,
currentPage: 'calculator'
currentPage: 'calculator',
siteSettings: settings || {}
});
} catch (error) {
console.error('Calculator page error:', error);
console.error('Modern calculator page error:', error);
res.status(500).render('error', {
title: 'Error',
settings: {},