pull/214/head
wenxianping 2019-01-17 17:37:36 +08:00
parent 8458017498
commit ae91368a26
2 changed files with 5 additions and 5 deletions

View File

@ -21,7 +21,7 @@ def sendPushBear(msg):
sendPushBearUrls = urls.get("Pushbear")
data = {
"sendkey": conf["pushbear_conf"]["send_key"].strip(),
"text": "易行购票成功通知-{}".format(time.strftime("%F %T")),
"text": "易行购票成功通知",
"desp": msg
}
httpClint = HTTPClient(0)

View File

@ -104,10 +104,10 @@ class GoLogin:
:param passwd: 密码
:return:
"""
if self.is_auto_code and self.auto_code_type == 1:
balance = DamatuApi(_get_yaml()["auto_code_account"]["user"], _get_yaml()["auto_code_account"]["pwd"]).getBalance()
if int(balance) < 40:
raise balanceException(u'余额不足,当前余额为: {}'.format(balance))
# if self.is_auto_code and self.auto_code_type == 1:
# balance = DamatuApi(_get_yaml()["auto_code_account"]["user"], _get_yaml()["auto_code_account"]["pwd"]).getBalance()
# if int(balance) < 40:
# raise balanceException(u'余额不足,当前余额为: {}'.format(balance))
user, passwd = _get_yaml()["set"]["12306account"][0]["user"], _get_yaml()["set"]["12306account"][1]["pwd"]
if not user or not passwd:
raise UserPasswordException(u"温馨提示: 用户名或者密码为空,请仔细检查")