# |
Mar 28th 2019, 08:47 |
anupgkale |
damn |
# |
Mar 28th 2019, 08:46 |
anupgkale |
Cakephp client uses Fopen and not curl |
# |
Mar 28th 2019, 08:28 |
anupgkale |
I am not sure how to debug this anymore. Can someone please help me? |
# |
Mar 28th 2019, 08:27 |
anupgkale |
I have run a small PHP script that uses cul follow redirect to download a file. but when I use /Cake/Http/Client. the request stops at the very penultimate redirect and does not download the file |
# |
Mar 28th 2019, 08:25 |
anupgkale |
Hi all, I am new here and I apologise if i am breaking any rules |
# |
Mar 28th 2019, 01:10 |
dereuromark |
fsf: you dont |
# |
Mar 28th 2019, 00:56 |
challgren |
Ahh it was with CakeDC/users permissions |
# |
Mar 28th 2019, 00:41 |
fsf |
how to create multiple login using multiple users tables |
# |
Mar 28th 2019, 00:40 |
fsf |
how to create multiple login using multiple users tables |
# |
Mar 27th 2019, 21:03 |
rogerpro |
I manipulated a child and added another with newEntity() instead |
# |
Mar 27th 2019, 20:59 |
ricksaccous |
well, you know to just explicitly set them as dirty now, after patchEntity I guess |
# |
Mar 27th 2019, 20:58 |
rogerpro |
Less than the time I spent researching :rolling_on_the_floor_laughing: |
# |
Mar 27th 2019, 20:57 |
rogerpro |
How many microseconds would it take to the framework to do a diff of the previous and current entities? |
# |
Mar 27th 2019, 20:57 |
ricksaccous |
i seee |
# |
Mar 27th 2019, 20:57 |
rogerpro |
I want to save the hasMany entities that has changed (actually all of them in the entity passed to save() have changed). |
# |
Mar 27th 2019, 20:56 |
rogerpro |
Why does `save()` not check diff in association entities? It’s for efficiency I guess, but I’m not sure it’s the best choice. |
# |
Mar 27th 2019, 20:55 |
ricksaccous |
lol |
# |
Mar 27th 2019, 20:55 |
ricksaccous |
is it a belongsToMany and you pretty much want it to be dirty on every save and save strategy is replace? |
# |
Mar 27th 2019, 20:54 |
rogerpro |
I’m afraid it’s a feature, not a bug ,:) Anyhow, I guess I’m not the only one to forgot the use of `dirty()` method. An ORM should be as easy and magical as posible (whilst not inventing stuff). |
# |
Mar 27th 2019, 20:53 |
bencayk |
I am new to cakephp;cakephp is installed,I want to add a test in create or modify; checking Date Of Birth (greater than 65 years old) |
# |
Mar 27th 2019, 20:51 |
cnizzardini |
You should submit a bug report |
# |
Mar 27th 2019, 20:45 |
rogerpro |
^ I think we should do something for Cake 4 :thinking_face: |
# |
Mar 27th 2019, 20:44 |
rogerpro |
I found a case where the ORM `save()` returns an entity with associations and does actually nothing :face_with_rolling_eyes: All changes were in associations and the solution is to set them `dirty`. But the fact that `save()` returns something and does nothing is confusing IMHO. |
# |
Mar 27th 2019, 20:25 |
challgren |
Could also be that the hashed password is salted with something |
# |
Mar 27th 2019, 20:24 |
andy-ttg |
thanks guys |
# |
Mar 27th 2019, 20:24 |
andy-ttg |
cheers! I'll give it a go |
# |
Mar 27th 2019, 20:23 |
andy-ttg |
Yes, I only want to delete the one record @ricksaccous I think that may work |
# |
Mar 27th 2019, 20:22 |
ricksaccous |
@andy-ttg also saveStrategy doesn't necessary delete anything for you, it only replaces instead of appends if you specify that |
# |
Mar 27th 2019, 20:21 |
ricksaccous |
@andy-ttg that would work wouldn't it? |
# |
Mar 27th 2019, 20:20 |
ricksaccous |
i suppose you could just do $this->Model->Associated->delete($entity->associated); |
# |
Mar 27th 2019, 20:20 |
cnizzardini |
ah i see |
# |
Mar 27th 2019, 20:20 |
ricksaccous |
if you contain it and it gets hydrated |
# |
Mar 27th 2019, 20:20 |
ricksaccous |
i don't think he cares to delete one after the other, he just wants to delete it from the other model, lol |
# |
Mar 27th 2019, 20:20 |
cnizzardini |
But I assume it would work with hasOne |
# |
Mar 27th 2019, 20:19 |
cnizzardini |
I know the example shown is for hasMany |
# |
Mar 27th 2019, 20:19 |
cnizzardini |
Does cascading deletes not working? |
# |
Mar 27th 2019, 20:18 |
andy-ttg |
i could get around it by deleting them straight up, but just thought I would ask if there was a more elegant solution |
# |
Mar 27th 2019, 20:17 |
andy-ttg |
right, it's kinda of weird case |
# |
Mar 27th 2019, 20:16 |
ricksaccous |
but i think you just want to clear the associated record |
# |
Mar 27th 2019, 20:16 |
ricksaccous |
hasOne? kind of weird, i thought you meant delete one after you delete the other |
# |
Mar 27th 2019, 20:16 |
ricksaccous |
oh wait |