chore: remove Slides page and Salla console output

- Remove Slides route, import, and mobile nav link from App.tsx
- Remove Salla route mounting and console output from server

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
fahed
2026-03-26 17:16:40 +03:00
parent 18821fd560
commit b4f4104e3e
2 changed files with 3 additions and 24 deletions

View File

@@ -1,7 +1,6 @@
import express from 'express';
import cors from 'cors';
import { server, salla, erp } from './config';
import sallaRoutes from './routes/salla';
import { server, erp } from './config';
import erpRoutes from './routes/erp';
const app = express();
@@ -9,25 +8,15 @@ app.use(cors());
app.use(express.json());
// Mount routes
app.use(sallaRoutes);
app.use('/api/erp', erpRoutes);
app.listen(server.port, () => {
console.log(`\nServer running on http://localhost:${server.port}`);
console.log('\nERP API:');
if (erp.apiUrl && erp.username) {
console.log(` GET /api/erp/sales?startDate=...&endDate=...`);
console.log(` GET /api/erp/status`);
console.log(' GET /api/erp/sales?startDate=...&endDate=...');
console.log(' GET /api/erp/status');
} else {
console.log(' WARNING: ERP_API_URL / ERP_USERNAME not set in .env');
}
console.log('\nSalla:');
if (salla.clientId && salla.clientSecret) {
console.log(' GET /auth/login, /auth/callback, /auth/status');
console.log(' GET /api/store, /api/orders, /api/products, /api/customers');
} else {
console.log(' WARNING: SALLA_CLIENT_ID / SALLA_CLIENT_SECRET not set in .env');
}
});

View File

@@ -3,7 +3,6 @@ import { BrowserRouter as Router, Routes, Route, Link, useLocation } from 'react
const Dashboard = lazy(() => import('./components/Dashboard'));
const Comparison = lazy(() => import('./components/Comparison'));
const Slides = lazy(() => import('./components/Slides'));
import LoadingSkeleton from './components/shared/LoadingSkeleton';
import { fetchData, getCacheStatus, refreshData } from './services/dataService';
import { useLanguage } from './contexts/LanguageContext';
@@ -240,7 +239,6 @@ function App() {
<Routes>
<Route path="/" element={<Dashboard data={data} showDataLabels={showDataLabels} setShowDataLabels={setShowDataLabels} includeVAT={includeVAT} setIncludeVAT={setIncludeVAT} />} />
<Route path="/comparison" element={<Comparison data={data} showDataLabels={showDataLabels} setShowDataLabels={setShowDataLabels} includeVAT={includeVAT} setIncludeVAT={setIncludeVAT} />} />
<Route path="/slides" element={<Slides data={data} />} />
</Routes>
</Suspense>
</main>
@@ -264,14 +262,6 @@ function App() {
</svg>
<span>{t('nav.compare')}</span>
</NavLink>
<NavLink to="/slides" className="mobile-nav-item">
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round" aria-hidden="true">
<rect x="2" y="3" width="20" height="14" rx="2"/>
<line x1="8" y1="21" x2="16" y2="21"/>
<line x1="12" y1="17" x2="12" y2="21"/>
</svg>
<span>{t('nav.slides')}</span>
</NavLink>
<button
className="mobile-nav-item"
onClick={switchLanguage}