Skip to content

Commit

Permalink
[extension] mountfield - use loyalty if no orig. price
Browse files Browse the repository at this point in the history
And release new extension version
  • Loading branch information
junkycoder committed Oct 21, 2022
1 parent 4818042 commit 5d771bf
Show file tree
Hide file tree
Showing 8 changed files with 35 additions and 28 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ folder.
Release process of extension is fully automated. To start the release process, you have to:
1. [Update extension version](#updating-extension-version)
2. Commit & create tag in github repository in following format: `extension-x.y.z`,
where `x.y.z` is the version you set in previous step. This
where `x.y.z` is the version you set in previous step.


## Web www.hlidacshopu.cz development
Expand Down
40 changes: 20 additions & 20 deletions apple/Hlídač Shopů.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -614,7 +614,7 @@
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 75;
CURRENT_PROJECT_VERSION = 76;
DEVELOPMENT_TEAM = 8P5697C5H7;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = "iOS (ShareExtension)/Info.plist";
Expand All @@ -626,7 +626,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 1.9.46;
MARKETING_VERSION = 1.9.47;
PRODUCT_BUNDLE_IDENTIFIER = "com.topmonks.hlidac-shopu.ShareExtension";
PRODUCT_NAME = "$(TARGET_NAME)";
SDKROOT = iphoneos;
Expand All @@ -641,7 +641,7 @@
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 75;
CURRENT_PROJECT_VERSION = 76;
DEVELOPMENT_TEAM = 8P5697C5H7;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = "iOS (ShareExtension)/Info.plist";
Expand All @@ -653,7 +653,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 1.9.46;
MARKETING_VERSION = 1.9.47;
PRODUCT_BUNDLE_IDENTIFIER = "com.topmonks.hlidac-shopu.ShareExtension";
PRODUCT_NAME = "$(TARGET_NAME)";
SDKROOT = iphoneos;
Expand Down Expand Up @@ -778,7 +778,7 @@
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 75;
CURRENT_PROJECT_VERSION = 76;
DEVELOPMENT_TEAM = 8P5697C5H7;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = "iOS (Extension)/Info.plist";
Expand All @@ -790,7 +790,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 1.9.46;
MARKETING_VERSION = 1.9.47;
OTHER_LDFLAGS = (
"-framework",
SafariServices,
Expand All @@ -809,7 +809,7 @@
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 75;
CURRENT_PROJECT_VERSION = 76;
DEVELOPMENT_TEAM = 8P5697C5H7;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = "iOS (Extension)/Info.plist";
Expand All @@ -821,7 +821,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 1.9.46;
MARKETING_VERSION = 1.9.47;
OTHER_LDFLAGS = (
"-framework",
SafariServices,
Expand All @@ -844,7 +844,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 75;
CURRENT_PROJECT_VERSION = 76;
DEVELOPMENT_TEAM = 8P5697C5H7;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = "iOS (App)/Info.plist";
Expand All @@ -859,7 +859,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.9.46;
MARKETING_VERSION = 1.9.47;
OTHER_LDFLAGS = (
"-framework",
SafariServices,
Expand All @@ -882,7 +882,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 75;
CURRENT_PROJECT_VERSION = 76;
DEVELOPMENT_TEAM = 8P5697C5H7;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = "iOS (App)/Info.plist";
Expand All @@ -897,7 +897,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.9.46;
MARKETING_VERSION = 1.9.47;
OTHER_LDFLAGS = (
"-framework",
SafariServices,
Expand All @@ -919,7 +919,7 @@
buildSettings = {
CODE_SIGN_ENTITLEMENTS = "macOS (Extension)/hlidac shopu.entitlements";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 75;
CURRENT_PROJECT_VERSION = 76;
DEVELOPMENT_TEAM = 8P5697C5H7;
ENABLE_HARDENED_RUNTIME = YES;
GENERATE_INFOPLIST_FILE = YES;
Expand All @@ -932,7 +932,7 @@
"@executable_path/../../../../Frameworks",
);
MACOSX_DEPLOYMENT_TARGET = 10.14;
MARKETING_VERSION = 1.9.46;
MARKETING_VERSION = 1.9.47;
OTHER_LDFLAGS = (
"-framework",
SafariServices,
Expand All @@ -951,7 +951,7 @@
buildSettings = {
CODE_SIGN_ENTITLEMENTS = "macOS (Extension)/hlidac shopu.entitlements";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 75;
CURRENT_PROJECT_VERSION = 76;
DEVELOPMENT_TEAM = 8P5697C5H7;
ENABLE_HARDENED_RUNTIME = YES;
GENERATE_INFOPLIST_FILE = YES;
Expand All @@ -964,7 +964,7 @@
"@executable_path/../../../../Frameworks",
);
MACOSX_DEPLOYMENT_TARGET = 10.14;
MARKETING_VERSION = 1.9.46;
MARKETING_VERSION = 1.9.47;
OTHER_LDFLAGS = (
"-framework",
SafariServices,
Expand All @@ -986,7 +986,7 @@
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_ENTITLEMENTS = "macOS (App)/hlidac shopu.entitlements";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 75;
CURRENT_PROJECT_VERSION = 76;
DEVELOPMENT_TEAM = 8P5697C5H7;
ENABLE_HARDENED_RUNTIME = YES;
GENERATE_INFOPLIST_FILE = YES;
Expand All @@ -1000,7 +1000,7 @@
"@executable_path/../Frameworks",
);
MACOSX_DEPLOYMENT_TARGET = 10.14;
MARKETING_VERSION = 1.9.46;
MARKETING_VERSION = 1.9.47;
OTHER_LDFLAGS = (
"-framework",
SafariServices,
Expand All @@ -1023,7 +1023,7 @@
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_ENTITLEMENTS = "macOS (App)/hlidac shopu.entitlements";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 75;
CURRENT_PROJECT_VERSION = 76;
DEVELOPMENT_TEAM = 8P5697C5H7;
ENABLE_HARDENED_RUNTIME = YES;
GENERATE_INFOPLIST_FILE = YES;
Expand All @@ -1037,7 +1037,7 @@
"@executable_path/../Frameworks",
);
MACOSX_DEPLOYMENT_TARGET = 10.14;
MARKETING_VERSION = 1.9.46;
MARKETING_VERSION = 1.9.47;
OTHER_LDFLAGS = (
"-framework",
SafariServices,
Expand Down
2 changes: 1 addition & 1 deletion extension/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"default_locale": "cs",
"name": "__MSG_extensionName__",
"description": "__MSG_extensionDescription__",
"version": "1.9.46",
"version": "1.9.47",
"author": "TopMonks s.r.o. & contributors",
"homepage_url": "https://www.hlidacshopu.cz/",
"applications": {
Expand Down
2 changes: 1 addition & 1 deletion extension/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@hlidac-shopu/extension",
"version": "1.9.46",
"version": "1.9.47",
"description": "Extension",
"dependencies": {
"@hlidac-shopu/lib": "^1.3.8",
Expand Down
2 changes: 1 addition & 1 deletion extension/popup/about.html
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ <h1>
/>
</svg>
</a>
<small>1.9.46</small>
<small>1.9.47</small>
</h1>
<div class="c">
<p>
Expand Down
11 changes: 9 additions & 2 deletions extension/shops/mountfield.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,19 @@ export class Mountfield extends Shop {
const title = elem
.querySelector("h1.box-detail__heading")
.textContent.trim();
const currentPrice = elem
let currentPrice = elem
.querySelector("meta[itemprop=price]")
.content.trim();
const originalPrice = cleanPrice(
let originalPrice = cleanPrice(
".box-detail-add__prices__item__text__price"
);

const loyaltyPrice = cleanPrice(".box-detail-add__prices__item__club");
if (!originalPrice && loyaltyPrice) {
originalPrice = currentPrice;
currentPrice = loyaltyPrice;
}

const imageUrl = elem.querySelector("img[itemprop=image]").src;
return { itemId, title, currentPrice, originalPrice, imageUrl };
}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "hlidac-shopu",
"version": "1.9.46",
"version": "1.9.47",
"private": true,
"description": "Rozšíření zobrazuje historická data pro největší české eshopy.",
"author": "TopMonks s.r.o. & contributors",
Expand Down
2 changes: 1 addition & 1 deletion www.hlidacshopu.cz/src/static/webapp.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "1.9.46",
"version": "1.9.47",
"name": "Hlídač Shopů",
"description": "Ověřte si, jestli v nejoblíbenějších českých e-shopech nakupujete opravdu se slevou.",
"type": "web",
Expand Down

0 comments on commit 5d771bf

Please sign in to comment.