Commit ba915264 authored by ElenaSubbotina's avatar ElenaSubbotina Committed by Alexander Trofimov

DocFormat - исправление Интернет_Проект_Трудовой_договор.doc

parent d534c9f3
......@@ -50,8 +50,9 @@ namespace DocFileFormat
//date
//_revisionData->Dttm.Convert( new DateMapping( rPrChange ) );
//author
XMLTools::XMLAttribute<wchar_t> author( _T( "w:author" ), static_cast<WideString*>( this->_doc->RevisionAuthorTable->operator []( _revisionData->Isbt ) )->c_str() );
WideString* author_str = static_cast<WideString*>( this->_doc->RevisionAuthorTable->operator []( _revisionData->Isbt ));
XMLTools::XMLAttribute<wchar_t> author( _T( "w:author" ), FormatUtils::XmlEncode(*author_str).c_str());
rPrChange.AppendAttribute( author );
//convert revision stack
......
......@@ -43,7 +43,8 @@ namespace DocFileFormat
m_pXmlWriter->WriteNodeBegin( _T( "w:comment" ), TRUE );
m_pXmlWriter->WriteAttribute( _T( "w:id" ), FormatUtils::IntToWideString( index ).c_str() );
m_pXmlWriter->WriteAttribute( _T( "w:author" ), m_document->AnnotationOwners->at( atrdPre10->GetAuthorIndex() ).c_str() );
m_pXmlWriter->WriteAttribute( _T( "w:author" ),
FormatUtils::XmlEncode(m_document->AnnotationOwners->at( atrdPre10->GetAuthorIndex() ) ).c_str());
m_pXmlWriter->WriteAttribute( _T( "w:initials" ), atrdPre10->GetUserInitials().c_str() );
//!!!TODO!!!
......
......@@ -319,9 +319,10 @@ namespace DocFileFormat
}
else if ( rev.Type == Inserted )
{
WideString* author = dynamic_cast<WideString*>(m_document->RevisionAuthorTable->operator[](rev.Isbt));
//if it's a inserted run
m_pXmlWriter->WriteNodeBegin(_T("w:ins"), TRUE);
m_pXmlWriter->WriteAttribute(_T("w:author"), dynamic_cast<WideString*>(m_document->RevisionAuthorTable->operator[](rev.Isbt))->c_str());
m_pXmlWriter->WriteAttribute(_T("w:author"), FormatUtils::XmlEncode(*author).c_str());
m_pXmlWriter->WriteNodeEnd(_T(""), TRUE, FALSE);
//rev.Dttm.Convert(new DateMapping(m_pXmlWriter));
}
......
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