# |
Jul 9th 2018, 09:18 |
josbeir |
your blocks are stored in there |
# |
Jul 9th 2018, 09:17 |
josbeir |
because in the end it uses your view class |
# |
Jul 9th 2018, 09:17 |
josbeir |
good question... i would think so |
# |
Jul 9th 2018, 09:16 |
neon1024 |
if I define a block in a cell, can I still append to it elsewhere? |
# |
Jul 9th 2018, 09:14 |
neon1024 |
I’ve written a hook view method, but I don’t really want to do that in every View method across my admin area |
# |
Jul 9th 2018, 09:13 |
neon1024 |
It would be there even if the result was `0` rows I’d think |
# |
Jul 9th 2018, 09:13 |
neon1024 |
I don’t see a query in the Debug Kit SQL tab |
# |
Jul 9th 2018, 09:12 |
josbeir |
r u sure its not working ? |
# |
Jul 9th 2018, 08:44 |
neon1024 |
I mean, I can write my own method and hook the beforeFind to contain the association, but that defeats the whole point of the listener |
# |
Jul 9th 2018, 08:42 |
neon1024 |
Perhaps that’s it? Perhaps Crud is inflecting Roles to Role |
# |
Jul 9th 2018, 08:42 |
neon1024 |
A `Roles hasMany Users` and vice versa |
# |
Jul 9th 2018, 08:41 |
neon1024 |
I am viewing a Role, and expecting a query for Users in that role |
# |
Jul 9th 2018, 08:41 |
neon1024 |
I am using Crud plugin, and have setup the relatedModels listener, and enabled it for my View action, however I’m not getting a query for the associations. Anyone think why this might be? |
# |
Jul 9th 2018, 08:39 |
neon1024 |
Morning all |
# |
Jul 9th 2018, 05:13 |
sherwinrobles |
File uploaded https://cakesf.slack.com/files/U42VDSR19/FBLRBBHAP/image.png / https://slack-files.com/T053DPNCM-FBLRBBHAP-63bc608f0b - Hi to all. I am working with cookies.. in the latest cakephp 3x. I can't make it work . What is wrong here? thanks |
# |
Jul 9th 2018, 02:19 |
hmic |
i dont actually know off hand if there had been changes to that. but i would suggest you check the debugkit changelog for the 3.6 release, as they would have needed to change the behaviour too |
# |
Jul 9th 2018, 02:19 |
itmpls |
i mean in 3.5, its defined too |
# |
Jul 9th 2018, 02:18 |
hmic |
so there you have it |
# |
Jul 9th 2018, 02:18 |
itmpls |
middleware() has the queue for ErrorHandlerMiddleware etc |
# |
Jul 9th 2018, 02:18 |
hmic |
is there another place you use? |
# |
Jul 9th 2018, 02:17 |
itmpls |
in src/Application? |
# |
Jul 9th 2018, 02:17 |
itmpls |
err |
# |
Jul 9th 2018, 02:17 |
hmic |
just setup the middleware in your old codebase too :p |
# |
Jul 9th 2018, 02:17 |
hmic |
probably because you didnt setup the middleware before, so the fallbak was the old errorhandler |
# |
Jul 9th 2018, 02:16 |
itmpls |
in order to adjust my framework to display the exception properly during debug |
# |
Jul 9th 2018, 02:16 |
itmpls |
where does ErrorHandler get set/invoked? i'm trying to figure out why between 3.5 and 3.6 if I have an invalid class declaration, it gets caught in the error middleware in 3.6 but errorhandler in 3.5 |
# |
Jul 9th 2018, 02:14 |
hmic |
waspinator: check the "dirty" property in the entity |
# |
Jul 9th 2018, 01:33 |
waspinator |
guess cake checks for that before calling beforeSave |
# |
Jul 9th 2018, 01:32 |
waspinator |
ah, it wasn't being called because nothing about the object changed. |
# |
Jul 9th 2018, 01:04 |
waspinator |
hmm, so I call `$this->ModelName->save($model);` and I have a `debub('test'); die;` in the `beforeSave()` function, but it's not called |
# |
Jul 9th 2018, 00:13 |
itmpls |
I'm overriding the ExceptionHandler in config/app.php with my own, but I find lately with 3.6+ I don't think it's catching middleware exceptions. Is there a special case/exception for these? Debugging in src/Error/Middleware/ErrorHandlerMiddleware now. |
# |
Jul 8th 2018, 23:09 |
chris-andre |
Before the class UsersTable, «use Cake\Event\Event» and so on to import the classes. You have to use Event, EntityInterface and ArrayObject |
# |
Jul 8th 2018, 22:19 |
waspinator |
besides putting the function in my table class, what else do I have to do? |
# |
Jul 8th 2018, 22:18 |
waspinator |
what was that last part? |
# |
Jul 8th 2018, 21:24 |
chris-andre |
Put it in your table class. That is it. Remember du use the classes Event, EntityInterface an ArrayObject |
# |
Jul 8th 2018, 21:23 |
chris-andre |
‘ beforeSave(Event $event, EntityInterface $entity, ArrayObject $options)’ |
# |
Jul 8th 2018, 21:11 |
waspinator |
I'm trying to call `beforeSave` in a table, but it doesn't seem to be triggered. All I did was define a `public function beforeSave($event, $entity, $options){}` in my `*Table.php` file. Do I have to initilize an event listener for it to work? |
# |
Jul 8th 2018, 19:47 |
saeideng |
are you feeling ? |
# |
Jul 8th 2018, 19:46 |
saeideng |
looks firefox style changed today |
# |
Jul 8th 2018, 17:56 |
wYm |
Hi All, how can I reset data post after a submit |
# |
Jul 8th 2018, 16:04 |
itmpls |
@turkles err what's the difference again? can you elaborate? |