hacking up output paths within the avm for the virgin demo.

refixed the fix for making captions look good in the form
turned off debugging within the form.



git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/WCM-DEV2/root@3571 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Ariel Backenroth
2006-08-22 19:33:07 +00:00
parent d7c07afbfe
commit a6c83ecbe0
3 changed files with 13 additions and 7 deletions

View File

@@ -171,7 +171,7 @@ public class OutputUtil
LOGGER.debug("generated " + fileName + " using " + tom); LOGGER.debug("generated " + fileName + " using " + tom);
AVMService avmService = AVMContext.fgInstance.getAVMService(); AVMService avmService = AVMContext.fgInstance.getAVMService();
String parentPath = "repo-1:/repo-1/alice/appBase/avm_webapps/my_webapp"; String parentPath = "repo-1:/repo-1/alice/appBase/avm_webapps/ROOT/home-insurance";
try try
{ {
out = new OutputStreamWriter(avmService.createFile(parentPath, generatedFileName)); out = new OutputStreamWriter(avmService.createFile(parentPath, generatedFileName));

View File

@@ -67,11 +67,11 @@ public class XFormsInputMethod
final Document result = ts.newDocument(); final Document result = ts.newDocument();
final Element div = result.createElement("div"); final Element div = result.createElement("div");
div.setAttribute("id", "alf-ui"); div.setAttribute("id", "alf-ui");
div.setAttribute("style", "width: 100%; border: solid 1px orange;"); div.setAttribute("style", "width: 100%; border: solid 0px orange;");
result.appendChild(div); result.appendChild(div);
Element e = result.createElement("script"); Element e = result.createElement("script");
e.appendChild(result.createTextNode("djConfig = { isDebug: true };\n" + e.appendChild(result.createTextNode("djConfig = { isDebug: false };\n" +
"var WEBAPP_CONTEXT = \"" + cp + "\";\n")); "var WEBAPP_CONTEXT = \"" + cp + "\";\n"));
div.appendChild(e); div.appendChild(e);
e = result.createElement("script"); e = result.createElement("script");

View File

@@ -81,16 +81,22 @@ public class BaseSchemaFormBuilder
// if the word is all upper case, then set to lower case and continue // if the word is all upper case, then set to lower case and continue
if (text.equals(text.toUpperCase())) if (text.equals(text.toUpperCase()))
text = text.toLowerCase(); text = text.toLowerCase();
String[] s = text.split("/[-_\\ ]/"); String[] s = text.split("[-_\\ ]");
StringBuffer result = new StringBuffer(); StringBuffer result = new StringBuffer();
for (int i = 0; i < s.length; i++) for (int i = 0; i < s.length; i++)
{ {
if (i != 0) if (i != 0)
result.append(' '); result.append(' ');
result.append(Character.toUpperCase(s[i].charAt(0)) + if (s[i].length() > 1)
s[i].substring(1, s[i].length() - 1)); {
result.append(Character.toUpperCase(s[i].charAt(0)) +
s[i].substring(1, s[i].length()));
}
else
{
result.append(s[i]);
}
} }
return result.toString(); return result.toString();
} }