Jump to content

gebeer

Members
  • Posts

    1,383
  • Joined

  • Last visited

  • Days Won

    39

Everything posted by gebeer

  1. Maybe you want to take a look at https://processwire.com/modules/fieldtype-page-table-extended/ That module hasn't been updated in a while but should have code that can point you in the right direction.
  2. Glad you found it and thanks for the tips for windows users. There is a dedicated forum thread with tips & tricks:
  3. Code here: and here: might be helpful. This implementation is working for me on several projects.
  4. Thanks a lot for your help with testing. I also added the snippet and will have an eye on this for a while.
  5. I see. This problem is quite hard to debug because it is not 100% reproducable. For me it is happening only sporadicly and I didn't see it in quite a while now. Would you like to try and put that missing snippet in the createField method and see if the problem goas away?
  6. Thanks for spotting this. Did you try this and will it return the correct field type? If so, could you please make a PR? Thank you.
  7. What does the error say? Have you turned on debug mode, are you using tracy debugger? Have you lookes in the error logs?
  8. Although I agree on most of what you are saying, I still respect other people's views on the subject. I know this is a subject where people have very strong opinions. Since this is a programming related forum, I would like to keep those discussions out of this thread as to not pollute it. Maybe something for the beergarden?
  9. EDIT: which version of RockPdf are you using, free or new commercial (https://www.baumrock.com/en/processwire/modules/rockpdf/)? What is the error message your getting? Not sure you can invoke a new instance of \Mpdf\Config\FontVariables() and then use the getDefaults() method right away. In the mpdf docs they do it like $defaultConfig = (new Mpdf\Config\ConfigVariables())->getDefaults(); $fontDirs = $defaultConfig['fontDir']; $defaultFontConfig = (new Mpdf\Config\FontVariables())->getDefaults(); $fontData = $defaultFontConfig['fontdata']; $mpdf = new \Mpdf\Mpdf([ 'fontDir' => array_merge($fontDirs, [ __DIR__ . '/custom/font/directory', ]), 'fontdata' => $fontData + [ // lowercase letters only in font key 'frutiger' => [ 'R' => 'Frutiger-Normal.ttf', 'I' => 'FrutigerObl-Normal.ttf', ] ], 'default_font' => 'frutiger' ]);
  10. Although I disagree with most of your views and opinions I want to thank you for sharing them. Good to have a diverse community.
  11. Thank you for bringing this to my attention. Sorry to hear you're having trouble. This module hasn't been maintained for a long time. It definitely could need some love and care. Just a few days ago this came to my mind oout of the blue. I'm quite busy atm but hope that I can spare some time and look into this. But it may take another week or so.
  12. Good to hear @bernhard, that you like Cursor so far. Over the course of the last year, with all that AI hype going on, I have tried several AI assistants integrated into VsCode through extensions. Copilot, Codeium, Cody, Tabby, to name the major ones. Now about 10 days ago I stumbled across Cursor and have worked with it since. Guess, I'm a bit late to the party, seeing how well it is anticipated in the Dev community. Cursor is integrating AI, more specifically OpenAIs GPTs, exceptionally well into the IDE. It is available when you need it, but doesn't get into your way. The UX is extremely good, in my opinion. What makes it really stand out from other solution, is the ability to build indices of your code base and give them as meaningful context to the AI. While other tools can also do this, the process of indexing and referencing the index is very efficient in Cursor. This is great for onboarding to new code bases. Cursor indexes the code and you can ask questions and, in most cases, it will be spot on with it's answers. So you very quickly find your way to the relevant parts of the code for the task at hand. The killer feature that I like the most and that I have not seen in any of the other tools is called Docs. With a simple command '@Docs' you point Cursor to a URL, let's say https://processwire.com/blog/posts/pw-3.0.173/ (URL Hooks documentation) and it will create a vector based index of those docs in the background. You give these docs a custom name, pwUrlHooks. Now you can reference them inside your instructions to the assistant with @pwUrlHooks. This drastically reduces hallucinations and produces very good code suggestions in most cases. I's really fun to watch the AI writing code for you that you can actually use. Cursor itself is free. But you only get like 50 requests a month for free. If you need more, they ask 20$/month. But you can also use your OpenAI API key to have unlimited requests. Then you pay OpenAI, of course. But at least you have the choice. And 20 bucks a month isn't that much after all for the time that this can save you. I'm not affiliated with them in any way. Just find it a pleasure to work with. EDIT: Here's a link to the docs. I couldn't find that on the Cursor website but they seem to be the official docs: https://anysphere.mintlify.app/get-started/moving-from-vsc-to-cursor
  13. Have you tried https://marketplace.visualstudio.com/items?itemName=donjayamanne.githistory ? This seems to be the most popular one. Latest commits last year. The graph looks similar to git graph. There is a number of actions you can take on commits, like revert, create branch, cherry pick etc.
  14. I'll try to replicate this. What versions of ProcessWire and RockMigrations are you on?
  15. Thank you for this module. Great addition. Now people who prefer to work more in the GUI can manage migrations with your module. The automatic recording feature looks interesting.
  16. @ryangreat news. Thank you so much for adding this to the core. Having the Pro module for a GUI is a good approach imo.
  17. @nloyolareading my post after almost 2 month, I realize it can indeed be confusing if you are not deep into the code. In the meantime there is a method createRepeaterMatrixField() available that should avoid this problem. See https://github.com/baumrock/RockMigrations#repeatermatrix-field
  18. Great way of managing the docs. I'll make a PR.
  19. Thank you for the explanations 🙂 Would be awesome to have this in the Wiki. Would you mind me adding it there through a PR? Splitting up migrations and working with multiple migrations distributed over the code base is something more advanced and not so easy to wrap ones head around. Especially when it comes to order of execution. Can we influence that? Might have overlooked it if it's in the documentation or Wiki...
  20. Thank you very much @ryanfor working on this. For larger corporate sites this is a must have. We are using ProDrafts atm and got it kind of working with nested repeaters with some dirty hacks. Approval workflow like mentioned by @Pete would be awesome 🙂
  21. Hi @bernhard, referring to this post: Thank you for the detailed explanation there. I was not sure if the custom PageClass files would be called before the associated template exists and therefore the migrations would run initially. For example, I have a site/classes/MemberPage.php with migrations in it, where the migration creates the member template. Will the migrations be triggered before the member template even exists?
  22. Thanks @bernhardfor the detailed explanations about splitting up the migrations. MAybe you want to add that to the Wiki. That would be awesome. For that big project where I have that 4000 lines migrations in one file I still need to do that. When I started out with that project I wasn't fully aware on how to properly organize my migrations. Like with any other tool, knowledge grows with usage time 🙂
  23. Which version of RockMigrations did you use? I added Repeater Matrix support and this was merged approx. 2 months ago. Here's how to use it: https://github.com/baumrock/RockMigrations#repeatermatrix-field Repeater Matrix support is also mentioned on the module's page https://processwire.com/modules/rock-migrations/ If you tried the version with Repeater Matrix support and it didn't work for you, please let us know what exactly went wrong so we can help to fix it. In all my tests and using it in a production project, I didn't encounter problems so far. RockMigrations has been a big time saver and working reliably for me for the past 2 years or so. I haven't tried other solutions mentioned here since they are not actively maintained. As for having this functionality in the core. Yes, that would be great, indeed. Honestly, I don't understand, why @ryan hasn't implemented it yet. Maybe also because there is a great solution with a well designed API available already as a free module? Still, I think it would benefit the project if this was either in core or available as an optional core module. IMO, migrations are essential, especially when using PW for bigger projects and when working on projects in a team. As for the discussion here about potential problems with migrations brought up by @MarkE , I was able to work around all of those with RockMigrations since it is also declarative, but not destructive (unless explicitly intended). The "few things too many" argument is flawed since all the extra functionality is optional and therefore doesn't impact performance. And the addon-features are well designed and can be very useful. Performance with RockMigrations is really good. Only very large migrations take some time. I have a project with about 4000 lines of migrations for templates, fields, pages and roles in my main migration file and then some additional 1000 lines spread throughout modules and these take about 20 seconds. Since you are not doing migrations all too often, this is very tolerable. Migrations on smaller projects are almost not noticable.
  24. actually the main work for this was done by @bernhardfor his old release RockMigrations V1. I just ported that to V2 and added some improvements/bugfixes :-)
×
×
  • Create New...