# |
Jul 20th 2017, 16:12 |
inoas |
well "works" as in you can see things ;) |
# |
Jul 20th 2017, 16:12 |
inoas |
if you pull that and just run OptionsBuilderTest.php in some browser/console it already works |
# |
Jul 20th 2017, 16:12 |
inoas |
but yes I read that and to look in the console io |
# |
Jul 20th 2017, 16:11 |
inoas |
Sadly it blows my head right now... already |
# |
Jul 20th 2017, 16:10 |
jeremyharris |
I like the concept so far. Did you take a look at my comment about re-using the validator class? |
# |
Jul 20th 2017, 16:10 |
inoas |
the schema validator is only started... string and int type |
# |
Jul 20th 2017, 16:10 |
inoas |
but you don't have to |
# |
Jul 20th 2017, 16:10 |
inoas |
you can add all the methods to be setters for the options builder |
# |
Jul 20th 2017, 16:09 |
inoas |
jeremy well here is at least some idea/concept https://github.com/inoas/options/blob/master/OptionBuilderTest.php |
# |
Jul 20th 2017, 15:54 |
admad |
Separate flash message pages were the stupidest thing |
# |
Jul 20th 2017, 15:40 |
shuyi |
magic is one of the bad things about PHP ... which I think is why nice things like Visual Studio don't come to us ... |
# |
Jul 20th 2017, 15:38 |
shuyi |
and doing grandfather coding styles |
# |
Jul 20th 2017, 15:38 |
jeremyharris |
remnants from rails inspiration I think |
# |
Jul 20th 2017, 15:38 |
shuyi |
I inherited this code from someone who loved doing copy and paste ... |
# |
Jul 20th 2017, 15:38 |
inoas |
magic! |
# |
Jul 20th 2017, 15:38 |
dereuromark |
yeah, totally uncool |
# |
Jul 20th 2017, 15:38 |
jeremyharris |
way back in the day :slightly_smiling_face: would redirect to an actual view if I recall |
# |
Jul 20th 2017, 15:38 |
inoas |
there was controller::flash() oO ;)( |
# |
Jul 20th 2017, 15:37 |
inoas |
shyui it removed $this->Session->setFlash ages ago |
# |
Jul 20th 2017, 15:36 |
shuyi |
@dereuromark you are my hero ... the upgrade tool from cake themselves, does not even as well as yours |
# |
Jul 20th 2017, 15:36 |
dereuromark |
You can also use https://github.com/dereuromark/cakephp-flash and have even more awesome flash messaging support :slightly_smiling_face: |
# |
Jul 20th 2017, 15:35 |
dereuromark |
use the component (Flash) - $this->Flash->success() as we all do |
# |
Jul 20th 2017, 15:35 |
dereuromark |
oh yeah that one was an anti pattern |
# |
Jul 20th 2017, 15:35 |
shuyi |
```Controller::flash() has been removed. This method was rarely used in real applications and served no purpose anymore.``` |
# |
Jul 20th 2017, 15:35 |
dereuromark |
It was long time ago removed from Session into its own Component, maybe you confused a few things here |
# |
Jul 20th 2017, 15:34 |
dereuromark |
As long as there are websites on this planet outputting flash messages cake will always have a Flash messenger tooling :slightly_smiling_face: |
# |
Jul 20th 2017, 15:34 |
jeremyharris |
hehe |
# |
Jul 20th 2017, 15:33 |
dereuromark |
Only I typed with less beer :P |
# |
Jul 20th 2017, 15:33 |
jeremyharris |
:) |
# |
Jul 20th 2017, 15:33 |
dereuromark |
LOOOL |
# |
Jul 20th 2017, 15:33 |
jeremyharris |
where did you read that? |
# |
Jul 20th 2017, 15:33 |
dereuromark |
where did you read that? |
# |
Jul 20th 2017, 15:32 |
shuyi |
hey guys, I read that Cake 3 decided to remove $this->Flash from Controller, so what is the best way to import it ? thanks |
# |
Jul 20th 2017, 15:26 |
inoas |
https://gist.github.com/inoas/a7b435a28616231f304fe6c305245f35 :) updated now that will also shrink my code |
# |
Jul 20th 2017, 15:09 |
inoas |
hm controller is using + ... $this->viewVars = $data + $this->viewVars; |
# |
Jul 20th 2017, 15:07 |
inoas |
well admad thanks for pointing out how easy it is... now with this adding more serialized variables in beforeRender etc works https://gist.github.com/inoas/a7b435a28616231f304fe6c305245f35 |
# |
Jul 20th 2017, 15:07 |
jeremyharris |
heh no worries |
# |
Jul 20th 2017, 15:06 |
eBugg |
I owe you one |
# |
Jul 20th 2017, 15:06 |
eBugg |
jeremyharris: one of the guys copy/pasted old non-sense js at the end of the template |
# |
Jul 20th 2017, 15:03 |
jeremyharris |
eBugg glad to help |
# |
Jul 20th 2017, 15:03 |
eBugg |
jeremyharris: I think I was able to track it down. Js indeed as you said. Thank you for the debug($this->Form) stuff. I didn't know about it. |