def handleHttp(dictParam: dict): fRmbFen = float(dictParam.get('rmb', "0")) if not checkIsFloat(fRmbFen): raise exceptionLogic(errorLogic.client_param_invalid) # 客户的给的是分 iRmbFen = int(fRmbFen * 100) if iRmbFen < 100 or iRmbFen > 300000: raise exceptionLogic(errorLogic.pay_online_amount_limit) try: #检查用户是否登录,检查用户token strAccountId = str(dictParam.get("accountId", "")) strToken = str(dictParam.get("token", "")) except: raise exceptionLogic(errorLogic.client_param_invalid) if len(strAccountId) <= 0: raise exceptionLogic(errorLogic.player_id_empty) if not procVariable.debug: certify_token(strAccountId, strToken) objResp = cResp() objResp.data = yield from lpayPayOrder(strAccountId, iRmbFen, "wx_wap", dictParam.get("srcIp", "")) return classJsonDump.dumps(objResp)
def handleHttp(dictParam: dict): fRmbFen = float(dictParam.get('rmb', "0")) if not checkIsFloat(fRmbFen): raise exceptionLogic(errorLogic.client_param_invalid) # 客户的给的是分 iRmbFen = int(fRmbFen * 100) if iRmbFen < 100 or iRmbFen > 300000: raise exceptionLogic(errorLogic.pay_online_amount_limit) try: #检查用户是否登录,检查用户token strAccountId = str(dictParam.get("accountId", "")) strToken = str(dictParam.get("token", "")) except: raise exceptionLogic(errorLogic.client_param_invalid) if len(strAccountId) <= 0: raise exceptionLogic(errorLogic.player_id_empty) """ ret = certify_token(strAccountId,strToken) if not ret: raise exceptionLogic(errorLogic.login_token_expired) """ strClientIp = str(dictParam.get("srcIp", "")) objResp = cResp() #objResp.data = yield from pocoPayOrder(strAccountId,iRmbFen,"qq","wap",strClientIp,pocoWrapPayOrderCall) objResp.data = yield from lpayPayOrder(strAccountId, iRmbFen, "qq_wap", dictParam.get("srcIp", "")) return classJsonDump.dumps(objResp)
def handleHttp(dictParam: dict): objResp = cResp() fRmbFen = float(dictParam.get('rmb', "0")) if not checkIsFloat(fRmbFen): raise exceptionLogic(errorLogic.client_param_invalid) #客户的给的是分 iRmbFen = int(fRmbFen * 100) #检查用户是否登录,检查用户token strAccountId = str(dictParam["accountId"]) objResp.data = yield from lpayPayOrder(strAccountId, iRmbFen, "weixin", dictParam.get("srcIp")) return classJsonDump.dumps(objResp)
def handleHttp(dictParam: dict): objResp = cResp() fRmbFen = float(dictParam.get('rmb', "0")) if not checkIsFloat(fRmbFen): raise exceptionLogic(errorLogic.client_param_invalid) # 客户的给的是分 iRmbFen = int(fRmbFen * 100) # 检查用户是否登录,检查用户token strAccountId = str(dictParam["accountId"]) strToken = str(dictParam.get("token", "")) if not procVariable.debug: certify_token(strAccountId, strToken) #这里用web的 objResp.data = yield from lpayPayOrder(strAccountId, iRmbFen, "unionpay_wap", dictParam.get("srcIp", "")) return classJsonDump.dumps(objResp)