Jump to content


  • Content Count

  • Joined

  • Last visited

  • Days Won


adrian last won the day on June 23

adrian had the most liked content!

Community Reputation

11,649 Excellent

About adrian

  • Rank
    Hero Member

Profile Information

  • Gender
    Not Telling
  • Location

Recent Profile Visitors

31,256 profile views
  1. @creativejay - sorry about that - I left a bd() debug call behind by accident. I have updated it to remove this.
  2. @teppo and @bernhard - new version attached. This lets you add module settings for your custom panels to Tracy's settings - you can add something like this to your panel class: public function addSettings() { $fieldset = $this->wire('modules')->get("InputfieldFieldset"); $fieldset->attr('name+id', 'testThirdPartyModuleSettings'); $fieldset->label = $this->_x('Test Third Party Module Settings', __FILE__); $f = $this->wire('modules')->get("InputfieldCheckbox"); $f->attr('name', 'testThirdPartyModule_myCheckbox'); $f->label = $this->_x('My Checkbox', __FILE__); $f->attr('checked', \TracyDebugger::getDataValue('testThirdPartyModule_myCheckbox') == '1' ? 'checked' : ''); $fieldset->add($f); return $fieldset; } The name of the field can be whatever you want, but I think you should prefix it with the class of the panel, eg: testThirdPartyModule_myCheckbox to avoid any conflicts with core settings. What do you guys think of this? Do you think there is a better way to implement? Would you rather store any needed settings in your module's settings instead? Also, please note the name+id attribute in the fieldset - the value entered here should match the last parameter in the generatePanelFooter() method in your panel code. This links the cog icon at the bottom of your panel to the anchor link in Tracy's module settings. TracyDebugger.module.php
  3. It's just a way for other ProcessWire modules to add their own panels to Tracy's debug bar. The custom panel can display all sorts of relevant debug info, just like the core panels included with Tracy. Really it's up to module authors what they think would be useful info to display. I am also just working on the ability for these external module panels being able to inject settings into Tracy's main module settings so that users can customize the panel.
  4. @bernhard - not sure what to say. If you have a file called TestThirdPartModule.php and that file contains a class named "TestThirdPartyModulePanel" then it should work fine. Note that you can name the file and class whatever you want, so long as the class is the same as the file with the "Panel" suffix.
  5. I have made this change and committed it to the repo. Please let me know how it goes for you.
  6. Thanks @thausmann for those fixes and improvements - I've made a couple of small tweaks: 1) the title subfield is automatically selected now so that users don't need to do anything when exporting to get each column automatically added. 2) I added support for pageAutocompleteMultiple New version is committed to the repo and updated in the modules directory.
  7. Hi @helin, Sorry for the late response. This has annoyed me for a long time and while it might seem like an easy fix, it has eluded me several times. I have put in another concerted effort and I think I have a working solution, but it would be great if you could test before I commit to the repo. Please try the attached file and let me know. It should work regardless of whether you have the "Rename on Save" option checked, but please note that if you upload a replacement file for a single image field (max allowed 1 file), then the -1 will be appended until you save the page - this is simply because the other image still exists until you save the page, so the filename must be adjusted, but it should now be removed if there are no other conflicting filenames. ProcessCustomUploadNames.module.php
  8. @teppo and @bernhard Please try the attached main module file. With this version, you can simply add your panel to your module directory structure eg: /site/modules/TestModule/TracyPanels/TestThirdPartyModule.php Make sure the class name of the panel in this example is: TestThirdPartyModulePanel That should be all you need. Not super well tested so let me know if you find any problems or have any suggestions. If everything looks good, I'll commit the changes to the repo. TracyDebugger.module.php
  9. Hi @thausmann - when exporting a table with a page reference field, it should export the title of the selected page(s), and not the ID so I am maybe confused about what you are seeing. The option to export a field from the referenced page would be great for sure. The way I'd envision this working would be for the "Columns / Order to Export" selection to work like Lister does with its ASM parents functionality where you select a parent and then get to select subfields, but I am rushed for time, so for the moment, I've just made it possible to select them as separate top-level items. Please try the not-well-tested version attached. Please feel free to make improvements. TableCsvImportExport.zip
  10. I think it's probably good idea, but this is a request for @Pete and @ryan
  11. Hi @teppo - I'd love to make it easier to support custom panels. It's interesting about the $allPanels array - it really wouldn't be necessary except for the title vs the name, eg "phpInfo" to "PHP Info". In most cases it would be easy to programmatically convert the case, except for those with acronyms (PHP, API, etc). I think you are probably correct that hooks might be problematic because Tracy is always loaded before all other modules. Perhaps module authors who want to add new Tracy panels could simply provide me with the path and panel class name and I can have Tracy check the location if the module is installed. Perhaps as simple as adding a new $externalPanels array that is added to as needed? This array could be merged into the $allPanels array which would probably need to be made multidimensional to support separate title and path properties so that https://github.com/adrianbj/TracyDebugger/blob/cc1c17e50487580f5c1e3485411d7c9a766b0a4f/TracyDebugger.module.php#L1526 would know what path to use to load these external panels. Anyway, I'll have a play around and see what I think will work best and send you a test version to work with.
  12. Yeah, I know it's coming, but it's still often not that great of an improvement in size, whereas AVIF looks like it will be significant.
  13. Thanks Horst - been following this a little lately - definitely keen because WebP just doesn't seem worth the effort given the often limited size reduction and lack of Safari support.
  14. That's not actually Tracy - that is the PW core: https://github.com/processwire/processwire/blob/b429de71e33066f611b0bf6e2cc3782b7e5dafa3/wire/core/WireShutdown.php#L281-L286
  15. @psy - I am not certain at this stage, but see this comment and the two before it: https://processwire.com/talk/topic/12208-tracy-debugger/page/76/?tab=comments#comment-178165 Seems like it wasn't due to Tracy in that case - any chance it might actually be something else for you too?
  • Create New...