Skip to content

Commit

Permalink
Новыая версия XML ЕГАИС
Browse files Browse the repository at this point in the history
  • Loading branch information
redeyser committed Jun 29, 2017
1 parent c6bf96e commit 8f451b5
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 10 deletions.
Binary file modified DTPrint/fprint.pyc
Binary file not shown.
Binary file modified DTPrint/kkmdrv.pyc
Binary file not shown.
Binary file modified DTPrint/shtrihm.pyc
Binary file not shown.
5 changes: 1 addition & 4 deletions chIceCash.py
Expand Up @@ -31,9 +31,7 @@

OFD_LINK = "t=20170603T2230&s=199.99&fn=871000010034410&i=9435&fp=1337907693&n=1"
def _round(V,n):
return str(round(V,n))
"""
Временно возвращаем обычное округление
#return str(round(V,n))
z=str(V.__format__(".4f")).split(".")
if len(z)<2:
return str(V)
Expand Down Expand Up @@ -71,7 +69,6 @@ def _round(V,n):
s="."+s
result=str(d)+s
return result
"""

class chIceCash:

Expand Down
12 changes: 6 additions & 6 deletions clientEgais.py
Expand Up @@ -21,7 +21,7 @@
"qp":"http://fsrar.ru/WEGAIS/QueryParameters",\
'tc':"http://fsrar.ru/WEGAIS/Ticket",\
"rst":"http://fsrar.ru/WEGAIS/ReplyRests",\
'wa':"http://fsrar.ru/WEGAIS/ActTTNSingle",\
'wa':"http://fsrar.ru/WEGAIS/ActTTNSingle_v2",\
'ttn':"http://fsrar.ru/WEGAIS/ReplyNoAnswerTTN",\
}

Expand Down Expand Up @@ -141,7 +141,7 @@
<ns:FSRAR_ID>%fsrar_id%</ns:FSRAR_ID>
</ns:Owner>
<ns:Document>
<ns:WayBillAct>
<ns:WayBillAct_v2>
<wa:Header>
<wa:IsAccept>%accept%</wa:IsAccept>
<wa:ACTNUMBER>%iddoc%</wa:ACTNUMBER>
Expand All @@ -152,15 +152,15 @@
<wa:Content>
%content%
</wa:Content>
</ns:WayBillAct>
</ns:WayBillAct_v2>
</ns:Document>
</ns:Documents>
"""

XML_ACT_CONTENT="""
<wa:Position>
\t<wa:Identity>%identity%</wa:Identity>
\t<wa:InformBRegId>%wb_RegId%</wa:InformBRegId>
\t<wa:InformF2RegId>%wb_RegId%</wa:InformF2RegId>
\t<wa:RealQuantity>%real%</wa:RealQuantity>
</wa:Position>
"""
Expand Down Expand Up @@ -557,7 +557,7 @@ def _dodoc(self):
self._delete(url)
pass

if typedoc=="{%s}WayBillAct" % ns["ns"]:
if typedoc=="{%s}WayBillAct" % ns["ns"] or typedoc=="{%s}WayBillAct_v2" % ns["ns"]:
if self._addWayBillAct(url,id,tree):
if res.has_key("WayBillAct"):
res['WayBillAct']+=1
Expand Down Expand Up @@ -829,7 +829,7 @@ def _addWayBillAct(self,url,reply_id,tree):
else:
self.struct['status'] = 6
self.struct['xml_ticket']= self.data
self.struct['ns_typedoc']= "WayBillAct"
self.struct['ns_typedoc']= "WayBillAct_v2"
self.struct['wt_IsConfirm']=self.struct['wa_IsAccept']
del self.struct['wa_IsAccept']

Expand Down

0 comments on commit 8f451b5

Please sign in to comment.