feat: add StationTaggingService with supermarket detection

This commit is contained in:
Ovidiu U
2026-04-03 18:49:34 +01:00
parent 7f153fb08d
commit 80a8a9f93b
3 changed files with 107 additions and 7 deletions

View File

@@ -10,10 +10,10 @@ class StationFactory extends Factory
{
public function definition(): array
{
$trading = $this->faker->company();
$trading = 'Station ' . str()->random(8);
return [
'node_id' => hash('sha256', $this->faker->unique()->uuid()),
'node_id' => (string) str()->ulid(),
'trading_name' => $trading,
'brand_name' => $trading,
'is_same_trading_and_brand' => true,
@@ -24,14 +24,14 @@ class StationFactory extends Factory
'permanent_closure' => false,
'permanent_closure_date' => null,
'public_phone_number' => null,
'address_line_1' => $this->faker->streetAddress(),
'address_line_1' => 'Address ' . str()->random(6),
'address_line_2' => null,
'city' => $this->faker->city(),
'city' => 'City ' . str()->random(6),
'county' => null,
'country' => 'England',
'postcode' => strtoupper($this->faker->postcode()),
'lat' => $this->faker->latitude(49.9, 60.9),
'lng' => $this->faker->longitude(-8.2, 1.8),
'postcode' => strtoupper(str()->random(6)),
'lat' => random_int(499, 609) / 10.0,
'lng' => random_int(-82, 18) / 10.0,
'amenities' => [],
'opening_times' => null,
'fuel_types' => ['E10', 'E5'],