Beispiel #1
0
 def __init__(self, parent=None):
     QtGui.QWidget.__init__(self, parent)
     Shared.__init__(self)
     with open(os.path.join('tmp','comm'),'w') as comm:
         # communicates with export manager
         comm.write('')
     self.gui = Ui_Update()
     self.gui.setupUi(self)
     self.gui.tree_selected.headerItem().setText(0,
                                                ('League'))
     self.gui.tree_selected.headerItem().setText(1,
                                                 ('url'))
     self.gui.tree_links.headerItem().setText(0,
                                                 ('Links'))
     self.gui.tree_selected.setColumnWidth(0, 200)
     self.gui.tree_selected.setColumnWidth(1, 800)
     self.page = self.gui.webView.page().mainFrame()
     ## webview settings: don't load images
     settings = self.gui.webView.settings()
     settings.setAttribute(settings.AutoLoadImages,False)
     self.update_state = 0
     self.scrape = 0
     self.bindings()
     self.links_profiles() # website scraping
     #self.links_profiles_fd() #football-data.co.uk
     self.combo_path()
 def __init__(self, parent=None):
     QtGui.QMainWindow.__init__(self, parent)
     Shared.__init__(self)
     self.gui = Ui_MainWindow()
     self.gui.setupUi(self)
     self.database = bb_engine.Database()
     self.combo_nets_fill()
     self.combo_ranges_fill()
     #main tab variables
     self.v = {
         'mode_std': self.gui.combo_standings_mode.currentIndex,
         'mode_form': self.gui.combo_form_mode.currentIndex,
         'mode_date': self.gui.combo_scheudle_dates.currentText,
         'mode_home': self.gui.combo_home_mode.currentIndex,
         'mode_away': self.gui.combo_away_mode.currentIndex,
         'home_team': self.gui.main_combo_home.currentText,
         'away_team': self.gui.main_combo_away.currentText,
         'net': self.gui.main_combo_nets.currentText,
         'ranges': self.gui.main_combo_ranges.currentText,
         'c_1': QtGui.QColor('#E6E6FA'),
         'c_2': QtGui.QColor('#BFBFBF'),
         'c_home': QtGui.QColor('#71CA80'),
         'c_away': QtGui.QColor('#E1571F'),
         'c_win': QtGui.QColor('#90D889'),
         'c_draw': QtGui.QColor('#9894EB'),
         'c_lose': QtGui.QColor('#DE7C7C'),
         'palette': '#39A1B2'
     }
     self.leagues_tree()
     try:
         self.tree_return()
     except:
         pass
     self.bindings()
Beispiel #3
0
 def __init__(self, parent=None):
     QtGui.QMainWindow.__init__(self, parent)
     Shared.__init__(self)
     self.gui = Ui_MainWindow()
     self.gui.setupUi(self)
     self.database = bb_engine.Database()
     self.combo_nets_fill()
     self.combo_ranges_fill()
     #main tab variables
     self.v = {
     'mode_std': self.gui.combo_standings_mode.currentIndex,
     'mode_form': self.gui.combo_form_mode.currentIndex,
     'mode_date': self.gui.combo_scheudle_dates.currentText,
     'mode_home': self.gui.combo_home_mode.currentIndex,
     'mode_away': self.gui.combo_away_mode.currentIndex,
     'home_team': self.gui.main_combo_home.currentText,
     'away_team': self.gui.main_combo_away.currentText,
     'net': self.gui.main_combo_nets.currentText,
     'ranges': self.gui.main_combo_ranges.currentText,
     'c_1': QtGui.QColor('#E6E6FA'),
     'c_2': QtGui.QColor('#BFBFBF'),
     'c_home': QtGui.QColor('#71CA80'),
     'c_away': QtGui.QColor('#E1571F'),
     'c_win': QtGui.QColor('#90D889'),
     'c_draw': QtGui.QColor('#9894EB'),
     'c_lose': QtGui.QColor('#DE7C7C'),
     'palette': '#39A1B2'}
     self.leagues_tree()
     try:
         self.tree_return()
     except:
         pass
     self.bindings()
Beispiel #4
0
 def __init__(self, parent=None):
     QtGui.QWidget.__init__(self, parent)
     Shared.__init__(self)
     self.gui = Ui_Learn()
     self.gui.setupUi(self)
     self.bindings()
     self.exports_tree()
     self.nets_tree()
     try:
         self.auto_load()
     except:
         print 'restore settings problem'
 def __init__(self, parent=None):
     QtGui.QWidget.__init__(self, parent)
     Shared.__init__(self)
     self.gui = Ui_Learn()
     self.gui.setupUi(self)
     self.bindings()
     self.exports_tree()
     self.nets_tree()
     try:
         self.auto_load()
     except:
         print 'restore settings problem'
Beispiel #6
0
 def __init__(self, parent=None):
     QtGui.QWidget.__init__(self, parent)
     Database.__init__(self)
     Shared.__init__(self)
     self.odds_level = 100
     self.app = 'selector'
     self.gui = Ui_Selector()
     self.gui.setupUi(self)
     self.gui.tree_selected.headerItem().setText(0, ('Selected'))
     self.filters_tree()
     self.leagues_tree()
     self.bindings()
     try:
         self.filters_load()
     except:
         pass
Beispiel #7
0
    def __init__(self, parent=None):
        QtGui.QWidget.__init__(self, parent)
        Shared.__init__(self)
        self.gui = Ui_Links()
        self.gui.setupUi(self)

        self.gui.tree_url.sortItems(0, QtCore.Qt.SortOrder(0))
        self.gui.tree_url.setSortingEnabled(1)
        self.gui.tree_url.headerItem().setText(0, ('League'))
        self.gui.tree_url.headerItem().setText(1, ('url'))
        self.gui.tree_url.setColumnWidth(0,200)
        self.gui.tree_url.setColumnWidth(1,800)
        self.default_url = 'http://stats.betradar.com/s4/?clientid=271&language=en#2_1,22_1'
        self.gui.line_url.setText(self.default_url)
        self.gui.webView.load(QtCore.QUrl(self.default_url))
        self.bindings()
        self.tree_link_saved()
Beispiel #8
0
    def __init__(self, parent=None):
        QtGui.QWidget.__init__(self, parent)
        Shared.__init__(self)
        self.gui = Ui_Links()
        self.gui.setupUi(self)

        self.gui.tree_url.sortItems(0, QtCore.Qt.SortOrder(0))
        self.gui.tree_url.setSortingEnabled(1)
        self.gui.tree_url.headerItem().setText(0, ('League'))
        self.gui.tree_url.headerItem().setText(1, ('url'))
        self.gui.tree_url.setColumnWidth(0, 200)
        self.gui.tree_url.setColumnWidth(1, 800)
        self.default_url = 'http://stats.betradar.com/s4/?clientid=271&language=en#2_1,22_1'
        self.gui.line_url.setText(self.default_url)
        self.gui.webView.load(QtCore.QUrl(self.default_url))
        self.bindings()
        self.tree_link_saved()
 def __init__(self, parent=None):
     Shared.__init__(self)
     self.database = bb_engine.Database()
     QtGui.QWidget.__init__(self, parent)
     self.gui = Ui_Leagues()
     self.gui.setupUi(self)
     self.gui.tree_matches.headerItem().setText(0, ('Date'))
     self.gui.tree_matches.headerItem().setText(1, ('Home'))
     self.gui.tree_matches.headerItem().setText(2, ('Away'))
     self.gui.tree_matches.headerItem().setText(3, ('FTH'))
     self.gui.tree_matches.headerItem().setText(4, ('FTA'))
     self.gui.tree_teams_home.headerItem().setText(0, ('Home'))
     self.gui.tree_teams_away.headerItem().setText(0, ('Away'))
     self.gui.tree_leagues.headerItem().setText(0, ('Leagues'))
     self.gui.tree_leagues_own.headerItem().setText(0, ('Leagues'))
     self.gui.tree_teams.headerItem().setText(0, ('Teams'))
     self.gui.tree_team_profiles.headerItem().setText(0, ('Profiles'))
     self.bindings()
     self.tree_leagues_teams()
     self.tree_profiles()
     self.line_to_add()
Beispiel #10
0
 def __init__(self, parent=None):
     Shared.__init__(self)
     self.database = bb_engine.Database()
     QtGui.QWidget.__init__(self, parent)
     self.gui = Ui_Leagues()
     self.gui.setupUi(self)
     self.gui.tree_matches.headerItem().setText(0, ("Date"))
     self.gui.tree_matches.headerItem().setText(1, ("Home"))
     self.gui.tree_matches.headerItem().setText(2, ("Away"))
     self.gui.tree_matches.headerItem().setText(3, ("FTH"))
     self.gui.tree_matches.headerItem().setText(4, ("FTA"))
     self.gui.tree_teams_home.headerItem().setText(0, ("Home"))
     self.gui.tree_teams_away.headerItem().setText(0, ("Away"))
     self.gui.tree_leagues.headerItem().setText(0, ("Leagues"))
     self.gui.tree_leagues_own.headerItem().setText(0, ("Leagues"))
     self.gui.tree_teams.headerItem().setText(0, ("Teams"))
     self.gui.tree_team_profiles.headerItem().setText(0, ("Profiles"))
     self.bindings()
     self.tree_leagues_teams()
     self.tree_profiles()
     self.line_to_add()
Beispiel #11
0
 def __init__(self, radio, league, parent=None):
     Shared.__init__(self)
     self.league = league
     self.path = radio
     self.run()
Beispiel #12
0
 def __init__(self, radio, league, parent=None):
     Shared.__init__(self)
     self.league = league
     self.path = radio
     self.run()