AdminOverview plugin


(Παναγιώτης) #1

Hallo,
I have installed the AdminOverview plugin and I get the following error:


There is an error. Please report the message and full backtrace in the Piwik forums.
Notice: Undefined index: view in ????????????\tmp\templates_c\%%8E^8E9^8E99ABE8%%AdminOverview.tpl.php on line 76
Backtrace -->
#0 Piwik_ErrorHandler(8,
Undefined index: view,
????????????\tmp\templates_c\%%8E^8E9^8E99ABE8%%AdminOverview.tpl.php,76,
Array ([resource_name] => ????????????\plugins\AdminOverview/templates/AdminOverview.tpl,
[cache_id] => ,
[compile_id] => ,
[display] => ,
[_cache_info] => Array (),
[_smarty_old_error_level] => 30719,
[this] => Piwik_Smarty Object ([template_dir] => Array ([0] => ????????????/plugins,
[1] => ????????????/themes/default,
[2] => ????????????/themes),
[compile_dir] => ????????????/tmp/templates_c,
[config_dir] => configs,
[plugins_dir] => Array ([0] => ????????????/core/SmartyPlugins,
[1] => ????????????/libs/Smarty/plugins),
[debugging] => ,
[error_reporting] => 30719,
[debug_tpl] => ,
[debugging_ctrl] => NONE,
[compile_check] => 1,
[force_compile] => ,
[caching] => 0,
[cache_dir] => ????????????/tmp/cache,
[cache_lifetime] => 3600,
[cache_modified_check] => ,
[php_handling] => 0,
[security] => ,
[secure_dir] => Array (),
[security_setti...<span id="languageSelection" style="display:none;position:absolute"><form action="index.php?module=LanguagesManager&action=saveLanguage" method="get"><select name="language"><option value="el">Ελληνικά</option><option href='?module=Proxy&action=redirect&url=http://piwik.org/translations/'>Πληροφόρηση</option><option value="am" title="???? (Amharic)">????</option><option value="ar" title="??????? (Arabic)">???????</option><option value="be" title="?????????? (Belarusian)">??????????</option><option value="bg" title="????????? (Bulgarian)">?????????</option><option value="ca" title="Catala (Catalan)">Catala</option><option value="cs" title="Cesky (Czech)">Cesky</option><option value="da" title="Dansk (Danish)">Dansk</option><option value="de" title="Deutsch (German)">Deutsch</option><option value="el" title="Ελληνικά (Hellenic)">Ελληνικά</option><option value="en" title="English (English)">English</option><option value="es" title="Espanol (Spanish)">Espanol</option><option value="et" title="Eesti keel (Estonian)">Eesti keel</option><option value="eu" title="Euskara (Basque)">Euskara</option><option value="fi" title="Suomi (Finnish)">Suomi</option><option value="fr" title="Francais (French)">Francais</option><option value="gl" title="Galego (Galician)">Galego</option><option value="he" title="????? (Hebrew)">?????</option><option value="hu" title="Magyar (Hungarian)">Magyar</option><option value="id" title="Bahasa Indonesia (Indonesian)">Bahasa Indonesia</option><option value="is" title="Islenska (Icelandic)">Islenska</option><option value="it" title="Italiano (Italian)">Italiano</option><option value="ja" title="??? (Japanese)">???</option><option value="ka" title="??????? (Georgian)">???????</option><option value="ko" title="??? (Korean)">???</option><option value="lt" title="Lietuviu (Lithuanian)">Lietuviu</option><option value="nb" title="Norsk (bokmal) (Norwegian Bokmal)">Norsk (bokmal)</option><option value="nl" title="Nederlands (Dutch)">Nederlands</option><option value="nn" title="Nynorsk (Norwegian Nynorsk)">Nynorsk</option><option value="pl" title="Polski (Polish)">Polski</option><option value="pt-br" title="Portugues brasileiro (Brazilian Portuguese)">Portugues brasileiro</option><option value="pt" title="Portugues (Portuguese)">Portugues</option><option value="ro" title="Romana (Romanian)">Romana</option><option value="ru" title="??????? (Russian)">???????</option><option value="sk" title="Slovensky (Slovak)">Slovensky</option><option value="sq" title="Shqip (Albanian)">Shqip</option><option value="sr" title="Srpski (Serbian)">Srpski</option><option value="sv" title="Svenska (Swedish)">Svenska</option><option value="te" title="?????? (Telugu)">??????</option><option value="th" title="??????? (Thai)">???????</option><option value="tr" title="Turkce (Turkish)">Turkce</option><option value="uk" title="?????????? (Ukrainian)">??????????</option><option value="zh-cn" title="???? (Simplified Chinese)">????</option><option value="zh-tw" title="???? (Traditional Chinese (Taiwan))">????</option></select><input type="submit" value="go" /></form></span><script type="text/javascript"> piwik.languageName = "Ελληνικά"; $(document).ready(function() { $("#languageSelection").fdd2div({CssClassName:"formDiv"}); $("#languageSelection").show(); $("#languageSelection ul").hide(); });</script></span>,
[_order] => 30,
[_hasSubmenu] => )),
[currentAdminMenuName] => AdminOverview_MenuOverview,
[debugTrackVisitsInsidePiwikUI] => 0,
[isSuperUser] => 1,
[menu] => Array ([AdminOverview_MenuOverview] => Array ([_url] => Array ([module] => AdminOverview,
[action] => index),
[_order] => 0,
[_hasSubmenu] => ),
[UsersManager_MenuUserSettings] => Array ([_url] => Array ([module] => UsersManager,
[action] => userSettings),
[_order] => 1,
[_hasSubmenu] => ),
[UsersManager_MenuUsers] => Array ([_url] => Array ([module] => UsersManager,
[action] => index),
[_order] => 3,
[_hasSubmenu] => ),
[SitesManager_MenuSites] => Array ([_url] => Array ([module] => SitesManager,
[action] => index),
[_order] => 5,
[_hasSubmenu] => ),
[CoreAdminHome_MenuGeneralSettings] => Array ([_url] => Array ([module] => CoreAdminHome,
[action] => generalSettings),
[_order] => 6,
[_hasSubmenu] => ),
[CorePluginsAdmin_MenuPlugins] => Array ([_url] => Array ([module] => CorePluginsAdmin,
[action] => index),
[_order] => 7,
[_hasSubmenu] => ),
[DBSta...#1 include(????????????\tmp\templates_c\%%8E^8E9^8E99ABE8%%AdminOverview.tpl.php) called at [????????????\libs\Smarty\Smarty.class.php:1263]#2 Smarty->fetch(????????????\plugins\AdminOverview/templates/AdminOverview.tpl) called at [????????????\core\View.php:172]#3 Piwik_View->render() called at [????????????\plugins\AdminOverview\Controller.php:30]#4 Piwik_AdminOverview_Controller->index()#5 call_user_func_array(Array ([0] => Piwik_AdminOverview_Controller Object ([] => AdminOverview,
[] => 2011-03-10,
[] => Piwik_Date Object ([] => 1299757659,
[] => UTC),
[] => 1,
[] => Piwik_Site Object ([] => 1)),
[1] => index),

Array ()) called at [????????????\core\FrontController.php:125]#6 Piwik_FrontController->dispatch() called at [????????????\index.php:57]

Does anyone know how to solve it?
:slight_smile:


(syaz) #2

Hi, my guess is at line 54 of AdminOverview.tpl where I call the $user.view. It’s complaining that $user[‘view’] is undefined, which is weird. Try commenting out that line and see if it loads. I can’t reproduce this. How many users do you have and are there any with 0 view access? More info would really help.

It’s not fatal and just a notice though.

If anyone want to help with debugging, the $users is first assigned in API.php: getAccessCountByLogin().

ps: Do request any features you think is neat to have in the plugin.


(Παναγιώτης) #3

Hallo,

[quote=syaz]
Hi, my guess is at line 54 of AdminOverview.tpl where I call the $user.view. It’s complaining that $user[‘view’] is undefined, which is weird. Try commenting out that line and see if it loads.[/quote]
The plugin does load but when I click on the Overview tab I get this error in the cells of the admin sites column and after the second user. See the attached file to check how it looks like.

I have in total 3 users besides root and anonymous. Only Anonymous has 0 view access.
One comment is it possible not to count the anonymous user.
For any feedback I will let you know.
:slight_smile:


(Παναγιώτης) #4

I forgot to mention that I have translate the plugin in Greek.
I can send you the file if you want it!
:wink:


(syaz) #5

Sure, I always welcome help. Just attach the file on the Trac page and I will update the main .zip.

Regarding your error – it is very weird indeed. To be honest I have no clue as I also can’t reproduce it. Does it happen for just that particular user, or seemingly random?

Just FYI, you can click any rows to view what that user has access to.


(Παναγιώτης) #6

I tried to connect as a different user and the behavior was different.
I got this message on top of the page:


There is an error. Please report the message and full backtrace in the Piwik forums.

Notice: Undefined variable: usersAccess in 
?????\plugins\AdminOverview\Controller.php on line 25

Backtrace -->
#0 Piwik_ErrorHandler(8, Undefined variable: usersAccess,
?????\plugins\AdminOverview\Controller.php, 25, Array ([view] =>
Piwik_View Object([] => ?????\plugins\AdminOverview/templates/AdminOverview.tpl,[]
=> Piwik_Smarty Object ([template_dir] => Array ([0] => ?????/plugins,[1] =>
?????/themes/default,[2] => ?????/themes),[compile_dir] => ?????/tmp/templates_c,[config_dir]
=> configs,[plugins_dir] => Array ([0] =>?????/core/SmartyPlugins,[1] =>
?????/libs/Smarty/plugins),[debugging] => ,[error_reporting] => 30719,[debug_tpl] =>
,[debugging_ctrl] => NONE,[compile_check] => 1,[force_compile] => ,[caching] =>
0,[cache_dir] => ?????/tmp/cache,[cache_lifetime] => 3600,[cache_modified_check] =>
,[php_handling] => 0,[security] => ,[secure_dir] => Array (),[security_settings] =>
Array ([PHP_HANDLING] => ,[IF_FUNCS] => Array ([0] => array,[1] => list,[2] =>
isset,[3] => empty...#1 Piwik_AdminOverview_Controller->index()#2
call_user_func_array(Array ([0] => Piwik_AdminOverview_Controller Object ([] => 
AdminOverview,[] => 2011-03-15,[] => Piwik_Date Object ([] => 1300188340,[] => UTC),
[] => 1,[] => Piwik_Site Object ([] => 1)),[1] => index), Array ()) called at
[?????\core\FrontController.php:125]#3 Piwik_FrontController->dispatch() called at
[?????\index.php:57]

and no user appeared on the table just the head of it.
Each row, even if it looks that it is a row, it does not work.
I attached the file in the trac.
:slight_smile: