1 (edited by boxygen 10/31/2017 02:49:04 am)

Topic: Dropdown theme showing error and not displaying custom modules

Hello,

Dropdown theme is showing error as below in can_access_page function as below

Undefined index: SA_CSVIMPORT in file: /home/boxygenb/public_html/fa/fa24/includes/current_user.inc at line 192
/home/boxygenb/public_html/fa/fa24/includes/current_user.inc:201:    (current_user Object)->can_access('SA_CSVIMPORT')
/home/boxygenb/public_html/fa/fa24/themes/dropdown/renderer.php:142:    (current_user Object)->can_access_page('SA_CSVIMPORT')
/home/boxygenb/public_html/fa/fa24/includes/page/header.inc:158:    (renderer Object)->menu_header('Users','','')
/home/boxygenb/public_html/fa/fa24/includes/main.inc:44:    page_header('Users','','','','','')
/home/boxygenb/public_html/fa/fa24/admin/users.php:16:    page('Users')

And the extension is also not appearing. While in Default theme no such errors and extensions are shown.

Please check it.

You can reproduce error at Here

id: admin
pass: Pakistan1947

www.boxygen.pk

Re: Dropdown theme showing error and not displaying custom modules

Both themes have same core function calls but why this theme showing error about all custom modules' SECURITY AREAS if debug mode is on and not showing up custom modules?

These errors can be ignored if debug mode is set to off but problem is that the link of custom modules are not showing up.

This theme is now added to the default repo so its need to be fixed. I tried but unable to find the exact reason. @joe may help us here!!

www.boxygen.pk

Re: Dropdown theme showing error and not displaying custom modules

There is no constant SA_CSVIMPORT in any of the themes and the FA core. It is possible you got it from one of your extensions or the official import_items extension. My extensions repo has the updated files (attached) for the official extension and see if they mitigate your issue.

Post's attachments

import_items.zip 9.1 kb, 8 downloads since 2017-10-31 

You don't have the permssions to download the attachments of this post.

Re: Dropdown theme showing error and not displaying custom modules

The issue still exists

Undefined index: SA_CSVIMPORT in file: C:\xampp\htdocs\bx242\includes\current_user.inc at line 192
C:\xampp\htdocs\bx242\includes\current_user.inc:201:    (current_user Object)->can_access('SA_CSVIMPORT')
C:\xampp\htdocs\bx242\themes\default\renderer.php:198:    (current_user Object)->can_access_page('SA_CSVIMPORT')
C:\xampp\htdocs\bx242\includes\page\header.inc:164:    (renderer Object)->menu_header('Dashboard','','')
C:\xampp\htdocs\bx242\includes\main.inc:44:    page_header('Dashboard','','','','function openWindow(url, title) { var left = (screen.width - 800) / 2; var top = (screen.height - 500) / 2; return window.open(url, title, 'width=800,height=500,left='+left+',top='+top+',screenX='+left+',screenY='+top+',status=no,scrollbars=yes'); } function lookupWindow(url, title) { var u = url.split('#'); if (u.length == 2) { var element = document.getElementById(u[1]); var options = element.options; url = u[0] + '&' + u[1] + '=' + options[element.selectedIndex].value; } openWindow(url, title); }','')
C:\xampp\htdocs\bx242\admin\dashboard.php:27:    page('Dashboard','','','','function openWindow(url, title) { var left = (screen.width - 800) / 2; var top = (screen.height - 500) / 2; return window.open(url, title, 'width=800,height=500,left='+left+',top='+top+',screenX='+left+',screenY='+top+',status=no,scrollbars=yes'); } function lookupWindow(url, title) { var u = url.split('#'); if (u.length == 2) { var element = document.getElementById(u[1]); var options = element.options; url = u[0] + '&' + u[1] + '=' + options[element.selectedIndex].value; } openWindow(url, title); }')

This issue is for all external extensions and only for this theme Dropdown

www.boxygen.pk

5 (edited by notrinos 10/31/2017 10:23:51 am)

Re: Dropdown theme showing error and not displaying custom modules

Can you post your renderer.php code? I did not see can_access_page() in line 142 of original dropdown theme renderer.php

Phuong

6 (edited by boxygen 10/31/2017 10:42:14 am)

Re: Dropdown theme showing error and not displaying custom modules

its on Line 154

<?php
/**********************************************************************
    Copyright (C) FrontAccounting, LLC.
    Released under the terms of the GNU General Public License, GPL, 
    as published by the Free Software Foundation, either version 3 
    of the License, or (at your option) any later version.
    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
    See the License here <http://www.gnu.org/licenses/gpl-3.0.html>.
***********************************************************************/
// Author: Joe Hunt, 17/11/2015. Upgraded to release 2.4. 10/11/2015.

    class renderer
    {
        function wa_get_apps($title, $applications, $sel_app)
        {
            foreach($applications as $app)
            {
                foreach ($app->modules as $module)
                {
                    $apps = array();
                    foreach ($module->lappfunctions as $appfunction)
                        $apps[] = $appfunction;
                    foreach ($module->rappfunctions as $appfunction)
                        $apps[] = $appfunction;
                    $application = array();    
                    foreach ($apps as $application)    
                    {
                        $url = explode('?', $application->link);
                        $app_lnk = $url[0];                    
                        $pos = strrpos($app_lnk, "/");
                        if ($pos > 0)
                        {
                            $app_lnk = substr($app_lnk, $pos + 1);
                            $lnk = $_SERVER['REQUEST_URI'];
                            $url = explode('?', $lnk);
                            $asset = false;
                            if (isset($url[1]))
                                $asset = strstr($url[1], "FixedAsset");
                            $lnk = $url[0];                    
                            $pos = strrpos($lnk, "/");
                            $lnk = substr($lnk, $pos + 1);
                            if ($app_lnk == $lnk)  
                            {
                                $acc = access_string($app->name);
                                $app_id = ($asset != false ? "assets" : $app->id);
                                return array($acc[0], $module->name, $application->label, $app_id);
                            }    
                        }    
                    }
                }
            }
            return array("", "", "", $sel_app);
        }
        
        function wa_header()
        {
            page(_($help_context = "Main Menu"), false, true);
        }

        function wa_footer()
        {
            end_page(false, true);
        }
        function shortcut($url, $label) 
        {
            echo "<li>";
            echo menu_link($url, $label);
            echo "</li>";
        }
        function menu_header($title, $no_menu, $is_index)
        {
            global $path_to_root, $SysPrefs, $version;

            $sel_app = $_SESSION['sel_app'];
            echo "<div class='fa-main'>\n";
            if (!$no_menu)
            {
                $applications = $_SESSION['App']->applications;
                $local_path_to_root = $path_to_root;
                $pimg = "<img src='$local_path_to_root/themes/".user_theme()."/images/preferences.gif' style='width:14px;height:14px;border:0;vertical-align:middle;padding-bottom:3px;' alt='"._('Preferences')."'>&nbsp;&nbsp;";
                $limg = "<img src='$local_path_to_root/themes/".user_theme()."/images/lock.gif' style='width:14px;height:14px;border:0;vertical-align:middle;padding-bottom:3px;' alt='"._('Change Password')."'>&nbsp;&nbsp;";
                $img = "<img src='$local_path_to_root/themes/".user_theme()."/images/on_off.png' style='width:14px;height:14px;border:0;vertical-align:middle;padding-bottom:3px;' alt='"._('Logout')."'>&nbsp;&nbsp;";
                $himg = "<img src='$local_path_to_root/themes/".user_theme()."/images/help.gif' style='width:14px;height:14px;border:0;vertical-align:middle;padding-bottom:3px;' alt='"._('Help')."'>&nbsp;&nbsp;";
                echo "<div id='header'>\n";
                echo "<ul>\n";
                echo "  <li><a href='$local_path_to_root/admin/display_prefs.php?'>$pimg" . _("Preferences") . "</a></li>\n";
                echo "  <li><a href='$local_path_to_root/admin/change_current_user_password.php?selected_id=" . $_SESSION["wa_current_user"]->username . "'>$limg" . _("Change password") . "</a></li>\n";
                if ($SysPrefs->help_base_url != null)
                    echo "  <li><a target = '_blank' onclick=" .'"'."javascript:openWindow(this.href,this.target); return false;".'" '. "href='". 
                        help_url()."'>$himg" . _("Help") . "</a></li>";
                echo "  <li><a href='$path_to_root/access/logout.php?'>$img" . _("Logout") . "</a></li>";
                echo "</ul>\n";
                $indicator = "$path_to_root/themes/".user_theme(). "/images/ajax-loader.gif";
                echo "<h1>$SysPrefs->power_by $version<span style='padding-left:300px;'><img id='ajaxmark' src='$indicator' align='center' style='visibility:hidden;'></span></h1>\n";
                echo "</div>\n"; // header
                                
                echo "<div id='cssmenu'>\n";
                echo "<ul>\n";
                $i = 0;
                $account = $this->wa_get_apps($title, $applications, $sel_app);
                foreach($applications as $app)
                {
                    if ($_SESSION["wa_current_user"]->check_application_access($app))
                    {
                        $acc = access_string($app->name);
                        $class = ($account[3] == $app->id ? "active" : "");
                        $n = count($app->modules);
                        if ($n)
                            $class .= " has-sub";
                        $dashboard = "";    
                        $u_agent = $_SERVER['HTTP_USER_AGENT']; 
                        if (preg_match('/android/i', $u_agent) && preg_match('/mobile/i', $u_agent)) {
                            $link = "#'";
                            $dashboard = "$local_path_to_root/index.php?application=$app->id";
                        }
                        else
                            $link = "$local_path_to_root/index.php?application=$app->id '$acc[1]";
                        echo "  <li class ='$class'><a href='$link><span>" . $acc[0] . "</span></a>\n";
                        if (!$n)
                        {
                            echo "  </li>\n";
                            continue;
                        }    
                        echo "    <ul>\n";
                           if ($dashboard !="")
                            echo "      <li><a href='$dashboard'><span><font color='red'>"._("Dashboard")."</font></span></a></li>\n";
                        foreach ($app->modules as $module)
                        {
                            if (!$_SESSION["wa_current_user"]->check_module_access($module))
                                continue;
                             echo "      <li class='has-sub'><a href='#'><span>$module->name</span></a>\n"; 
                             $apps2 = array();
                             foreach ($module->lappfunctions as $appfunction)
                                $apps2[] = $appfunction;
                            foreach ($module->rappfunctions as $appfunction)
                                $apps2[] = $appfunction;
                            $application = array();    
                               $n = count($apps2);
                               $class = "";
                               if ($i > 5)
                                   $class = "class='align_right'";
                            if ($n)
                                echo "        <ul $class>\n";
                            else
                            {
                                echo "      </li>\n";
                                continue;
                            }    
                            foreach ($apps2 as $application)    
                            {
                                $lnk = access_string($application->label);
                                if ($_SESSION["wa_current_user"]->can_access_page($application->access))
                                {
                                    if ($application->label != "")
                                    {
                                        echo "          <li><a href='$path_to_root/$application->link'><span>$lnk[0]</span></a></li>\n";
                                    }
                                }
                                elseif (!$_SESSION["wa_current_user"]->hide_inaccessible_menu_items())    
                                    echo "          <li><a href='#'><span><font color='gray'>$lnk[0]</font></span></a></li>\n";
                            }
                            if ($n)
                                echo "        </ul>\n";    
                            echo "      </li>\n";
                        }
                        echo "    </ul>\n"; // menu
                    }
                    echo"  </li>\n";
                    $i++;
                }    
                echo "</ul>\n"; 
                echo "</div>\n"; // menu
            }
            echo "<div class='fa-body'>\n";
            if ($no_menu)
                echo "<br>";
            elseif ($title && !$no_menu && !$is_index)
            {
                echo "<div class='fa-content'>\n";
                echo "<center><table id='title'><tr><td width='100%' class='titletext'>$title</td>"
                ."<td align=right>"
                .(user_hints() ? "<span id='hints'></span>" : '')
                ."</td>"
                ."</tr></table></center>";
            }
        }

        function menu_footer($no_menu, $is_index)
        {
            global $path_to_root, $SysPrefs, $version, $db_connections;
            include_once($path_to_root . "/includes/date_functions.inc");

            if (!$no_menu && !$is_index)
                echo "</div>\n"; // fa-content
            echo "</div>\n"; // fa-body
            if (!$no_menu)
            {
                   echo "<script type='text/javascript'>if( /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent))
                          {document.getElementById('cssmenu').style.position = 'fixed';}</script>\n";
                echo "<div class='fa-footer'>\n";
                if (isset($_SESSION['wa_current_user']))
                {
                    echo "<span class='power'><a target='_blank' href='$SysPrefs->power_url'>$SysPrefs->power_by $version</a></span>\n";
                    echo "<span class='date'>".Today() . "&nbsp;" . Now()."</span>\n";
                    echo "<span class='date'>" . $db_connections[$_SESSION["wa_current_user"]->company]["name"] . "</span>\n";
                    echo "<span class='date'>" . $_SERVER['SERVER_NAME'] . "</span>\n";
                    echo "<span class='date'>" . $_SESSION["wa_current_user"]->name . "</span>\n";
                    echo "<span class='date'>" . _("Theme:") . " " . user_theme() . "</span>\n";
                    echo "<span class='date'>".show_users_online()."</span>\n";
                }
                echo "</div>\n"; // footer
            }
            echo "</div>\n"; // fa-main
        }

        function display_applications(&$waapp)
        {
            global $path_to_root;

            $sel = $waapp->get_selected_application();
            meta_forward("$path_to_root/admin/dashboard.php", "sel_app=$sel->id");    
            end_page();
            exit;
        }    
    }
    

Below is the Error Code from the Core renderer.php without any customization

Undefined index: SA_CSVIMPORT in file: C:\xampp\htdocs\FA242ORG\includes\current_user.inc at line 192
C:\xampp\htdocs\FA242ORG\includes\current_user.inc:201:    (current_user Object)->can_access('SA_CSVIMPORT')
C:\xampp\htdocs\FA242ORG\themes\dropdown\renderer.php:154:    (current_user Object)->can_access_page('SA_CSVIMPORT')
C:\xampp\htdocs\FA242ORG\includes\page\header.inc:158:    (renderer Object)->menu_header('Search Outstanding Purchase Orders','','')
C:\xampp\htdocs\FA242ORG\includes\main.inc:44:    page_header('Search Outstanding Purchase Orders','','','','function openWindow(url, title) { var left = (screen.width - 900) / 2; var top = (screen.height - 500) / 2; return window.open(url, title, 'width=900,height=500,left='+left+',top='+top+',screenX='+left+',screenY='+top+',status=no,scrollbars=yes'); } function lookupWindow(url, title) { var u = url.split('#'); if (u.length == 2) { var element = document.getElementById(u[1]); var options = element.options; url = u[0] + '&' + u[1] + '=' + options[element.selectedIndex].value; } openWindow(url, title); }','')
C:\xampp\htdocs\FA242ORG\purchasing\inquiry\po_search.php:25:    page('Search Outstanding Purchase Orders','','','','function openWindow(url, title) { var left = (screen.width - 900) / 2; var top = (screen.height - 500) / 2; return window.open(url, title, 'width=900,height=500,left='+left+',top='+top+',screenX='+left+',screenY='+top+',status=no,scrollbars=yes'); } function lookupWindow(url, title) { var u = url.split('#'); if (u.length == 2) { var element = document.getElementById(u[1]); var options = element.options; url = u[0] + '&' + u[1] + '=' + options[element.selectedIndex].value; } openWindow(url, title); }')
    
www.boxygen.pk

Re: Dropdown theme showing error and not displaying custom modules

The Dropdown theme was not updated by the author.
It is based on the Dynamic theme.
Compare the files between the two if you have issues.
Attached is the Dropdown theme after making $SysPrefs fixes.
Updated in my FA24Extensions Repo.

Post's attachments

dropdown.zip 87.4 kb, 4 downloads since 2017-10-31 

You don't have the permssions to download the attachments of this post.

Re: Dropdown theme showing error and not displaying custom modules

Seems @apmuthu's fixs working.

Phuong

Re: Dropdown theme showing error and not displaying custom modules

@apmuthu I have applied your code but still problem exists.

If Dynamic theme is latest than Dropdown then in Download package instead of Dropdown, Dynamic must have been added.

www.boxygen.pk

Re: Dropdown theme showing error and not displaying custom modules

Seems @apmuthu's fixs working.

really

www.boxygen.pk

Re: Dropdown theme showing error and not displaying custom modules

After applying apmuthus fix the error code appears on Line 142

Undefined index: SA_CSVIMPORT in file: C:\xampp\htdocs\bx242\includes\current_user.inc at line 192
C:\xampp\htdocs\bx242\includes\current_user.inc:201:    (current_user Object)->can_access('SA_CSVIMPORT')
C:\xampp\htdocs\bx242\themes\dropdown-new\renderer.php:142:    (current_user Object)->can_access_page('SA_CSVIMPORT')
C:\xampp\htdocs\bx242\includes\page\header.inc:164:    (renderer Object)->menu_header('Display Setup','','')
C:\xampp\htdocs\bx242\includes\main.inc:44:    page_header('Display Setup','','','','','')
C:\xampp\htdocs\bx242\admin\display_prefs.php:16:    page('Display Setup')
www.boxygen.pk

12 (edited by notrinos 10/31/2017 12:38:17 pm)

Re: Dropdown theme showing error and not displaying custom modules

Insert add_access_extensions(); after line 128 of renderer file will fix the problem.

I guess not only this theme has the problem.

Phuong

Re: Dropdown theme showing error and not displaying custom modules

Use this file and see (rename as php and use) for dropdown theme.

Lines 163-164:

            echo "<div class='fa-body'>\n";
            echo "<div class='fa-content'>\n";

have been replaced with:

            echo "<div class='fa-body'>\n";
            if (!$no_menu)
                add_access_extensions();
            echo "<div class='fa-content'>\n";
Post's attachments

renderer.php1 24.3 kb, 5 downloads since 2017-10-31 

You don't have the permssions to download the attachments of this post.

Re: Dropdown theme showing error and not displaying custom modules

Thanks @apmuthu and @notrinos for your help. I compared @apmuthu's suggestion with Dynamic theme and finally got the solution.

Add following lines at Line: 101

    if (!$no_menu)
        {
                    add_access_extensions();

Close the If statement at Line: 169

www.boxygen.pk

15 (edited by boxygen 11/01/2017 02:41:24 am)

Re: Dropdown theme showing error and not displaying custom modules

Here is the final renderer.php code

<?php
/**********************************************************************
    Copyright (C) FrontAccounting, LLC.
    Released under the terms of the GNU General Public License, GPL,
    as published by the Free Software Foundation, either version 3
    of the License, or (at your option) any later version.
    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
    See the License here <http://www.gnu.org/licenses/gpl-3.0.html>.
***********************************************************************/
// Author: Joe Hunt, 17/11/2015. Upgraded to release 2.4. 10/11/2015.

    class renderer
    {
        function wa_get_apps($title, $applications, $sel_app)
        {
            foreach($applications as $app)
            {
                foreach ($app->modules as $module)
                {
                    $apps = array();
                    foreach ($module->lappfunctions as $appfunction)
                        $apps[] = $appfunction;
                    foreach ($module->rappfunctions as $appfunction)
                        $apps[] = $appfunction;
                    $application = array();
                    foreach ($apps as $application)
                    {
                        $lnk = $_SERVER['REQUEST_URI'];
                        $pos = strpos($application->link, "/");
                        if ($pos > 0)
                        {
                            $app_lnk = substr($application->link, $pos + 1);
                            $pos = strpos($app_lnk, "?");
                            if ($pos == false)
                                $pos = strlen($app_lnk);
                            $app_lnk = substr($app_lnk, 0, $pos);
                            $pos = strrpos($lnk, "/");
                            $lnk = substr($lnk, $pos + 1);
                            $pos = strpos($lnk, "?");
                            if ($pos == false)
                                $pos = strlen($lnk);
                            $lnk = substr($lnk, 0, $pos);
                            if ($app_lnk == $lnk)
                            {
                                $acc = access_string($app->name);
                                return array($acc[0], $module->name, $application->label, $app->id);
                            }
                        }
                    }
                }
            }
            return array("", "", "", $sel_app);
        }

        function wa_header()
        {
            page(_($help_context = "Main Menu"), false, true);
        }

        function wa_footer()
        {
            end_page(false, true);
        }
        function shortcut($url, $label)
        {
            echo "<li>";
            echo menu_link($url, $label);
            echo "</li>";
        }
        function menu_header($title, $no_menu, $is_index)
        {
            global $path_to_root, $SysPrefs, $version, $db_connections, $installed_extensions;

            $sel_app = $_SESSION['sel_app'];
            echo "<div class='fa-main'>\n";
            if (!$no_menu)
            {
                echo "<script type='text/javascript' src='$path_to_root/themes/dynamic/ddmenu/ddlevelsmenu.js'></script>\n";
                $applications = $_SESSION['App']->applications;
                $local_path_to_root = $path_to_root;
                $img = "<img src='$local_path_to_root/themes/dynamic/images/login.gif' width='14' height='14' border='0' alt='"._('Logout')."'>&nbsp;&nbsp;";
                $himg = "<img src='$local_path_to_root/themes/dynamic/images/help.gif' width='14' height='14' border='0' alt='"._('Help')."'>&nbsp;&nbsp;";
                echo "<div id='header'>\n";
                echo "<ul>\n";
                echo "  <li><a href='$local_path_to_root/admin/display_prefs.php?'>" . _("Preferences") . "</a></li>\n";
                echo "  <li><a href='$local_path_to_root/admin/change_current_user_password.php?selected_id=" . $_SESSION["wa_current_user"]->username . "'>" . _("Change password") . "</a></li>\n";
                if ($SysPrefs->help_base_url != null)
                    echo "  <li><a target = '_blank' onclick=" .'"'."javascript:openWindow(this.href,this.target); return false;".'" '. "href='".
                        help_url()."'>$himg" . _("Help") . "</a></li>";
                echo "  <li><a href='$path_to_root/access/logout.php?'>$img" . _("Logout") . "</a></li>";
                echo "</ul>\n";
                $indicator = "$path_to_root/themes/".user_theme(). "/images/ajax-loader.gif";
                echo "<h1>$SysPrefs->power_by $version<span style='padding-left:300px;'><img id='ajaxmark' src='$indicator' align='center' style='visibility:hidden;'></span></h1>\n";
                echo "</div>\n"; // header

                echo "<div id='cssmenu'>\n";
                echo "<ul>\n";
                $account = $this->wa_get_apps($title, $applications, $sel_app);
                if (!$no_menu)
        {
                    add_access_extensions();
                
                foreach($applications as $app)
                {
                    if ($this->check_application_access($app))
                    {
                        if ($account[3] == $app->id)
                            $sel_application = $app;
                        $acc = access_string($app->name);
                        $class = ($account[3] == $app->id ? "active" : "");
                        $n = count($app->modules);
                        if ($n)
                            $class .= " has-sub";
                        echo "  <li class ='$class'><a href='$local_path_to_root/index.php?application=" . $app->id
                            ."'$acc[1]'><span>" . $acc[0] . "</span></a>\n";
                        if (!$n)
                        {
                            echo "  </li>\n";
                            continue;
                        }
                        echo "    <ul>\n";
                        foreach ($app->modules as $module)
                        {
                            if (!$this->check_module_access($module))
                                continue;
                             echo "      <li class='has-sub'><a href='#'><span>$module->name</span></a>\n";
                             $apps2 = array();
                             foreach ($module->lappfunctions as $appfunction)
                                $apps2[] = $appfunction;
                            foreach ($module->rappfunctions as $appfunction)
                                $apps2[] = $appfunction;
                            $application = array();
                               $n = count($apps2);
                            if ($n)
                                echo "        <ul>\n";
                            else
                            {
                                echo "      </li>\n";
                                continue;
                            }
                            foreach ($apps2 as $application)
                            {
                                $lnk = access_string($application->label);
                                if ($_SESSION["wa_current_user"]->can_access_page($application->access))
                                {
                                    if ($application->label != "")
                                    {
                                        echo "          <li><a href='$path_to_root/$application->link'><span>$lnk[0]</span></a></li>\n";
                                    }
                                }
                                elseif (!$this->hide_inaccessible_menu_items())
                                    echo "          <li><a href='#'><span><font color='gray'>$lnk[0]</font></span></a>/li>\n";
                            }
                            if ($n)
                                echo "        </ul>\n";
                            echo "      </li>\n";
                        }
                        echo "    </ul>\n"; // menu
                    }
                    echo"  </li>\n";
                }
                echo "</ul>\n";
                echo "</div>\n"; // menu
            }
            echo "<div class='fa-body'>\n";
            echo "<div class='fa-content'>\n";
        }
            if ($no_menu)
                echo "<br>";
            elseif ($title && !$no_menu && !$is_index)
            {
                echo "<center><table id='title'><tr><td width='100%' class='titletext'>$title</td>"
                ."<td align=right>"
                .(user_hints() ? "<span id='hints'></span>" : '')
                ."</td>"
                ."</tr></table></center>";
            }
        }

        function menu_footer($no_menu, $is_index)
        {
            global $path_to_root, $SysPrefs, $version, $db_connections;
            include_once($path_to_root . "/includes/date_functions.inc");

            if (!$no_menu)
                echo "</div>\n"; // fa-content
            echo "</div>\n"; // fa-body
            if (!$no_menu)
            {
                echo "<div class='fa-footer'>\n";
                if (isset($_SESSION['wa_current_user']))
                {
                    echo "<span class='power'><a target='_blank' href='$SysPrefs->power_url'>$SysPrefs->power_by $version</a></span>\n";
                    echo "<span class='date'>".Today() . "&nbsp;" . Now()."</span>\n";
                    echo "<span class='date'>" . $db_connections[$_SESSION["wa_current_user"]->company]["name"] . "</span>\n";
                    echo "<span class='date'>" . $_SERVER['SERVER_NAME'] . "</span>\n";
                    echo "<span class='date'>" . $_SESSION["wa_current_user"]->name . "</span>\n";
                    echo "<span class='date'>" . _("Theme:") . " " . user_theme() . "</span>\n";
                    echo "<span class='date'>".show_users_online()."</span>\n";
                }
                echo "</div>\n"; // footer
            }
            echo "</div>\n"; // fa-main
        }

        function display_applications(&$waapp)
        {
            global $path_to_root, $SysPrefs;
            include_once("$path_to_root/includes/ui.inc");
            include_once($path_to_root . "/reporting/includes/class.graphic.inc");
            include($path_to_root . "/includes/system_tests.inc");

            if ($SysPrefs->use_popup_windows)
            {
                $js = get_js_open_window(900, 500);
                  add_js_source($js);
            }
            if (!defined('FLOAT_COMP_DELTA'))
                define('FLOAT_COMP_DELTA', 0.004);

            $selected_app = $waapp->get_selected_application();
            if (!$this->check_application_access($selected_app))
                return;
            // first have a look through the directory,
            // and remove old temporary pdfs and pngs
            $dir = company_path(). '/pdf_files';

            if ($d = @opendir($dir)) {
                while (($file = readdir($d)) !== false) {
                    if (!is_file($dir.'/'.$file) || $file == 'index.php') continue;
                // then check to see if this one is too old
                    $ftime = filemtime($dir.'/'.$file);
                 // seems 3 min is enough for any report download, isn't it?
                    if (time()-$ftime > 180){
                        unlink($dir.'/'.$file);
                    }
                }
                closedir($d);
            }

            //check_for_overdue_recurrent_invoices();
            if ($selected_app->id == "orders")
                display_customer_topten();
            elseif ($selected_app->id == "AP")
                display_supplier_topten();
            elseif ($selected_app->id == "stock")
                display_stock_topten();
            elseif ($selected_app->id == "manuf")
                display_stock_topten(true);
            elseif ($selected_app->id == "proj")
                display_dimension_topten();
            elseif ($selected_app->id == "GL")
                display_gl_info();
            else
                display_all();
        }

        function check_application_access($waapp)
        {
            if (!$this->hide_inaccessible_menu_items())
            {
                return true;
            }

            foreach ($waapp->modules as $module)
            {
                if ($this->check_module_access($module))
                {
                    return true;
                }
            }

            return false;

        }

        function check_module_access($module)
        {

            if (!$this->hide_inaccessible_menu_items())
            {
                return true;
            }

            if (sizeof($module->lappfunctions) > 0)
            {
                foreach ($module->lappfunctions as $appfunction)
                {
                    if ($appfunction->label != "" && $_SESSION["wa_current_user"]->can_access_page($appfunction->access))
                    {
                        return true;
                    }
                }
            }

            if (sizeof($module->rappfunctions) > 0)
            {
                foreach ($module->rappfunctions as $appfunction)
                {
                    if ($appfunction->label != "" && $_SESSION["wa_current_user"]->can_access_page($appfunction->access))
                    {
                        return true;
                    }
                }
            }

            return false;

        }

        function hide_inaccessible_menu_items()
        {
            global $hide_inaccessible_menu_items;

            if (!isset($hide_inaccessible_menu_items) || $hide_inaccessible_menu_items == 0)
            {
                return false;
            }

            else
            {
                return true;
            }
        }
    }

    function display_customer_topten()
    {
        global $path_to_root;;

        $pg = new graph();

        $today = Today();
        $title = customer_top($today, 10, 33, $pg);
        source_graphic($today, $title, _("Customer"), $pg);
        customer_trans($today);
        customer_recurrent_invoices($today);
    }

    function display_supplier_topten()
    {
        global $path_to_root;

        $pg = new graph();

        $today = Today();
        $title = supplier_top($today, 10, 33, $pg);
        source_graphic($today, $title, _("Supplier"), $pg);
        supplier_trans($today);
    }

    function display_stock_topten($manuf=false)
    {
        global $path_to_root;

        $pg = new graph();

        $today = Today();
        $title = stock_top($today, 10, 33, $manuf, $pg);
        $source = ($manuf) ? _("Manufacturing") : _("Items");
        source_graphic($today, $title, $source, $pg);
    }

    function display_dimension_topten()
    {
        global $path_to_root;

        $pg = new graph();

        $today = Today();
        $title = dimension_top($today, 10, 33, $pg);
        source_graphic($today, $title, _("Dimension"), $pg, 5);
    }

    function display_gl_info()
    {
        global $path_to_root;

        $pg = new graph();

        $today = Today();
        $title = gl_top($today, 33, $pg);
        source_graphic($today, $title, _("Class"), $pg, 5);
    }

    function display_all()
    {
        $today = Today();

        $pg = new graph();

        echo "<table width='100%'>";
        echo "<tr valign=top><td style='width:50%'>\n"; // outer table

        $title = customer_top($today, 3, 66, $pg);
        source_graphic($today, $title, _("Customer"), $pg);
        $title = supplier_top($today, 3, 66, $pg);
        source_graphic($today, $title, _("Supplier"), $pg);
        $title = stock_top($today, 3, 66, false, $pg);
        source_graphic($today, $title, _("Stock"), $pg);

        echo "</td><td style='width:50%'>\n";

        dimension_top($today, 3, 66);
        $title = gl_top($today, 66, $pg);
        source_graphic($today, $title, _("Class"), $pg, 5);
        stock_top($today, 3, 66, true);

        echo "</td></tr></table>\n";
    }

    function display_title($title, $colspan=2)
    {
        br();
        echo "<tr><td colspan=$colspan class='headingtext' style='text-align:center;border:0;height:40px;'>$title</td></tr>\n";
    }

    function customer_top($today, $limit=10, $width="33", &$pg=null)
    {
        $begin = begin_fiscalyear();
        $begin1 = date2sql($begin);
        $today1 = date2sql($today);
        $sql = "SELECT SUM((ov_amount + ov_discount) * rate * IF(trans.type = ".ST_CUSTCREDIT.", -1, 1)) AS total,d.debtor_no, d.name FROM
            ".TB_PREF."debtor_trans AS trans, ".TB_PREF."debtors_master AS d WHERE trans.debtor_no=d.debtor_no
            AND (trans.type = ".ST_SALESINVOICE." OR trans.type = ".ST_CUSTCREDIT.")
            AND tran_date >= '$begin1' AND tran_date <= '$today1' GROUP by d.debtor_no ORDER BY total DESC, d.debtor_no
            LIMIT $limit";
        $result = db_query($sql);
        $title = _("Top $limit customers in fiscal year");
        $th = array(_("Customer"), _("Amount"));
        start_table(TABLESTYLE, "width='$width%'");
        display_title($title, count($th));
        table_header($th);
        $k = 0; //row colour counter
        $i = 0;
        while ($myrow = db_fetch($result))
        {
            alt_table_row_color($k);
            $name = $myrow["debtor_no"]." ".$myrow["name"];
            label_cell($name);
            amount_cell($myrow['total']);
            if ($pg != null)
            {
                $pg->x[$i] = $name;
                $pg->y[$i] = $myrow['total'];
            }
            $i++;
            end_row();
        }
        end_table(2);
        return $title;
    }

    function supplier_top($today, $limit=10, $width="33", &$pg=null)
    {
        $begin = begin_fiscalyear();
        $begin1 = date2sql($begin);
        $today1 = date2sql($today);
        $sql = "SELECT SUM((trans.ov_amount + trans.ov_discount) * rate) AS total, s.supplier_id, s.supp_name FROM
            ".TB_PREF."supp_trans AS trans, ".TB_PREF."suppliers AS s WHERE trans.supplier_id=s.supplier_id
            AND (trans.type = ".ST_SUPPINVOICE." OR trans.type = ".ST_SUPPCREDIT.")
            AND tran_date >= '$begin1' AND tran_date <= '$today1' GROUP by s.supplier_id ORDER BY total DESC, s.supplier_id
            LIMIT $limit";
        $result = db_query($sql);
        $title = _("Top $limit suppliers in fiscal year");
        $th = array(_("Supplier"), _("Amount"));
        start_table(TABLESTYLE, "width='$width%'");
        display_title($title, count($th));
        table_header($th);
        $k = 0; //row colour counter
        $i = 0;
        while ($myrow = db_fetch($result))
        {
            alt_table_row_color($k);
            $name = $myrow["supplier_id"]." ".$myrow["supp_name"];
            label_cell($name);
            amount_cell($myrow['total']);
            if ($pg != null)
            {
                $pg->x[$i] = $name;
                $pg->y[$i] = $myrow['total'];
            }
            $i++;
            end_row();
        }
        end_table(2);
        return $title;
    }

    function stock_top($today, $limit=10, $width="33", $manuf=false, &$pg=null)
    {
        $begin = begin_fiscalyear();
        $begin1 = date2sql($begin);
        $today1 = date2sql($today);
        $sql = "SELECT SUM((trans.unit_price * trans.quantity) * d.rate) AS total, s.stock_id, s.description,
            SUM(trans.quantity) AS qty FROM
            ".TB_PREF."debtor_trans_details AS trans, ".TB_PREF."stock_master AS s, ".TB_PREF."debtor_trans AS d
            WHERE trans.stock_id=s.stock_id AND trans.debtor_trans_type=d.type AND trans.debtor_trans_no=d.trans_no
            AND (d.type = ".ST_SALESINVOICE." OR d.type = ".ST_CUSTCREDIT.") ";
        if ($manuf)
            $sql .= "AND s.mb_flag='M' ";
        $sql .= "AND d.tran_date >= '$begin1' AND d.tran_date <= '$today1' GROUP by s.stock_id ORDER BY total DESC, s.stock_id
            LIMIT $limit";
        $result = db_query($sql);
        if ($manuf)
            $title = _("Top $limit Manufactured Items in fiscal year");
        else
            $title = _("Top $limit Sold Items in fiscal year");
        $th = array(_("Item"), _("Amount"), _("Quantity"));
        start_table(TABLESTYLE, "width='$width%'");
        display_title($title, count($th));
        table_header($th);
        $k = 0; //row colour counter
        $i = 0;
        while ($myrow = db_fetch($result))
        {
            alt_table_row_color($k);
            $name = $myrow["description"];
            label_cell($name);
            amount_cell($myrow['total']);
            qty_cell($myrow['qty']);
            if ($pg != NULL)
            {
                $pg->x[$i] = $name;
                $pg->y[$i] = $myrow['total'];
            }
            $i++;
            end_row();
        }
        end_table(2);
    }

    function dimension_top($today, $limit=10, $width="33", &$pg=null)
    {

        $begin = begin_fiscalyear();
        $begin1 = date2sql($begin);
        $today1 = date2sql($today);
        $sql = "SELECT SUM(-t.amount) AS total, d.reference, d.name FROM
            ".TB_PREF."gl_trans AS t,".TB_PREF."dimensions AS d WHERE
            (t.dimension_id = d.id OR t.dimension2_id = d.id) AND
            t.tran_date >= '$begin1' AND t.tran_date <= '$today1' GROUP BY d.id ORDER BY total DESC LIMIT $limit";
        $result = db_query($sql, "Transactions could not be calculated");
        $title = _("Top $limit Dimensions in fiscal year");
        $th = array(_("Dimension"), _("Amount"));
        start_table(TABLESTYLE, "width='$width%'");
        display_title($title, count($th));
        table_header($th);
        $k = 0; //row colour counter
        $i = 0;
        while ($myrow = db_fetch($result))
        {
            alt_table_row_color($k);
            $name = $myrow['reference']." ".$myrow["name"];
            label_cell($name);
            amount_cell($myrow['total']);
            if ($pg != null)
            {
                $pg->x[$i] = $name;
                $pg->y[$i] = abs($myrow['total']);
            }
            $i++;
            end_row();
        }
        end_table(2);
    }

    function gl_top($today, $width="33", &$pg=null)
    {
        $begin = begin_fiscalyear();
        $begin1 = date2sql($begin);
        $today1 = date2sql($today);
        $sql = "SELECT SUM(amount) AS total, c.class_name, c.ctype FROM
            ".TB_PREF."gl_trans,".TB_PREF."chart_master AS a, ".TB_PREF."chart_types AS t,
            ".TB_PREF."chart_class AS c WHERE
            account = a.account_code AND a.account_type = t.id AND t.class_id = c.cid
            AND IF(c.ctype > 3, tran_date >= '$begin1', tran_date >= '0000-00-00')
            AND tran_date <= '$today1' GROUP BY c.cid ORDER BY c.cid";
        $result = db_query($sql, "Transactions could not be calculated");
        $title = _("Class Balances");
        start_table(TABLESTYLE2, "width='$width%'");
        display_title($title);
        $i = 0;
        $total = 0;
        while ($myrow = db_fetch($result))
        {
            if ($myrow['ctype'] > 3)
            {
                $total += $myrow['total'];
                $myrow['total'] = -$myrow['total'];
                if ($pg != null)
                {
                    $pg->x[$i] = $myrow['class_name'];
                    $pg->y[$i] = abs($myrow['total']);
                }
                $i++;
            }
            label_row($myrow['class_name'], number_format2($myrow['total'], user_price_dec()),
                "class='label' style='font-weight:bold;'", "style='font-weight:bold;' align=right");
        }
        $calculated = _("Calculated Return");
        label_row("&nbsp;", "");
        label_row($calculated, number_format2(-$total, user_price_dec()),
            "class='label' style='font-weight:bold;'", "style='font-weight:bold;' align=right");
        if ($pg != null)
        {
            $pg->x[$i] = $calculated;
            $pg->y[$i] = -$total;
        }
        end_table(2);
    }

    function source_graphic($today, $title, $source, $pg, $type=2)
    {
        $pg->title     = $title;
        $pg->axis_x    = $source;
        $pg->axis_y    = _("Amount");
        $pg->graphic_1 = $today;
        $pg->type      = $type;
        $pg->skin      = 1;
        $pg->built_in  = false;
        $filename = company_path(). "/pdf_files/". uniqid("").".png";
        $pg->display($filename, true);
        start_table(TABLESTYLE);
        start_row();
        echo "<td>";
        echo "<img src='$filename' border='0' alt='$title'>";
        echo "</td>";
        end_row();
        end_table(1);
    }

    function customer_trans($today)
    {
        $today = date2sql($today);

        $sql = "SELECT trans.trans_no, trans.reference,    trans.tran_date, trans.due_date, debtor.debtor_no,
            debtor.name, branch.br_name, debtor.curr_code,
            (trans.ov_amount + trans.ov_gst + trans.ov_freight
                + trans.ov_freight_tax + trans.ov_discount)    AS total,
            (trans.ov_amount + trans.ov_gst + trans.ov_freight
                + trans.ov_freight_tax + trans.ov_discount - trans.alloc) AS remainder,
            DATEDIFF('$today', trans.due_date) AS days
            FROM ".TB_PREF."debtor_trans as trans, ".TB_PREF."debtors_master as debtor,
                ".TB_PREF."cust_branch as branch
            WHERE debtor.debtor_no = trans.debtor_no AND trans.branch_code = branch.branch_code
                AND trans.type = ".ST_SALESINVOICE." AND (trans.ov_amount + trans.ov_gst + trans.ov_freight
                + trans.ov_freight_tax + trans.ov_discount - trans.alloc) > ".FLOAT_COMP_DELTA."
                AND DATEDIFF('$today', trans.due_date) > 0 ORDER BY days DESC";
        $result = db_query($sql);
        $title = db_num_rows($result) . _(" overdue Sales Invoices");
        br(1);
        display_heading($title);
        br();
        $th = array("#", _("Ref."), _("Date"), _("Due Date"), _("Customer"), _("Branch"), _("Currency"),
            _("Total"), _("Remainder"),    _("Days"));
        start_table(TABLESTYLE);
        table_header($th);
        $k = 0; //row colour counter
        while ($myrow = db_fetch($result))
        {
            alt_table_row_color($k);
            label_cell(get_trans_view_str(ST_SALESINVOICE, $myrow["trans_no"]));
            label_cell($myrow['reference']);
            label_cell(sql2date($myrow['tran_date']));
            label_cell(sql2date($myrow['due_date']));
            $name = $myrow["debtor_no"]." ".$myrow["name"];
            label_cell($name);
            label_cell($myrow['br_name']);
            label_cell($myrow['curr_code']);
            amount_cell($myrow['total']);
            amount_cell($myrow['remainder']);
            label_cell($myrow['days'], "align='right'");
            end_row();
        }
        end_table(2);
    }

    function calculate_next_invoice($myrow)
    {
        if ($myrow["last_sent"] == '0000-00-00')
            $next = sql2date($myrow["begin"]);
        else
            $next = sql2date($myrow["last_sent"]);
        $next = add_months($next, $myrow['monthly']);
        $next = add_days($next, $myrow['days']);
        return add_days($next,-1);
    }

    function customer_recurrent_invoices($today)
    {
        $result = get_recurrent_invoices($today);
        $title = _("Overdue Recurrent Invoices");
        br(1);
        display_heading($title);
        br();
        $th = array(_("Description"), _("Template No"),_("Customer"),_("Branch")."/"._("Group"),_("Next invoice"));
        start_table(TABLESTYLE, "width=70%");
        table_header($th);
        $k = 0;
        while ($myrow = db_fetch($result))
        {
            if (!$myrow['overdue'])
                continue;
            alt_table_row_color($k);

            label_cell($myrow["description"]);
            label_cell(get_customer_trans_view_str(ST_SALESORDER, $myrow["order_no"]));
            if ($myrow["debtor_no"] == 0)
            {
                label_cell("");

                label_cell(get_sales_group_name($myrow["group_no"]));
            }
            else
            {
                label_cell(get_customer_name($myrow["debtor_no"]));
                label_cell(get_branch_name($myrow['group_no']));
            }
            label_cell(calculate_next_invoice($myrow),  "align='center'");
            end_row();
        }
        end_table(2);
    }

    function supplier_trans($today)
    {
        $today = date2sql($today);
        $sql = "SELECT trans.trans_no, trans.reference, trans.tran_date, trans.due_date, s.supplier_id,
            s.supp_name, s.curr_code,
            (trans.ov_amount + trans.ov_gst + trans.ov_discount) AS total,
            (trans.ov_amount + trans.ov_gst + trans.ov_discount - trans.alloc) AS remainder,
            DATEDIFF('$today', trans.due_date) AS days
            FROM ".TB_PREF."supp_trans as trans, ".TB_PREF."suppliers as s
            WHERE s.supplier_id = trans.supplier_id
                AND trans.type = ".ST_SUPPINVOICE." AND (ABS(trans.ov_amount + trans.ov_gst +
                    trans.ov_discount) - trans.alloc) > ".FLOAT_COMP_DELTA."
                AND DATEDIFF('$today', trans.due_date) > 0 ORDER BY days DESC";
        $result = db_query($sql);
        $title = db_num_rows($result) . _(" overdue Purchase Invoices");
        br(1);
        display_heading($title);
        br();
        $th = array("#", _("Ref."), _("Date"), _("Due Date"), _("Supplier"), _("Currency"), _("Total"),
            _("Remainder"),    _("Days"));
        start_table(TABLESTYLE);
        table_header($th);
        $k = 0; //row colour counter
        while ($myrow = db_fetch($result))
        {
            alt_table_row_color($k);
            label_cell(get_trans_view_str(ST_SUPPINVOICE, $myrow["trans_no"]));
            label_cell($myrow['reference']);
            label_cell(sql2date($myrow['tran_date']));
            label_cell(sql2date($myrow['due_date']));
            $name = $myrow["supplier_id"]." ".$myrow["supp_name"];
            label_cell($name);
            label_cell($myrow['curr_code']);
            amount_cell($myrow['total']);
            amount_cell($myrow['remainder']);
            label_cell($myrow['days'], "align='right'");
            end_row();
        }
        end_table(2);
    }

Get it updated in Repo also. Thanks alot

www.boxygen.pk

16 (edited by boxygen 11/01/2017 03:57:50 am)

Re: Dropdown theme showing error and not displaying custom modules

Line 153, 154 shall be replaced with this

elseif (!$_SESSION["wa_current_user"]->hide_inaccessible_menu_items())
echo "          <li><a href='#'><span><font color='gray'>$lnk[0]</font></span></a></li>\n";
www.boxygen.pk

Re: Dropdown theme showing error and not displaying custom modules

There is no need to check for !$no_menu again as we are already inside an if which has already done so.
Also, the add_access_extensions(); is placed between the two divs of class fa-body and fa-content like in the other themes. If done earlier, what happens was not determined. As it is an independent check, the earlier the better but it should have necessary pre-requisites to perform it's job. If we retain it as you suggested, we lose the graphic plot display in the dashboards.

Attached is the latest version.

What about the default dropdown theme in FA 2.4.x?
@joe: must some reconciliation be done between the two?

Post's attachments

dropdown.zip 96.4 kb, 1 downloads since 2017-11-01 

You don't have the permssions to download the attachments of this post.

Re: Dropdown theme showing error and not displaying custom modules

I haven't followed this discussion. I am very busy fixing php 7.X compabitily at present. We are there now so the next minor will contain php 7.X compability.

I have to study this closer about what shall be done.

/Joe

Re: Dropdown theme showing error and not displaying custom modules

The add_access_extensions() is missing in a few themes such as this and was causing missing security access permissions for extensions if they exist and such a theme was chosen. Since dropdown is a core theme it should work flawlessly regardless of whether any extension is loaded or not.

Re: Dropdown theme showing error and not displaying custom modules

I don't know what you guys have been doing. I hope we are talking about 2.4.

The official 'dropdown' theme is using the built-in dashboard.php from /admin folder.

I see no reference to this in your posts.

Please use the correct theme, and I will respond to this asap.

It is difficult for me to follow other builts and only misuse my time.

/Joe

Re: Dropdown theme showing error and not displaying custom modules

The dropdown theme is the one in the official repo for FA 2.4. Must it not match the one in the FA 2.4 repo too?

@boxygen: are you using the said theme in FA 2.3.x or in FA 2.4.x - the file path in the errors states fa24?

Re: Dropdown theme showing error and not displaying custom modules

There are three built-in themes in the core. Default, Canvas and Dropdown. I am referring to the official Dropdown that is shipped with release 2.4.2.

If we concentrate on this Dropdown. Are there any access problems, then please tell, and I will try to fix this asap.

/Joe

Re: Dropdown theme showing error and not displaying custom modules

@joe: Please remove the dropdown theme from the official PKG repo as this is the one that is causing all the issues.

Was it left behind to help those migrating by merely overwiting files with the ones from FA 2.4.x? Then it it would be a veritable nightmare with all kinds of files that may get accidentally auto included and executed inadvertently.

If it must be there, then synch it with the one that is shipped with FA 2.4.2. Then the default and canvas themes too can find a place in it.

It is best to remove all themes that will not work with FA 2.4.x. The fact that the existing official PKG had the version number as 2.4.0-2 and also stated so inside it's renderer.php file is what confused me. In fact I thought it was an improved version of the one that shipped with FA 2.4.2 which doesn't appear to have been updated in quite a while - the last time it was modified was on 2015-12-24.

I have removed it from the FA24extensions repo since it is in the AF 2.4 core - otherwise, updating it will be redundant here.

@boxygen: add_access_extensions() is executed in FA 2.4 in index,php, admin/security_roles.php and is defined in include/access_levels.inc. If the themes are a legacy carryover from FA 2.3.x, then they will be present for now and may be used with care. These themes are: bluecollar, dashboard_theme, dynamic, exclusive, exclusive_db.

Re: Dropdown theme showing error and not displaying custom modules

I see no problem with the theme, Dropdown, if you are using the right one that ships with FA 2.4.2.

This is, and has been, included in core since 2.4.1.

And please don't use unofficial themes in this forum, but instead use the module forum for those.

It will only confuse people if we try to make unofficial themes the right ones.

/Joe

Re: Dropdown theme showing error and not displaying custom modules

The theme that is discussed here is from the Official PKG repo.