Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Update broken norwegian stores and add 5080/5090 products #3220

Closed
wants to merge 8 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ RUN npm prune --production

FROM node:16.18.0-alpine3.16

RUN apk add --no-cache chromium
RUN apk add --no-cache chromium npm

ENV PUPPETEER_EXECUTABLE_PATH=/usr/bin/chromium-browser \
DOCKER=true
Expand All @@ -39,5 +39,5 @@ COPY --from=builder /build/build/ build/
COPY web/ web/
COPY package.json package.json

ENTRYPOINT ["npm", "run"]
ENTRYPOINT [ "sh", "-c", "which npm && npm run" ]
CMD ["start:production"]
24 changes: 8 additions & 16 deletions src/store/model/elkjop.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
labels: {
inStock: {
container:
'#product-detail-wrapper > div.col.any-5-12.M-2-5.information > div.buy-button-container.align-left.any-1-1.table-btn > div > div > div.product-price-button-wrap > div > div > span > span',
text: ['Legg i handlevogn'],
'.border-t-0 > div:nth-child(1) > div:nth-child(3) > button:nth-child(1)',
text: ['Legg i handlekurv'],
},
maxPrice: {
container: '.product-price-container > span:nth-child(1)',
Expand All @@ -22,32 +22,24 @@
brand: 'test:brand',
model: 'test:model',
series: 'test:series',
cartUrl:
'https://www.elkjop.no/INTERSHOP/web/WFS/store-elkjop-Site/no_NO/-/NOK/ViewCart-AddProductByAjax?SKU=218425&Quantity=1&AddToCart=true',
url: 'https://www.elkjop.no/product/mobil-og-gps/mobiltelefon/296618/oneplus-9-pro-5g-smarttelefon-12256gb-stellar-black',
url: 'https://www.elkjop.no/product/mobil-nettbrett-og-smartklokker/mobiltelefon/iphone-16-pro-5g-smarttelefon-128gb-sort-titan/825109',
},
{
brand: 'pny',
model: 'xlr8 epic x',
series: '3090',
cartUrl:
'https://www.elkjop.no/INTERSHOP/web/WFS/store-elkjop-Site/no_NO/-/NOK/ViewCart-AddProductByAjax?SKU=215370&Quantity=1&AddToCart=true',
url: 'https://www.elkjop.no/product/data/pc-komponenter/grafikkort/215370/pny-rtx-3090-24gb-xlr8-gaming-epic-x-rgb-3-fan-2-7slot',
},
brand: 'asus',
model: 'tuf gaming oc',
series: '5080',
url: 'https://www.elkjop.no/product/gaming/pc-komponenter/grafikkort-gpu/asus-geforce-rtx-5080-rog-tuf-gaming-16gb-oc-grafikkort/883821',

Check failure on line 31 in src/store/model/elkjop.ts

View workflow job for this annotation

GitHub Actions / Build and lint

Delete `··`
},

Check failure on line 32 in src/store/model/elkjop.ts

View workflow job for this annotation

GitHub Actions / Build and lint

Delete `··`
{
brand: 'evga',
model: 'xc3',
series: '3080',
cartUrl:
'https://www.elkjop.no/INTERSHOP/web/WFS/store-elkjop-Site/no_NO/-/NOK/ViewCart-AddProductByAjax?SKU=218419&Quantity=1&AddToCart=true',
url: 'https://www.elkjop.no/product/data/pc-komponenter/grafikkort/218419/evga-geforce-rtx-3080-xc3',
},
{
brand: 'evga',
model: 'xc3 black',
series: '3080',
cartUrl:
'https://www.elkjop.no/INTERSHOP/web/WFS/store-elkjop-Site/no_NO/-/NOK/ViewCart-AddProductByAjax?SKU=218425&Quantity=1&AddToCart=true',
url: 'https://www.elkjop.no/product/data/pc-komponenter/grafikkort/218425/evga-geforce-rtx-3080-xc3-black',
},
{
Expand Down
226 changes: 215 additions & 11 deletions src/store/model/komplett-no.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
labels: {
inStock: {
container:
'#MainContent > div.no-bs-center.maincontent-container.container.main-body.ignore-gutter-xs.product-page-boxes > div.responsive-content-wrapper > div.product-page > section > div > section > div.product-main-info__body > div.product-main-info__buy-and-more > div.buy-button-section > div > div > div.product-main-info-buy-button > div.buy-button > button',
text: ['LEGG I HANDLEVOGN'],
'.product-main-info-buy-button > div:nth-child(1) > button:nth-child(1)',
text: ['LEGG I HANDLEKURV'],
},
outOfStock: {
container:
Expand All @@ -19,20 +19,224 @@
brand: 'test:brand',
model: 'test:model',
series: 'test:series',
url: 'https://www.komplett.no/product/1168415/',
url: 'https://www.komplett.no/product/1307896/pc-nettbrett/nettbrett-ipad-lesebrett/nettbrett-ipad/xiaomi-redmi-pad-se-128gb-graphite-gray',
},
{
brand: 'msi',
model: 'gaming x trio',
series: '3080',
url: 'https://www.komplett.no/product/1168380/',
brand: 'gainward',
model: 'phantom',
series: '5090',
url: 'https://www.komplett.no/product/1318990/datautstyr/pc-komponenter/skjermkort/gainward-geforce-rtx-5090-phantom',
},
{
brand: 'msi',
model: 'suprim x',
series: '3080',
url: 'https://www.komplett.no/product/1173669',
brand: 'gigabyte',
model: 'gaming oc',
series: '5090',
url: 'https://www.komplett.no/product/1319436/datautstyr/pc-komponenter/skjermkort/gigabyte-geforce-rtx-5090-gaming-oc',
},
{
brand: 'gigabyte',
model: 'aorus master',
series: '5090',
url: 'https://www.komplett.no/product/1319418/datautstyr/pc-komponenter/skjermkort/gigabyte-aorus-geforce-rtx-5090-master',
},
{
brand: 'gigabyte',
model: 'windforce oc',
series: '5090',
url: 'https://www.komplett.no/product/1319443/datautstyr/pc-komponenter/skjermkort/gigabyte-geforce-rtx-5090-windforce-oc',
},
{
brand: 'gigabyte',
model: 'master ice',
series: '5090',
url: 'https://www.komplett.no/product/1319444/datautstyr/pc-komponenter/skjermkort/gigabyte-aorus-geforce-rtx-5090-master-ice',
},

Check failure on line 53 in src/store/model/komplett-no.ts

View workflow job for this annotation

GitHub Actions / Build and lint

Delete `····`

Check failure on line 53 in src/store/model/komplett-no.ts

View workflow job for this annotation

GitHub Actions / Build and lint

Trailing spaces not allowed
{
brand: 'msi',
model: 'gaming trio oc',
series: '5090',
url: 'https://www.komplett.no/product/1319408/datautstyr/pc-komponenter/skjermkort/msi-geforce-rtx-5090-gaming-trio-oc',
},

Check failure on line 59 in src/store/model/komplett-no.ts

View workflow job for this annotation

GitHub Actions / Build and lint

Delete `········`

Check failure on line 59 in src/store/model/komplett-no.ts

View workflow job for this annotation

GitHub Actions / Build and lint

Trailing spaces not allowed
{
brand: 'msi',
model: 'ventus 3x oc',
series: '5090',
url: 'https://www.komplett.no/product/1319421/datautstyr/pc-komponenter/skjermkort/msi-geforce-rtx-5090-ventus-3x-oc',
},

Check failure on line 65 in src/store/model/komplett-no.ts

View workflow job for this annotation

GitHub Actions / Build and lint

Delete `······`

Check failure on line 65 in src/store/model/komplett-no.ts

View workflow job for this annotation

GitHub Actions / Build and lint

Trailing spaces not allowed
{
brand: 'msi',
model: 'suprim soc',
series: '5090',
url: 'https://www.komplett.no/product/1319422/datautstyr/pc-komponenter/skjermkort/msi-geforce-rtx-5090-suprim-soc',
},

Check failure on line 71 in src/store/model/komplett-no.ts

View workflow job for this annotation

GitHub Actions / Build and lint

Delete `····`

Check failure on line 71 in src/store/model/komplett-no.ts

View workflow job for this annotation

GitHub Actions / Build and lint

Trailing spaces not allowed
{
brand: 'asus',
model: 'astral',
series: '5090',
url: 'https://www.komplett.no/product/1319468/datautstyr/pc-komponenter/skjermkort/asus-rog-astral-geforce-rtx-5090',
},
{
brand: 'asus',
model: 'tuf gaming oc',
series: '5090',
url: 'https://www.komplett.no/product/1319469/datautstyr/pc-komponenter/skjermkort/asus-tuf-gaming-geforce-rtx-5090-oc',
},
{
brand: 'gigabyte',
model: 'windforce',
series: '5080',
url: 'https://www.komplett.no/product/1318911/datautstyr/pc-komponenter/skjermkort/gigabyte-geforce-rtx-5080-windforce-ssf',
},
{
brand: 'gainward',
model: 'phoenix',
series: '5080',
url: 'https://www.komplett.no/product/1318904/datautstyr/pc-komponenter/skjermkort/gainward-geforce-rtx-5080-phoenix',
},
{
brand: 'palit',
model: 'gamerock oc',
series: '5080',
url: 'https://www.komplett.no/product/1318985/datautstyr/pc-komponenter/skjermkort/palit-geforce-rtx-5080-gamerock-oc',
},
{
brand: 'palit',
model: 'gamerock',
series: '5080',
url: 'https://www.komplett.no/product/1318987/datautstyr/pc-komponenter/skjermkort/palit-geforce-rtx-5080-gamerock',
},
{
brand: 'palit',
model: 'gaming pro oc',
series: '5080',
url: 'https://www.komplett.no/product/1318986/datautstyr/pc-komponenter/skjermkort/palit-geforce-rtx-5080-gamingpro-oc',
},
{
brand: 'palit',
model: 'gaming pro',
series: '5080',
url: 'https://www.komplett.no/product/1318984/datautstyr/pc-komponenter/skjermkort/palit-geforce-rtx-5080-gamingpro',
},
{
brand: 'gainward',
model: 'phantom gs',
series: '5080',
url: 'https://www.komplett.no/product/1318908/datautstyr/pc-komponenter/skjermkort/gainward-geforce-rtx-5080-phantom-gs',
},
{
brand: 'msi',
model: 'gaming trio oc',
series: '5080',
url: 'https://www.komplett.no/product/1319045/datautstyr/pc-komponenter/skjermkort/msi-geforce-rtx-5080-gaming-trio-oc',
},
{
brand: 'msi',
model: 'gaming trio oc white',
series: '5080',
url: 'https://www.komplett.no/product/1319070/datautstyr/pc-komponenter/skjermkort/msi-geforce-rtx-5080-gaming-trio-oc-hvit',
},
{
brand: 'msi',
model: 'ventus 3x oc plus',
series: '5080',
url: 'https://www.komplett.no/product/1319044/datautstyr/pc-komponenter/skjermkort/msi-geforce-rtx-5080-ventus-3x-oc-plus',
},
{
brand: 'gainward',
model: 'phoenix gs',
series: '5080',
url: 'https://www.komplett.no/product/1318909/datautstyr/pc-komponenter/skjermkort/gainward-geforce-rtx-5080-phoenix-gs',
},
{
brand: 'gigabyte',
model: 'aero oc',
series: '5080',
url: 'https://www.komplett.no/product/1318913/datautstyr/pc-komponenter/skjermkort/gigabyte-geforce-rtx-5080-aero-oc',
},
{
brand: 'gigabyte',
model: 'gaming oc',
series: '5080',
url: 'https://www.komplett.no/product/1318910/datautstyr/pc-komponenter/skjermkort/gigabyte-geforce-rtx-5080-gaming-oc',
},
{
brand: 'gigabyte',
model: 'aorus master',
series: '5080',
url: 'https://www.komplett.no/product/1318906/datautstyr/pc-komponenter/skjermkort/gigabyte-geforce-rtx-5080-aorus-master',
},
{
brand: 'msi',
model: 'suprim soc',
series: '5080',
url: 'https://www.komplett.no/product/1319047/datautstyr/pc-komponenter/skjermkort/msi-geforce-rtx-5080-suprim-soc',
},
{
brand: 'gigabyte',
model: 'master ice',
series: '5080',
url: 'https://www.komplett.no/product/1319430/datautstyr/pc-komponenter/skjermkort/gigabyte-aorus-geforce-rtx-5080-master-ice',
},
{
brand: 'zotac',
model: 'solid oc',
series: '5080',
url: 'https://www.komplett.no/product/1319406/datautstyr/pc-komponenter/skjermkort/zotac-gaming-geforce-rtx-5080-solid-oc',
},
{
brand: 'zotac',
model: 'amp extreme infinity',
series: '5080',
url: 'https://www.komplett.no/product/1319407/datautstyr/pc-komponenter/skjermkort/zotac-gaming-geforce-rtx-5080-amp-extreme-infinity',
},
{
brand: 'zotac',
model: 'solid',
series: '5080',
url: 'https://www.komplett.no/product/1319423/datautstyr/pc-komponenter/skjermkort/zotac-gaming-geforce-rtx-5080-solid',
},
{
brand: 'pny',
model: 'gaming',
series: '5080',
url: 'https://www.komplett.no/product/1319103/datautstyr/pc-komponenter/skjermkort/pny-geforce-rtx-5080-argb-oc',
},
{
brand: 'pny',
model: 'gaming',
series: '5080',
url: 'https://www.komplett.no/product/1319104/datautstyr/pc-komponenter/skjermkort/pny-geforce-rtx-5080-oc',
},
{
brand: 'msi',
model: 'ventus 3x oc',
series: '5080',
url: 'https://www.komplett.no/product/1319480/datautstyr/pc-komponenter/skjermkort/msi-geforce-rtx-5080-ventus-3x-oc',
},
{
brand: 'asus',
model: 'tuf',
series: '5080',
url: 'https://www.komplett.no/product/1319346/datautstyr/pc-komponenter/skjermkort/asus-tuf-gaming-geforce-rtx-5080',
},
{
brand: 'asus',
model: 'astral',
series: '5080',
url: 'https://www.komplett.no/product/1319347/datautstyr/pc-komponenter/skjermkort/asus-rog-astral-geforce-rtx-5080',
},
{
brand: 'gigabyte',
model: 'windforce oc',
series: '5080',
url: 'https://www.komplett.no/product/1319417/datautstyr/pc-komponenter/skjermkort/gigabyte-geforce-rtx-5080-windforce-oc-sff',
},
{
brand: 'msi',
model: 'ventus 3x oc white',
series: '5080',
url: 'https://www.komplett.no/product/1319049/datautstyr/pc-komponenter/skjermkort/msi-geforce-rtx-5080-ventus-3x-oc-hvit',
},
{
brand: 'msi',
model: 'ventus 3x oc',
Expand Down
Loading