0

Context:

I have a webpage with an applet in the Share side. The webpage can be seen through the link

localhost:8080/share/page/hdp/ws/my-page?file=nodeRefOfFile

Problem:

I define a custom workflow. I want integrate this applet in the workflow for the user accept the task.

I define a Java class in repository side that is called in workflow.

How can I call the webpage (Share side) in JAVA class that I use in the workflow. In JAVA class I have a nodeRef of the file of the workflow, but I don't know too how can I refresh file on javascript and gives the nodeRef to JAVA. My problem is communicate JAVA (repository) with javascript (share).

I have to make a webscript repository with the page? Any suggestion?

1 Answer 1

2
+100

Answer changed: the OP is trying to integrate an applet with the Share workflow. I'd highly recommend loading the applet inside of a new custom component and calling the applet from the task's workflow validation.

The component itself can calculate the url of the file you want to sign, or you can read the form data and get the url of the file with Ajax. Finally, the applet will need to write the signed file into a hidden field (via base64). Before posting the workflow form, you can use ajax to send the file to the repository. Use the share proxy url to avoid needing to authenticate with the repository.

Sign up to request clarification or add additional context in comments.

15 Comments

But my question it's the opposite. I have a webpage webscript on Share with <authentication>user</authentication>. In this webpage I have an applet. I have a Java class on the repository and I can access the file (I have the NodeRef), and call the webpage (my page is not under /alfresco/service but share/page/hdp/ws/mypage. Then I want to pass the NodeRef for the applet (javascript)... Then, I run applet and after this I want to receive in the Java the new NodeRef (updated with modifications). But the situation of call webpage, its under share/page/hdp/ws/mypage .
I'm having a difficult time understanding your question and comments. If you could rephrase your question (maybe have a coworker with strong English help you out), it would be easier to understand your issue and get you a good reply.
I have my workflow tasks on repository side (only the form is on the share side). But I want to call a webpage (where is on the share side) /share/page/hdp/ws/newpage, on the accept button of the user task with a Java repository class. But the webpage is on share side so, I get an error 401 unauthorized when I want to open the Page. This is the first Problem. The second is comunicate Java repository class (where i want to call the webpage) with the Applet (javascript share side) that I have on webpage.
It's still very unclear and grammatically incorrect. I really think you need to get it proofread by someone with better English, preferably someone with a technical background.
Yes, the English has multiple mistakes which make your meaning unclear. What you want to do is obviously clear for you, but you need to understand it will not be clear to others, especially if it is an unusual request.
|

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.