Skip to content

Comply with best practices, Round 2 #4507

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
Dec 7, 2014
Merged

Conversation

wouterj
Copy link
Member

@wouterj wouterj commented Nov 20, 2014

Q A
Doc fix? yes
New docs? no
Applies to all
Fixed tickets partly #4431

Less other fixes, more find/replace this time to speed up the process. I have one question this time:

  • Should we just mention the use of the param converter (the current case), or update all simple controller examples to the use param converter?


The majority of the work is done by the ``form_row`` helper, which renders
the label, errors and HTML form widget of each field inside a ``div`` tag
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why removing this ? form_row indeed renders the errors of the specific field too

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I misread the code example, added it back now

@@ -106,7 +96,7 @@ from inside a controller::
->add('save', 'submit', array('label' => 'Create Task'))
->getForm();

return $this->render('AcmeTaskBundle:Default:new.html.twig', array(
return $this->render('Default/new.html.twig', array(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@javiereguiluz The official recommendation is to lowercase the directories, correct? That would mean that @Template won't work (even if it were extended to be able to look in the app/Resources/views dir), but that certainly doesn't bother me (and I like the consistency of having lowercased resources). I'm just triple-checking before we make a lot of changes.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lowercase? Then I've done it wrong in the previous PR too, we'll need to do that in a new PR then.

@weaverryan
Copy link
Member

@wouterj I added some notes, but it looks great. The only pending question is for Javier - but I'm pretty positive we need to change the template directories to lower-case.

Thanks for this! I love that you've been taking this on, and I love having an extra set of eyes on these old (as in, originally written years ago) docs.

Cheers!

@wouterj
Copy link
Member Author

wouterj commented Nov 25, 2014

Thanks @weaverryan and @stof! I've fixed the remaining comments

@weaverryan
Copy link
Member

Thanks for your hard work on this Wouter! The trick now is that we need to be extra-vigilant for bugs in the near-term as we change so many little things. The more people that can read through the docs and find any bugs, the better :). Cheers!

@weaverryan weaverryan merged commit 5ee9791 into symfony:2.3 Dec 7, 2014
weaverryan added a commit that referenced this pull request Dec 7, 2014
This PR was merged into the 2.3 branch.

Discussion
----------

Comply with best practices, Round 2

| Q   | A
| --- | ---
| Doc fix? | yes
| New docs? | no
| Applies to | all
| Fixed tickets | partly #4431

Less other fixes, more find/replace this time to speed up the process. I have one question this time:

* Should we just mention the use of the param converter (the current case), or update all simple controller examples to the use param converter?

Commits
-------

5ee9791 Some fixes
fdc460d Minor standard fix for best practices guide
2a97453 Minor tweak
a29f9fb Don't use form() helper
4ef1ef3 Apply best practices to forms
de4fcf4 Use AppBundle instead of AcmeStoreBundle
c8ce507 Other minor fixes
3c71b6d Use AppBundle instead of AcmeDemoBundle
@wouterj wouterj deleted the 4431_batch_2 branch December 7, 2014 22:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants