mirror of
https://github.com/ONLYOFFICE/sdkjs-forms.git
synced 2026-03-31 10:23:35 +08:00
[oform] Write main part to xml
This commit is contained in:
@ -220,7 +220,11 @@
|
||||
};
|
||||
CDocument.prototype.toPkg = function(xmlPkg)
|
||||
{
|
||||
|
||||
let xmlWriter = xmlPkg.getXmlWriter();
|
||||
let main = xmlPkg.addPart(AscCommon.openXml.Types.oformMain);
|
||||
|
||||
xmlWriter.Seek(0);
|
||||
main.part.setDataXml(this, xmlWriter);
|
||||
};
|
||||
CDocument.prototype.fromXml = function(reader)
|
||||
{
|
||||
@ -291,7 +295,7 @@
|
||||
|
||||
for (let fgIndex = 0, fgCount = this.FieldGroups.length; fgIndex < fgCount; ++fgIndex)
|
||||
{
|
||||
this.FieldsGroups[fgIndex].toXml(writer);
|
||||
this.FieldGroups[fgIndex].toXml(writer);
|
||||
}
|
||||
|
||||
writer.WriteXmlNodeEnd("document");
|
||||
|
||||
@ -51,7 +51,7 @@
|
||||
{
|
||||
let zip = this.zip;
|
||||
let pkg = this;
|
||||
zip.files.forEach(function(path)
|
||||
zip.getPaths().forEach(function(path)
|
||||
{
|
||||
if (!path.endsWith("/"))
|
||||
{
|
||||
@ -78,6 +78,10 @@
|
||||
{
|
||||
this.context = context;
|
||||
};
|
||||
XmlPackage.prototype.getXmlWriter = function()
|
||||
{
|
||||
return this.xmlWriter;
|
||||
};
|
||||
|
||||
//--------------------------------------------------------export----------------------------------------------------
|
||||
AscOForm.XmlPackage = XmlPackage;
|
||||
|
||||
Reference in New Issue
Block a user