Esempio n. 1
0
 def get_currrncy_data(self):
     try:
         __MZCdata = ElementsIde().elementXpath(HomeData().mzc_curData).text
         __MZCprice = ElementsIde().elementXpath(HomeData().mzc_price).text
         return __MZCdata + __MZCprice
     except Exception:
         return "获取跌币最新价格失败!"
Esempio n. 2
0
 def get_AppreCurrency_data(self):
     try:
         __LSKDtat = ElementsIde().elementXpath(
             HomeData().currency_data).text
         __LSKprice = ElementsIde().elementXpath(HomeData().price_new).text
         return __LSKDtat + __LSKprice
     except Exception:
         return "获取涨币最新价格失败!"
Esempio n. 3
0
 def get_trade_BTCCurrency(self):
     try:
         __currencyNew = ElementsIde().elementXpath(
             HomeData().trade_BTC_name).tex
         __curNewNum = ElementsIde().elementXpath(
             HomeData.trade_BTC_value).text
         return __currencyNew + __curNewNum
     except Exception:
         return "获取场外交易BTC最新价失败!"
Esempio n. 4
0
 def click_BTCtap_To_Trade(self):
     try:
         ElementsIde().elementXpath(HomeData().btcTrade_button).click()
         __expect_value = "My Order"
         ___act_value = ElementsIde().elementXpath(
             HomeData().act_Trade_Page)
         if __expect_value == ___act_value:
             return "页面跳转到场外交易成功!"
     except Exception:
         return "页面跳转到场外交易页面失败!"
Esempio n. 5
0
 def slideshow(self):
     ElementsIde().elementXpath(HomeData().slideshow_1).click()
     try:
         ElementsIde().elementXpath(HomeData().slideshow_1).click()
     except Exception:
         print "没有找到轮播图1!"
     try:
         ElementsIde().elementXpath(HomeData().slideshow_2).click()
     except Exception:
         print "没有找到轮播图2!"
Esempio n. 6
0
    def ErrorValue(self):
        try:
            __ErrorValue = ElementsIde().elementXpath(
                ".//*[@id='login_fm']/div/div[5]/p").text
            if __ErrorValue == "Please enter email" or "Account does not exist":
                ElementsIde().elementXpath(".//*[@id='lg_myem']").click()
                SignIN().Email()
            if __ErrorValue == "Please enter password" or "Incorrect password ! You left 4 chances !":  #错误字符串错误处理
                ElementsIde().elementXpath(".//*[@id='lg_mypsw']").click()
                SignIN().PassWd()

        except Exception:
            return "登录信息无误!"
Esempio n. 7
0
 def PassWd(self):
     __PassWd = ""
     try:
         ElementsIde().elementXpath(".//*[@id='lg_mypsw']").send_keys(
             __PassWd)
     except Exception:
         return "输入密码错误!!!"
Esempio n. 8
0
 def chg(self):
     try:
         __chg = ElementsIde().elementXpath(
             ".//*[@id='trendsCon']/div/div[5]").text
         return __chg
     except Exception:
         return "获取币种涨跌幅失败!"
Esempio n. 9
0
 def LowPrice(self):
     try:
         __lowPrice = ElementsIde().elementXpath(
             ".//*[@id='trendsCon']/div/div[4]").text
         return __lowPrice
     except Exception:
         return "获取最低价失败!"
Esempio n. 10
0
 def HighPrice(self):
     try:
         __highprice = ElementsIde().elementXpath(
             ".//*[@id='trendsCon']/div/div[3]").text
         return __highprice
     except Exception:
         return "获取最高价失败!"
Esempio n. 11
0
 def fl(self):
     try:
         __currencyDynamic = ElementsIde().elementXpath(
             ".//*[@id='trendsCon']/div/div[1]").text
         return __currencyDynamic
     except Exception:
         return ("获取'币种'最新交易动态失败!")
Esempio n. 12
0
 def tradeNum(self):
     try:
         __tradeNum = ElementsIde().elementXpath(
             ".//*[@id='trendsCon']/div/div[6]").text
         return __tradeNum
     except Exception:
         return "获取24小时成交量失败!"
Esempio n. 13
0
 def Email(self):
     __Email = ""
     try:
         ElementsIde().elementXpath(".//*[@id='lg_myem']").send_keys(
             __Email)
     except Exception:
         return "输入邮箱错误!!!"
Esempio n. 14
0
 def title(self):
     #...最新交易动态
     try:
         __trade_name_element = ElementsIde().elementXpath(
             BTC_Data().trade_name_element)
         print __trade_name_element
     except Exception:
         print "获取比特币(BTC)最新交易动态失败!"
         #最新价
     try:
         __newPrice = ElementsIde().elementXpath(BTC_Data().newPrice)
         print __newPrice
     except Exception:
         print
         #最高价
         __highPrice = ElementsIde().elementXpath(BTC_Data().highPrice)
         print __highPrice
Esempio n. 15
0
 def Sumbit(self):
     try:
         ElementsIde().elementID("reg_btn").click()
     except Exception:
         return "点击注册按钮失败!"
Esempio n. 16
0
 def Ver_Code(self):
     vercode = ""
     try:
         ElementsIde().elementID("captcha").send_keys(vercode)
     except Exception:
         return "输入图形验证码失败!"
Esempio n. 17
0
 def Terms(self):
     try:
         ElementsIde().elementID("reg_agck").click()
     except Exception:
         return "勾选用户协议失败!"
Esempio n. 18
0
 def Invite(self):
     uid = ""
     try:
         ElementsIde().elementID("pid").send_keys(uid)
     except Exception:
         return "添加邀请人失败!"
Esempio n. 19
0
 def Repeat_Password(self):
     rpaw = "qwerqwer"
     try:
         ElementsIde().elementID("repwd").send_keys(rpaw)
     except ElementsIde:
         return "输入确认密码失败!"
Esempio n. 20
0
 def Email(self):
     email = ""
     try:
         ElementsIde().elementID("lg_myem").send_keys()
     except Exception:
         return "登录输入用户名失败!"
Esempio n. 21
0
 def Submit(self):
     try:
         ElementsIde().elementID("forgot_btn").click()
     except Exception:
         return "点击确定按钮失败!"
Esempio n. 22
0
 def ForgotPwd(self):
     try:
         ElementsIde().elementID("lg_forgot").click()
     except Exception:
         return "点击忘记密码失败!"
Esempio n. 23
0
 def SignInButton(self):
     try:
         ElementsIde().elementID("lg_btn").click()
     except Exception:
         return "点击登录按钮失败!"
Esempio n. 24
0
 def saleList(self):
     try:
         __salelist = ElementsIde().elementID("salelist").text
         return __salelist
     except Exception:
         return "获取卖单列表失败!"
Esempio n. 25
0
 def SignUp(self):
     try:
         ElementsIde().elementID("lg_creat").click()
     except Exception:
         return "点击注册失败!"
Esempio n. 26
0
 def Eamil(self):
     __email = publicModle().RandomEmail()
     try:
         ElementsIde().elementID("email").send_keys(__email)
     except Exception:
         return "输入邮箱失败!"
Esempio n. 27
0
 def ImageCode(self):
     code = ""
     try:
         ElementsIde().elementID("forgot_code").send_keys(code)
     except Exception:
         return "输入图形验证码失败!"
Esempio n. 28
0
 def Password(self):
     paw = "qwerqwer"
     try:
         ElementsIde().elementID("pwd").send_keys(paw)
     except Exception:
         return "输入密码失败!"
Esempio n. 29
0
 def Email(self):
     email = ""
     try:
         ElementsIde().elementID("forgot_myem").send_keys(email)
     except Exception:
         return "输入邮箱失败!"
Esempio n. 30
0
 def Password(self):
     pwd = "qwerqweqr"
     try:
         ElementsIde().elementID("lg_mypsw").send_keys()
     except Exception:
         return "登录输入密码失败!"