Spaces:
Sleeping
Sleeping
Update google_sheet_to_xml.py
Browse files- google_sheet_to_xml.py +3 -2
google_sheet_to_xml.py
CHANGED
|
@@ -91,7 +91,8 @@ def create_xml(documentname , dbPath):
|
|
| 91 |
Height.text=str(0)
|
| 92 |
if rowY[2]=='m2':
|
| 93 |
Area = ET.SubElement(Markup, "Area")
|
| 94 |
-
|
|
|
|
| 95 |
else:
|
| 96 |
Area = ET.SubElement(Markup, "Area")
|
| 97 |
Area.text=str(0)
|
|
@@ -156,7 +157,7 @@ def create_xml(documentname , dbPath):
|
|
| 156 |
tree = ET.ElementTree(MarkupSummary)
|
| 157 |
# write the tree into an XML file
|
| 158 |
# tree.write(str(documentname).split('.pdf')[0]+".xml", encoding ='UTF-8', xml_declaration = True ,method='xml')
|
| 159 |
-
# dbPath='/TSA
|
| 160 |
# (pdfname,path)
|
| 161 |
# path=path+pdfname
|
| 162 |
xmllink= tsadropboxretrieval.uploadanyFile(doc=tree,pdfname=documentname,path=dbPath,flag='xml')
|
|
|
|
| 91 |
Height.text=str(0)
|
| 92 |
if rowY[2]=='m2':
|
| 93 |
Area = ET.SubElement(Markup, "Area")
|
| 94 |
+
print('rowY',rowY)
|
| 95 |
+
Area.text=str(rowY[1])
|
| 96 |
else:
|
| 97 |
Area = ET.SubElement(Markup, "Area")
|
| 98 |
Area.text=str(0)
|
|
|
|
| 157 |
tree = ET.ElementTree(MarkupSummary)
|
| 158 |
# write the tree into an XML file
|
| 159 |
# tree.write(str(documentname).split('.pdf')[0]+".xml", encoding ='UTF-8', xml_declaration = True ,method='xml')
|
| 160 |
+
# dbPath='/TSA JOBS/ADR Test'+pdfpath+'XML/'
|
| 161 |
# (pdfname,path)
|
| 162 |
# path=path+pdfname
|
| 163 |
xmllink= tsadropboxretrieval.uploadanyFile(doc=tree,pdfname=documentname,path=dbPath,flag='xml')
|