-
1. Re: CMS portlet customization HELP
theute Jul 9, 2007 5:44 AM (in response to shtainberg)Of course you can, the source code is available look at core-cms.
The service is in cms, you shouldn't need to change it, just to use it.
Look at core-cms to see how you can build your own portlet.
By the way if you modify and improve the existing portlet, please consider contributing back :) -
2. Re: CMS portlet customization HELP
shtainberg Jul 9, 2007 6:51 AM (in response to shtainberg)Can i do it without modifing the portlet code ?
I just want some simple API to upload files and add some custom fields for search ... -
3. Re: CMS portlet customization HELP
theute Jul 9, 2007 7:11 AM (in response to shtainberg)You can already upload files. See the current portlet.
I don't understand what you want to do. You tell me that you want to change the portlet without changing the code, It is not clear to me that you are trying to achieve. -
4. Re: CMS portlet customization HELP
shtainberg Jul 9, 2007 7:19 AM (in response to shtainberg)My final destination , for example , is to have a simple form in which a logged-in user can upload a file and write some input to custom fields (like "related case number") and than have the file uploaded to a directory with the "related case number" string name...
What is the most simplest way to achive that ? -
5. Re: CMS portlet customization HELP
theute Jul 9, 2007 7:30 AM (in response to shtainberg)If you want to reuse the current CMS service and browser you can adapt it.
Add a field on the form, then query the CMS service to create a CMS folder using the Command org.jboss.portal.cms.impl.jcr.command.FolderCreateCommand
But of course you will have to adapt the UI and the backend.
You can also create a totally new portlet and call the same CMS service. (See core-cms to see how it works) That would be easier if you want to benefit from bug fixes and improvement of the CMS admin portlet. -
6. Re: CMS portlet customization HELP
shtainberg Jul 9, 2007 9:25 AM (in response to shtainberg)Another newbie question :-)
I mpdified a little the core-cms code and compiled it. How should i deploy it ?
10x! -
7. Re: CMS portlet customization HELP
soshah Jul 9, 2007 9:40 AM (in response to shtainberg)Just go to the core-cms directory and type in:
ant clean main deploy-explode
Also make sure your build/local.properties file is setup according to your local box setup
The values are pretty self explanatory
Thanks -
8. Re: CMS portlet customization HELP
shtainberg Jul 9, 2007 10:01 AM (in response to shtainberg):-(
After deploying. i get the following error:
org.apache.jasper.JasperException: File "/WEB-INF/portlet.tld" not found
what wrong have i done ? -
9. Re: CMS portlet customization HELP
soshah Jul 9, 2007 10:08 AM (in response to shtainberg)Is the rest of your jboss-portal.sar deployed in your application server
I am assuming all your portal stuff is deployed and you are deploying only the core-cms component into the jboss-portal.sar.
Also, can you paste a stack trace with your error for a clearer picture of what is happening
Thanks -
10. Re: CMS portlet customization HELP
shtainberg Jul 9, 2007 10:10 AM (in response to shtainberg)now, it's more complex ...
I restarted jboss and now accessing the portal gives me this:
java.lang.IllegalStateException: Cannot get portal server
org.jboss.portal.server.servlet.PortalServlet.getServer(PortalServlet.java:126)
org.jboss.portal.server.servlet.PortalServlet.service(PortalServlet.java:345)
javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96) -
11. Re: CMS portlet customization HELP
soshah Jul 9, 2007 10:22 AM (in response to shtainberg)Can you post what your jboss-portal.sar looks like after doing the deploy?
Also can you post more of the server stack trace as well?
Thanks -
12. Re: CMS portlet customization HELP
shtainberg Jul 9, 2007 10:46 AM (in response to shtainberg)[root@dannys jboss-portal.sar]# ls
conf lib portal-admin.sar portal-aop.xml portal-core.war portal-samples.sar portal-wsrp.sar
dtd META-INF portal-ajax.war portal-cms.sar portal-management.sar portal-server.war widget.war
from the server log , maybe that's the problem ??
2007-07-09 17:28:58,129 ERROR [org.jboss.deployment.MainDeployer] Could not create deployment: file:/home/danny/jboss-portal-2.6-CR2/server/default/deploy/hsorg.jboss.deployment.DeploymentException: create operation failed for package file:/home/danny/jboss-portal-2.6-CR2/server/default/deploy/hsqldb-ds.xml; - ne at org.jboss.deployment.SARDeployer.create(SARDeployer.java:278)
2007-07-09 17:29:17,161 ERROR [org.jboss.deployment.scanner.URLDeploymentScanner] Incomplete Deployment listing:
.....
org.jboss.deployment.DeploymentInfo@18308a19 { url=file:/home/danny/jboss-portal-2.6-CR2/server/default/deploy/jboss-portal.sar/portal-cms.sar/ }
deployer: org.jboss.deployment.SARDeployer@164dbd5
status: Deployment FAILED reason: - nested throwable: (java.lang.reflect.UndeclaredThrowableException)
state: FAILED
watch: file:/home/danny/jboss-portal-2.6-CR2/server/default/deploy/jboss-portal.sar/portal-cms.sar/META-INF/jboss-service.xml
altDD: null
lastDeployed: 1183991309972
lastModified: 1183991139000
mbeans:
.
....
org.jboss.deployment.DeploymentInfo@213e6eb8 { url=file:/home/danny/jboss-portal-2.6-CR2/server/default/deploy/hsqldb-ds.xml }
deployer: org.jboss.deployment.XSLSubDeployer@109df06
status: Deployment FAILED reason: create operation failed for package file:/home/danny/jboss-portal-2.6-CR2/server/default/deploy/hsqldb-ds.xml; - nested t state: FAILED
watch: file:/home/danny/jboss-portal-2.6-CR2/server/default/deploy/hsqldb-ds.xml
altDD: null
lastDeployed: 1183991337909
lastModified: 1183991337000
mbeans:
jboss.jca:service=LocalTxCM,name=DefaultDS (state not available)
jboss.jca:service=ManagedConnectionPool,name=DefaultDS (state not available)
jboss.jca:service=ManagedConnectionFactory,name=DefaultDS (state not available)
jboss.jca:service=DataSourceBinding,name=DefaultDS (state not available)
jboss.jdbc:service=metadata,datasource=DefaultDS (state not available)
jboss:service=Hypersonic,database=localDB (state not available) -
13. Re: CMS portlet customization HELP
soshah Jul 9, 2007 10:49 AM (in response to shtainberg)From the stack trace it looks like your hsqldb-ds.xml maybe missing.
You can copy it over from any other server configuration.
Thats the DefaultDS that you need for the application server.
btw- also try deploying with a clean installation by doing
rm -rf data log tmp work
in the server configuration where your portal is deployed
Thanks -
14. Re: CMS portlet customization HELP
shtainberg Jul 11, 2007 4:57 AM (in response to shtainberg)There is a hsqldb-ds.xml file in server/default/depoloy ...