# |
Aug 26th 2016, 03:26 |
xuding |
@jeremyharris thanks |
# |
Aug 26th 2016, 03:07 |
jeremyharris |
@xuding you can invalidate the entity field like so: `$entity->errors(â??fieldnameâ??, â??error messageâ??);` (see: http://book.cakephp.org/3.0/en/orm/entities.html#validation-errors) |
# |
Aug 26th 2016, 02:58 |
xuding |
how do we manually invalidate form fields in Cake 3? |
# |
Aug 26th 2016, 02:57 |
xuding |
hi |
# |
Aug 26th 2016, 00:02 |
sinus |
eg: ``` 'redisForeverCache' => [ 'className' => 'Redis', 'duration' => '+1 year', 'host' => 'localhost', 'server' => '127.0.0.1', ], |
# |
Aug 26th 2016, 00:01 |
sinus |
```$ redis-cli 127.0.0.1:6379> exit ``` |
# |
Aug 26th 2016, 00:01 |
sinus |
I have Redis installed and also predis |
# |
Aug 26th 2016, 00:00 |
sinus |
I get `Cache engine Cake\Cache\Engine\RedisEngine is not properly configured.` |
# |
Aug 25th 2016, 23:59 |
sinus |
Hi, anyone used Redis as cache with Cake3? |
# |
Aug 25th 2016, 22:29 |
latbud |
Hey guys. I'm looking into CakePHP to add a small, custom ecommerce solution I'd build for a client's site. I'm wondering if there's any kind of PayPal integration plugin for CakePHP 3.x. I've been able to find them for 2.x but haven't had any luck with the current version. Thanks! |
# |
Aug 25th 2016, 22:26 |
nemmons |
my best guess is that it would just be inconvenient or difficult or perhaps impossible to pass that configuration option on to the Marshaller as well so that all of Marshaller's references to _joinData would be handled properly |
# |
Aug 25th 2016, 22:24 |
nemmons |
Not a big deal either way, i was just sort of curious, since so much of CakePHP *is* configurable |
# |
Aug 25th 2016, 22:23 |
nemmons |
right, @admad, thanks, i know it's not configurable, i was asking if anyone has any thoughts on why it's not configurable |
# |
Aug 25th 2016, 22:00 |
cpierce |
http://book.cakephp.org/3.0/en/controllers/request-response.html |
# |
Aug 25th 2016, 22:00 |
cpierce |
n/m found it |
# |
Aug 25th 2016, 21:50 |
cpierce |
in 2 |
# |
Aug 25th 2016, 21:50 |
cpierce |
they used to be called media views |
# |
Aug 25th 2016, 21:48 |
cpierce |
is there a sendfile for cakephp 3 |
# |
Aug 25th 2016, 21:07 |
admad |
that special key `_joinTable` is not configurable |
# |
Aug 25th 2016, 21:06 |
admad |
oh wait, you asked about `$_junctionProperty` |
# |
Aug 25th 2016, 21:04 |
admad |
* junction() |
# |
Aug 25th 2016, 21:04 |
admad |
or just `joinTable` in options |
# |
Aug 25th 2016, 21:03 |
admad |
@nemmons you can using juntion() method |
# |
Aug 25th 2016, 20:54 |
nemmons |
Good afternoon. Does anyone have any thoughts on why \Cake\ORM\Association\BelongsToMany.php->_options() doesn't allow for the user to set $_junctionProperty by passing in an option for it? Any reason that we shouldn't be able to edit $_junctionProperty? (https://github.com/cakephp/cakephp/blob/master/src/ORM/Association/BelongsToMany.php#L1359) |
# |
Aug 25th 2016, 20:43 |
saliak |
my belongsToMany Products through OrderLines ? |
# |
Aug 25th 2016, 20:42 |
saliak |
i thought the association would do that automatically? |
# |
Aug 25th 2016, 20:41 |
saliak |
ah, shit. that did it. |
# |
Aug 25th 2016, 20:41 |
btx |
also check your OrderLines table and make sure `product_id` actual exists |
# |
Aug 25th 2016, 20:41 |
btx |
you should be doign something like `$this->Orders->get($id, [â??containâ??=> â??Orders.OrderLines.Productsâ??])` |
# |
Aug 25th 2016, 20:39 |
saliak |
that error goes away if I remove Products from the contains in the Porducts->get() in my view action |
# |
Aug 25th 2016, 20:39 |
btx |
oh I meant your php code |
# |
Aug 25th 2016, 20:38 |
saliak |
https://gist.github.com/anonymous/2f9f1e652241c5adaf65d9d54ccf9b84 |
# |
Aug 25th 2016, 20:36 |
btx |
so what does your Query look like |
# |
Aug 25th 2016, 20:36 |
saliak |
yes |
# |
Aug 25th 2016, 20:35 |
btx |
Products* |
# |
Aug 25th 2016, 20:35 |
btx |
and OrderLines belongsTo Product? |
# |
Aug 25th 2016, 20:35 |
saliak |
yes, it does |
# |
Aug 25th 2016, 20:34 |
saliak |
hold on |
# |
Aug 25th 2016, 20:34 |
saliak |
oh |
# |
Aug 25th 2016, 20:34 |
saliak |
yes |
# |
Aug 25th 2016, 20:34 |
btx |
@saliak ** |