Skip to content

Commit

Permalink
20170110
Browse files Browse the repository at this point in the history
  • Loading branch information
Arnold1974 committed Jan 10, 2017
1 parent 4e6659d commit 23df940
Show file tree
Hide file tree
Showing 2 changed files with 64 additions and 1 deletion.
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
#json files
#json files
*.json*

#Word文档
*.doc

#图像文件
*.jpg

# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
Expand Down
60 changes: 60 additions & 0 deletions dfcf.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,66 @@
if len(StockList.json()["Data"])==0:
print "Stock Position: 0"

GetOrdersData=s.post('https://jy.xzsec.com/Search/GetOrdersData',{'qqhs':'20','dwc':''});
if len(GetOrdersData.json()["Data"])==0:
print "Orders: 0"
else:
print len(GetOrdersData.json()["Data"])
print GetOrdersData.json()["Data"][0]["Wtsj"]


GetKyzjAndKml=s.post('https://jy.xzsec.com/Trade/GetKyzjAndKml', {'stockCode':'601666','price':'5.01','tradeType':'B','stockName':'平煤股份'});
print GetKyzjAndKml.json()["Data"]["Kmml"]
Kmml=GetKyzjAndKml.json()["Data"]["Kmml"]
print Kmml, type(Kmml)

SubmitTrade=s.post('https://jy.xzsec.com/Trade/SubmitTrade', \
{'stockCode':'601666','price':'5.01','amount':'100','tradeType':'B','stockName':'平煤股份'}
)


GetRevokeList=s.post('https://jy.xzsec.com/Trade/GetRevokeList')
if len(GetRevokeList.json()["Data"])==0:
print "Orders: 0"
else:
print len(GetRevokeList.json()["Data"])
print GetRevokeList.json()["Data"][0]["Zqdm"]
print GetRevokeList.json()["Data"][0]["Zqmc"]
print GetRevokeList.json()["Data"][0]["Mmsm"]
print GetRevokeList.json()["Data"][0]["Wtzt"]
print GetRevokeList.json()["Data"][0]["Wtjq"]
print GetRevokeList.json()["Data"][0]["Wtsl"]
print GetRevokeList.json()["Data"][0]["Cjjq"]
print GetRevokeList.json()["Data"][0]["Cjsl"]
print GetRevokeList.json()["Data"][0]["Wtbh"] #委托编号
print GetRevokeList.json()["Data"][0]["Cdsl"] #撤单价格
print GetRevokeList.json()["Data"][0]["Gddm"] #股东代码
print GetRevokeList.json()["Data"][0]["Market"]
print GetRevokeList.json()["Data"][0]["Wtsj"] #委托时间
print GetRevokeList.json()["Data"][0]["Dwc"]
print GetRevokeList.json()["Data"][0]["Cjje"]
print GetRevokeList.json()["Data"][0]["Wtrq"]
print GetRevokeList.json()["Data"][0]["Khdm"] #客户代码
print GetRevokeList.json()["Data"][0]["Khxm"]
print GetRevokeList.json()["Data"][0]["Zjzh"]
print GetRevokeList.json()["Data"][0]["Hb"]
print GetRevokeList.json()["Data"][0]["Jgbm"]
print GetRevokeList.json()["Data"][0]["Htxh"]
print GetRevokeList.json()["Data"][0]["Bpsj"]
print GetRevokeList.json()["Data"][0]["Cpbm"]
print GetRevokeList.json()["Data"][0]["Cpmc"]
print GetRevokeList.json()["Data"][0]["Djje"]
print GetRevokeList.json()["Data"][0]["Jyxw"]
print GetRevokeList.json()["Data"][0]["Cdbs"]
print GetRevokeList.json()["Data"][0]["Czrq"] #操作日期
print GetRevokeList.json()["Data"][0]["Yjlx"]
print GetRevokeList.json()["Data"][0]["Wtqd"]
print GetRevokeList.json()["Data"][0]["Bzxx"]
print GetRevokeList.json()["Data"][0]["Mmbz"]

RevokeOrders=s.post('https://jy.xzsec.com/Trade/RevokeOrders',{'revokes':'20170110_209948'})
print RevokeOrders.json()["20170110"]


#print(r.text, '\n{}\n'.format('*'*79), r.encoding)
#r.encoding = 'GBK'
Expand Down

0 comments on commit 23df940

Please sign in to comment.