[TYPO3-mvc] I proudly present...

Susanne Moog typo3 at susannemoog.de
Wed May 27 19:15:08 CEST 2009


Hey Sebastian,


Sebastian Kurfürst schrieb:

> - You can rename the top-level directory "tests" to "Tests" (with
> capital T)

I just renamed it to tests with a lowercase t because of the TYPO3
phpunit extension not recognizing the folder with a capital one. If that
bug is fixed I'll rename it again.

> 
> Inside the Controller:
> - I'd rename "indexConf" to something like "indexConfiguration"
>   or "indexSettings"

done (locally, not in svn)

> - Where dio you get $limit from? I don't see where it is
>   initialized :-)
;-) (locally, not in svn)

> - Never get GET-Parameters with "$_GET['tx_addresses_pi1']['page'];" -
> instead, use an annotation:
> 
> /**
>  * @param integer $currentPage The current page
>  */
> public function indexAction($currentPage = NULL) {
>     // Now, you'll have the parameter inside $currentPage
> }

Hmm... I don't understand. Where do I "fetch" the GET param now? Or how
do I retrieve the value of currentPage?


> - You still have the "Pagebrowser" inside Domain/Model

Whoops. Forgot to delete the file.

> 
> Inside the ViewHelper:
> - You currently call $_GET there - because you want to create a widget.
> Actually we are not yet sure how we can handle these widgets which
> "live" only in the View and change their state on page refresh... So,
> $_GET is ugly but currently I don't know a more fancy solution apart
> from getting stuff from $request directly

I now use this instead:

if($this->variableContainer->get('view')->getRequest()->hasArgument('page'))
{
$currentPage =
$this->variableContainer->get('view')->getRequest()->getArgument('page');
} else {
	$currentPage = 0;
}


> - getLink: You can use the URIHelper - see the Link_ActionViewHelper as
> an example how to fetch the URIHelper. (But beware - we'll still change
> the name and location of the URIHelper when backporting the new FLOW3
> changes before the final 4.3 release)

To be honest I found the URIHelper a bit confusing - and I don't know
how to get back a full <a> tag instead of just the URI, I'll have to
take a deeper look at the weekend.

> 
> That's all my comments for now - I hope it is OK that I give my comments
> here. I really like a lot how much you've done in such a short
> timeframe, and I hope my feedback helps a bit :-)

Thanks for all your feedback, it really helps a lot :-)! Hopefully
sometime in the future I'll be able to write my extension alone again,
but up until that time I really appreciate your help :-)

> 
> Greets from Dresden,

... and back from Bremen.

Susanne


-- 
Susanne Moog
NEUSTA GmbH - www.neusta.de


More information about the TYPO3-project-typo3v4mvc mailing list