# |
Jul 5th 2019, 16:11 |
olanowsubomi |
i will show the files to you |
# |
Jul 5th 2019, 16:11 |
olanowsubomi |
ok |
# |
Jul 5th 2019, 16:09 |
ndm |
@olanowsubomi That doesn't really sounds as if it's CakePHP related...? You should probably just show an example, it's hard to tell what exactly your problem is. |
# |
Jul 5th 2019, 16:07 |
slackebot |
since we can move everything into application rules if we want to, I guess it's fine. |
# |
Jul 5th 2019, 16:07 |
ndm |
@ionas Well, you could probably call it an edge case I guess. The current behavior has it's pros and cons, and the lines blur here and there, but IMHO tables should be responsible for providing the contract that defines what's valid, and when it's the table that actually creates/updates the entity, ie via `newEntity()` or `patchEntity()`, then it's IMHO fine that the table supplies the rules. But surely there's also arguments against that, but |
# |
Jul 5th 2019, 15:58 |
slackebot |
respond to the css code. i can show you both file at your request, i would appreciate your consideration. thanks |
# |
Jul 5th 2019, 15:58 |
olanowsubomi |
hello, please can someone help me out with using css on bootstrap, im only used to inline cascading for html but i think it simplier to use external css for bootstrap but im not sure if it giving me problem because it bootstrap html or it just because i did not apply it rightly . both the css file and html is stored in the same directory in my flash drive but i want my ' headerbar' div to show border and change colour but the html wont |
# |
Jul 5th 2019, 15:46 |
inoas |
IMHO the table should only know about primary keys, foreign keys, indexes and constraints |
# |
Jul 5th 2019, 15:46 |
inoas |
but then validate in the table... |
# |
Jul 5th 2019, 15:46 |
inoas |
the split is often confusing where you transform data with mutators and accessors |
# |
Jul 5th 2019, 15:46 |
inoas |
now if a database adapter needs to convert json to text or can take binary json tahts another thing |
# |
Jul 5th 2019, 15:45 |
inoas |
the stateless stuff belongs all into the entity, as does how it converts (abstract) |
# |
Jul 5th 2019, 15:45 |
inoas |
just business rules (stateful) do |
# |
Jul 5th 2019, 15:45 |
inoas |
well I dont think validation belongs into the table class |
# |
Jul 5th 2019, 15:43 |
ndm |
Indeed, CakePHP already ships with a Json type, kinda forgot about it :slightly_smiling_face: As far as entities are concerned, an entity is just a data container, I don't think type conversion is something it should be concerned with. |
# |
Jul 5th 2019, 15:39 |
inoas |
seems the json type is available anyway and all I need to do is mapping the schmea |
# |
Jul 5th 2019, 15:39 |
inoas |
however i wished there was just fromDatabase and toDatabase things in the entity I suppose to make things easier |
# |
Jul 5th 2019, 15:38 |
inoas |
now thats awesome |
# |
Jul 5th 2019, 15:38 |
inoas |
ndm oh there is a 2nd step where I can convert things |
# |
Jul 5th 2019, 15:30 |
ndm |
@scuadra `$date->format('m')` |
# |
Jul 5th 2019, 15:26 |
ndm |
@ionas Sounds like you're looking for a custom database type, see https://book.cakephp.org/3.0/en/orm/database-basics.html#adding-custom-types |
# |
Jul 5th 2019, 15:26 |
scuadra |
How can I get month from FrozenDate with leading zero |
# |
Jul 5th 2019, 15:11 |
inoas |
aka I want to have php arrays in cakephp world and json strings for the database? (yeah I know it is just for simple persistence trickery)? |
# |
Jul 5th 2019, 15:10 |
inoas |
is there a way to differentiate between marshalling for php memory and marshalling into an entity for saving to the database |
# |
Jul 5th 2019, 15:09 |
inoas |
hi |
# |
Jul 5th 2019, 15:02 |
rochasmarcelo |
Could you provide the full error with trace info? |
# |
Jul 5th 2019, 14:54 |
joey.mukherjee |
Yes |
# |
Jul 5th 2019, 14:52 |
rochasmarcelo |
Are you able to access /profile without changing routes.php? |
# |
Jul 5th 2019, 14:50 |
joey.mukherjee |
@rochasmarcelo, on the second "url", do you mean error? If so, its /admin/queue. I have `Router::prefix('admin', function ($routes) {...` in my routes.php as well. Probably should mention that. |
# |
Jul 5th 2019, 14:48 |
rochasmarcelo |
@joey.mukherjee which url do you get this url? |
# |
Jul 5th 2019, 14:45 |
joey.mukherjee |
I am using the Queue plugin and the CakeDC users plugin, but I can't navigate to /admin/queue without having ``` $routes->connect ('/profile', ['plugin' => 'CakeDC/Users', 'controller' => 'Users', 'action' => 'profile']); $routes->connect ('/logout', ['plugin' => 'CakeDC/Users', 'controller' => 'Users', 'action' => 'logout']);``` explicitly in my routes.php. If don't have that, I get an Missing Routes error. Why is that? |
# |
Jul 5th 2019, 14:26 |
josbeir |
add line in robots.txt => Disallow: / |
# |
Jul 5th 2019, 14:22 |
allan088 |
Hi, is there a way to prevent search bots from indexing websites that are still under development? I'm using CakePhp 3.7 |
# |
Jul 5th 2019, 14:03 |
ndm |
@kiwi_60 A behavior can unload itself via the table object that it is attached to, but you should probably avoid loading the behavior in a table where it would cause recursion in the first place. |
# |
Jul 5th 2019, 13:38 |
kiwi_60 |
Hello guys... How can I disable a behavior inside a behavior? I have a log behavior that it's logging itself, so "Maximum function nesting level of '256' reached, aborting!" |
# |
Jul 5th 2019, 12:46 |
ndm |
Same for `IS NOT` btw, it will be converted to `!=` |
# |
Jul 5th 2019, 12:45 |
madbbb |
@ndm hah. thank you |
# |
Jul 5th 2019, 12:45 |
ndm |
@madbbb Just the the `IS` variant, CakePHP will convert it to `=` in case the value is not `null`. |
# |
Jul 5th 2019, 12:41 |
slackebot |
<madbbb> |
# |
Jul 5th 2019, 12:40 |
rchavik |
ok |
# |
Jul 5th 2019, 12:35 |
admad |
you need to convert the dispatchfilter into a middleware |