mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-04-09 16:38:50 +00:00
[PepperBridgeAbstract,DealabsBridge,HotUKDealsBridge,MydealsBridge] (#3982)
Exclude thread results Some categories showed some thread in the middle of the deals : now only the deals are handled Updated the "no results" text to follow the sites changes
This commit is contained in:
parent
598ee5b51e
commit
4d15ffd2cf
@ -1913,7 +1913,7 @@ class DealabsBridge extends PepperBridgeAbstract
|
|||||||
'uri-merchant' => 'search/bons-plans?merchant-id=',
|
'uri-merchant' => 'search/bons-plans?merchant-id=',
|
||||||
'request-error' => 'Impossible de joindre Dealabs',
|
'request-error' => 'Impossible de joindre Dealabs',
|
||||||
'thread-error' => 'Impossible de déterminer l\'ID de la discussion. Vérifiez l\'URL que vous avez entré',
|
'thread-error' => 'Impossible de déterminer l\'ID de la discussion. Vérifiez l\'URL que vous avez entré',
|
||||||
'no-results' => 'Il n'y a rien à afficher pour le moment :(',
|
'no-results' => 'Aucun résultat',
|
||||||
'currency' => '€',
|
'currency' => '€',
|
||||||
'relative-date-indicator' => [
|
'relative-date-indicator' => [
|
||||||
'il y a',
|
'il y a',
|
||||||
|
@ -3277,7 +3277,7 @@ class HotUKDealsBridge extends PepperBridgeAbstract
|
|||||||
'uri-merchant' => 'search/deals?merchant-id=',
|
'uri-merchant' => 'search/deals?merchant-id=',
|
||||||
'request-error' => 'Could not request HotUKDeals',
|
'request-error' => 'Could not request HotUKDeals',
|
||||||
'thread-error' => 'Unable to determine the thread ID. Check the URL you entered',
|
'thread-error' => 'Unable to determine the thread ID. Check the URL you entered',
|
||||||
'no-results' => 'Ooops, looks like we could',
|
'no-results' => 'no results',
|
||||||
'currency' => '£',
|
'currency' => '£',
|
||||||
'relative-date-indicator' => [
|
'relative-date-indicator' => [
|
||||||
'ago',
|
'ago',
|
||||||
|
@ -2024,7 +2024,7 @@ class MydealsBridge extends PepperBridgeAbstract
|
|||||||
'uri-merchant' => 'search/gutscheine?merchant-id=',
|
'uri-merchant' => 'search/gutscheine?merchant-id=',
|
||||||
'request-error' => 'Could not request mydeals',
|
'request-error' => 'Could not request mydeals',
|
||||||
'thread-error' => 'Die ID der Diskussion kann nicht ermittelt werden. Überprüfen Sie die eingegebene URL',
|
'thread-error' => 'Die ID der Diskussion kann nicht ermittelt werden. Überprüfen Sie die eingegebene URL',
|
||||||
'no-results' => 'Ups, wir konnten nichts',
|
'no-results' => 'keine Ergebnisse',
|
||||||
'currency' => '€',
|
'currency' => '€',
|
||||||
'relative-date-indicator' => [
|
'relative-date-indicator' => [
|
||||||
'vor',
|
'vor',
|
||||||
|
@ -44,7 +44,7 @@ class PepperBridgeAbstract extends BridgeAbstract
|
|||||||
protected function collectDeals($url)
|
protected function collectDeals($url)
|
||||||
{
|
{
|
||||||
$html = getSimpleHTMLDOM($url);
|
$html = getSimpleHTMLDOM($url);
|
||||||
$list = $html->find('article[id]');
|
$list = $html->find('article[id][class*=thread--deal]]');
|
||||||
|
|
||||||
// Deal Image Link CSS Selector
|
// Deal Image Link CSS Selector
|
||||||
$selectorImageLink = implode(
|
$selectorImageLink = implode(
|
||||||
@ -109,9 +109,9 @@ class PepperBridgeAbstract extends BridgeAbstract
|
|||||||
|
|
||||||
$item['content'] = '<table><tr><td><a href="'
|
$item['content'] = '<table><tr><td><a href="'
|
||||||
. $item['uri']
|
. $item['uri']
|
||||||
. '"><img src="'
|
. '">'
|
||||||
. $this->getImage($deal)
|
. $this->getImage($deal)
|
||||||
. '"/></td><td>'
|
. '</td><td>'
|
||||||
. $this->getHTMLTitle($item)
|
. $this->getHTMLTitle($item)
|
||||||
. $this->getPrice($jsonDealData)
|
. $this->getPrice($jsonDealData)
|
||||||
. $this->getDiscount($jsonDealData)
|
. $this->getDiscount($jsonDealData)
|
||||||
@ -430,7 +430,7 @@ HEREDOC;
|
|||||||
{
|
{
|
||||||
// Get thread Image JSON content
|
// Get thread Image JSON content
|
||||||
$content = Json::decode($deal->find('div[class*=threadGrid-image]', 0)->find('div[class=js-vue2]', 0)->getAttribute('data-vue2'));
|
$content = Json::decode($deal->find('div[class*=threadGrid-image]', 0)->find('div[class=js-vue2]', 0)->getAttribute('data-vue2'));
|
||||||
return $content['props']['threadImageUrl'];
|
return '<img src="' . $content['props']['threadImageUrl'] . '"/>';
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user