cancel
Showing results for 
Search instead for 
Did you mean: 

3.4 Custom action problem

ghernando
Champ in-the-making
Champ in-the-making
With the standard example for Custom Document Library Action in 3.4 (Backup), I'm seeing an error.
This was working for me in 3.3.

Do I need to use a different class on the bean that defines where the property file is?

org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find class [org.alfresco.i18n.ResourceBundleBootstrapComponent] for bean with name 'webscripts.resources.actions' defined in URL [jar:file:/C:/Alfresco/c34c/tomcat/shared/lib/share-backup-action.jar!/org/springframework/extensions/surf/slingshot-custom-backup-action-context.xml]; nested exception is java.lang.ClassNotFoundException: org.alfresco.i18n.ResourceBundleBootstrapComponent
        at org.springframework.beans.factory.support.AbstractBeanFactory.resolveBeanClass(AbstractBeanFactory.java:1208)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.predictBeanType(AbstractAutowireCapableBeanFactory.java:568)
        at org.springframework.beans.factory.support.AbstractBeanFactory.isFactoryBean(AbstractBeanFactory.java:1277)
9 REPLIES 9

ghernando
Champ in-the-making
Champ in-the-making
I see that this error on startup is actually being thrown during the deployment of the wcmqs.war file.
The share.war file deployed successfully with no error.
I have my custom action in the tomcat\share\lib directory.

openpj
Elite Collaborator
Elite Collaborator
Does anybody knows something about the new pages of the wiki about how to customize Share?
There are some pages in the wiki that are deprecated and for the latest version of Share it is a problem, for example the following page:
http://wiki.alfresco.com/wiki/Custom_Document_Library_Action

Thank you for any information.

akudinov
Champ in-the-making
Champ in-the-making
Hello

What about this problem ?

How I can develop custom library action ?

Thank you

wabson
Star Contributor
Star Contributor
I'm afraid I can't comment on the wiki page, but I found that my version of the custom backup action hosted on Share Extras still works perfectly in version 3.4.

You can find more information here - http://code.google.com/p/share-extras/wiki/BackupAction

Thanks,
Will.

csabee
Champ in-the-making
Champ in-the-making
Hi,

I've been going through the example you have provided. So I have finished all the steps, but it doesn't seem to be working.
I'm using Alfresco 3.4.d!

Here is what I see:
1. Firebug console shows no errors in the code.
2. The webscript is accessable as you have wrote.
3. In firebug, under the DOM, I can see the action under Alfresco.doclib.actions.prototype…
4. In firebug, also under DOM I see an other object, DocumentActions.prototype that doesn't contain onActionBackup, but all the other event handlers. I think this may be a problem.

When I click on the link, nothing happens. I have added seome console.debug() calls to the starting point of the code (backup-action-min.js), and it seems to me, that the event handler isn't attached to the link.
Why is this? Can you help me on solving this problem?

Thank you!

csabee
Champ in-the-making
Champ in-the-making
Hi again,

I have been surfing on the alfresco forum, and have found the following topic:
http://forums.alfresco.com/en/viewtopic.php?f=47&t=37518

It gave me a big help, and I have made the necessary modifications to the following file:
documentlibrary-actions.js (also copied it as documentlibrary-actions-min.js)

But the best would be if any custom action could work without overwriting the original alfresco files.

Any idea on this, how to do this correctly, or why the first one (described here: http://wiki.alfresco.com/wiki/Custom_Document_Library_Action) doesn't work?

Thank you!

mikeh
Star Contributor
Star Contributor

need
Champ in-the-making
Champ in-the-making
I csabee,

i have the some problem, i follow exactly the share extra google page example and usage instruction for backup action but i don't seem in the document library list and in edit metadata page in section document actions. In the alfresco log don't see error.

You have resolved this problem??

My version is 3.4d.

Thanks man

wabson
Star Contributor
Star Contributor
@need,

I would suggest you install a JavaScript debugger such as Firebug (if you are using Firefox), or Chrome's developer tools. Get yourself familiar with it and it will help you to troubleshoot what's going on with the custom action.

The first thing it should tell you is if any errors are being thrown by the custom action. If not, there's a few other things you can investigate with the tools as Csabee explains in the four points in his/her post above.

Lastly although it's not relevant to 3.4, it's worth noting for others perhaps that the doclib actions framework has changed again in 4.0 and it is now much easier to add new actions.

Cheers,
Will.