Log message #4020046

# At Username Text
# Apr 25th 2017, 19:05 spylinux sharing only the database, only a few tables btw
# Apr 25th 2017, 19:05 jeremyharris if the apps are sharing some logic, perhaps a plugin would be best?
# Apr 25th 2017, 19:04 jeremyharris no need to apologize!
# Apr 25th 2017, 19:04 spylinux sorry my bad english, i'm brazilian cakephp user.
# Apr 25th 2017, 19:04 spylinux thanks @jeremyharris. Its an app from the same client, but they need a parallel module that use the same database, but not same auth, classes, etc
# Apr 25th 2017, 19:02 jeremyharris spylinux you could globally install cakephp with composer and include the global autoloader. not sure there’s a benefit to that over installing it regularly, other than saving some disk space
# Apr 25th 2017, 19:01 spylinux Its possible to use one install of CakePHP 3, to multiple apps, like in Cake 2, when its just make a copy of "app" folder and use the same core?
# Apr 25th 2017, 18:59 phishy How does one do a query_string search with the Elasticsearch plugin? Not seeing it pop out at me in the code or tests.
# Apr 25th 2017, 18:41 chris-andre Thought I'd share my first cakephp plugin (CsvImport): https://github.com/chris-andre/cakephp-csvimport . I guess there are a lot of things to point out in my code, so any feedback is welcome.
# Apr 25th 2017, 18:39 admad doug__: because you are not using 3.4. Use ->templates ()
# Apr 25th 2017, 18:25 doug__ @ypnos, I get this error Method Cake\View\Helper\PaginatorHelper::setTemplates does not exist
# Apr 25th 2017, 18:15 doug__ ok
# Apr 25th 2017, 18:13 ypnos so, in fact, it is there
# Apr 25th 2017, 18:12 ypnos doug__: because it is part of StringTemplateTrait which is used by PaginatorHelper
# Apr 25th 2017, 18:07 doug__ Does anyone know why the documentation says to use '$this->Paginator->setTemplates' but that function does not exist?
# Apr 25th 2017, 17:45 ypnos for all dirty fields I think you need getDirty() which is available since 3.4.3
# Apr 25th 2017, 17:45 adityapansari Actually I want all dirty fields. I am using cakephp 3.3
# Apr 25th 2017, 17:44 ypnos in cake3 you call dirty with a single argument and it returns true or false
# Apr 25th 2017, 17:43 adityapansari ?
# Apr 25th 2017, 17:43 adityapansari Any alernative
# Apr 25th 2017, 17:43 adityapansari How can I call the getDirty() in cakephp 3.3 ?
# Apr 25th 2017, 17:36 ypnos in newest cakephp, isDirty() to check, setDirty() to set
# Apr 25th 2017, 17:34 adityapansari Hey, alternative for dirty() function ? I also want to access the dirty value after saving the entity.
# Apr 25th 2017, 17:32 chris-andre I forgot about saveMany(), so I will probably use that method.
# Apr 25th 2017, 17:31 chris-andre Quite simple change. I tested something similar, if `save()` failed, but it didn't give me the result I expected. I probably did something wrong.
# Apr 25th 2017, 17:29 chris-andre Okay. Thanks for looking at it ;) I'll read your comment on my gist ;)
# Apr 25th 2017, 17:26 ypnos with comment I meant a comment on your gist :)
# Apr 25th 2017, 17:25 ypnos see https://book.cakephp.org/3.0/en/orm/saving-data.html#saving-multiple-entities
# Apr 25th 2017, 17:25 ypnos but for your simple use case, you should use saveMany()
# Apr 25th 2017, 17:24 ypnos as I said, you need to propagate the negative result of save() so that transactional() can act upon the failure and rollback the transaction
# Apr 25th 2017, 17:23 ypnos I made a comment on how to fix the code
# Apr 25th 2017, 17:22 chris-andre Sure.
# Apr 25th 2017, 17:22 ypnos do some googling on xdebug php :)
# Apr 25th 2017, 17:22 chris-andre xdebug(): call to undefined method.
# Apr 25th 2017, 17:21 chris-andre Allright, doesn't get it. Here my method: https://gist.github.com/chris-andre/af7981db40095016c815800e1c56b15c
# Apr 25th 2017, 17:17 ypnos you can use xdebug
# Apr 25th 2017, 17:17 chris-andre ?
# Apr 25th 2017, 17:17 chris-andre Sorry for asking stupidly, but what do I do to debug my callback
# Apr 25th 2017, 17:15 ypnos_ saving entities with an error fails and returns false, but you need to propagate it in the callback
# Apr 25th 2017, 17:15 chris-andre I thought the transaction would fail if any entity has an error, but it doesn't.
# Apr 25th 2017, 17:15 ypnos_ how does your callback look like? maybe show a gist?