Log message #4202824

# At Username Text
# Sep 12th 2019, 14:59 jh urgh ... so it is there ... twice?
# Sep 12th 2019, 14:59 jh https://github.com/dereuromark/cakephp-tools/blob/master/src/Error/ErrorHandler.php#L29-L30
# Sep 12th 2019, 14:57 jh can one of you confirm?
# Sep 12th 2019, 14:57 jh Seems there is old and new code living side by side
# Sep 12th 2019, 14:55 jh and well.. for 2 hours nothing worked and then I found that commeting out the ErrorHandlerMiddleware reenabled the error handler
# Sep 12th 2019, 14:55 jh I have created my own error handler to separate 404s
# Sep 12th 2019, 14:54 jh now that ErrorHandlerMiddleware is in effect https://book.cakephp.org/3.0/en/controllers/middleware.html#middleware-in-cakephp
# Sep 12th 2019, 14:54 jh hm could it be that https://book.cakephp.org/3.0/en/development/errors.html is a bit full of lies
# Sep 12th 2019, 14:52 this.impetus (and FWIW I ought to have thought of that, but I learned cake before they existed and have reasonably recently returned, thanks guys)
# Sep 12th 2019, 14:49 this.impetus @admad view cells. that's perfect. thanks
# Sep 12th 2019, 14:48 this.impetus @admad It might really be just the models; there are a lot of HABTM relationships, otherwise it's really amoutns to formatting lines of the database into human-readable components
# Sep 12th 2019, 14:48 admad view cells
# Sep 12th 2019, 14:48 dereuromark This is called "dashboard" usually, but still only one controller, just with different data sources behind, e.g. different models fetching/processing data.
# Sep 12th 2019, 14:47 admad @this.impetus do you really need different controller or just compose a page using data from different models?
# Sep 12th 2019, 14:47 this.impetus No, interestingly; it's a static document, ultimately—it could have been a word document except for the constraint that it be assembled from a database, the context for that is that this is serving an academic, data-retrieval purpose.
# Sep 12th 2019, 14:46 ricksaccous I'm guessing you want a bunch of ajax requests?
# Sep 12th 2019, 14:45 this.impetus (and that's broad, I realize, but a broad answer is all I'm looking for, just a sketch of how cake intends to do this sort of thing)
# Sep 12th 2019, 14:44 this.impetus Making all those requests from within the document itself feels pretty uncake-like and is certainy unweidly. Any advice on a reasonable way to go about this?
# Sep 12th 2019, 14:43 this.impetus *it's also the primary focus of the site I'm building)
# Sep 12th 2019, 14:43 this.impetus Hi guys—I've a question about approach, more than method, here; I'm authoring a page that is supposed to thread together and format requests of about a dozen different controllers (this single page is going to be enormous but it
# Sep 12th 2019, 14:36 jbcharron yep, that's what I'll do :P Thanks for you help anyway :slightly_smiling_face:
# Sep 12th 2019, 14:29 ricksaccous where id = x and slug = x
# Sep 12th 2019, 14:29 ricksaccous you could easily just delete directly from the join
# Sep 12th 2019, 14:29 ricksaccous i never really use that method
# Sep 12th 2019, 14:28 ricksaccous I'm guessing it's just the unorthodox structure that causes unlink to fail but i don't really know
# Sep 12th 2019, 14:26 jbcharron Yeah. I actually had to migrate the code from join table using TableA and TableB PKs to the slug one, and I tried to figure out a solution allowing me not to change the whole controllers code, which used the link() and unlink() function. And as the link() still worked, I was wondering why the unlink() didn't. But I guess I will have to try out a different solution :P
# Sep 12th 2019, 14:24 ricksaccous and you could maybe have a flag for latest tag you update in app logic as well, sounds like a pain
# Sep 12th 2019, 14:23 ricksaccous then you'd achieve the same thing
# Sep 12th 2019, 14:23 jbcharron yep, that's the idea, a many have many. For example, my ObjectA has 3 versions, I link it with tags (using the slug, so my tags are linked to all the object versions), so if I delete the last version of my object, the versions 1 and 2 of my object don't lose the link to the tags
# Sep 12th 2019, 14:23 ricksaccous one thing you could do is post/preprocess records from slugs to records if you really want
# Sep 12th 2019, 14:22 ricksaccous hmmm
# Sep 12th 2019, 14:21 ricksaccous in this case i don't think joindata makes sense
# Sep 12th 2019, 14:20 ricksaccous many have many
# Sep 12th 2019, 14:20 ricksaccous i mean
# Sep 12th 2019, 14:20 ricksaccous but using both pks you could still say one has many, but i suppose you want to relate them to subsets
# Sep 12th 2019, 14:20 ricksaccous maybe i'm missing something
# Sep 12th 2019, 14:19 ricksaccous that seems unecessary
# Sep 12th 2019, 14:15 jbcharron And so, the versions share the same Tags (which is the purpose of my join table)
# Sep 12th 2019, 14:15 jbcharron Actually, no :( this is a model containing many versions of the same business object, the versions 1 to N share the same slug
# Sep 12th 2019, 14:09 ricksaccous are slugs not unique?
# Sep 12th 2019, 14:09 ricksaccous how is it a hasMany to TableB