| @@ 308-319 (lines=12) @@ | ||
| 305 | *  | 
                                |
| 306 | * @return ViewableData_Customised  | 
                                |
| 307 | */  | 
                                |
| 308 | public function index(SS_HTTPRequest $request)  | 
                                |
| 309 |     { | 
                                |
| 310 |         if ($this->getTrigger($request)) { | 
                                |
| 311 | $locations = $this->getLocations();  | 
                                |
| 312 |         } else { | 
                                |
| 313 | $locations = ArrayList::create();  | 
                                |
| 314 | }  | 
                                |
| 315 | ||
| 316 | return $this->customise(array(  | 
                                |
| 317 | 'Locations' => $locations,  | 
                                |
| 318 | ));  | 
                                |
| 319 | }  | 
                                |
| 320 | ||
| 321 | /**  | 
                                |
| 322 | * Return a XML feed of all locations marked "show in locator"  | 
                                |
| @@ 327-338 (lines=12) @@ | ||
| 324 | * @param SS_HTTPRequest $request  | 
                                |
| 325 | * @return HTMLText  | 
                                |
| 326 | */  | 
                                |
| 327 | public function xml(SS_HTTPRequest $request)  | 
                                |
| 328 |     { | 
                                |
| 329 |         if ($this->getTrigger($request)) { | 
                                |
| 330 | $locations = $this->getLocations();  | 
                                |
| 331 |         } else { | 
                                |
| 332 | $locations = ArrayList::create();  | 
                                |
| 333 | }  | 
                                |
| 334 | ||
| 335 | return $this->customise(array(  | 
                                |
| 336 | 'Locations' => $locations,  | 
                                |
| 337 |         ))->renderWith('LocationXML'); | 
                                |
| 338 | }  | 
                                |
| 339 | ||
| 340 | /**  | 
                                |
| 341 | * @return ArrayList|DataList  | 
                                |