cancel
Showing results for 
Search instead for 
Did you mean: 

XML Editor

rdanner
Champ in-the-making
Champ in-the-making
If you are looking for an XML editor that uses a schema to generate a form then this is may be of interest  to you.

I have been working on a tutorial for adding an inline editor to alfresco. I need to go back and finish that.

in the mean time the source for the work can be found at

http://www.posit-group.org/cache/xml-editor.zip

This is only an example.  There are a number of issues.

First the example uses a applet (that costs money).

Second the example uses an applet (that causes browsers to flake)

Third,

I used this as an oppertunity to demonstrate how we can put most of the code in alfresco in to uber-configurable patterns.

In the checkinCheckoutbean method editFile you will notice the code has been pulled out and replace with a "pipeline invokation"

The pipeline definition can be found in checkinCheckoutPipelineChains.xml
and the components used by the pipeline in pipeline-context.xml

more on this later… gotta run
16 REPLIES 16

rdanner
Champ in-the-making
Champ in-the-making
If you are looking for an XML editor that uses a schema to generate a form then this is may be of interest  to you.

I have been working on a tutorial for adding an inline editor to alfresco. I need to go back and finish that.

in the mean time the source for the work can be found at

http://www.posit-group.org/cache/xml-editor.zip

This is only an example.  There are a number of issues.

First the example uses a applet (that costs money).

Second the example uses an applet (that causes browsers to flake)

Third,

I used this as an oppertunity to demonstrate how we can put most of the code in alfresco in to uber-configurable patterns.

In the checkinCheckoutbean method editFile you will notice the code has been pulled out and replace with a "pipeline invokation"

The pipeline definition can be found in checkinCheckoutPipelineChains.xml
and the components used by the pipeline in pipeline-context.xml

more on this later… gotta run


Ok so if you want to take a look at this thing, here is how

o  Download the version 1 Alfresco Source
o  Expand it somewhere
o  Download the xml-editor.zip from (http://www.posit-group.org/cache/xml-editor.zip)
o Unzip it inside the projects folder of the alfresco source code (it should be right aside the other projects like repository)
o  go inside of the xml-editor project and run build.bat.  Build.bat doesnt actual build anything. It just copies the files from the xml-editor over top of the existing projects.
o build afresco war as usual

o upload the sample documents in to a space.
o each file should be "inlineeditable" and of the mimetype XML
o add the Validated XML aspect to the salesreport.xml
o edit the salesreport.xml (properties panel). You will see it has properties for a schema and a xsl.  edit them by selecting the xsl and xsd file you just uploaded.

when you click on the pencil for the xsl and xsd you should get the inline text editor.  when you click on the pencil for HTML you should get the html editor. When you click on the pencil for the salesreport.xml you should see an applet load, then have a form you can edit which will do validation.

rdanner
Champ in-the-making
Champ in-the-making
If you are looking for an XML editor that uses a schema to generate a form then this is may be of interest  to you.

I have been working on a tutorial for adding an inline editor to alfresco. I need to go back and finish that.

in the mean time the source for the work can be found at

http://www.posit-group.org/cache/xml-editor.zip

This is only an example.  There are a number of issues.

First the example uses a applet (that costs money).

Second the example uses an applet (that causes browsers to flake)

Third,

I used this as an oppertunity to demonstrate how we can put most of the code in alfresco in to uber-configurable patterns.

In the checkinCheckoutbean method editFile you will notice the code has been pulled out and replace with a "pipeline invokation"

The pipeline definition can be found in checkinCheckoutPipelineChains.xml
and the components used by the pipeline in pipeline-context.xml

more on this later… gotta run


Ok so if you want to take a look at this thing, here is how

o  Download the version 1 Alfresco Source
o  Expand it somewhere
o  Download the xml-editor.zip from (http://www.posit-group.org/cache/xml-editor.zip)
o Unzip it inside the projects folder of the alfresco source code (it should be right aside the other projects like repository)
o  go inside of the xml-editor project and run build.bat.  Build.bat doesnt actual build anything. It just copies the files from the xml-editor over top of the existing projects.
o build afresco war as usual

o upload the sample documents in to a space.
o each file should be "inlineeditable" and of the mimetype XML
o add the Validated XML aspect to the salesreport.xml
o edit the salesreport.xml (properties panel). You will see it has properties for a schema and a xsl.  edit them by selecting the xsl and xsd file you just uploaded.

when you click on the pencil for the xsl and xsd you should get the inline text editor.  when you click on the pencil for HTML you should get the html editor. When you click on the pencil for the salesreport.xml you should see an applet load, then have a form you can edit which will do validation.


Now.. the xml editor is not the interesting part in my oppinion.  What is interesting is the ability to choose what editor goes with what mimetype and other conditions like the content having a particular aspect without editing any code.

to make logic changes on how the editor is chosen, edit the checkinCheckoutPipelineChains.xml file. to modify what implements each link, modify the pipeline-context.xml.

Now this is all well and good. but where this actually becomes interesting is when we allow plugins to add, subtract, and modify existing links from the chains, or even add new chains.

a5sk4s
Champ in-the-making
Champ in-the-making
Russ:

As part of an evaluation, I am interested in going through the steps of integrating an XML editor.  Unfortunately, I could not access the link http://www.posit-group.org/cache/xml-editor.zip mentioned above.  Also, the Wiki page at http://www.alfresco.org/mediawiki/index.php/Adding_an_Editor_Guide appears to be work in progress.  Is there any better place for me to get jump-started?  Could you please make the above resource available?  Thank you in advance.

Regards,

Andreas

rdanner
Champ in-the-making
Champ in-the-making
Russ:

As part of an evaluation, I am interested in going through the steps of integrating an XML editor.  Unfortunately, I could not access the link http://www.posit-group.org/cache/xml-editor.zip mentioned above.  Also, the Wiki page at http://www.alfresco.org/mediawiki/index.php/Adding_an_Editor_Guide appears to be work in progress.  Is there any better place for me to get jump-started?  Could you please make the above resource available?  Thank you in advance.

Regards,

Andreas


Sure I will repost that code on my personal server as the posit server is down at the moment.  Check again in a few minutes at URL
http://www.devartisan.org/xml-editor.zip


-R

a5sk4s
Champ in-the-making
Champ in-the-making
Russ, thanks for providing the example.  My current understanding is that this is at the proof of concept stage.

I checked the amount of effort, it would take me to merge it into the source code version that I have.  Based on the amount of changes and the fact that there are 3rd party libraries that don't appear to be open source, I've decided to stay away from it.

On the other hand, I believe that this or a similar approach would be very useful.

Is there any activity within the Alfresco team to make inline editor integration a more straight-forward process?

Thanks for any feedback.

Andreas

rdanner
Champ in-the-making
Champ in-the-making
It is based on a third party tool, the second drawback is that it is an applet.

There is a section in the wiki I think that helps integrate this code.  I am not sure if much has changed but this code was written for the pre 1.0 release.

Sorry it is not more helpful.  We just did it to prove to people that you can plug other applications in to alfresco.

You might look at using BXE or something simular.

a5sk4s
Champ in-the-making
Champ in-the-making
Russ, I hope you didn't get me wrong: seeing what you've done was very helpful and I think that it goes into the right direction.

The only part that concerned me a bit was the use of the pipeline framework (which is fine for a proof of concept), as I'm not clear on the availability and licensing ramification.  So I decided not to integrate.

I'm still interested in a solution and you pointed me in the right direction.

At the same time, I was just interested  in existing activities in that area.  Maybe one of the Alfresco developers can speak to that.

Thanks,

Andreas

rdanner
Champ in-the-making
Champ in-the-making
Russ, I hope you didn't get me wrong: seeing what you've done was very helpful and I think that it goes into the right direction.

The only part that concerned me a bit was the use of the pipeline framework (which is fine for a proof of concept), as I'm not clear on the availability and licensing ramification.  So I decided not to integrate.

I'm still interested in a solution and you pointed me in the right direction.

At the same time, I was just interested  in existing activities in that area.  Maybe one of the Alfresco developers can speak to that.

Thanks,

Andreas


Hey Andreas,

No problem what so ever.  The pipeline framework was partially to demonstate some of the concepts discussed in other threads where you can basically do inversion of control at the method level. 

The pipeline stuff is licensed under the apache license 2.0.

unknown-user
Champ on-the-rise
Champ on-the-rise
what about http://chiba.sourceforge.net/ from http://www.chibacon.de? It's a server side, but ajax enabled xforms editor. They have an xsd2xforms conversion (bot in java and in xslt). Using xforms for editing xml would be cool.