Commit 7c05a14d by sikang

Merge branch 'master' of http://47.100.14.92:8929/sikang/lib_base

bug fix string 加密
parents f0b25f8e 932c24bf
...@@ -30,7 +30,10 @@ with open(path, "w") as f_w: ...@@ -30,7 +30,10 @@ with open(path, "w") as f_w:
line = "harvest_port=%s\n"%(gateway['harvester'][0].split(":")[2]) line = "harvest_port=%s\n"%(gateway['harvester'][0].split(":")[2])
elif "gateway_ip=" in line: elif "gateway_ip=" in line:
line = "gateway_ip=\"%s\"\n"%(gateway['gateway'][1]) ip = gateway['gateway'][0]
if len(gateway['gateway']) > 1:
ip = gateway['gateway'][1]
line = "gateway_ip=\"%s\"\n"%(ip)
elif "repayment_h5=" in line: elif "repayment_h5=" in line:
line = "repayment_h5=\"%s\"\n"%(gateway['repay'][0]) line = "repayment_h5=\"%s\"\n"%(gateway['repay'][0])
...@@ -41,7 +44,7 @@ with open(path, "w") as f_w: ...@@ -41,7 +44,7 @@ with open(path, "w") as f_w:
elif "agreement_url=" in line: elif "agreement_url=" in line:
line = "agreement_url=\"%s\"\n"%(gateway['privacy'][0]) line = "agreement_url=\"%s\"\n"%(gateway['privacy'][0])
elif "home=" in line: elif "home=" in line and "home" in gateway.keys():
line = "home=\"%s\"\n"%(gateway['home'][0]) line = "home=\"%s\"\n"%(gateway['home'][0])
f_w.write(line) f_w.write(line)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment