Log message #4209212

# At Username Text
# Oct 17th, 11:33 francis.nadal @jotpe hi i get this when debug is enabled
# Oct 17th, 11:31 jotpe Form looks good. You see the post data with `if ($this->request->is('post')) { debug($this->request->getData('photo'));...`
# Oct 17th, 11:27 francis.nadal @conehead this is my form
# Oct 17th, 11:26 conehead And how does your form look like?
# Oct 17th, 11:26 francis.nadal Thank you very much! I will try it right now
# Oct 17th, 11:25 slackebot1 <jotpe>
# Oct 17th, 11:25 jotpe @francis.nadal I don't know about this plugin, but you can try to debug it. In your UsersController try something like this:
# Oct 17th, 11:15 francis.nadal Do I also need to configure this here in users table?
# Oct 17th, 11:15 francis.nadal hello, I have a question regarding the cakephp-upload plugin. I wanted to have a photo upload for users and it was suggested to me to use it. But I was trying out their documentation example(https://cakephp-upload.readthedocs.io/en/latest/examples.html) but I seem to not get it to work. I always get this error.
# Oct 17th, 10:02 koeller If I do it your way I don’t have to do the setConnection on the loaded Model :slightly_smiling_face: Thank you!
# Oct 17th, 09:52 slackebot1 <challgren>
# Oct 17th, 09:51 slackebot1 <challgren>
# Oct 17th, 09:50 challgren That might be your issue is your loading the config after the alias
# Oct 17th, 09:49 challgren and maybe load your config before the alias
# Oct 17th, 09:45 koeller To have be aware of not configured connection names passed?
# Oct 17th, 09:44 challgren @koeller did you try to inspect it with `ConnectionManager::configured()`?
# Oct 17th, 09:41 koeller @alexdd55976: For now I’m able to perform the action I want in loading the connection into the Model directly, like: ```$this->Users ->setConnection(ConnectionManager::get($args->getArgument('connection')))```
# Oct 17th, 09:21 alexdd55976 @koeller i do not know, but if you find the solution can you add to docu and do a PR on it?
# Oct 17th, 09:18 koeller Hey, How can I switch a database in a Command. I’ve tried in command execute(): `ConnectionManager::alias($args->getArgument(‘connection’), ‘default’); Configure::load($args->getArgument(‘connection’), ‘default’, true);` But that doesn’t work :S I haven’t found anything in the documentation on that topic, either.
# Oct 17th, 09:08 challgren Evening all!
# Oct 17th, 08:51 neon1024 Wishing everyone a great day! :tada:
# Oct 17th, 08:50 neon1024 Heya everyone
# Oct 17th, 07:20 jotpe Morning, folks!
# Oct 17th, 06:47 javier.villanueva morning!
# Oct 17th, 06:32 alexdd55976 good morning
# Oct 16th, 21:42 slackebot1 'marketingthumb >' => 0 ] ]``` any ideas how to achieve that?
# Oct 16th, 21:42 slackebot1 'Projectfiles', function (Query $q) { return $q->where( [ 'OR' => [ 'marketingvideo >' => 0, 'marketingthumb >' => 0 ] ] ); } ); $query->cache('project_list_video_images'); $query2 = $this->Projects->find('all')
# Oct 16th, 21:42 slackebot1 'Products', 'Marketinginfos', 'Clients', 'Projectfiles' ] ); $query->where(['active' => true]); $query->order(['Projects.id' => 'DESC']); return $query; } ``` this is of course not 100% correct as the condition is to open in ``` return $q->where( [ 'OR' => [ 'marketingvideo >' => 0,
# Oct 16th, 21:42 slackebot1 ->contain(['Marketinginfos', 'Products']) ->toArray(); debug($query2); return $query; } private function __prepareApiMarketingGetProjectList() { $query = $this->find(); $query->matching( 'Marketinginfos', function (Query $q) { return $q->where(['closed' => true]); } ); $query->contain( [
# Oct 16th, 21:42 slackebot1 ``` public function ApiGetProjectListVideoAndImages() { $query = $this->__prepareApiMarketingGetProjectList(); $query->matching( 'Products', function (Query $q) { return $q->where( [ 'producttype_id' => [1,2], ] ); // Videos and Images Only } ); $query->matching(
# Oct 16th, 21:42 mrfeedback i am not sure how i can build a query for the following example: i have projects I want to select `projects` which have in `marketinginfos.closed = true`, and `producttype_id` either `1` or `2` and if it is `producttype_id = 1` it has to have at least one `projectfiles.marketingthumb > 0` and `projectfiles.video > 0` if it is `producttype_id=2` it as to have at least one `projectfile.marketingthumb > 0` only. my approach is the following
# Oct 16th, 16:49 ssalvatori I want to test the internal logic of the listerner
# Oct 16th, 16:49 ssalvatori hello, hey any examples how to test a EventListener ?
# Oct 16th, 16:47 javier.villanueva Im testing with 10.000 and time to save its very up
# Oct 16th, 16:47 javier.villanueva I may not need lft and rght structure
# Oct 16th, 16:45 javier.villanueva ok
# Oct 16th, 16:44 admad MPTT is optimized for read
# Oct 16th, 16:44 admad it won't crash on finds but more like on saves :slightly_smiling_face:
# Oct 16th, 16:09 javier.villanueva ok i will make it
# Oct 16th, 16:09 ndm Finds shouldn't be an issue even with billions of records (assuming your DBMS can handle large amounts of data in general), writes on the other hand can be very expensive. Generate some test data and try it out.
# Oct 16th, 16:01 javier.villanueva really when I write finds is reorder