# |
Apr 19th 2017, 10:39 |
Neon1024 |
Appropriate nickname I think cobra-the-joker ;) |
# |
Apr 19th 2017, 10:39 |
dereuromark |
cobra-the-joker: even 10+ veterans like me dont know anything about that ancient framework version anymore :S |
# |
Apr 19th 2017, 10:39 |
hmic |
cobra-the-joker, can you repeat that version number again please? |
# |
Apr 19th 2017, 10:37 |
joop |
but its seems there no wrong with the query |
# |
Apr 19th 2017, 10:36 |
cobra-the-joker |
Hey guys , i am having a problem with cake 1.2 ... i use paginate on a model .... but it doesn't return with it the hasOne element that i set in the controller , any help ? |
# |
Apr 19th 2017, 10:36 |
Neon1024 |
Class autoloading != Loading a component |
# |
Apr 19th 2017, 10:35 |
Neon1024 |
See above. |
# |
Apr 19th 2017, 10:35 |
joop |
use Cake\Controller\Component\AuthComponent; |
# |
Apr 19th 2017, 10:35 |
joop |
i inserted the AuthComponent |
# |
Apr 19th 2017, 10:35 |
Neon1024 |
https://book.cakephp.org/3.0/en/controllers/components/authentication.html |
# |
Apr 19th 2017, 10:35 |
Neon1024 |
joop: Well I can’t find an example in the book, but you’ll need a $this->loadComponent(‘Auth’, $myAuthConfig); somewhere in your controller, usually AppController::initialize |
# |
Apr 19th 2017, 10:34 |
hmic |
add the first_name to the order in line 31 i guess |
# |
Apr 19th 2017, 10:34 |
Neon1024 |
hmic: Ah yes, so because it’s a join, I’ll need to order the whole query! Good idea |
# |
Apr 19th 2017, 10:33 |
hmic |
Neon1024, you order by date below |
# |
Apr 19th 2017, 10:33 |
Neon1024 |
https://book.cakephp.org/3.0/en/controllers/components.html#using-components |
# |
Apr 19th 2017, 10:33 |
Neon1024 |
Then the AuthComponent is not loaded |
# |
Apr 19th 2017, 10:32 |
joop |
https://pastebin.com/bgfADqxc |
# |
Apr 19th 2017, 10:31 |
Neon1024 |
So anyone know why my order doesn’t work? https://pastebin.com/iTMcJAwW -> ln 11 |
# |
Apr 19th 2017, 10:30 |
Neon1024 |
Which would cause that kind of error |
# |
Apr 19th 2017, 10:29 |
Neon1024 |
Show use the code, as it sounds like $entity->user() |
# |
Apr 19th 2017, 10:29 |
joop |
triing to acces entity's data but keep geeting call to a member function user |
# |
Apr 19th 2017, 10:22 |
Neon1024 |
It’s possible to order a contained association right? Strange, as I’ve added an order() to my contain closure, but it’s not making it to my SQL |
# |
Apr 19th 2017, 10:19 |
matvey151 |
Hello everybody! |
# |
Apr 19th 2017, 09:43 |
Nick5 |
So its just removing it and re-populating on the save method |
# |
Apr 19th 2017, 09:43 |
Nick5 |
It's cakephp2 :( I have the cache working when it calls the queriesfor the page |
# |
Apr 19th 2017, 09:42 |
theaxiom |
or an afterSave or something |
# |
Apr 19th 2017, 09:41 |
theaxiom |
you could use some sort of message queue to perform the call via console to re-cache the data, etc |
# |
Apr 19th 2017, 09:41 |
theaxiom |
Nick5 a combination of this https://book.cakephp.org/3.0/en/orm/query-builder.html#caching-query-results> and this <https://book.cakephp.org/3.0/en/core-libraries/caching.html#clearing-cached-data I suppose |
# |
Apr 19th 2017, 09:38 |
Martin` |
I always mis the private conversations :( |
# |
Apr 19th 2017, 09:37 |
theaxiom |
I just found out about it through the Kubernetes project |
# |
Apr 19th 2017, 09:37 |
theaxiom |
It's a public message archive for Slack communities. Kind of like http://irc.cakephp.org but for Slack |
# |
Apr 19th 2017, 09:37 |
theaxiom |
Anyone ever heard of http://slackarchive.io ? |
# |
Apr 19th 2017, 09:36 |
Nick5 |
ie the cache is called short and name is new_offers. If I add an offer, can this be removed and then rebuilt without waiting for a pageload? |
# |
Apr 19th 2017, 09:35 |
Nick5 |
Is there a way to automatically remove and rebuild a query cache when a new item is added? |
# |
Apr 19th 2017, 09:06 |
Martin` |
https://gist.github.com/blieb/27e2f9c3b76e03c778eed4810942139b << why can I not use the "$idsChannels" as a subquery in an array? I can just run it on its own, but not as subquery, then it gives the error you see in the comment |
# |
Apr 19th 2017, 08:52 |
hmic |
so this needs to read $roles->name instead |
# |
Apr 19th 2017, 08:52 |
Neon1024 |
If you’d round a role, you’d get a RoleEntity, so it’d be like $role->get(‘name’) |
# |
Apr 19th 2017, 08:52 |
hmic |
oh, i got it wrong, roles is *one* entity |
# |
Apr 19th 2017, 08:52 |
Neon1024 |
So accessing data using arrays will not work |
# |
Apr 19th 2017, 08:52 |
Neon1024 |
Collections of entity objects |
# |
Apr 19th 2017, 08:51 |
Neon1024 |
Well, not in model keyed arrays, but rather in Collections |