diff --git a/dotenv-example b/dotenv-example index f19d598ecb..9f3ca6c410 100644 --- a/dotenv-example +++ b/dotenv-example @@ -73,6 +73,9 @@ MAX_PRICE_SERIES_SONYPS5DE= MAX_PRICE_SERIES_XBOXSS= MAX_PRICE_SERIES_XBOXSX= MAX_PRICE_SERIES_TEST= +MAX_PRICE_SERIES_UDM_PRO= +MAX_PRICE_SERIES_UDM_US= +MAX_PRICE_SERIES_UDR_US= MICROCENTER_LOCATION= MQTT_BROKER_ADDRESS= MQTT_BROKER_PORT= diff --git a/src/config.ts b/src/config.ts index a46f7fe5cb..c862ce9bd9 100644 --- a/src/config.ts +++ b/src/config.ts @@ -428,6 +428,9 @@ const store = { sonyps5c: envOrNumber(process.env.MAX_PRICE_SERIES_SONYPS5C), sonyps5de: envOrNumber(process.env.MAX_PRICE_SERIES_SONYPS5DE), 'test:series': envOrNumber(process.env.MAX_PRICE_SERIES_TEST), + 'udm-pro': envOrNumber(process.env.MAX_PRICE_SERIES_UDM_PRO), + 'udm-us': envOrNumber(process.env.MAX_PRICE_SERIES_UDM_US), + 'udr-us': envOrNumber(process.env.MAX_PRICE_SERIES_UDR_US), xboxss: envOrNumber(process.env.MAX_PRICE_SERIES_XBOXSS), xboxsx: envOrNumber(process.env.MAX_PRICE_SERIES_XBOXSX), }, @@ -460,6 +463,9 @@ const store = { 'sf', 'sonyps5c', 'sonyps5de', + 'udm-pro', + 'udm-us', + 'udr-us', 'xboxss', 'xboxsx', ]), diff --git a/src/store/model/index.ts b/src/store/model/index.ts index 08a65a9768..f7a653fe8b 100644 --- a/src/store/model/index.ts +++ b/src/store/model/index.ts @@ -154,6 +154,7 @@ import {TescoIE} from './tesco-ie'; import {TheWarehouse} from './thewarehouse'; import {TopAchat} from './topachat'; import {ToysRUs} from './toysrus'; +import {Ubiquiti} from './ubiquiti'; import {Umart} from './umart'; import {Unieuro} from './unieuro'; import {Very} from './very'; @@ -328,6 +329,7 @@ export const storeList = new Map([ [TopAchat.name, TopAchat], [ToysRUs.name, ToysRUs], [Umart.name, Umart], + [Ubiquiti.name, Ubiquiti], [Unieuro.name, Unieuro], [UltimaInformatica.name, UltimaInformatica], [Very.name, Very], diff --git a/src/store/model/store.ts b/src/store/model/store.ts index c23820062c..2975567d3f 100644 --- a/src/store/model/store.ts +++ b/src/store/model/store.ts @@ -30,10 +30,11 @@ export type Brand = | 'nvidia' | 'palit' | 'pny' + | 'powercolor' | 'sapphire' | 'sony' + | 'ubiquiti' | 'xfx' - | 'powercolor' | 'zotac'; export type Series = @@ -59,6 +60,9 @@ export type Series = | 'sonyps5c' | 'sonyps5de' | 'sf' + | 'udm-pro' + | 'udm-us' + | 'udr-us' | 'xboxsx' | 'xboxss'; @@ -91,6 +95,9 @@ export type Model = | 'challenger pro' | 'challenger pro oc' | 'crosshair viii' + | 'dream machine' + | 'dream machine pro' + | 'dream router' | 'dual fan' | 'dual oc' | 'dual' diff --git a/src/store/model/ubiquiti.ts b/src/store/model/ubiquiti.ts new file mode 100644 index 0000000000..57d0c83974 --- /dev/null +++ b/src/store/model/ubiquiti.ts @@ -0,0 +1,44 @@ +import {Store} from './store'; + +export const Ubiquiti: Store = { + currency: '$', + labels: { + inStock: [ + { + container: '#titleInStockBadge', + text: ['In Stock'], + }, + ], + outOfStock: [ + { + container: '.titleSoldOutBadge', + text: ['Sold Out'], + }, + { + container: '#titleSoldOutBadge', + text: ['Sold Out'], + }, + ], + }, + links: [ + { + brand: 'ubiquiti', + model: 'dream machine', + series: 'udm-us', + url: 'https://store.ui.com/collections/unifi-network-unifi-os-consoles/products/udm-us', + }, + { + brand: 'ubiquiti', + model: 'dream machine pro', + series: 'udm-pro', + url: 'https://store.ui.com/collections/unifi-network-unifi-os-consoles/products/udm-pro', + }, + { + brand: 'ubiquiti', + model: 'dream router', + series: 'udr-us', + url: 'https://store.ui.com/collections/unifi-network-unifi-os-consoles/products/dream-router', + }, + ], + name: 'ubiquiti', +};