CakePHP 3.1.1 - deleteAll when using condition NOT IN array fails

2015-12-29 Thread glk
Hello, A function in OpSpTable.php uses the following code: $op_id = 18; > $actualUsed = [2, 101]; > > $conditions = [ > 'OpSps.op_id' => $op_id, > 'OptSps.ec_id NOT IN' => $actualUsed, > ]; > >

hasmany validation and save data in a form, best approach

2015-12-29 Thread Raul Magdalena Catala
hello, lets say that i have a form that represents an invoice and the invoice items. the invoice has many invoice items relation. the form has some inputs for the invoice, and 10 rows with inputs for the invoice items: item code, item qty, item price, etc... Not always all the 10 rows are filled

how to deploy i18n translations ?

2015-12-29 Thread Alysson Gonçalves de Azevedo
In my development environment the I18n works fine, i can set the locale with both ini_set('intl.default_locale', 'pt_BR') and I18n::locale('pt_BR'). But on my server nothing seems to work. Permissions are fine, cakephp can read the src/Locale files and write cache files on tmp/cache/persistent. In

How to force DebugKit to use HTTPS for its requests?

2015-12-29 Thread Ethan Pooley
Apps running on Heroku can be requested via HTTPS even though the app and Web server don't know anything about it. Apps behind CloudFlare have a similar option. In this environment, DebugKit may be blocked as "mixed content" because the request for it happens via HTTP. My browser (Firefox 43) s

Re: Help with Cakephp 2.x pagination

2015-12-29 Thread Clement Crownrise
Thanks @John On Tue, Dec 29, 2015 at 8:53 AM, John Andersen wrote: > As Matthew wrote, use the Neighbor function. See the CakePHP book in this > page: > > http://book.cakephp.org/2.0/en/models/retrieving-your-data.html#find-neighbors > > Enjoy, John > > > On Tuesday, 29 December 2015 00:54:37 UT

CakePHP 3 - Catch invalidargument email -> to exception

2015-12-29 Thread Willem
How can we catch an invalid email exception? Cake throws and invalidargumentexception. Invalid email: "bassdsd.cs#adcdc.com"InvalidArgumentException This does not work, the catch is not reached: $toEmailAddress = "bassdsd.cs#adcdc.com"; $email = new Email('default'); try { $email->t