RE: [Rainbowportal-devel] help
Brought to you by:
danijel_kecman,
manudea
From: Hongwei S. <hs...@oc...> - 2005-06-24 18:39:51
|
Hello, Rainbow management, I just developed a new functionality for HtmlDocument module to allow editor or approver to compare the staging content with the production content while working in workflow mode. If you think this functionality is useful, please give me check-in permission to submit the code. For you to evaluate it, I enclosed all the necessary files needed to test the functionality. Among them: 1. Rainbow.MergeEngine.dll, inside this class library, I first parse the html strings into English words collection with html tags retained but not compared, and then implement the algorithm proposed by Eugene W. Myers (http://www.si.xmailserver.org/diff2.pdf it is also the algorithm of Unix Diff) to compare the two words collections word-wisely (not character wise). I plan to put the class library project under the Extension repository. For testing, just save the enclosed dll file to Rainbow/bin directory. Since I need a little bit more time to do clean-up, the source code is not enclosed at this time. 2. PortalModuleControl.cs. Implementing the compare functionality doesn't need to modify this file; however, there are two bugs in the file that are triggered by my code. I fixed them and please read the comment inside the code for details. For your convenience, the modified locations are: a) Started from line 680 inside OnLoad=20 b) Started from line 2933 inside protected void RevertToProductionContent (object sender, EventArgs e) 3. HtmlModule.ascx.cs the functionality is implemented here. Modification is inside the region "support for version comparison" and at line 268 to turn on ViewState 4. Put the icon files in the themes/icon directory. Note: All the files and test are based on Rainbow 15 Release, not on the development version on CVS or SVN! If you have any question, I can be reached by Hon...@gm... during the weekend. My sincere thanks to Matt Cowan, he pushed this work and did lots of testing. Hongwei |