src/Controller/API/GuildController.php 1 location
|
@@ 50-58 (lines=9) @@
|
47 |
|
* ) |
48 |
|
* @SWG\Tag(name="guild") |
49 |
|
*/ |
50 |
|
public function collect(GuildCrawler $guildCrawler) |
51 |
|
{ |
52 |
|
$guilds = $this->getDoctrine()->getRepository(Guild::class)->findAll(); |
53 |
|
|
54 |
|
foreach ($guilds as $guild) { |
55 |
|
$guildCrawler->crawl($guild); |
56 |
|
} |
57 |
|
return $this->getHandler()->collect(['guild']); |
58 |
|
} |
59 |
|
|
60 |
|
public function getHandler() |
61 |
|
{ |
src/Controller/API/HookController.php 1 location
|
@@ 25-33 (lines=9) @@
|
22 |
|
/** |
23 |
|
* @Route("/fetch-guild", name="api_guild_collect_users") |
24 |
|
*/ |
25 |
|
public function fetchGuilds(GuildCrawler $crawler) |
26 |
|
{ |
27 |
|
$guilds = $this->getDoctrine()->getRepository(Guild::class)->findAll(); |
28 |
|
foreach ($guilds as $guild) { |
29 |
|
$crawler->crawl($guild); |
30 |
|
} |
31 |
|
|
32 |
|
return JsonResponse::create(['success']); |
33 |
|
} |
34 |
|
/** |
35 |
|
* @Route("/fetch-characters", name="api_collect_characters") |
36 |
|
*/ |