# |
Mar 13th 2019, 22:39 |
rochasmarcelo |
please try using develop branch |
# |
Mar 13th 2019, 22:38 |
challgren |
Damm |
# |
Mar 13th 2019, 22:38 |
challgren |
Ahh yeah ^8.0 |
# |
Mar 13th 2019, 22:38 |
rochasmarcelo |
It's using 8.0 |
# |
Mar 13th 2019, 22:38 |
rochasmarcelo |
The example repo seems to be using wrong cakedc/users version |
# |
Mar 13th 2019, 22:35 |
challgren |
This is my Application.php |
# |
Mar 13th 2019, 22:33 |
challgren |
Its almost like the plugin.php middleware isnt being called |
# |
Mar 13th 2019, 22:33 |
rochasmarcelo |
let me check one thing |
# |
Mar 13th 2019, 22:32 |
challgren |
https://challgren.geoclique.me/login |
# |
Mar 13th 2019, 22:32 |
challgren |
Weird Im following that and when I try to login I get The request object does not contain the required ‘authentication’ attribute |
# |
Mar 13th 2019, 22:25 |
rochasmarcelo |
@challgren https://github.com/CakeDC/users-example this is 'work in progress' but could help. |
# |
Mar 13th 2019, 20:47 |
challgren |
@steinkel or @CakeDC team do you have any example apps with CakeDC/Users dev-develop loaded? Running into some issues and would be helpful to look at an example. The develop docs are all over the place |
# |
Mar 13th 2019, 19:35 |
ricksaccous |
not sure if you already looked at that |
# |
Mar 13th 2019, 19:35 |
ricksaccous |
@tunafish https://book.cakephp.org/3.0/en/orm/query-builder.html#subqueries |
# |
Mar 13th 2019, 18:38 |
ruc0la |
is the configuration correct and the problem is somewhere else? |
# |
Mar 13th 2019, 18:38 |
ruc0la |
this cakephp2 was installed with composer and I get server error (500) |
# |
Mar 13th 2019, 18:38 |
slackebot |
<ruc0la> |
# |
Mar 13th 2019, 18:37 |
ruc0la |
Hey all, Can somebody assist me with some nginx configuration for cakephp2? |
# |
Mar 13th 2019, 18:08 |
slackebot |
+-----------+---------------+---------+---------------------+ ``` The part which I can't figure out and can't find in the docs, is how to alias the table in the subquery. Any help would be greatly appreciated. |
# |
Mar 13th 2019, 18:08 |
slackebot |
query which fetches the current version for every `software_name` in the table. The SQL which does this, looks like this: ``` select server_id, software_name, version, state_date from server_software_versions WHERE state_date = (select MAX(myAlias.state_date) FROM server_software_versions myAlias WHERE server_software_versions.software_name = myAlias.software_name) order by state_date; ``` The results of this query: ``` |
# |
Mar 13th 2019, 18:08 |
slackebot |
+-----------+---------------+---------+---------------------+ | server_id | software_name | version | state_date | +-----------+---------------+---------+---------------------+ | 7 | keepalived | 1.2.13 | 2018-06-12 09:22:01 | | 7 | haproxy | 1.7.11 | 2018-06-18 13:00:46 | | 7 | filebeat | 5.6.10 | 2018-06-18 13:00:46 | | 7 | exim | 4.84_2 | 2018-06-18 13:00:46 | |
# |
Mar 13th 2019, 18:08 |
slackebot |
2018-06-12 09:22:01 | | 7 | 7 | keepalived | 1.2.13 | 2018-06-12 09:22:01 | | 8 | 7 | exim | 4.84_2 | 2018-06-12 09:22:01 | | 9 | 7 | haproxy | 1.7.11 | 2018-06-18 13:00:46 | | 10 | 7 | filebeat | 5.6.10 | 2018-06-18 13:00:46 | | 11 | 7 | exim | 4.84_2 | 2018-06-18 13:00:46 | +----+-----------+---------------+---------+---------------------+ ``` What I want, is to have on |
# |
Mar 13th 2019, 18:08 |
slackebot |
+----+-----------+---------------+---------+---------------------+ | 1 | 7 | haproxy | 1.7.11 | 2018-06-05 17:23:10 | | 2 | 7 | filebeat | 5.6.9 | 2018-06-05 17:23:10 | | 3 | 7 | keepalived | 1.2.13 | 2018-06-05 17:23:10 | | 4 | 7 | exim | 4.84_2 | 2018-06-05 17:23:10 | | 5 | 7 | haproxy | 1.7.11 | 2018-06-12 09:22:01 | | 6 | 7 | filebeat | 5.6.9 | |
# |
Mar 13th 2019, 18:08 |
tunafish |
Hi everyone! I'm having some trouble writing a query in the ORM. It uses a where with a subquery referencing the main query to select the row with a maximum value in it, and aliases the table in the subquery. I'll clarify: My table looks like this: ``` +----+-----------+---------------+---------+---------------------+ | id | server_id | software_name | version | state_date | |
# |
Mar 13th 2019, 16:41 |
this.impetus |
ah ha. ok. tyvm. I'm on my way now |
# |
Mar 13th 2019, 16:32 |
this.impetus |
So in the example page you linked, the key 'photo'—is that a sample field name? Or should the photos array contain a "fields" key? |
# |
Mar 13th 2019, 16:27 |
this.impetus |
sadly I'm someone who doesn't reallllly understand cake but once I learn to accomplish a thing I can repeat it lol. assembling enough pieces eventually passes for competence |
# |
Mar 13th 2019, 16:26 |
this.impetus |
yeah I guessed as much. seems like a pretty cakey logic |
# |
Mar 13th 2019, 16:26 |
ricksaccous |
okay, to give you a further hint it has to do with the name of your image field in the actual upload form |
# |
Mar 13th 2019, 16:25 |
this.impetus |
second I am looking at my project and trying to understand what you're suggesting before asking further questions |
# |
Mar 13th 2019, 16:25 |
ricksaccous |
hehe |
# |
Mar 13th 2019, 16:25 |
this.impetus |
I *definitely* need to better understand cake.. I used cake2 a *lot* once upon a time, I am totally lost with 3+ |
# |
Mar 13th 2019, 16:25 |
ricksaccous |
you are making these configuration changes where you add the behavior, most likely in your model's initialize |
# |
Mar 13th 2019, 16:24 |
ricksaccous |
in the behavior set up |
# |
Mar 13th 2019, 16:24 |
ricksaccous |
you need to dig deeper into reading about the configuration/docs and if you're not understanding what you're reading you probably need to understand more about cake but basically your image field name has to be configured |
# |
Mar 13th 2019, 16:23 |
ricksaccous |
hehe |
# |
Mar 13th 2019, 16:23 |
this.impetus |
I don't think, sorry, that I really understand the fields option. What's their purpose/function? |
# |
Mar 13th 2019, 16:22 |
this.impetus |
Nope; paths exist, permissions correct |
# |
Mar 13th 2019, 16:22 |
ricksaccous |
but those are possible as well |
# |
Mar 13th 2019, 16:22 |
ricksaccous |
it could be a number of issues, including you might not have your fields option set up correctly |
# |
Mar 13th 2019, 16:21 |
neon1024 |
Perhaps the folder doesn’t exist, or there is a permissions issue? |