<!DOCTYPE html>
<html lang="fa" dir="rtl">
<head>
    <meta charset="utf-8">
    <title>حسابداری پورتال</title>
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="robots" content="noindex">
    <link rel="stylesheet" href="/acc-engine/assets/css/base/fonts-local.css?v=2">
    <link rel="stylesheet" href="/acc-engine/assets/css/base/shop-premium.css?v=11">
    <link rel="stylesheet" href="/acc-engine/assets/css/erp-shop-panel.css?v=2">
    <link rel="stylesheet" href="/acc-engine/assets/css/shop-accounting.css?v=2">
    <script>
        window.ACC_PORTAL_CFG = {
            baseUrl: '/acc-engine/',
            api: '/acc-engine/api.php/acc/v1',
            module: new URLSearchParams(location.search).get('module') || 'service_portal'
        };
    </script>
</head>
<body class="erp-shop-body sacct-body">
    <div id="portal-acct-root"></div>
    <script type="module">
        import PortalAccountingView from '/acc-engine/assets/js/views/PortalAccountingView.js?v=1';
        const mod = window.ACC_PORTAL_CFG.module;
        const titles = {
            service_portal: 'حسابداری پورتال خدمات',
            election: 'حسابداری کمپین انتخابات',
            arag_shop: 'حسابداری فروش فروشگاه',
            education: 'حسابداری EduBrain — بهای تمام‌شده',
        };
        const backMap = {
            service_portal: 'service.php',
            election: 'election.php',
            education: 'education.php',
        };
        const view = new PortalAccountingView({
            module: mod,
            title: titles[mod] || 'حسابداری پورتال',
            backLinks: [
                { href: backMap[mod] || 'index.php', label: 'پورتال' },
            ],
        });
        view.render(document.getElementById('portal-acct-root'));
    </script>
</body>
</html>
