UNPKG

oddsportal

Version:

oddsportal scrape for www.keydobot.com

119 lines (93 loc) 1.99 kB
const convertMn = (sid, mn) => { console.log(sid, mn); switch (sid) { case 1: return convertMn1(mn); default: return null; } }; const activeList = (sid, mn) => { switch (sid) { case 1: return activeList1(mn); default: return null; } }; const convertOna = (ona) => { switch (ona) { case "1": return "1"; case "X": return "0"; case "2": return "2"; case "Over": return "Üst"; case "Under": return "Alt"; case "Yes": return "Var"; case "No": return "Yok"; case "1X": return "1 ve 0"; case "12": return "1 ve 2"; case "X2": return "0 ve 2"; default: return null; } }; const convertMn1 = (mn) => { switch (mn) { case "1X2": return "Maç Sonucu"; case "Over/Under": return "Altı/Üstü"; case "Both Teams to Score": return "Karşılıklı Gol"; case "Double Chance": return "Çifte Şans"; case "European Handicap": return "Handikap"; default: return null; } }; const activeList1 = (mn) => { switch (mn) { case "1X2": return { mn: 1 }; case "O/U": return { mn: 1, clicks: [ { click: "Over/Under +1.5", mn: " +1.5" }, { click: "Over/Under +2.5", mn: " +2.5" }, { click: "Over/Under +3.5", mn: " +3.5" }, ], }; // case "Both Teams to Score": // return { mn: 1 }; case "EH": return { mn: 1, clicks: [ { click: "European handicap -1", mn: " 0:1" }, { click: "European handicap +1", mn: " 1:0" }, ], }; case "Double Chance": return { mn: 1 }; default: return null; } }; module.exports = { convertMn, convertOna, activeList, };