Dashboard for Nextcloud by flost and Holger (was: Anyone in for an Overview / Dashboard / Start page app?)

@Holger_Dehnhardt new app store api is usable, we are currently working on the web interface. If anyone is interested in testing or helping out (Python, Django), feel free to ask questions on IRC or the issue tracker.

Docs are available on https://nextcloudappstore.readthedocs.io/en/latest/ btw

ncdev is not yet pushed to pypi but should probably work (I guess :P) if you install it from the repo. README is a bit outdated. Otherwise just use curl.

Production Web server config is still not ready, we are currently using apache instead of Nginx. If anyone is familiar with nginx feel free to help us out.

Thank you Bernhard, but the app store seems to me like “step two”. I first need to upload the code to an (git) repository.

Well technically you just need to upload the archive somewhere :slight_smile:

But yes, you need to write the code first ;D

True, but if I understand you correctly, you are indeed willing to to start working on the app to make it compatible with NC 9+. That’ll be brilliant news indeed.As the author of the dashboard app is looking for a maintainer, why not creating a new git repo for it, fork the app there and get in touch with flost. He even left his contact details for willing maintainers to get in touch: flost-dev(at]mailbox{dot}org
John

I created a git repo at: GitHub - dehnhardt/nc_dashboard: Dashboard for Nextcloud - based on Work from Florian Steffens.
I have found some more problems with L10N which are already fixed in the repository. When you check out the master branch (and copy the subdirectory dashboard to the apps folder) it should work.

3 Likes

Cool, thx heaps.

Much to my regret it doesn’t work for me


Downloaded zip from git, uploaded and extracted into apps. Modified info.xml.
For name ocDashboard I can activate the app with no result: reloading the page switches “deactivate” back to “activate” option

For name “dashboard” NC stops working throwing up an internal server error:

Interner Serverfehler
Der Server hat einen internen Fehler und konnte Ihre Anfrage nicht vervollstÀndigen.
Bitte wende Dich an den Serveradministrator, sollte dieser Fehler mehrfach auftreten, und fĂŒge Deiner Anfrage die unten stehenden technischen Details bei.
Weitere Details können im Serverprotokoll gefunden werden.

Technische Details
Entfernte Adresse: 79.xxx.xxx.xx
Anforderungskennung: dhghfjdejhfguikz6rgg

This looks like github is packimg the zip without corrections, as this is the behaviour I had before fixing. I’m completely new to git and github!
I Will try an fresh install tonight and report my findings here


2 Likes

Cool! thanks for bothering!!

@John
I have set up a complete new development nextcloud and installed the dashboard:
There is no problem with the git repository. All fixes are in the zip (I now added the max version tag to the info.xml as well.) - but there was something I had added manually to the database which I forgot to mention; There is some kínd of broken group filter. Broken, because there is a group selection in the admin panel, but the values are not stored - so I added them directly. Something to investigate later


I have bypassed the filter now, so no need for you to modify the database - but this problem only lead to an empty widget selection screen abd not to the symptom you described.
Could it be that you copied the whole directory to your apps folder? You should only copy the dashboard subdirectory!

So please download a new zip, copy the subdirectory ‘dashboard’ to the apps folder and try to enable it.
If it still does not work, please enable the debug log and try to send some relevant information:-)

All the best
Holger

To proof my words;-)

I’ll try that tommorrow. Thanks for taking the time to doublecheck. One more thing that came to mind: can it be an issue due to me using PHP 7?

Main thing is: it DOES work. So if all else fails, I can still do a fresh installation next week and start from scratch 
WITH a dashboard :smiley:

THanks for your work and dedication: keep going! :wink:

One more thing that came to mind: can it be an issue due to me using PHP 7?

Hard to say as I’m still using PHP5

Ok, I’ll make sure to check that as well then. :+1:

Just for the record: the error remains as described: with a name other than “dashboard” NC runs but the app cannot be activated. With a name of “dashboard” NC stops working throwing up an Internal Server Error.

Edit: No matter whether I try this with PHP 7 or PHP 5.6 installed: behaviour remains the same in both cases.

The log throws up an Error as well:

Error     index     Exception: {"Exception":"Doctrine\\DBAL\\Exception\\TableNotFoundException","Message":"An exception occurred while executing 'SELECT count(id) as counter FROM `oc_dashboard_widgets` WHERE `wid` LIKE ?' with params [\"dummy\"]:\n\nSQLSTATE[42S02]: Base table or view not found: 1146 Table 'd02274a1.oc_dashboard_widgets' doesn't exist","Code":0,"Trace":"#0 \/www\/htdocs\/user\/nc\/3rdparty\/doctrine\/dbal\/lib\/Doctrine\/DBAL\/DBALException.php(116): Doctrine\\DBAL\\Driver\\AbstractMySQLDriver->convertException('An exception oc...', Object(Doctrine\\DBAL\\Driver\\PDOException))\n#1 \/www\/htdocs\/user\/nc\/3rdparty\/doctrine\/dbal\/lib\/Doctrine\/DBAL\/Statement.php(175): Doctrine\\DBAL\\DBALException::driverExceptionDuringQuery(Object(Doctrine\\DBAL\\Driver\\PDOMySql\\Driver), Object(Doctrine\\DBAL\\Driver\\PDOException), 'SELECT count(id...', Array)\n#2 \/www\/htdocs\/user\/nc\/lib\/private\/db\/statementwrapper.php(73): Doctrine\\DBAL\\Statement->execute(Array)\n#3 \/www\/htdocs\/user\/nc\/apps\/dashboard\/db\/widgetsdao.php(56): OC_DB_StatementWrapper->execute(Array)\n#4 \/www\/htdocs\/user\/nc\/apps\/dashboard\/services\/widgetmanagementservice.php(138): OCA\\Dashboard\\Db\\WidgetsDAO->insertIfNotExist('dummy', 'dashboard', 'widgetDummyCont...', 'widgetDummyTemp...', '', Array, Array)\n#5 \/www\/htdocs\/user\/nc\/apps\/dashboard\/api\/api_1_0.php(42): OCA\\Dashboard\\Services\\WidgetManagementService->addWidget('dummy', 'dashboard', 'widgetDummyCont...', 'widgetDummyTemp...', '', Array, Array)\n#6 \/www\/htdocs\/user\/nc\/apps\/dashboard\/appinfo\/app.php(126): OCA\\Dashboard\\Api\\Api_1_0->addWidget(Array)\n#7 \/www\/htdocs\/user\/nc\/lib\/private\/app.php(163): require_once('\/www\/htdocs\/w00...')\n#8 \/www\/htdocs\/user\/nc\/lib\/private\/app.php(144): OC_App::requireAppFile('dashboard')\n#9 \/www\/htdocs\/user\/nc\/lib\/private\/app.php(117): OC_App::loadApp('dashboard')\n#10 \/www\/htdocs\/user\/nc\/lib\/base.php(946): OC_App::loadApps()\n#11 \/www\/htdocs\/user\/nc\/index.php(39): OC::handleRequest()\n#12 {main}","File":"\/www\/htdocs\/user\/nc\/3rdparty\/doctrine\/dbal\/lib\/Doctrine\/DBAL\/Driver\/AbstractMySQLDriver.php","Line":53} 

But as I said: JUST FOR THE RECORD.

I’ll set up another instance of NC now. Given the update script does not work either for me, chances are that my installation is simply screwed. To make sure, let me test this on a fresh installation before taking any measures :wink:

Thanks!

Ok then
 did a fresh installation of 9.0.52 using my old config and database.
NC runs fine.
Naming the app dashboard at least keeps NC running. No more “Internal Server Error” but I still cannot activate it. Now an error msg pops up telling me:

Error: this app cannot be enabled because it makes the server unstable

(Yes, experimental apps have been activated.)
Database is missing the oc_dashboard_* tables
Log throws up the exact same error msg I posted above.
Tried PHP 5.6 and 7 again. Both to no avail.

I may need to test it with setting up a new DB as well, but for the time being I’m reluctant to do so due to some mother testruns I want to do first.

So much for now :slight_smile:

Why do you have to name the app at all - and where do you name the app. It was not necessary when I did a fresh install.

BTW: From the error message: "‘d02274a1.oc_dashboard_widgets’ doesn’t exist"
Is d02274a1 your database name - sounds a littlebit weird to me.

I didn’t, the app I tried on 9052 always was called “dashboard” but as it caused problems earlier, which I could only get rid off by renaming the app in order to make NC accessible again I thought I’d mention it anyway.

I upload nc_dashboard_master.tar.gz to /nc/apps/ extract it to /nc/apps/nc_dashboard_master/dashboard and then copy dashboard to /nc/apps/ so the path to dashboard is:
/nc/apps/dashboard

Yes, d02274a1 is the db name.

I don’t have to install app_framework, have I?

@groovy, @Bugsbane or @BernhardPosselt : Is someone of you willing to test the git version as well. Maybe we can collect some more information.

No, no need for app framework afaik. (remember, this stuff is new for me as well
:wink:
All in all it looks like the tables were not created at first activation. (Have you checked it on the database - it might be that the table is there but with no rows. The query explicit asks for a row with wid ‘dummy’ )
But shouldn’t be there errors when initialization fails?!?
I’m running Postgres here, maybe I should test with MySQL as well.

I am very well aware that all this is new to you and I didn’t mean to build up any pressure. Quite the contrary really: I am super grateful you started this venture although you are not feeling to comfy with it yet. So thanks again :slight_smile: and sorry if I came across demanding or assuming. This was not at all intended.

Yes the tables are not created as mentioned earlier: as to WHY is still beyond me. Right now I try to figure out how to create them manually, but as of yet I failed to find an SQL file or any documentation on how to setup the the tables.

John