From c0e06c4773cd208872c88455e99826764931d2c3 Mon Sep 17 00:00:00 2001 From: Ivan Habunek Date: Wed, 3 Apr 2024 12:32:39 +0200 Subject: [PATCH] Add laptops category --- lib/harvey.ex | 3 ++- lib/harvey/providers/adm.ex | 1 + lib/harvey/providers/elipso.ex | 9 +++++---- lib/harvey/providers/harvey_norman.ex | 9 +++++---- lib/harvey/providers/hgspot.ex | 1 + lib/harvey/providers/instar.ex | 7 ++++--- lib/harvey/providers/links.ex | 1 + lib/harvey/providers/mikronis.ex | 1 + lib/harvey/providers/sancta_domenica.ex | 2 ++ lib/harvey/providers/svijet_medija.ex | 1 + 10 files changed, 23 insertions(+), 12 deletions(-) diff --git a/lib/harvey.ex b/lib/harvey.ex index 7635b82..df50eaa 100644 --- a/lib/harvey.ex +++ b/lib/harvey.ex @@ -19,7 +19,7 @@ defmodule Harvey do Harvey.Providers.Mikronis, Harvey.Providers.SanctaDomenica, Harvey.Providers.SvijetMedija, - Harvey.Providers.Neutrino, + Harvey.Providers.Neutrino # TODO: Mall.hr disabled because it cannot be accessed from the digital # ocean droplet. Investigate. # Harvey.Providers.MallHr, @@ -42,6 +42,7 @@ defmodule Harvey do {:hardware, :cpus, "CPUs"}, {:hardware, :graphics, "Graphic cards"}, {:hardware, :hard_drives, "Hard drives"}, + {:hardware, :laptops, "Laptops"}, {:hardware, :monitors, "Monitors"}, {:hardware, :motherboards, "Motherboards"}, {:hardware, :ram, "RAM"}, diff --git a/lib/harvey/providers/adm.ex b/lib/harvey/providers/adm.ex index fe2641b..f7474b0 100644 --- a/lib/harvey/providers/adm.ex +++ b/lib/harvey/providers/adm.ex @@ -9,6 +9,7 @@ defmodule Harvey.Providers.Adm do cpus: "https://www.adm.hr/procesori-cpu-091/37/", graphics: "https://www.adm.hr/graficke-kartice-gfx-097/41/", hard_drives: "https://www.adm.hr/pohrana-podataka-098/42/", + laptops: "https://www.adm.hr/laptopi/2/l/?catef=10,9,8", monitors: "https://www.adm.hr/business-monitori-052/16/", monitors: "https://www.adm.hr/gaming-monitori-051/15/", monitors: "https://www.adm.hr/uredski-monitori-053/17/", diff --git a/lib/harvey/providers/elipso.ex b/lib/harvey/providers/elipso.ex index edeec39..1048080 100644 --- a/lib/harvey/providers/elipso.ex +++ b/lib/harvey/providers/elipso.ex @@ -6,13 +6,14 @@ defmodule Harvey.Providers.Elipso do @behaviour Provider @categories [ + dish_washers: "https://www.elipso.hr/bijela-tehnika/perilice-posuda/", fridges_freezers: "https://www.elipso.hr/bijela-tehnika/hladnjaci/", fridges_freezers: "https://www.elipso.hr/bijela-tehnika/zamrzivaci/", - washers_dryers: "https://www.elipso.hr/bijela-tehnika/perilice-rublja/", - washers_dryers: "https://www.elipso.hr/bijela-tehnika/susilice-rublja/", - dish_washers: "https://www.elipso.hr/bijela-tehnika/perilice-posuda/", + laptops: "https://www.elipso.hr/informatika/laptopi/", + monitors: "https://www.elipso.hr/informatika/monitori/", tvs: "https://www.elipso.hr/audio__video/televizori/", - monitors: "https://www.elipso.hr/informatika/monitori/" + washers_dryers: "https://www.elipso.hr/bijela-tehnika/perilice-rublja/", + washers_dryers: "https://www.elipso.hr/bijela-tehnika/susilice-rublja/" ] @impl Provider diff --git a/lib/harvey/providers/harvey_norman.ex b/lib/harvey/providers/harvey_norman.ex index 2000bc7..fa0c17d 100644 --- a/lib/harvey/providers/harvey_norman.ex +++ b/lib/harvey/providers/harvey_norman.ex @@ -6,12 +6,13 @@ defmodule Harvey.Providers.HarveyNorman do @behaviour Provider @categories [ - fridges_freezers: "https://www.harveynorman.hr/bijela-tehnika/hladnjaci-i-zamrzivaci", - washers_dryers: "https://www.harveynorman.hr/bijela-tehnika/perilice-i-susilice-rublja", dish_washers: "https://www.harveynorman.hr/bijela-tehnika/perilice-posuda", - tvs: "https://www.harveynorman.hr/audio-video/televizori", + fridges_freezers: "https://www.harveynorman.hr/bijela-tehnika/hladnjaci-i-zamrzivaci", + laptops: "https://www.harveynorman.hr/informatika/laptopi", monitors: "https://www.harveynorman.hr/informatika/racunalna-periferija/monitori", - smartphones: "https://www.harveynorman.hr/mobiteli/smartphone" + smartphones: "https://www.harveynorman.hr/mobiteli/smartphone", + tvs: "https://www.harveynorman.hr/audio-video/televizori", + washers_dryers: "https://www.harveynorman.hr/bijela-tehnika/perilice-i-susilice-rublja" ] @impl Provider diff --git a/lib/harvey/providers/hgspot.ex b/lib/harvey/providers/hgspot.ex index 9e9bb3f..451ddea 100644 --- a/lib/harvey/providers/hgspot.ex +++ b/lib/harvey/providers/hgspot.ex @@ -8,6 +8,7 @@ defmodule Harvey.Providers.Hgspot do @categories [ cpus: "https://www.hgspot.hr/it-oprema/komponente/procesori", graphics: "https://www.hgspot.hr/it-oprema/komponente/graficke-kartice", + laptops: "https://www.hgspot.hr/racunala/prijenosna-racunala/laptopi", motherboards: "https://www.hgspot.hr/it-oprema/komponente/maticne-ploce", ram: "https://www.hgspot.hr/it-oprema/komponente/radna-memorija", smartphones: "https://www.hgspot.hr/mobiteli-i-oprema/mobilni-telefoni/smartphones", diff --git a/lib/harvey/providers/instar.ex b/lib/harvey/providers/instar.ex index a1fa8da..341fe46 100644 --- a/lib/harvey/providers/instar.ex +++ b/lib/harvey/providers/instar.ex @@ -8,10 +8,11 @@ defmodule Harvey.Providers.Instar do @categories [ cpus: "https://www.instar-informatika.hr/procesori/34/", graphics: "https://www.instar-informatika.hr/graficke-kartice/48/", - hard_drives: "https://www.instar-informatika.hr/ssd-diskovi/1809/", - hard_drives: "https://www.instar-informatika.hr/pc-diskovi/449/", - hard_drives: "https://www.instar-informatika.hr/hard-disk-za-laptop/450/", hard_drives: "https://www.instar-informatika.hr/eksterni-hard-diskovi/1810/", + hard_drives: "https://www.instar-informatika.hr/hard-disk-za-laptop/450/", + hard_drives: "https://www.instar-informatika.hr/pc-diskovi/449/", + hard_drives: "https://www.instar-informatika.hr/ssd-diskovi/1809/", + laptops: "https://www.instar-informatika.hr/laptopi/2/", motherboards: "https://www.instar-informatika.hr/maticne-ploce/33/", ram: "https://www.instar-informatika.hr/memorija-za-laptop/758/", ram: "https://www.instar-informatika.hr/memorija/35/" diff --git a/lib/harvey/providers/links.ex b/lib/harvey/providers/links.ex index abd6af5..d6dddf5 100644 --- a/lib/harvey/providers/links.ex +++ b/lib/harvey/providers/links.ex @@ -26,6 +26,7 @@ defmodule Harvey.Providers.Links do graphics: "129", hard_drives: "115", hard_drives: "690", + laptops: "1053", monitors: "244", motherboards: "25", ovens: "1497", diff --git a/lib/harvey/providers/mikronis.ex b/lib/harvey/providers/mikronis.ex index a2ba3d5..1102aa7 100644 --- a/lib/harvey/providers/mikronis.ex +++ b/lib/harvey/providers/mikronis.ex @@ -9,6 +9,7 @@ defmodule Harvey.Providers.Mikronis do cpus: "https://www.mikronis.hr/katalog/informatika/komponente/procesori/", graphics: "https://www.mikronis.hr/katalog/informatika/komponente/graficke-kartice/", hard_drives: "https://www.mikronis.hr/katalog/informatika/komponente/hdd-i-ssd/", + laptops: "https://www.mikronis.hr/katalog/informatika/laptopi/", motherboards: "https://www.mikronis.hr/katalog/informatika/komponente/maticne-ploce/", ram: "https://www.mikronis.hr/katalog/informatika/komponente/memorije-za-racunala/", smartphones: "https://www.mikronis.hr/katalog/elektronika/mobiteli-i-tableti/mobiteli/" diff --git a/lib/harvey/providers/sancta_domenica.ex b/lib/harvey/providers/sancta_domenica.ex index d767e66..83160c0 100644 --- a/lib/harvey/providers/sancta_domenica.ex +++ b/lib/harvey/providers/sancta_domenica.ex @@ -9,12 +9,14 @@ defmodule Harvey.Providers.SanctaDomenica do dish_washers: "https://www.sancta-domenica.hr/bijela-tehnika/perilice-posuda.html", fridges_freezers: "https://www.sancta-domenica.hr/bijela-tehnika/hladnjaci.html", fridges_freezers: "https://www.sancta-domenica.hr/bijela-tehnika/zamrzivaci.html", + # graphics category URL is correct but is currently empty graphics: "https://www.sancta-domenica.hr/racunala-i-periferija/racunalne-komponente/graficke-kartice.html", hard_drives: "https://www.sancta-domenica.hr/racunala-i-periferija/racunalne-komponente/hard-diskovi-ssd.html", hard_drives: "https://www.sancta-domenica.hr/racunala-i-periferija/racunalne-komponente/hdd-ssd-interni.html", + laptops: "https://www.sancta-domenica.hr/racunala-i-periferija/prijenosna-racunala.html", monitors: "https://www.sancta-domenica.hr/racunala-i-periferija/it-monitori/laserski.html", motherboards: "https://www.sancta-domenica.hr/racunala-i-periferija/racunalne-komponente/maticne-ploce.html", diff --git a/lib/harvey/providers/svijet_medija.ex b/lib/harvey/providers/svijet_medija.ex index 6a87b25..2ede665 100644 --- a/lib/harvey/providers/svijet_medija.ex +++ b/lib/harvey/providers/svijet_medija.ex @@ -9,6 +9,7 @@ defmodule Harvey.Providers.SvijetMedija do dish_washers: "https://www.svijet-medija.hr/gg/206/perilice-posuda", fridges_freezers: "https://www.svijet-medija.hr/gg/205/hladnjaci", fridges_freezers: "https://www.svijet-medija.hr/gg/4462/zamrzivaci", + laptops: "https://www.svijet-medija.hr/gg/3/laptopi", ovens: "https://www.svijet-medija.hr/gg/201/ugradbene-pecnice", smartphones: "https://www.svijet-medija.hr/gg/88/mobiteli", tvs: "https://www.svijet-medija.hr/gg/74/televizori", -- 2.45.2