Ticket #634 (closed enhancement: fixed)
describe refresh and refreshRelated in the manual
| Reported by: | chris | Owned by: | somebody |
|---|---|---|---|
| Priority: | minor | Milestone: | 0.11.0 |
| Component: | Documentation | Version: | 0.10.0 |
| Severity: | Keywords: | ||
| Cc: | Has Test: | ||
| Status: | Has Patch: |
Description (last modified by chris) (diff)
UPDATE: Please mention refresh and refreshRelated in the manual.
Old summary: refresh method does not update relationship collections Old description:
$book = new Book();
$book->title = "Jungle Expedition Handbook";
$archimedes = new Author();
$archimedes->name = 'Archimedes Q. Porter';
$archimedes->books[] = $book;
$dummy = $book->authors;
$archimedes->save();
$dummy = $book->authors;
assert( 0 === count($book->authors) );
$book->refresh();
assert( 0 === count($book->authors) );
$doctrine->queryOne("FROM Book");
assert( 1 === count($book->authors) );
This is related to http://doctrine.pengus.net/trac/ticket/622
Change History
Note: See
TracTickets for help on using
tickets.