Log message #4222115

# At Username Text
# Jan 13th 2020, 10:50 dereuromark phpcsfixer has a few bad practices IMO in terms of exdendability (prevention), and is sometimes a bit too opininated in a bad way). So most still use the first.
# Jan 13th 2020, 10:44 neon1024 As PHPCS comes with PHPCBF for fixing
# Jan 13th 2020, 10:44 neon1024 What are the differences between https://github.com/FriendsOfPHP/PHP-CS-Fixer and https://github.com/squizlabs/PHP_CodeSniffer
# Jan 13th 2020, 08:13 javier.villanueva morning all
# Jan 13th 2020, 07:05 hanumanprasad.yadav Thanks @admad
# Jan 13th 2020, 06:54 admad yes something like that
# Jan 13th 2020, 06:53 hanumanprasad.yadav Ok, then we need to user this: https://book.cakephp.org/3/en/orm/query-builder.html#subqueries right?
# Jan 13th 2020, 06:53 admad and to get `exists` you'll probably need to use query expressoin
# Jan 13th 2020, 06:51 admad so you need subqueries, hence forget matching() as it does joins. The book has examples for using sub queries
# Jan 13th 2020, 06:47 hanumanprasad.yadav @admad please check below simple query example for above requirement: select * from `users` where exists (select * from `listings` where `users`.`id` = `listings`.`user_id`) or exists (select * from `organizations` where `users`.`id` = `organizations`.`user_id`)
# Jan 13th 2020, 06:33 admad step 1: come up with the SQL query needed to achieve what you want
# Jan 13th 2020, 06:24 slackebot solution about this type of query
# Jan 13th 2020, 06:24 slackebot this case if anyone listing available then we need result and also anyone Organizations available then we need result but if both Listings or Organizations not available then we don't need result. Current query: $query = $this->Users->find(); $query->matching('Listings'); $query->matching('Organizations'); I need like this: $query = $this->Users->find(); $query->matching('Listings'); $query->orMatching('Organizations'); Please help me if have any
# Jan 13th 2020, 06:24 hanumanprasad.yadav I have a problem on Retrieving Data with matching 2 different different tables. I want if any one table match condition from both tables then we want the result. it is possible using matching? this behavior like we need according to matching and orMacthing scenario My requirement is: I have 3 Models: 1) Users 2) Listings 3) Organizations Now I am find the result using Users Model with matching Listings and Organizations and in
# Jan 13th 2020, 03:18 kani Hello
# Jan 12th 2020, 19:13 tjkalinowski I had problem with CakePHP and Mac. I turn to MAMP.
# Jan 12th 2020, 18:39 kiwi_50 Hi! Anyone with trouble running CakePHP on Mac with Homebrew httpd?
# Jan 12th 2020, 11:24 challgren haha ok
# Jan 12th 2020, 11:23 tibor.hajos Thanks for the help! That was the one I've been following. For some reason sphp did nothing. For now I've just made an alias for the brew commands. Perhaps things will break tomorrow at my job, but we'll see about that tomorrow 8)
# Jan 12th 2020, 11:18 challgren The best guide Ive seen so far
# Jan 12th 2020, 11:18 challgren https://getgrav.org/blog/macos-catalina-apache-multiple-php-versions
# Jan 12th 2020, 11:18 tibor.hajos I just tried it and all seems fine. I can get started
# Jan 12th 2020, 11:16 tibor.hajos I have some config in the ini that I want to preserve. I don't know if ```brew unlink php@7.0 brew link php@7.2``` will preserve that
# Jan 12th 2020, 11:12 tibor.hajos Trying to install sphp
# Jan 12th 2020, 11:12 tibor.hajos yes
# Jan 12th 2020, 10:57 challgren @tibor.hajos you use Mac?
# Jan 12th 2020, 10:56 tibor.hajos @dereuromark I'm having some trouble setting up my environment with multiple PHP versions, so it takes a bit longer than expected to work on the plugins
# Jan 12th 2020, 10:07 challgren https://book.cakephp.org/4/en/orm/associations.html and https://book.cakephp.org/3/en/orm/associations.html but its about users
# Jan 11th 2020, 22:21 luizcmarin Does anyone know if this appears in the book? Where?
# Jan 11th 2020, 22:14 luizcmarin I need an example with Father-> Children, which I can study to order-> items. I don't remember if I ever saw that.
# Jan 11th 2020, 14:11 dereuromark no one was missing saveMany() so far in annotations?^^ https://github.com/dereuromark/cakephp-ide-helper/releases/tag/0.14.5
# Jan 11th 2020, 08:31 alexdd55976 morning
# Jan 11th 2020, 05:21 akhil.mohan Never mind, I found the problem
# Jan 11th 2020, 04:31 slackebot implements AuthenticationServiceProviderInterface to src/Application.php breaks everything in results in HTTP 500 error. The lines that I have changed inside src/Application.php are listed here https://pastebin.com/GhuRWypy I would appreciate if anyone help on this.
# Jan 11th 2020, 04:31 akhil.mohan Hey Everyone, I am trying to setup CakePHP 4 with authentication. Tried following the examples https://book.cakephp.org/4/en/tutorials-and-examples/cms/authentication.html and https://book.cakephp.org/authentication/2/en/index.html Both of the examples lead me to an error: Subject must be an instance of Authentication\AuthenticationServiceInterfaceorAuthentication\AuthenticationServiceProviderInterface, App\Application given. Also adding
# Jan 11th 2020, 03:55 latenal input mask sucks. I found a workaround modifying the values in beforeMarchal
# Jan 11th 2020, 03:31 admad Just don't accept such values, use input masks in UI for comma separated disply and submit standard values only
# Jan 11th 2020, 02:33 latenal Hi guys! how do you fix numbers with commas during validation? I mean things like “1,000”
# Jan 10th 2020, 20:08 phantomwatson `->requirePresence('fieldname', false)` would cover the condition of the field not being present in the data array, but I want to avoid tripping any validation errors if it _is_ present and `null`.
# Jan 10th 2020, 19:56 phantomwatson `Validation::isInteger()` looks like it would fail for `null`, but the `allowEmptyFoo()` methods seem to all expect empty values of non-null types.
# Jan 10th 2020, 19:53 phantomwatson I'm somehow forgetting a basic validation thing for CakePHP 3. If a field is a nullable integer field, does `$validator->integer('fieldname')` cover that, or is an `->allowEmptyFoo()` rule also necessary? With `allowEmpty()` being deprecated, I forget what the equivalent is of "allow null values".