Hello,
I have a community install, version 3.0 of Alfrecso. I have some custom metadata (amounts), and there are some problems. The metadata for certain types of documents of this type seems fine, both in database and when i view the properties in the web client. But in the Share, when the users log in, they don't see some of the amounts correctly.
IE. instead of the amount 94532.32 they see 945,323.20 or something similar. This is not always when there are thousand separators, some numbers bigger then 1000.00 show correctly, but some don't.
This has been a minor problem till now, but from recently, I'm even having some issues with Tasks dashlets, that I believe are connected.
For example, in the "Pay tasks" dashlet, when the documents waiting for payment (custom workflow-assigned) load, they don't show correctly (I get the model.load-failed message and my catalina.out shows this: (detailed output at the end of the post):
21:11:11,547 ERROR [web.scripts.AbstractRuntime] Exception from executeScript - redirecting to status template error: Failed to load script '/org/alfresco/components/dashlets/protenus/pay-tasks-list.get.js (in classpath store file:/opt/pbk-svn/webapps/share/WEB-INF/classes/alfresco/site-webscripts)': SyntaxError: missing } after property list (file:/opt/pbk-svn/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/dashlets/protenus/pay-tasks-list.get.js#10(eval)#7579)
This script (pay-tasks-list.get.js) evals output from "pay-tasks-list.json.ftl" script, which reads through the pay tasks and sorts them according to the filter (all/today/tomorrow…). The "SyntaxError" thing leads me to believe that there is some extra comma or extra bracket in the metadata.
I'm struggling 3 days with this (and with alfresco itself only a few weeks now), I don't know where I haven't looked at yet.
Did somebody get this error before? Can you give me a hint please? Can I look for incorrect values in the database (tried searching for ',' in alf_node_properties, but with thousands of documents already in alfresco, it didn't pay off, tried searching for incorrect amounts or something)? Also, how would I call this pay-tasks-list.json.ftl from the web-client (without the eval) - maybe that way I get to see which document has flawed metadata?
Any suggestions where to look at?
Thanks in advance!
The errors from error log:
21:30:19,673 User:avon_fin DEBUG [alfresco.repo.workflow] Detached (commit) JBPM Context from transaction 79727c70-326c-46db-8c79-997bf87053f1
21:30:19,693 ERROR [web.scripts.AbstractRuntime] Exception from executeScript - redirecting to status template error: Failed to load script '/org/alfresco/components/dashlets/protenus/pay-tasks-list.get.js (in classpath store file:/opt/pbk-svn/webapps/share/WEB-INF/classes/alfresco/site-webscripts)': SyntaxError: missing } after property list (file:/opt/pbk-svn/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/dashlets/protenus/pay-tasks-list.get.js#10(eval)#7579)
org.alfresco.web.scripts.WebScriptException: Failed to load script '/org/alfresco/components/dashlets/protenus/pay-tasks-list.get.js (in classpath store file:/opt/pbk-svn/webapps/share/WEB-INF/classes/alfresco/site-webscripts)': SyntaxError: missing } after property list (file:/opt/pbk-svn/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/dashlets/protenus/pay-tasks-list.get.js#10(eval)#7579)
at org.alfresco.web.scripts.PresentationScriptProcessor.executeScript(PresentationScriptProcessor.java:161)
at org.alfresco.web.scripts.AbstractWebScript.executeScript(AbstractWebScript.java:827)
at org.alfresco.web.scripts.DeclarativeWebScript.execute(DeclarativeWebScript.java:90)
at org.alfresco.web.scripts.PresentationContainer.executeScript(PresentationContainer.java:60)
at org.alfresco.web.scripts.LocalWebScriptRuntimeContainer.executeScript(LocalWebScriptRuntimeContainer.java:169)
at org.alfresco.web.scripts.AbstractRuntime.executeScript(AbstractRuntime.java:262)
at org.alfresco.web.scripts.AbstractRuntime.executeScript(AbstractRuntime.java:139)
at org.alfresco.web.scripts.servlet.WebScriptServlet.service(WebScriptServlet.java:122)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190)
at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:767)
at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:697)
at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:889)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690)
at java.lang.Thread.run(Thread.java:619)
Caused by: org.alfresco.web.scripts.WebScriptException: SyntaxError: missing } after property list (file:/opt/pbk-svn/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/dashlets/protenus/pay-tasks-list.get.js#10(eval)#7579)
at org.alfresco.web.scripts.PresentationScriptProcessor.executeScriptImpl(PresentationScriptProcessor.java:275)
at org.alfresco.web.scripts.PresentationScriptProcessor.executeScript(PresentationScriptProcessor.java:157)
… 23 more
Caused by: org.mozilla.javascript.EcmaError: SyntaxError: missing } after property list (file:/opt/pbk-svn/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/dashlets/protenus/pay-tasks-list.get.js#10(eval)#7579)
at org.mozilla.javascript.ScriptRuntime.constructError(ScriptRuntime.java:3350)
at org.mozilla.javascript.DefaultErrorReporter.error(DefaultErrorReporter.java:89)
at org.mozilla.javascript.Parser.addError(Parser.java:140)
at org.mozilla.javascript.Parser.reportError(Parser.java:154)
at org.mozilla.javascript.Parser.mustMatchToken(Parser.java:240)
at org.mozilla.javascript.Parser.primaryExpr(Parser.java:2031)
at org.mozilla.javascript.Parser.memberExpr(Parser.java:1729)
at org.mozilla.javascript.Parser.unaryExpr(Parser.java:1590)
at org.mozilla.javascript.Parser.mulExpr(Parser.java:1519)
at org.mozilla.javascript.Parser.addExpr(Parser.java:1500)
at org.mozilla.javascript.Parser.shiftExpr(Parser.java:1480)
at org.mozilla.javascript.Parser.relExpr(Parser.java:1454)
at org.mozilla.javascript.Parser.eqExpr(Parser.java:1410)
at org.mozilla.javascript.Parser.bitAndExpr(Parser.java:1399)
at org.mozilla.javascript.Parser.bitXorExpr(Parser.java:1388)
at org.mozilla.javascript.Parser.bitOrExpr(Parser.java:1377)
at org.mozilla.javascript.Parser.andExpr(Parser.java:1365)
at org.mozilla.javascript.Parser.orExpr(Parser.java:1353)
at org.mozilla.javascript.Parser.condExpr(Parser.java:1336)
at org.mozilla.javascript.Parser.assignExpr(Parser.java:1321)
at org.mozilla.javascript.Parser.primaryExpr(Parser.java:1952)
at org.mozilla.javascript.Parser.memberExpr(Parser.java:1729)
at org.mozilla.javascript.Parser.unaryExpr(Parser.java:1590)
at org.mozilla.javascript.Parser.mulExpr(Parser.java:1519)
at org.mozilla.javascript.Parser.addExpr(Parser.java:1500)
at org.mozilla.javascript.Parser.shiftExpr(Parser.java:1480)
at org.mozilla.javascript.Parser.relExpr(Parser.java:1454)
at org.mozilla.javascript.Parser.eqExpr(Parser.java:1410)
at org.mozilla.javascript.Parser.bitAndExpr(Parser.java:1399)
at org.mozilla.javascript.Parser.bitXorExpr(Parser.java:1388)
at org.mozilla.javascript.Parser.bitOrExpr(Parser.java:1377)
at org.mozilla.javascript.Parser.andExpr(Parser.java:1365)
at org.mozilla.javascript.Parser.orExpr(Parser.java:1353)
at org.mozilla.javascript.Parser.condExpr(Parser.java:1336)
at org.mozilla.javascript.Parser.assignExpr(Parser.java:1321)
at org.mozilla.javascript.Parser.plainProperty(Parser.java:2135)
at org.mozilla.javascript.Parser.primaryExpr(Parser.java:2011)
at org.mozilla.javascript.Parser.memberExpr(Parser.java:1729)
at org.mozilla.javascript.Parser.unaryExpr(Parser.java:1590)
at org.mozilla.javascript.Parser.mulExpr(Parser.java:1519)
at org.mozilla.javascript.Parser.addExpr(Parser.java:1500)
at org.mozilla.javascript.Parser.shiftExpr(Parser.java:1480)
at org.mozilla.javascript.Parser.relExpr(Parser.java:1454)
at org.mozilla.javascript.Parser.eqExpr(Parser.java:1410)
at org.mozilla.javascript.Parser.bitAndExpr(Parser.java:1399)
at org.mozilla.javascript.Parser.bitXorExpr(Parser.java:1388)
at org.mozilla.javascript.Parser.bitOrExpr(Parser.java:1377)
at org.mozilla.javascript.Parser.andExpr(Parser.java:1365)
at org.mozilla.javascript.Parser.orExpr(Parser.java:1353)
at org.mozilla.javascript.Parser.condExpr(Parser.java:1336)
at org.mozilla.javascript.Parser.assignExpr(Parser.java:1321)
at org.mozilla.javascript.Parser.primaryExpr(Parser.java:1952)
at org.mozilla.javascript.Parser.memberExpr(Parser.java:1729)
at org.mozilla.javascript.Parser.unaryExpr(Parser.java:1590)
at org.mozilla.javascript.Parser.mulExpr(Parser.java:1519)
at org.mozilla.javascript.Parser.addExpr(Parser.java:1500)
at org.mozilla.javascript.Parser.shiftExpr(Parser.java:1480)
at org.mozilla.javascript.Parser.relExpr(Parser.java:1454)
at org.mozilla.javascript.Parser.eqExpr(Parser.java:1410)
at org.mozilla.javascript.Parser.bitAndExpr(Parser.java:1399)
at org.mozilla.javascript.Parser.bitXorExpr(Parser.java:1388)
at org.mozilla.javascript.Parser.bitOrExpr(Parser.java:1377)
at org.mozilla.javascript.Parser.andExpr(Parser.java:1365)
at org.mozilla.javascript.Parser.orExpr(Parser.java:1353)
at org.mozilla.javascript.Parser.condExpr(Parser.java:1336)
at org.mozilla.javascript.Parser.assignExpr(Parser.java:1321)
at org.mozilla.javascript.Parser.plainProperty(Parser.java:2135)
at org.mozilla.javascript.Parser.primaryExpr(Parser.java:2011)
at org.mozilla.javascript.Parser.memberExpr(Parser.java:1729)
at org.mozilla.javascript.Parser.unaryExpr(Parser.java:1590)
at org.mozilla.javascript.Parser.mulExpr(Parser.java:1519)
at org.mozilla.javascript.Parser.addExpr(Parser.java:1500)
at org.mozilla.javascript.Parser.shiftExpr(Parser.java:1480)
at org.mozilla.javascript.Parser.relExpr(Parser.java:1454)
at org.mozilla.javascript.Parser.eqExpr(Parser.java:1410)
at org.mozilla.javascript.Parser.bitAndExpr(Parser.java:1399)
at org.mozilla.javascript.Parser.bitXorExpr(Parser.java:1388)
at org.mozilla.javascript.Parser.bitOrExpr(Parser.java:1377)
at org.mozilla.javascript.Parser.andExpr(Parser.java:1365)
at org.mozilla.javascript.Parser.orExpr(Parser.java:1353)
at org.mozilla.javascript.Parser.condExpr(Parser.java:1336)
at org.mozilla.javascript.Parser.assignExpr(Parser.java:1321)
at org.mozilla.javascript.Parser.expr(Parser.java:1308)
at org.mozilla.javascript.Parser.primaryExpr(Parser.java:2045)
at org.mozilla.javascript.Parser.memberExpr(Parser.java:1729)
at org.mozilla.javascript.Parser.unaryExpr(Parser.java:1590)
at org.mozilla.javascript.Parser.mulExpr(Parser.java:1519)
at org.mozilla.javascript.Parser.addExpr(Parser.java:1500)
at org.mozilla.javascript.Parser.shiftExpr(Parser.java:1480)
at org.mozilla.javascript.Parser.relExpr(Parser.java:1454)
at org.mozilla.javascript.Parser.eqExpr(Parser.java:1410)
at org.mozilla.javascript.Parser.bitAndExpr(Parser.java:1399)
at org.mozilla.javascript.Parser.bitXorExpr(Parser.java:1388)
at org.mozilla.javascript.Parser.bitOrExpr(Parser.java:1377)
at org.mozilla.javascript.Parser.andExpr(Parser.java:1365)
at org.mozilla.javascript.Parser.orExpr(Parser.java:1353)
at org.mozilla.javascript.Parser.condExpr(Parser.java:1336)
at org.mozilla.javascript.Parser.assignExpr(Parser.java:1321)
at org.mozilla.javascript.Parser.expr(Parser.java:1308)
at org.mozilla.javascript.Parser.statementHelper(Parser.java:1205)
at org.mozilla.javascript.Parser.statement(Parser.java:655)
at org.mozilla.javascript.Parser.parse(Parser.java:377)
at org.mozilla.javascript.Parser.parse(Parser.java:315)
at org.mozilla.javascript.Context.compileImpl(Context.java:2320)
at org.mozilla.javascript.Context.compileString(Context.java:1348)
at org.mozilla.javascript.ScriptRuntime.evalSpecial(ScriptRuntime.java:2276)
at org.mozilla.javascript.ScriptRuntime.callSpecial(ScriptRuntime.java:2143)
at org.mozilla.javascript.optimizer.OptRuntime.callSpecial(OptRuntime.java:165)
at org.mozilla.javascript.gen.c26._c1(file:/opt/pbk-svn/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/dashlets/protenus/pay-tasks-list.get.js:10)
at org.mozilla.javascript.gen.c26.call(file:/opt/pbk-svn/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/dashlets/protenus/pay-tasks-list.get.js)
at org.mozilla.javascript.optimizer.OptRuntime.callName0(OptRuntime.java:108)
at org.mozilla.javascript.gen.c26._c0(file:/opt/pbk-svn/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/dashlets/protenus/pay-tasks-list.get.js:1)
at org.mozilla.javascript.gen.c26.call(file:/opt/pbk-svn/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/dashlets/protenus/pay-tasks-list.get.js)
at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:393)
at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:2834)
at org.mozilla.javascript.gen.c26.call(file:/opt/pbk-svn/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/dashlets/protenus/pay-tasks-list.get.js)
at org.mozilla.javascript.gen.c26.exec(file:/opt/pbk-svn/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/dashlets/protenus/pay-tasks-list.get.js)
at org.alfresco.web.scripts.PresentationScriptProcessor.executeScriptImpl(PresentationScriptProcessor.java:265)
… 24 more