# |
Feb 7th 2018, 11:22 |
neon1024 |
This simply does not fit into my brain. |
# |
Feb 7th 2018, 11:17 |
neon1024 |
As I don’t want to delete the Catalog when the filter is deleted, because it could be associated to many Catalogs. Which would lead to a catastrophic deletion of any associated Catalog, bad times and many tickets. |
# |
Feb 7th 2018, 11:17 |
neon1024 |
Dependent is not it. #inb4 |
# |
Feb 7th 2018, 11:16 |
neon1024 |
So that if I delete a Filter my Catalogs.filter_id is set to null. Or is that something I need to put into my `Filters::delete()` myself? |
# |
Feb 7th 2018, 11:16 |
neon1024 |
Is there a setting in `hasMany` so that the association foreign key is updated upon the deletion? |
# |
Feb 7th 2018, 10:42 |
dennis.richter021 |
Thanks, I will try later |
# |
Feb 7th 2018, 10:40 |
rochasmarcelo |
@dennis.richter021 in cake 3 you could use $this->viewBuilder()->templatePath('Email/html') inside controller action |
# |
Feb 7th 2018, 10:34 |
dennis.richter021 |
Hi, I rewrite a service for sending mails to our customers. One requested Feature is the "View in Browser"-Link on Emails. Ist there any way to show the Content of the `template/email/html` in a browser or do I have to store them somewhere else and use an external SDK? |
# |
Feb 7th 2018, 10:08 |
neon1024 |
That might give you some pointers on how to write your Authentication adapters |
# |
Feb 7th 2018, 10:08 |
neon1024 |
Which wraps the HybridAuth PHP library |
# |
Feb 7th 2018, 10:08 |
neon1024 |
If you’re interested in the design, perhaps check out @admad Hybrid Auth plugin > https://github.com/ADmad/CakePHP-HybridAuth |
# |
Feb 7th 2018, 10:08 |
neon1024 |
It’s been a while since I tried out the new auth plugin |
# |
Feb 7th 2018, 10:07 |
rochasmarcelo |
@neon1024 hi, in this plugin I believe I have to create a new Authenticator for oauth, but I'm not sure if the Authenticators should handle redirect |
# |
Feb 7th 2018, 10:04 |
neon1024 |
@rochasmarcelo That’s just standard OAuth flow, you can Google for that :slightly_smiling_face: Hint, You have to auth with the third party. Think about logging in with Twitter, you go to Twitter, then back to the site. |
# |
Feb 7th 2018, 10:03 |
neon1024 |
Morning all |
# |
Feb 7th 2018, 09:03 |
rochasmarcelo |
when user access something like /auth/facebook should the authenticator redirect to facebook or where it should redirect? |
# |
Feb 7th 2018, 09:02 |
rochasmarcelo |
guys, with https://github.com/cakephp/authentication, should an authenticator handle oauth2 redirect? |
# |
Feb 7th 2018, 08:24 |
Asphi |
If helps anyone... |
# |
Feb 7th 2018, 08:24 |
Asphi |
This is the line i needed: $this->Crud->action('add')->redirectConfig('post_add', ['reader' => 'entity.field', 'key' => 'id', 'url' => ['action' => 'edit', ['entity.field', 'id']]]); |
# |
Feb 7th 2018, 08:23 |
Asphi |
I think i solved my problem with Crud.Listener |
# |
Feb 7th 2018, 07:43 |
Asphi |
¿anyone can help me? |
# |
Feb 7th 2018, 07:40 |
Asphi |
This is the line i'm using to config: $this->Crud->action('add')->redirectConfig('post_add', ['key' => '_edit']); |
# |
Feb 7th 2018, 07:40 |
Asphi |
I have a problem with the Redirect Listener. I'm trying to redirect to "edit" action after add but is not working |
# |
Feb 7th 2018, 07:40 |
Asphi |
hi! i'm working with FriendsOfCake Crud plugin |
# |
Feb 7th 2018, 06:36 |
isemantics |
while waiting on answer, my current thinking is that I should do this in beforeMarshal, instead of beforeFind |
# |
Feb 7th 2018, 06:29 |
isemantics |
by "non-translated 'name' field", I mean the field 'name' that is on the database table 'collections' (as opposed to the _i18n table) |
# |
Feb 7th 2018, 06:27 |
isemantics |
translated content. After moving the code from Collections::beforeFilter to the controller itself, just before calling Collections->save(), does save the translations, so I assume that I'm correct about the "why". I got it working, but still would like to do it "nicely" in the beforeSave of the model, instead of before all places where Collections->save() is called. Might I still be doing it wrong? is this to be expected? |
# |
Feb 7th 2018, 06:27 |
isemantics |
that translation (in beforesave). At the end I checked the data on the $entity that would be saved ( at the end of beforeFilter ) and looks good, but it does not save the translated version. Thinking about the possible event flow, I realised it might be because TranslateBehavior::beforeSave is executed before the normal Cake beforeSave in the table and maybe does some magic that prevents the normal beforeSave to update/save the |
# |
Feb 7th 2018, 06:27 |
isemantics |
Hi guys. I have a "CollectionsTable" (and Collection entity class) set up with TranslateBehavior in CakePHP3.5 . After someone changes the 'name' field, I want to auto save a slug of the name in the 'friendly_url' field. I tried doing this via CollectionsTable::beforeFilter(...) and that works fine for the non-translated 'name' field, but not for the translations. I loop over the translations, change the friendly_url field for |
# |
Feb 7th 2018, 06:27 |
saeideng |
https://github.com/cakephp/debug_kit/tree/master/config |
# |
Feb 7th 2018, 06:27 |
itamer |
thanks @saeideng! |
# |
Feb 7th 2018, 06:26 |
saeideng |
yes |
# |
Feb 7th 2018, 06:25 |
itamer |
can a plugin have it's own \config\app_form.php file? |
# |
Feb 7th 2018, 04:08 |
FullmetalChocobo |
Quick question about migrations. Should migrations be used to input data into the database? |
# |
Feb 6th 2018, 23:25 |
saeideng |
looks this just used by requestAction() |
# |
Feb 6th 2018, 23:25 |
saeideng |
can i disable for all app? |
# |
Feb 6th 2018, 23:24 |
saeideng |
is this safe ? |
# |
Feb 6th 2018, 23:23 |
saeideng |
$this->loadComponent('RequestHandler', ['enableBeforeRedirect' => false]); |
# |
Feb 6th 2018, 23:02 |
saeideng |
even without `Y/json/index.ctp` |
# |
Feb 6th 2018, 23:01 |
saeideng |
now that works by `return` |
# |
Feb 6th 2018, 22:53 |
saeideng |
but now I want to use without `return` |