Jump to content

Jens Martsch - dotnetic

Members
  • Content Count

    722
  • Joined

  • Last visited

  • Days Won

    7

Jens Martsch - dotnetic last won the day on December 2 2019

Jens Martsch - dotnetic had the most liked content!

Community Reputation

760 Excellent

About Jens Martsch - dotnetic

  • Rank
    Superhero

Contact Methods

  • Website URL
    http://www.jensmartsch.de
  • Skype
    jens.martsch

Profile Information

  • Gender
    Male
  • Location
    Münster, Germany

Recent Profile Visitors

7,304 profile views
  1. Hey @gerritvanaaken, did you come up with a solution yet? I want to accomplish exactly the same, and this is how I implemented it: It's a Page Reference field, displayed as checkboxes. Now I try to use a similar code like @MoritzLost posted above, in my Smarty template.
  2. Yes it is good and in use on the site https://www.p-jentschura.com/ I added this directly in the HTML so it has nothing to do with ProcessWire in general, but I am thinking about developing a module for it to set the options. But thats only for the far future and next website project.
  3. It would also be nice, if I could add panels as an array of arrays (or objects) like $panels->add([ [ 'panel' => 'number', 'title' => 'Neue Seiten', 'data' => [ 'number' => 484, 'detail' => '100 mehr als im vorigen Monat', 'trend' => 'up', ] ], [ 'panel' => 'page-list', 'title' => 'zuletzt bearbeitete Seiten', 'data' => [ 'collection' => 'template=basic-page, limit=10', 'sortable' => true, ], ] ]); Right now, it seems, that I have to use $panels->add for every single panel, is that correct?
  4. Anyways, this is a really nice module. Thank you for releasing it.
  5. It would also be nice, if you provide a complete copy and paste solution for the admin.php, so one could directly see a working example. This requires of course to install all submodules.
  6. I found the solution, I have to include the hook before the require in admin.php
  7. I just installed the latest release from github and get the same "Your dashboard is empty" error as zoeck I have not installed multilanguage and it is a fresh install of the latest ProcessWire 1.0.148 To site/template/admin.php I added after the require $config->paths->adminTemplates . 'controller.php'; wire()->addHookAfter('Dashboard::getPanels', function ($event) { /* Get list of panels */ $panels = $event->return; /* Add panels */ $panels->add([ 'panel' => 'collection', 'title' => 'News items', 'data' => [ 'collection' => 'template=basic-page, limit=10', 'sortable' => true, ], ]); }); but the "Your dashboard is empty" message still appears. I did not set the dashboard as the entry point.
  8. 1: I don't know the answer to this, maybe the icon appears if you enable trash for non-superusers (see point 3) 2: Take a look at 3 3: Please take https://processwire.com/blog/posts/processwire-3.0.107-core-updates/#trash-for-all
  9. Hey guys I wanted to share this little snippet with you, which can be run as a .bat file, and backups all of your databases into a separate file: K:\laragon\bin\mysql\mysql-5.7.19-winx64\bin\mysql.exe -uroot -s -N -e "SHOW DATABASES" | for /F "usebackq" %%D in (`findstr /V "information_schema performance_schema"`) do K:\laragon\bin\mysql\mysql-5.7.19-winx64\bin\mysqldump.exe %%D -uroot > P:\htdocs\database-backups\%%D.sql of course you have to change the paths to your mysql/mysqldump.exe files and the destination directory, and the username, if you have to provide another than root. This task can be executed daily via task scheduling in Windows.
  10. @teppo for front-end uploads you could also take a look at this example which utilizes TusPHP (resumable uploads) and Uppy (a nice uploader widget)
  11. Note for PHPStorm users: In my case the AutoTemplateStubs directory was automatically marked as excluded (don't know from which setting this comes from) and I had to mark the directory as "not excluded" to make autocompletition work.
  12. If you don't need to support old browsers like IE, than it is also better to use "let" to define javascript variables.
  13. As the content of the panel is a totally different document (Iframe), than in the opening document your function has to be modified. $('.DeleteDiscountButton').on('click', function(e) { e.preventDefault(); var a_href = $(this).attr('href'); ProcessWire.confirm( discountActionStrings.confirm_delete_discount, function() { // dialogue OK click window.parent.document.location.href = a_href; } ); }); The key is using window.parent.document, which refers to the document that opened the panel.
  14. I would go with Smarty or Twig. Used both. Smarty allows to use PHP functions in it's template strings, Twig does not (only with custom extensions), and Twig throws errors if something is not programmed 100% clean. That nagged me about it, also disliked the double delimiters. In terms of speed Twig and Smarty are almost even, sometimes Smarty is quicker, sometimes Twig.
  15. I can only repeat what @bernhard said. For me the admin area is outdated and does not feel fast enough. However you are free to create an own custom admin area (not only theme, but you could do it as a vuejs application). One bottleneck is the PageFinder which is very slow compared to Laravel or RockFinder, as it fetches many relations for each page. RockTabulator in conjunction with RockFinder is better for some sort of listings than ListerPro but requires more initial work, and has not all the filter possibilities that ListerPro has. I think ListerPro would be a good match for you. I built some applications where I use both RockTabulator AND ListerPro, for different tasks/views. One disadvantage of ListerPro is, that you can't use it on custom module pages, but you can do it with RockTabulator. One superior feature of the PW admin is the conditional dependency of fields (show field only if value x is in another field), which I haven't seen in other tools yet, or not yet to that extend. Regarding your original question: It is possible with PW, and it might be the perfect fit for this type of application, but only if you use the right tools/modules. Else I would look into Laravel in conjunction with AdminLTE or Laravel Nova, but thats just my preference.
×
×
  • Create New...