コード例 #1
0
def getValues(url):
    print ("getValues()")

    url = "https://{0}".format(url)
    print ("Get URL: " + url)

    d = pq(url=url)
    list = d(".logostatam")
    obj = {}
    obj["site_id"] = common.getSiteId(url)

    if obj["site_id"] == None:
        obj["site_id"] = -1

    obj["total_account"] = list[1].text_content()
    obj["active_account"] = 0
    obj["total_deposit"] = list[2].text_content().replace("$ ", "")
    obj["total_withdraw"] = list[3].text_content().replace("$ ", "")
    obj["time"] = long(time.time()) * 1000

    print (
        "{0} - {1} - {2} {3}".format(
            obj["total_account"], obj["active_account"], obj["total_deposit"], obj["total_withdraw"], obj["time"]
        )
    )
    common.insertSiteStat(obj)
コード例 #2
0
ファイル: coiner_biz.py プロジェクト: vietdh85/vh-utility
def getValues(url):
	print("getValues()")
	
	d = pq(url="https://{0}".format(url))
	list = d(".welcome-stat .col-xs-4 td")
	obj = {}
	obj['site_id'] = common.getSiteId(url)
	
	if obj['site_id'] == None:
		obj['site_id'] = -1
		
	obj['total_account'] = list[7].text_content()
	obj['active_account'] = list[11].text_content()
	obj['total_deposit'] = list[1].text_content().replace("$ ", "")
	obj['total_withdraw'] = list[3].text_content().replace("$ ", "")
	obj['time'] = long(time.time()) * 1000
	
	print("{0} - {1} - {2} {3}".format(obj['total_account'], obj['active_account'], obj['total_deposit'], obj['total_withdraw'], obj['time']))
	common.insertSiteStat(obj)
コード例 #3
0
ファイル: oktrade_biz.py プロジェクト: vietdh85/vh-utility
def getValues(url):
	print("getValues()")
	
	d = pq(url="https://www.{0}/statistic/".format(url))
	list = d(".panel-body p")
	obj = {}
	obj['site_id'] = common.getSiteId(url)
	
	if obj['site_id'] == None:
		obj['site_id'] = -1
		
	obj['total_account'] = list[3].text_content().split("\"")[1]
	obj['active_account'] = 0
	obj['total_deposit'] = list[0].text_content().split("\"")[1].split("$")[0].replace(" ", "")
	obj['total_withdraw'] = list[1].text_content().split("\"")[1].split("$")[0].replace(" ", "")
	obj['time'] = long(time.time()) * 1000
	
	print("{0} - {1} - {2} {3}".format(obj['total_account'], obj['active_account'], obj['total_deposit'], obj['total_withdraw'], obj['time']))
	common.insertSiteStat(obj)
コード例 #4
0
def getValues(url):
	print("getValues()")
	
	d = pq(url="https://www.{0}".format(url))
	list = d("td.menutxt")
	obj = {}
	obj['site_id'] = common.getSiteId(url)
	
	if obj['site_id'] == None:
		obj['site_id'] = -1
	
	obj['total_account'] = list[4].text_content()
	obj['active_account'] = 0
	obj['total_deposit'] = list[6].text_content().replace("$ ", "")
	obj['total_withdraw'] = list[8].text_content().replace("$ ", "")
	obj['time'] = long(time.time()) * 1000
	
	print("{0} - {1} - {2} {3}".format(obj['total_account'], obj['active_account'], obj['total_deposit'], obj['total_withdraw'], obj['time']))
	common.insertSiteStat(obj)
コード例 #5
0
def getValues(url):
	print("getValues()")
	
	d = pq(url="https://{0}".format(url))
	list = d(".content-item-block p b")
	obj = {}
	obj['site_id'] = common.getSiteId(url)
	
	if obj['site_id'] == None:
		return
	
	obj['total_account'] = list[2].text_content()
	obj['active_account'] = 0
	obj['total_deposit'] = list[4].text_content().replace("$ ", "")
	obj['total_withdraw'] = list[5].text_content().replace("$ ", "")
	obj['time'] = long(time.time()) * 1000
	
	print("{0} - {1} - {2} {3}".format(obj['total_account'], obj['active_account'], obj['total_deposit'], obj['total_withdraw'], obj['time']))
	common.insertSiteStat(obj)
コード例 #6
0
ファイル: oilenergy.py プロジェクト: vietdh85/vh-utility
def getValues(url):
	print("getValues()", url)
	
	d = pq(url="https://{0}".format(url))
	list = d(".general .value")
	list1 = d("#statistics .left span")
	obj = {}
	obj['site_id'] = common.getSiteId(url)
	
	if obj['site_id'] == None:
		obj['site_id'] = -1
		
	obj['total_account'] = list1[2].text_content()
	obj['active_account'] = 0
	obj['total_deposit'] = list[0].text_content().replace("$ ", "")
	obj['total_withdraw'] = list[1].text_content().replace("$ ", "")
	obj['time'] = long(time.time()) * 1000
	
	print("{0} - {1} - {2} {3}".format(obj['total_account'], obj['active_account'], obj['total_deposit'], obj['total_withdraw'], obj['time']))
	common.insertSiteStat(obj)
コード例 #7
0
def getValues(url):
	print("getValues()")
	
	d = pq(url="https://{0}".format(url))
	list = d(".info-box .menutxt-info")
	list1 = d(".toptable3 #stat-top-right")
	obj = {}
	obj['site_id'] = common.getSiteId(url)
	
	if obj['site_id'] == None:
		obj['site_id'] = -1
	
	obj['total_account'] = list[5].text_content()
	obj['active_account'] = list[7].text_content()
	obj['total_deposit'] = list[9].text_content().replace("$ ", "")
	obj['total_withdraw'] = list1[0].text_content().replace("$ ", "")
	obj['time'] = long(time.time()) * 1000
	
	print("{0} - {1} - {2} {3}".format(obj['total_account'], obj['active_account'], obj['total_deposit'], obj['total_withdraw'], obj['time']))
	common.insertSiteStat(obj)
コード例 #8
0
def getValues(url):
    print ("getValues()")

    d = pq(url="http://{0}".format(url))
    list = d(".boxIndent td.menutxt")
    obj = {}
    obj["site_id"] = common.getSiteId(url)

    if obj["site_id"] == None:
        obj["site_id"] = -1

    obj["total_account"] = list[9].text_content()
    obj["active_account"] = 0
    obj["total_deposit"] = list[11].text_content().replace("$ ", "")
    obj["total_withdraw"] = list[13].text_content().replace("$ ", "")
    obj["time"] = long(time.time()) * 1000

    print (
        "{0} - {1} - {2} {3}".format(
            obj["total_account"], obj["active_account"], obj["total_deposit"], obj["total_withdraw"], obj["time"]
        )
    )
    common.insertSiteStat(obj)
コード例 #9
0
ファイル: unitiro_com.py プロジェクト: vietdh85/vh-utility
def getValues(url):
    print ("getValues()")

    d = pq(url="https://www.{0}".format(url))
    list = d(".started-menu ul li p span")
    obj = {}
    obj["site_id"] = common.getSiteId(url)

    if obj["site_id"] == None:
        obj["site_id"] = -1

    obj["total_account"] = list[2].text_content()
    obj["active_account"] = 0
    obj["total_deposit"] = list[3].text_content().replace("$ ", "")
    obj["total_withdraw"] = list[4].text_content().replace("$ ", "")
    obj["time"] = long(time.time()) * 1000

    print (
        "{0} - {1} - {2} {3}".format(
            obj["total_account"], obj["active_account"], obj["total_deposit"], obj["total_withdraw"], obj["time"]
        )
    )
    common.insertSiteStat(obj)