# |
Jun 12th 2019, 13:42 |
ricksaccous |
I think the answer is yessssss |
# |
Jun 12th 2019, 13:40 |
ondrej.nedvidek |
Hi there ;) ``` Select id, column1, null as column2 from tableA UNION Select id, column1, column2 from tableB ``` Does anybody know how to specify `union` null fields? As example above |
# |
Jun 12th 2019, 13:40 |
ricksaccous |
that supports multiple tables |
# |
Jun 12th 2019, 13:40 |
ricksaccous |
would the best way to go about that be to write my own resolver |
# |
Jun 12th 2019, 13:40 |
ricksaccous |
if i wanted to potentially verify users across multiple tables |
# |
Jun 12th 2019, 13:40 |
ricksaccous |
so |
# |
Jun 12th 2019, 13:35 |
niel45 |
many thanks |
# |
Jun 12th 2019, 13:35 |
neon1024 |
:thumbsup: |
# |
Jun 12th 2019, 13:34 |
niel45 |
@neon1024 looks like that fixed it |
# |
Jun 12th 2019, 13:32 |
niel45 |
definitely |
# |
Jun 12th 2019, 13:32 |
neon1024 |
Might be worth a go |
# |
Jun 12th 2019, 13:31 |
niel45 |
err no |
# |
Jun 12th 2019, 13:31 |
neon1024 |
niel45, Did you clear your composer cache? |
# |
Jun 12th 2019, 13:27 |
niel45 |
nope, that doesn't help |
# |
Jun 12th 2019, 13:26 |
niel45 |
I'll try deleting the composer.lock and doing composer install |
# |
Jun 12th 2019, 13:24 |
niel45 |
damn. I have no idea why it suddenly stopped working, or how to fix it |
# |
Jun 12th 2019, 13:24 |
Arckame |
niel45, composer is ok for me |
# |
Jun 12th 2019, 13:17 |
niel45 |
Is anybody else having problems with 'composer update'? It has been failing since yesterday for me, being unable to install cakephp/migrations because it cannot find a matching package for symfony/yaml |
# |
Jun 12th 2019, 13:15 |
dereuromark |
nah for session (stateful) this is not a good idea as static |
# |
Jun 12th 2019, 13:15 |
Arckame |
@dereuromark yep, but it use session. Not the best way of just codes and labels. using a static function (like with Number or Hash helpers) looks better. but thank you for the advice :) |
# |
Jun 12th 2019, 13:12 |
dereuromark |
you can pass down info, see how tinyauth AuthUser does it |
# |
Jun 12th 2019, 13:11 |
Arckame |
the helper function is now static... :D |
# |
Jun 12th 2019, 13:11 |
Arckame |
it was obvious... |
# |
Jun 12th 2019, 13:11 |
Arckame |
ok found... |
# |
Jun 12th 2019, 13:11 |
Arckame |
... |
# |
Jun 12th 2019, 13:09 |
Arckame |
Any idea ? |
# |
Jun 12th 2019, 13:09 |
Arckame |
As I don't want to have labels store in both helper and component / controller, what can I do ? maintaining a table ? (not sure it's the best way). Is there is a way to a component to access an Helper or for an Helper access an component ? |
# |
Jun 12th 2019, 13:08 |
Arckame |
In an online payment application, I know from the bank a return code list and the corresponding labels. As these labels can be used in multiples pages, I created an helper. And because it's in a helper, it's not availble from my controllers. but in the case of an excel extract, the excel file is build in a controller and I can't access the helper. |
# |
Jun 12th 2019, 13:08 |
Arckame |
hello |
# |
Jun 12th 2019, 11:12 |
skor |
$apiClient = new \GuzzleHttp\Client(); $remoteFile = $apiClient->request(‘GET’, ’http://remotefile/location')->getBody(); return $this->response ->withStringBody((string) $remoteFile) ->withType(‘pdf’) ->withDownload(‘YourFile.pdf’); |
# |
Jun 12th 2019, 11:12 |
skor |
``` |
# |
Jun 12th 2019, 11:12 |
skor |
ok, figured it out, if this helps anyone: |
# |
Jun 12th 2019, 11:09 |
conehead |
Isn't it possible to copy (part of) the headers as well as the body? |
# |
Jun 12th 2019, 11:01 |
slackebot1 |
thanks |
# |
Jun 12th 2019, 11:01 |
skor |
hey everyone! im downloading a file in cake with guzzle. file is generated by another container in the stack, the “other” container is inaccessible via the public network, its only accessible for my frontend. so, i would like to forward that file directly from the controller with the response, i tried withFile but that checks for a local file, and i would like to avoid saving it, then forwarding it, then having to delete it is there a way? |
# |
Jun 12th 2019, 10:04 |
neon1024 |
Thanks for the clarification @edgaras.jan :thumbsup: |
# |
Jun 12th 2019, 10:03 |
leon |
ok, thank you! |
# |
Jun 12th 2019, 10:03 |
edgaras.jan |
csrf is just random data, security component is hash of fields |
# |
Jun 12th 2019, 09:59 |
neon1024 |
Well, the locked fields, obviously if you unlock fields they are omitted I think |
# |
Jun 12th 2019, 09:59 |
neon1024 |
I believe so, as the token is a hash of the fields |
# |
Jun 12th 2019, 09:57 |
leon |
Is the from helper connected to csrf token, so that he knows which input was generated by cake? |