# |
Jun 29th 2018, 20:14 |
saeideng |
exactly |
# |
Jun 29th 2018, 20:13 |
chrisshick |
ahh we have to use every method |
# |
Jun 29th 2018, 20:13 |
saeideng |
yes you have not `marshal()` method |
# |
Jun 29th 2018, 20:12 |
slackebot4 |
@param Driver $driver database driver * @return mixed|string */ public function toDatabase($value, Driver $driver) { return inet_pton($value); } /** * @param string $value statement value * @param Driver $driver database driver * @return int|mixed */ public function toStatement($value, Driver $driver) { return PDO::PARAM_LOB; } } ``` |
# |
Jun 29th 2018, 20:12 |
chrisshick |
``` <?php namespace App\Database\Type; use Cake\Database\Driver; use Cake\Database\Type; use PDO; class IpAddressType extends Type { /** * * @param mixed $value database value * @param Driver $driver database driver * @return bool|mixed|null|string */ public function toPHP($value, Driver $driver) { return inet_ntop($value); } /** * * @param string $value php value * |
# |
Jun 29th 2018, 20:11 |
chrisshick |
all I did was |
# |
Jun 29th 2018, 20:11 |
chrisshick |
yep |
# |
Jun 29th 2018, 20:11 |
saeideng |
can you post a text with your use case ? |
# |
Jun 29th 2018, 20:10 |
saeideng |
https://github.com/cakephp/cakephp/issues/12257 |
# |
Jun 29th 2018, 20:10 |
saeideng |
there are open issue about this |
# |
Jun 29th 2018, 20:09 |
saeideng |
you can not use base type with default body |
# |
Jun 29th 2018, 20:09 |
saeideng |
specify all methods |
# |
Jun 29th 2018, 20:08 |
saeideng |
or |
# |
Jun 29th 2018, 20:08 |
saeideng |
it say you must use one of class |
# |
Jun 29th 2018, 20:08 |
chrisshick |
My type is in specific calls |
# |
Jun 29th 2018, 20:07 |
saeideng |
> @deprecated 3.1 All types should now be a specific class |
# |
Jun 29th 2018, 20:02 |
chrisshick |
Type::_basicTypeCast() is deprecated |
# |
Jun 29th 2018, 20:02 |
chrisshick |
anyone getting deprecation error for core code?? |
# |
Jun 29th 2018, 20:00 |
chrispecoraro |
I don't understand how to instantiate the PaginatorHelper. |
# |
Jun 29th 2018, 19:52 |
chrispecoraro |
``` $this->PaginatorHelper = new PaginatorHelper(); $this->Paginator->settings = ['limit' => 10, 'recursive'=>-1];``` |
# |
Jun 29th 2018, 19:52 |
chrispecoraro |
And then I do this: |
# |
Jun 29th 2018, 19:51 |
chrispecoraro |
``` public function index(){ $this->Paginator->settings = ['limit' => 10, 'recursive'=>-1]; $this->renderView($this->Paginator->paginate('Employer')); } ``` |
# |
Jun 29th 2018, 19:51 |
chrispecoraro |
If I do this: |
# |
Jun 29th 2018, 19:51 |
chrispecoraro |
I'm still having issues implementing the PaginationHelper. |
# |
Jun 29th 2018, 15:36 |
mdunham |
slackebot4: hey |
# |
Jun 29th 2018, 15:35 |
mdunham |
jose |
# |
Jun 29th 2018, 15:30 |
josbeir |
i guess i'll give it a go |
# |
Jun 29th 2018, 15:30 |
josbeir |
i know i know i read up on the basics |
# |
Jun 29th 2018, 15:29 |
admad |
Well then educate yourself :slightly_smiling_face: |
# |
Jun 29th 2018, 15:28 |
josbeir |
:) |
# |
Jun 29th 2018, 15:28 |
josbeir |
always hesistant for production use with plugins i dont know much about |
# |
Jun 29th 2018, 15:27 |
admad |
@josbeir I do :slightly_smiling_face: |
# |
Jun 29th 2018, 15:17 |
itmpls |
'plugin' => 'Companies', 'controller' => 'Companies', 'action' => 'index', 'prefix' => 'subdomain' should this not map to plugins/Companies/src/Controller/CompaniesController.php with namespace Companies\Controller; use Companies\Controller\AppController; class CompaniesController extends AppController { public function index(); } |
# |
Jun 29th 2018, 15:12 |
josbeir |
i'm deciding on using the crud plugin or not, you guys all using it ? |
# |
Jun 29th 2018, 15:01 |
itmpls |
:slightly_smiling_face: |
# |
Jun 29th 2018, 15:01 |
itmpls |
good morning |
# |
Jun 29th 2018, 14:46 |
mdunham |
good morning |
# |
Jun 29th 2018, 14:26 |
jhob |
all sorted now, used a collection - thanks for the help |
# |
Jun 29th 2018, 13:57 |
josbeir |
if you have a route that needs to be reachable from more then 1 host you can also load these in your middleware or something |
# |
Jun 29th 2018, 13:56 |
itmpls |
k |
# |
Jun 29th 2018, 13:56 |
itmpls |
yeah I don't need dynamic routes really |