Transavia fr auto check

Keep an eye in transavia specific date

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Greasemonkey lub Violentmonkey.

You will need to install an extension such as Tampermonkey to install this script.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana będzie instalacja rozszerzenia Tampermonkey lub Userscripts.

You will need to install an extension such as Tampermonkey to install this script.

Aby zainstalować ten skrypt, musisz zainstalować rozszerzenie menedżera skryptów użytkownika.

(Mam już menedżera skryptów użytkownika, pozwól mi to zainstalować!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Musisz zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

(Mam już menedżera stylów użytkownika, pozwól mi to zainstalować!)

// ==UserScript==
// @name         Transavia fr auto check
// @namespace    http://tampermonkey.net/
// @version      1.1
// @description  Keep an eye in transavia specific date
// @author       MegaBOuSsOl
// @match        https://www.transavia.com/fr-FR/reservez-un-vol/vols/rechercher/
// @match        https://www.transavia.com/fr-FR/accueil/
// @icon         https://www.google.com/s2/favicons?domain=transavia.com
// @grant        God
// ==/UserScript==

/*here we took an exempl from paris to Oran the the following dates*/
/*Depart*/
var depart ="Paris (Orly 3), France"
var Root="ORY"
var arrivee="Oran, Algérie"
var DateDepart="19 août 2021"
var DateArrive =""


/*Alert*/
setInterval(function(){if (document.getElementsByClassName('HV-gs--bp0 HV-gs--bp10 HV-gs--bp22')[1].innerHTML.indexOf('price') == -1 )
{setTimeout(function(){document.querySelector("#flights > div > section > div.panel_section.panel_section--button-search > div > button:nth-child(2)").click();}, 10* 1000)}
                       else {new Audio('https://www.soundjay.com/misc/sounds/dream-harp-07.mp3').play();}}, 7*1000)

/*refresh if lost connection*/
setInterval(function(){if ((document.body.innerHTML).indexOf(" pas passé comme prévu"))
{ document.querySelector("body > div.page-takeover.page-takeover-server-error.is-hidden.is-visible > div.HV-gw--bp10 > div > aside > div > div.panel_section.panel_section--button > div > a").click();}}, 7*1000)
//document.getElementById('flyingBlueSearch_FlyingBlueSearch').value=''
/*Depart*/
var routeSelection_DepartureStation=setInterval(function(){
    if (true) {document.getElementById('routeSelection_DepartureStation-input').value=depart ;clearInterval(routeSelection_DepartureStation);}
},
1000);

/*DateArrivé*/
/*var root=setInterval(function(){
    if (true) {document.querySelector("#root > div > div > input[type=hidden]:nth-child(2)").value=Root;clearInterval(root);}
},
1000);

/*Arrivé*/
var routeSelection_ArrivalStation=setInterval(function(){
    if (true) {document.getElementById('routeSelection_ArrivalStation-input').value=arrivee ;clearInterval(routeSelection_ArrivalStation);}
},
1000);


/*DateDepart*/
var dateSelection_OutboundDate=setInterval(function(){
    if (true) {document.getElementById('dateSelection_OutboundDate-datepicker').value=DateDepart;clearInterval(dateSelection_OutboundDate);}
},
1000);

/*DateArrivé*/
var dateSelection_IsReturnFlight=setInterval(function(){
    if (true) {document.getElementById('dateSelection_IsReturnFlight-datepicker').value=DateArrive;clearInterval(dateSelection_IsReturnFlight);}
},
1000);


setTimeout(function(){document.getElementsByClassName("button button-primary")[3].click();}, (330*1000));

/*selectionner le vole*/
var SelectVole=setInterval(function(){if(document.getElementsByClassName('flight-result-button') !== null )
{document.querySelector("#top > div > div > div:nth-child(3) > section > section > div > div.panel_section.panel_section--content.results.c-flight-results-panel > div.resultsPanelWrapper > div > div.margin-bottom-2rem.margin-bottom-1d5rem--bp10 > div > form > div > button").click();}

 ;
 clearInterval(SelectVole);}, 1000)