0001: /*
0002: * JFolder, Copyright 2001-2006 Gary Steinmetz
0003: *
0004: * Distributable under LGPL license.
0005: * See terms of license at gnu.org.
0006: */
0007:
0008: package org.jfolder.console.web.base;
0009:
0010: //base classes
0011: import java.io.IOException;
0012: import java.util.ArrayList;
0013: import java.util.Collections;
0014: import java.util.HashMap;
0015: import java.util.Iterator;
0016:
0017: //project specific classes
0018: import org.jfolder.common.entity.properties.SystemEntityProperties;
0019: import org.jfolder.common.utils.misc.MiscHelper;
0020: import org.jfolder.common.utils.xml.XMLHelper;
0021: import org.jfolder.common.web.template.ConsoleParameterContext;
0022: import org.jfolder.common.web.template.ConsoleTemplateParameters;
0023: import org.jfolder.common.web.template.CreationParameterContext;
0024: import org.jfolder.common.web.template.PageSetupContext;
0025: import org.jfolder.common.web.template.SubmitActionContext;
0026: import org.jfolder.common.web.template.SubmitActionParameters;
0027: import org.jfolder.console.base.ConsolePageContext;
0028: import org.jfolder.console.base.ConsolePageParameters;
0029: import org.jfolder.console.base.ConsolePageSession;
0030: import org.jfolder.console.base.NamesForParentCpc;
0031: import org.jfolder.console.base.context.SubLimitTextConsolePageContext;
0032: import org.jfolder.console.base.context.SubMessageHolderConsolePageContext;
0033: import org.jfolder.project.model.ProjectSystem;
0034: import org.jfolder.security.model.UserIdentity;
0035:
0036: //other classes
0037:
0038: public class ConsoleScreenContext extends ConsolePageContext {
0039:
0040: //
0041: private final static String BUTTON__DB_ACCESS = "BUTTON__DB_ACCESS";
0042: //private final static String BUTTON__QUERY = "BUTTON__QUERY";
0043: //private final static String BUTTON__IMP_EXP = "BUTTON__IMP_EXP";
0044: //private final static String BUTTON__DOC_SYS = "BUTTON__DOC_SYS";
0045: private final static String BUTTON__MAC_STU = "BUTTON__MAC_STU";
0046: private final static String BUTTON__MAC_EXE = "BUTTON__MAC_EXE";
0047: private final static String BUTTON__CON_STU = "BUTTON__CON_STU";
0048: //private final static String BUTTON__MAN_TRIG = "BUTTON__MAN_TRIG";
0049: //private final static String BUTTON__SER_MARK_UND = "BUTTON__SER_MARK_UND";
0050: private final static String BUTTON__SER_MARK_DEP = "BUTTON__SER_MARK_DEP";
0051: //private final static String BUTTON__COP_TO_SERV = "BUTTON__COP_TO_SERV";
0052: //private final static String BUTTON__US_APP_DEL = "BUTTON__US_APP_DEL";
0053: //private final static String BUTTON__US_APP_EXP = "BUTTON__US_APP_EXP";
0054: //private final static String BUTTON__US_MARK_UND = "BUTTON__US_MARK_UND";
0055: //private final static String BUTTON__US_MARK_DEP = "BUTTON__US_MARK_DEP";
0056: private final static String BUTTON__US_EDIT_WORK = "BUTTON__US_EDIT_WORK";
0057: private final static String BUTTON__US_CRE_PAGE = "BUTTON__US_CRE_PAGE";
0058: private final static String BUTTON__US_UPL_FILE = "BUTTON__US_UPL_FILE";
0059: private final static String BUTTON__US_UPD_DESC = "BUTTON__US_UPD_DESC";
0060: private final static String BUTTON__US_NEW_APP = "BUTTON__US_NEW_APP";
0061: private final static String BUTTON__US_DEPLOY = "BUTTON__US_DEPLOY";
0062: private final static String BUTTON__US_IMPORT = "BUTTON__US_IMPORT";
0063: //private final static String BUTTON__START_REC = "BUTTON__START_REC";
0064: //private final static String BUTTON__STOP_REC = "BUTTON__STOP_REC";
0065: //private final static String BUTTON__START_REP = "BUTTON__START_REP";
0066: //private final static String BUTTON__STOP_REP = "BUTTON__STOP_REP";
0067: private final static String BUTTON__AUD_QUE = "BUTTON__AUD_QUE";
0068: private final static String BUTTON__AUD_CRE = "BUTTON__AUD_CRE";
0069: private final static String BUTTON__AUT_APP = "BUTTON__AUT_APP";
0070: //
0071: private final static String BUTTON__DEPLOYED_SERVER_APPLICATION_OPTIONS = "BUTTON__DEPLOYED_SERVER_APPLICATION_OPTIONS";
0072: //
0073: private final static String BUTTON__USER_APP_OPTIONS = "BUTTON__USER_APP_OPTIONS";
0074: //
0075: private final static String CRE_PARAM_CALL__DEPLOY = "CRE_PARAM_CALL__DEPLOY";
0076: private final static String CRE_PARAM_CALL__APP_OPTIONS = "CRE_PARAM_CALL__APP_OPTIONS";
0077: private final static String CRE_PARAM_CALL__DEPLOYED_APP_OPTIONS = "CRE_PARAM_CALL__DEPLOYED_APP_OPTIONS";
0078: private final static String CRE_PARAM_CALL__UNDEP_APP_OPTIONS = "CRE_PARAM_CALL__UNDEP_APP_OPTIONS";
0079:
0080: //
0081: private final static String ADMINISTER = "ADMINISTER";
0082: private final static String DEVELOP = "DEVELOP";
0083: //
0084: private final static String APPLICATIONS = "APPLICATIONS";
0085: private final static String MONITOR = "MONITOR";
0086: //private final static String WEB_PAGES = "WEB_PAGES";
0087: //private final static String WEB_FILES = "WEB_FILES";
0088: private final static String WEB = "WEB";
0089: private final static String PROPERTY = "PROPERTY";
0090: private final static String INPUT_DIRECTORY_NAME = "INPUT_DIRECTORY_NAME";
0091: private final static String INPUT_FILE_UPLOAD = "INPUT_FILE_UPLOAD";
0092: private final static String INPUT_CREATE_PAGE = "INPUT_CREATE_PAGE";
0093: //private final static String INPUT_REP_MAC_UPL = "INPUT_REP_MAC_UPL";
0094: //private final static String INPUT_SERVLET_NAME = "INPUT_SERVLET_NAME";
0095: //private final static String INPUT_SERVLET_CLASS = "INPUT_SERVLET_CLASS";
0096: //
0097: //private final static String INPUT_PROJECT_DEPLOY_DIR =
0098: // "INPUT_PROJECT_DEPLOY_DIR";
0099: //private final static String INPUT_PROJECT_USER_SOURCE =
0100: // "INPUT_PROJECT_USER_SOURCE";
0101: //private final static String INPUT_PROJECT_NAME_SOURCE =
0102: // "INPUT_PROJECT_NAME_SOURCE";
0103: //
0104: //private final static String INPUT_PROJECT_DEPLOY_VISIBLE =
0105: // "INPUT_PROJECT_DEPLOY_VISIBLE";
0106: //
0107: private final static String DEPLOYED_SERVER_APPLICATIONS = "DEPLOYED_SERVER_APPLICATIONS";
0108: private final static String UNDEPLOYED_SERVER_APPLICATIONS = "UNDEPLOYED_SERVER_APPLICATIONS";
0109: private final static String AVAILABLE_SERVER_APPLICATIONS = "AVAILABLE_SERVER_APPLICATIONS";
0110: //
0111: private final static String IMAGE__DEPLOYED_APPLICATION = "IMAGE__DEPLOYED_APPLICATION";
0112: //
0113: private final static String TOG_CALL__PROPERTY = "TOG_CALL__PROPERTY";
0114: private final static String TOG_CALL__WEB = "TOG_CALL__WEB";
0115: private final static String TOG_CALL__USER_APP = "TOG_CALL__USER_APP";
0116: private final static String TOG_CALL__DEV_APPS = "TOG_CALL__DEV_APPS";
0117: private final static String TOG_CALL__ADMIN_APPS = "TOG_CALL__ADMIN_APPS";
0118: private final static String TOG_CALL__ADMIN_OTHER = "TOG_CALL__ADMIN_OTHER";
0119: private final static String TOG_CALL__ADMIN = "TOG_CALL__ADMIN";
0120: private final static String TOG_CALL__DEVEL = "TOG_CALL__DEVEL";
0121:
0122: private ConsoleScreenContext(ConsolePageSession inCps) {
0123:
0124: super (inCps);
0125: }
0126:
0127: public final static ConsoleScreenContext newInstance(
0128: ConsolePageSession inCps) {
0129:
0130: ConsoleScreenContext outValue = null;
0131:
0132: if (inCps.isConsolePageContextPresent(NamesForParentCpc
0133: .getConsoleScreenCpcName())) {
0134: //
0135: outValue = (ConsoleScreenContext) inCps
0136: .getConsolePageContext(NamesForParentCpc
0137: .getConsoleScreenCpcName());
0138: } else {
0139: outValue = new ConsoleScreenContext(inCps);
0140: inCps.registerConsolePageContext(NamesForParentCpc
0141: .getConsoleScreenCpcName(), outValue);
0142: }
0143:
0144: return outValue;
0145: }
0146:
0147: public String getFromPage() {
0148: return ConsolePageParameters.SERVLET_CONSOLE;
0149: }
0150:
0151: public String getHandleExtension() {
0152: return NULL_HANDLE;
0153: }
0154:
0155: //
0156: /*
0157: private final static Connection getTestConnection() {
0158:
0159: try {
0160: //MiscHelper.writeMessage(SystemStore.class, new Exception());
0161: Connection outValue = null;
0162:
0163: Context context = new InitialContext();
0164: Object dsObject = context.lookup(
0165: "java:comp/env/jdbc/JFolder/Apps");
0166: //Context context = new InitialContext("java:comp/env/");
0167: //Object dsObject = context.lookup(
0168: // "java:comp/env/jdbc/WorkflowLifecycle/DBStore");
0169: DataSource ds = (DataSource)PortableRemoteObject.narrow(
0170: dsObject, DataSource.class);
0171:
0172: outValue = ds.getConnection();
0173:
0174: MiscHelper.println("ConScrCon remove getTestConnection()");
0175: MiscHelper.println(
0176: "ConScrCon testCon autoCommit = " + outValue.getAutoCommit());
0177:
0178: outValue.close();
0179:
0180: return outValue;
0181: }
0182: catch (SQLException sqle) {
0183: throw new UnexpectedSystemException(sqle);
0184: }
0185: catch (NamingException ne) {
0186: throw new UnexpectedSystemException(ne);
0187: }
0188: }
0189: */
0190:
0191: //ConsoleScreenHelper
0192: protected void renderConsolePage() throws IOException {
0193:
0194: startCommonPage();
0195:
0196: ConsolePageSession cps = getConsolePageSession();
0197: //String consoleError = cs.getConsoleError();
0198:
0199: boolean administrator = true;
0200: boolean developer = true;
0201:
0202: //
0203: addDefaultTreeBranch(cps.getToggleLink());
0204: startEnclosingTableAndRowAndCell(alignCenter(null), cps
0205: .getToggleLink());
0206: startAndEndStretchTableAndRowAndCell("<hr/>");
0207: //
0208: startAndEndSimpleTableAndRowAndCell(2, "JFolder Console",
0209: getFontStyle(20, ARIAL, BLACK));
0210: //
0211: //startAndEndStretchTableAndRowAndCell("<hr/>");
0212: //SubmitActionContext testSac = SubmitActionContext.newInstance(this);
0213: //testSac.addAction(
0214: // testSac.FIRST_INPUT,
0215: // singleQuotes(SubmitActionParameters.DO_NOTHING));
0216: //CreationParameterContext testCpc =
0217: // CreationParameterContext.newInstance(
0218: // "Test Top Label", testSac, false);
0219: //testCpc.addInputAsButton(
0220: // testCpc.FIRST_INPUT, "ButtonLabel1", "alert('HiGary')");
0221: //testCpc.addInputAsTextBox(
0222: // testCpc.SECOND_INPUT, "Gary201", "Gary202");
0223: //testCpc.addInputAsExclusive(
0224: // testCpc.THIRD_INPUT, "Gary301",
0225: // new String[]{"A"}, new String[]{"a"});
0226: //testCpc.addInputAsInclusive(
0227: // testCpc.FOURTH_INPUT, "Gary401",
0228: // new String[]{"B"}, new String[]{"b"}, "Gary402");
0229: //testCpc.addInputAsHiddenBox(
0230: // testCpc.FIFTH_INPUT, "GaryHidden501");
0231: //testCpc.addInputAsFileUpload(
0232: // testCpc.SIXTH_INPUT, "GaryFile601");
0233: //startTable(4, alignCenter(null));
0234: //startRow();
0235: //startCell(4, alignCenter(null));
0236: //createButton("{-REMOVE-}", "Remove Text", null,
0237: // testCpc.createParameterCall(), null, null, null, null);
0238: //endCell();
0239: //endRow();
0240: //endTable();
0241: //startAndEndStretchTableAndRowAndCell("<hr/>");
0242: //
0243: //
0244: //CreationResultParameterContext crpc =
0245: // inSac.getCreationResultParameterContext();
0246:
0247: //
0248: SubMessageHolderConsolePageContext
0249: .renderMessagesIfPresent(this );
0250:
0251: if (administrator) {
0252:
0253: getConsolePageSession().pushToggleLink(ADMINISTER);
0254:
0255: startAndEndStretchTableAndRowAndCell("<hr/>");
0256:
0257: startAndEndSimpleTableAndRowAndCell(1,
0258: getAutoTogglingLinkWithTargetId(TOG_CALL__ADMIN,
0259: "Administer"),
0260: getFontStyle(18, ARIAL, BLUE));
0261:
0262: //try {
0263: startAutoTogglingTableAndRowAndCell();
0264: //}
0265: //catch (IOException ioe) {
0266: // ioe.printStackTrace();
0267: // throw ioe;
0268: //}
0269: //catch (RuntimeException re) {
0270: // re.printStackTrace();
0271: // throw re;
0272: //}
0273: //catch (Error e) {
0274: // e.printStackTrace();
0275: // throw e;
0276: //}
0277:
0278: int topLeftMargin = getLeftMargin();
0279: setLeftMargin(topLeftMargin + 1);
0280: subAdmin(cps);
0281: setLeftMargin(topLeftMargin);
0282:
0283: endEnclosingTableAndRowAndCell();
0284:
0285: getConsolePageSession().popToggleLink();
0286: }
0287:
0288: if (developer) {
0289:
0290: getConsolePageSession().pushToggleLink(DEVELOP);
0291:
0292: startAndEndStretchTableAndRowAndCell("<hr/>");
0293:
0294: startAndEndSimpleTableAndRowAndCell(1,
0295: getAutoTogglingLinkWithTargetId(TOG_CALL__DEVEL,
0296: "Develop"), getFontStyle(18, ARIAL, BLUE));
0297:
0298: startAutoTogglingTableAndRowAndCell();
0299:
0300: int topLeftMargin = getLeftMargin();
0301: setLeftMargin(topLeftMargin + 1);
0302: subDevelop(cps);
0303: setLeftMargin(topLeftMargin);
0304:
0305: endEnclosingTableAndRowAndCell();
0306:
0307: getConsolePageSession().popToggleLink();
0308: }
0309:
0310: startAndEndStretchTableAndRowAndCell("<hr/>");
0311: //
0312: endEnclosingTableAndRowAndCell();
0313:
0314: endCommonPage();
0315: }
0316:
0317: private void subAdmin(ConsolePageSession inCps) throws IOException {
0318:
0319: //
0320: startAndEndStretchTableAndRowAndCell("<hr/>");
0321:
0322: getConsolePageSession().pushToggleLink(APPLICATIONS);
0323: startAndEndSimpleTableAndRowAndCell(2,
0324: getAutoTogglingLinkWithTargetId(TOG_CALL__ADMIN_APPS,
0325: "Applications"), getFontStyle(18, ARIAL, BLUE));
0326:
0327: subAdminApps(inCps);
0328: getConsolePageSession().popToggleLink();
0329:
0330: //
0331: startAndEndStretchTableAndRowAndCell("<hr/>");
0332: //
0333: getConsolePageSession().pushToggleLink(MONITOR);
0334: startAndEndSimpleTableAndRowAndCell(1,
0335: getAutoTogglingLinkWithTargetId(TOG_CALL__ADMIN_OTHER,
0336: "Other"), getFontStyle(18, ARIAL, BLUE));
0337:
0338: int topSecondLeftMargin = getLeftMargin();
0339: setLeftMargin(topSecondLeftMargin + 1);
0340: subAdminMonitor(inCps);
0341: setLeftMargin(topSecondLeftMargin);
0342: getConsolePageSession().popToggleLink();
0343: }
0344:
0345: //private void subAdminDatabase(
0346: // ConsolePageSession inCps) throws IOException {
0347: //}
0348: //private void subAdminMacro(ConsolePageSession inCps) throws IOException {
0349: //}
0350: private void subAdminMonitor(ConsolePageSession inCps)
0351: throws IOException {
0352:
0353: startAutoTogglingTableAndRowAndCell();
0354:
0355: startAndEndStretchTableAndRowAndCell("<hr/>");
0356:
0357: //
0358: startTable(1);
0359: startRow();
0360: startCell(1, alignCenter(null));
0361: //
0362: SubmitActionContext sacDatabaseAccess = SubmitActionContext
0363: .newInstance(this );
0364: sacDatabaseAccess.addAction(
0365: ConsoleParameterContext.FIRST_INPUT,
0366: singleQuotes(SubmitActionParameters.OPEN));
0367: sacDatabaseAccess
0368: .setGoToPage(ConsolePageParameters.SERVLET_DATABASE_ACCESS);
0369: //createButton("Query", 150, sacQuery.submitActionCall(),
0370: // null, null, null, null);
0371: createButton(BUTTON__DB_ACCESS, "Database Access", 150,
0372: submitActionCall(sacDatabaseAccess), null, null, null,
0373: null);
0374: //
0375: endCell();
0376: endRow();
0377: endTable();
0378: //
0379:
0380: //startAndEndStretchTableAndRowAndCell("<hr/>");
0381: //
0382: ////
0383: //startTable(1);
0384: //startRow();
0385: //startCell(1, alignCenter(null));
0386: ////
0387: //SubmitActionContext sacQuery = SubmitActionContext.newInstance(this);
0388: //sacQuery.addAction(
0389: // sacQuery.FIRST_INPUT,
0390: // singleQuotes(SubmitActionParameters.OPEN));
0391: ////createButton("Query", 150, sacQuery.submitActionCall(),
0392: //// null, null, null, null);
0393: //createButton(BUTTON__QUERY, "Query", 150,
0394: // "alert('Not Implemented')", null, null, null, null);
0395: ////
0396: //endCell();
0397: //endRow();
0398: //endTable();
0399: ////
0400:
0401: //startAndEndStretchTableAndRowAndCell("<hr/>");
0402: //
0403: ////
0404: //startTable(1);
0405: //startRow();
0406: //startCell(1, alignCenter(null));
0407: ////
0408: //SubmitActionContext sacImportExport =
0409: // SubmitActionContext.newInstance(this);
0410: //sacImportExport.addAction(
0411: // sacImportExport.FIRST_INPUT,
0412: // singleQuotes(SubmitActionParameters.OPEN));
0413: //sacImportExport.setGoToPage(
0414: // ConsolePageParameters.SERVLET_IMPORT_EXPORT);
0415: ////createButton("Import/Export", 150,
0416: //// sacImportExport.submitActionCall(),
0417: //// null, null, null, null);
0418: //createButton(BUTTON__IMP_EXP, "Import/Export", 150,
0419: // sacImportExport.submitActionCall(),
0420: // null, null, null, null);
0421: ////
0422: //endCell();
0423: //endRow();
0424: //endTable();
0425: ////
0426:
0427: //startAndEndStretchTableAndRowAndCell("<hr/>");
0428: //
0429: ////
0430: //startTable(1);
0431: //startRow();
0432: //startCell(1, alignCenter(null));
0433: ////
0434: //SubmitActionContext sacDocumentSystem =
0435: // SubmitActionContext.newInstance(this);
0436: //sacDocumentSystem.addAction(
0437: // sacDocumentSystem.FIRST_INPUT,
0438: // singleQuotes(SubmitActionParameters.OPEN));
0439: //sacDocumentSystem.setGoToPage(
0440: // ConsolePageParameters.SERVLET_DOCUMENT_SYSTEM);
0441: //createButton(BUTTON__DOC_SYS, "Document System", 150,
0442: // sacDocumentSystem.submitActionCall(),
0443: // null, null, null, null);
0444: ////
0445: //endCell();
0446: //endRow();
0447: //endTable();
0448: ////
0449:
0450: startAndEndStretchTableAndRowAndCell("<hr/>");
0451:
0452: //
0453: startTable(1);
0454: startRow();
0455: startCell(1, alignCenter(null));
0456: //
0457: SubmitActionContext sacMacroExecute = SubmitActionContext
0458: .newInstance(this );
0459: sacMacroExecute.addAction(ConsoleParameterContext.FIRST_INPUT,
0460: singleQuotes(SubmitActionParameters.OPEN));
0461: sacMacroExecute
0462: .setGoToPage(ConsolePageParameters.SERVLET_MACRO_EXECUTE);
0463: createButton(BUTTON__MAC_EXE, "Macro Execute", 150,
0464: submitActionCall(sacMacroExecute), null, null, null,
0465: null);
0466: //
0467: endCell();
0468: endRow();
0469: endTable();
0470:
0471: //startAndEndStretchTableAndRowAndCell("<hr/>");
0472: //
0473: ////
0474: //startTable(1);
0475: //startRow();
0476: //startCell(1, alignCenter(null));
0477: ////
0478: //SubmitActionContext sacMacroStudio =
0479: // SubmitActionContext.newInstance(this);
0480: //sacMacroStudio.addAction(
0481: // ConsoleParameterContext.FIRST_INPUT,
0482: // singleQuotes(SubmitActionParameters.OPEN));
0483: //sacMacroStudio.setGoToPage(
0484: // ConsolePageParameters.SERVLET_MACRO_STUDIO);
0485: //createButton(BUTTON__MAC_STU, "Macro Studio", 150,
0486: // submitActionCall(sacMacroStudio),
0487: // null, null, null, null);
0488: ////
0489: //endCell();
0490: //endRow();
0491: //endTable();
0492:
0493: //startAndEndStretchTableAndRowAndCell("<hr/>");
0494: //
0495: ////
0496: //startTable(1);
0497: //startRow();
0498: //startCell(1, alignCenter(null));
0499: ////
0500: //SubmitActionContext sacConfigStudio =
0501: // SubmitActionContext.newInstance(this);
0502: //sacConfigStudio.addAction(
0503: // ConsoleParameterContext.FIRST_INPUT,
0504: // singleQuotes(SubmitActionParameters.OPEN));
0505: //sacConfigStudio.setGoToPage(
0506: // ConsolePageParameters.SERVLET_CONFIG_STUDIO);
0507: //createButton(BUTTON__CON_STU, "Config Studio", 150,
0508: // submitActionCall(sacConfigStudio),
0509: // null, null, null, null);
0510: ////
0511: //endCell();
0512: //endRow();
0513: //endTable();
0514:
0515: //startAndEndStretchTableAndRowAndCell("<hr/>");
0516: //
0517: ////
0518: //startTable(1);
0519: //startRow();
0520: //startCell(1, alignCenter(null));
0521: ////
0522: //SubmitActionContext sacAuditQuery =
0523: // SubmitActionContext.newInstance(this);
0524: //sacAuditQuery.addAction(
0525: // ConsoleParameterContext.FIRST_INPUT,
0526: // singleQuotes(SubmitActionParameters.OPEN));
0527: //sacAuditQuery.setGoToPage(
0528: // ConsolePageParameters.SERVLET_AUDIT_QUERY);
0529: //createButton(BUTTON__AUD_QUE, "Audit Query", 150,
0530: // submitActionCall(sacAuditQuery), null, null, null, null);
0531: ////
0532: //endCell();
0533: //endRow();
0534: //endTable();
0535:
0536: //startAndEndStretchTableAndRowAndCell("<hr/>");
0537: //
0538: ////
0539: //startTable(1);
0540: //startRow();
0541: //startCell(1, alignCenter(null));
0542: ////
0543: //SubmitActionContext sacAuditCreate =
0544: // SubmitActionContext.newInstance(this);
0545: //sacAuditCreate.addAction(
0546: // ConsoleParameterContext.FIRST_INPUT,
0547: // singleQuotes(SubmitActionParameters.OPEN));
0548: //sacAuditCreate.setGoToPage(
0549: // ConsolePageParameters.SERVLET_AUDIT_CREATE);
0550: //createButton(BUTTON__AUD_CRE, "Audit Create", 150,
0551: // submitActionCall(sacAuditCreate), null, null, null, null);
0552: ////
0553: //endCell();
0554: //endRow();
0555: //endTable();
0556:
0557: startAndEndStretchTableAndRowAndCell("<hr/>");
0558:
0559: //
0560: startTable(1);
0561: startRow();
0562: startCell(1, alignCenter(null));
0563: //
0564: SubmitActionContext sacResetConfig = SubmitActionContext
0565: .newInstance(this );
0566: sacResetConfig.addAction(ConsoleParameterContext.FIRST_INPUT,
0567: singleQuotes(SubmitActionParameters.RESET_CONFIG));
0568: createButton(BUTTON__AUD_CRE, "Reset Config", 150,
0569: submitActionCall(sacResetConfig), null, null, null,
0570: null);
0571: //
0572: endCell();
0573: endRow();
0574: endTable();
0575:
0576: startAndEndStretchTableAndRowAndCell("<hr/>");
0577:
0578: //
0579: startTable(1);
0580: startRow();
0581: startCell(1, alignCenter(null));
0582: //
0583: SubmitActionContext sacAutoApplicationGenerator = SubmitActionContext
0584: .newInstance(this );
0585: sacAutoApplicationGenerator.addAction(
0586: ConsoleParameterContext.FIRST_INPUT,
0587: singleQuotes(SubmitActionParameters.OPEN));
0588: sacAutoApplicationGenerator
0589: .setGoToPage(ConsolePageParameters.SERVLET_AUTO_APPLICATION_GENERATOR);
0590: createButton(BUTTON__AUT_APP, "App Generator", 150,
0591: submitActionCall(sacAutoApplicationGenerator), null,
0592: null, null, null);
0593: //
0594: endCell();
0595: endRow();
0596: endTable();
0597:
0598: //////////////////////////////////////////////
0599: //if (inCs.isInactiveMacroState() || inCs.isRecordingMacroState()) {
0600: // startAndEndStretchTableAndRowAndCell("<hr/>");
0601: // //
0602: // startTable(1);
0603: // startRow();
0604: // startCell(1, alignCenter(null));
0605: // //
0606: // if (inCs.isInactiveMacroState()) {
0607: // SubmitActionContext sacStartRecording =
0608: // SubmitActionContext.newInstance(this);
0609: // sacStartRecording.addAction(
0610: // sacStartRecording.FIRST_INPUT,
0611: // singleQuotes(SubmitActionParameters.START_RECORDING));
0612: // createButton(BUTTON__START_REC, "Start Recording", 150,
0613: // sacStartRecording.submitActionCall(),
0614: // null, null, null, null);
0615: // }
0616: // else if (inCs.isRecordingMacroState()) {
0617: // SubmitActionContext sacStopRecording =
0618: // SubmitActionContext.newInstance(this);
0619: // sacStopRecording.addAction(
0620: // sacStopRecording.FIRST_INPUT,
0621: // singleQuotes(SubmitActionParameters.STOP_RECORDING));
0622: // createButton(BUTTON__STOP_REC, "Stop Recording", 150,
0623: // sacStopRecording.submitActionCall(),
0624: // null, null, null, null);
0625: // }
0626: // else {
0627: // throw UnexpectedSystemException.unknownState();
0628: // }
0629: // //
0630: // endCell();
0631: // endRow();
0632: // endTable();
0633: //}
0634:
0635: //if (inCs.isInactiveMacroState()) {
0636: // //
0637: // //
0638: // //
0639: // String fileUpload = createFileUpload(
0640: // INPUT_REP_MAC_UPL, new Integer(5));
0641: // String fileUploadId = inCs.getPreviousToggleLink();
0642: // //
0643: // startAndEndStretchTableAndRowAndCell("<hr/>");
0644: // //
0645: //
0646: //
0647: // startTable(2);
0648: // startRow();
0649: // startCell(1, alignCenter(null));
0650: // //
0651: // SubmitActionContext sacStartReplaying =
0652: // SubmitActionContext.newInstance(this);
0653: // sacStartReplaying.addAction(
0654: // sacStartReplaying.FIRST_INPUT,
0655: // singleQuotes(SubmitActionParameters.START_REPLAYING));
0656: // sacStartReplaying.addParameter(
0657: // sacStartReplaying.FIRST_INPUT,
0658: // singleQuotes(fileUploadId));
0659: // createButton(BUTTON__START_REP, "Start Replaying", 150,
0660: // sacStartReplaying.submitActionCall(), null, null, null, null);
0661: // //
0662: // endCell();
0663: // startCell(1);
0664: // //
0665: // simpleAndPrint(fileUpload);
0666: // //
0667: // endCell();
0668: // endRow();
0669: // endTable();
0670: //}
0671:
0672: //
0673: //if (getDeployedScripts().length > 0) {
0674: //
0675: // startAndEndStretchTableAndRowAndCell("<hr/>");
0676: //
0677: // //
0678: // startTable(1);
0679: // startRow();
0680: // startCell(1, alignCenter(null));
0681: // //
0682: // SubmitActionContext sacManualTrigger =
0683: // SubmitActionContext.newInstance(this);
0684: // sacManualTrigger.addAction(
0685: // sacManualTrigger.FIRST_INPUT,
0686: // singleQuotes(SubmitActionParameters.OPEN));
0687: // sacManualTrigger.setGoToPage(
0688: // ConsolePageParameters.SERVLET_MANUAL_TRIGGER);
0689: // createButton(BUTTON__MAN_TRIG, "Manual Trigger", 150,
0690: // sacManualTrigger.submitActionCall(), null, null, null, null);
0691: // //createButton("Manual Trigger", 150,
0692: // // "alert('Not Implemented')", null, null, null, null);
0693: // //
0694: // endCell();
0695: // endRow();
0696: // endTable();
0697: // //
0698: //}
0699:
0700: endEnclosingTableAndRowAndCell();
0701: }
0702:
0703: private void subAdminApps(ConsolePageSession inCps)
0704: throws IOException {
0705:
0706: startAutoTogglingTableAndRowAndCell();
0707: inCps.pushToggleLinkDontRecordThisBranch();
0708: //
0709: HashMap deployedProjects = new HashMap();
0710: HashMap availableProjects = new HashMap();
0711: //
0712: for (int i = 0; i < inCps.getServerProjectSystemCount(); i++) {
0713: ProjectSystem nextPs = inCps.getServerProjectSystem(i);
0714: if (nextPs.isDeployVisible()) {
0715: deployedProjects.put(nextPs.getName().toUpperCase(),
0716: nextPs);
0717: } else {
0718: availableProjects.put(nextPs.getName().toUpperCase(),
0719: nextPs);
0720: }
0721: }
0722: //
0723: startAndEndSimpleTableAndRowAndCell(3, createHorizontalRow(3,
0724: null));
0725: ArrayList deployedList = new ArrayList(deployedProjects
0726: .keySet());
0727: Collections.sort(deployedList);
0728: //
0729: //
0730: inCps.pushToggleLink(DEPLOYED_SERVER_APPLICATIONS);
0731: //
0732: //
0733: for (int i = 0; i < deployedList.size(); i++) {
0734: ProjectSystem nextPs = (ProjectSystem) deployedProjects
0735: .get(deployedList.get(i));
0736: //
0737: //
0738: //
0739: inCps.pushToggleLink(nextPs.getName());
0740: //
0741: //
0742: SubmitActionContext sacMarkUndeployable = SubmitActionContext
0743: .newInstance(this );
0744: //
0745: sacMarkUndeployable.addAction(
0746: ConsoleParameterContext.FIRST_INPUT,
0747: singleQuotes(SubmitActionParameters.MARK));
0748: sacMarkUndeployable.addAction(
0749: ConsoleParameterContext.SECOND_INPUT,
0750: singleQuotes(SubmitActionParameters.APPLICATION));
0751: sacMarkUndeployable
0752: .addAction(
0753: ConsoleParameterContext.THIRD_INPUT,
0754: singleQuotes(SubmitActionParameters.DEPLOY_NOT_VISIBLE));
0755: //
0756: sacMarkUndeployable.addParameter(
0757: ConsoleParameterContext.FIRST_INPUT,
0758: singleQuotes(SubmitActionParameters.SERVER));
0759: sacMarkUndeployable.addParameter(
0760: ConsoleParameterContext.SECOND_INPUT,
0761: singleQuotes(nextPs.getName()));
0762: //
0763: String lightbulbOnImage = createStaticImage(
0764: IMAGE__DEPLOYED_APPLICATION,
0765: ConsoleTemplateParameters.GIF_PANE_LIGHTBULB_ON,
0766: null, null);
0767: //
0768: //
0769: //
0770: SubmitActionContext sacDelete = SubmitActionContext
0771: .newInstance(this );
0772: //
0773: sacDelete.addAction(ConsoleParameterContext.FIRST_INPUT,
0774: singleQuotes(SubmitActionParameters.DELETE));
0775: sacDelete.addAction(ConsoleParameterContext.SECOND_INPUT,
0776: singleQuotes(SubmitActionParameters.APPLICATION));
0777: //
0778: sacDelete.addParameter(ConsoleParameterContext.FIRST_INPUT,
0779: singleQuotes(SubmitActionParameters.SERVER));
0780: sacDelete.addParameter(
0781: ConsoleParameterContext.SECOND_INPUT,
0782: singleQuotes(nextPs.getName()));
0783: //
0784: sacDelete
0785: .setConfirm("'Are you sure you want to delete this application?'");
0786: //
0787: //
0788: PageSetupContext localPsc = inCps.getPageSetupContext();
0789: //
0790: CreationParameterContext deployedServerAppCpc = CreationParameterContext
0791: .newInstance(nextPs.getName(), SubmitActionContext
0792: .newInstance(this ), false, true);
0793: localPsc.registerCreationParameter(inCps,
0794: deployedServerAppCpc,
0795: CRE_PARAM_CALL__DEPLOYED_APP_OPTIONS);
0796: //
0797: deployedServerAppCpc.addInputAsButton(
0798: ConsoleParameterContext.FIRST_INPUT, "Undeploy",
0799: submitActionCall(sacMarkUndeployable));
0800: //
0801: deployedServerAppCpc.addInputAsButton(
0802: ConsoleParameterContext.SECOND_INPUT, "Delete",
0803: submitActionCall(sacDelete));
0804: //
0805: //
0806: startTable(3);
0807: startRow();
0808: if (i > 0) {
0809: startAndEndCell(1, padNbsp(1), getFontStyle(11, ARIAL,
0810: BLACK));
0811: } else {
0812: startAndEndCell(1, padNbsp(2) + "Deployed Apps",
0813: getFontStyle(11, ARIAL, BLACK));
0814: }
0815: startAndEndCell(1, lightbulbOnImage + padNbsp(1)
0816: + nextPs.getName(), getFontStyle(11, ARIAL, BLACK));
0817: startCell(1, alignCenter(null));
0818: createButton(BUTTON__DEPLOYED_SERVER_APPLICATION_OPTIONS,
0819: "Options", 100, deployedServerAppCpc
0820: .createParameterCall(), null, null, null,
0821: null);
0822: endCell();
0823: endRow();
0824: endTable();
0825: //
0826: //
0827: inCps.popToggleLink();
0828: //
0829: //
0830: //
0831: }
0832: if (deployedList.size() == 0) {
0833: startTable(3);
0834: startRow();
0835: startAndEndCell(1, padNbsp(2) + "Deployed Apps",
0836: getFontStyle(11, ARIAL, BLACK));
0837: startAndEndCell(2, "(There are no deployed applications)");
0838: endRow();
0839: endTable();
0840: }
0841: //
0842: //
0843: inCps.popToggleLink();
0844: //
0845: //
0846: //
0847: //
0848: //
0849: inCps.pushToggleLink(UNDEPLOYED_SERVER_APPLICATIONS);
0850: //
0851: //
0852: startAndEndSimpleTableAndRowAndCell(3, createHorizontalRow(3,
0853: new Integer(10)), alignRight(null));
0854: //createHorizontalRow(1);
0855: //
0856: ArrayList availableList = new ArrayList(availableProjects
0857: .keySet());
0858: Collections.sort(availableList);
0859: for (int i = 0; i < availableList.size(); i++) {
0860: ProjectSystem nextPs = (ProjectSystem) availableProjects
0861: .get(availableList.get(i));
0862: //
0863: //
0864: inCps.pushToggleLink(nextPs.getName());
0865: //
0866: //
0867: //
0868: SubmitActionContext sacMarkDeployable = SubmitActionContext
0869: .newInstance(this );
0870: //
0871: sacMarkDeployable.addAction(
0872: ConsoleParameterContext.FIRST_INPUT,
0873: singleQuotes(SubmitActionParameters.MARK));
0874: sacMarkDeployable.addAction(
0875: ConsoleParameterContext.SECOND_INPUT,
0876: singleQuotes(SubmitActionParameters.APPLICATION));
0877: sacMarkDeployable
0878: .addAction(
0879: ConsoleParameterContext.THIRD_INPUT,
0880: singleQuotes(SubmitActionParameters.DEPLOY_VISIBLE));
0881: //
0882: sacMarkDeployable.addParameter(
0883: ConsoleParameterContext.FIRST_INPUT,
0884: singleQuotes(SubmitActionParameters.SERVER));
0885: sacMarkDeployable.addParameter(
0886: ConsoleParameterContext.SECOND_INPUT,
0887: singleQuotes(nextPs.getName()));
0888: //
0889: //
0890: SubmitActionContext sacDelete = SubmitActionContext
0891: .newInstance(this );
0892: //
0893: sacDelete.addAction(ConsoleParameterContext.FIRST_INPUT,
0894: singleQuotes(SubmitActionParameters.DELETE));
0895: sacDelete.addAction(ConsoleParameterContext.SECOND_INPUT,
0896: singleQuotes(SubmitActionParameters.APPLICATION));
0897: //
0898: sacDelete.addParameter(ConsoleParameterContext.FIRST_INPUT,
0899: singleQuotes(SubmitActionParameters.SERVER));
0900: sacDelete.addParameter(
0901: ConsoleParameterContext.SECOND_INPUT,
0902: singleQuotes(nextPs.getName()));
0903: //
0904: sacDelete
0905: .setConfirm("'Are you sure you want to delete this application?'");
0906: //
0907: String lightbulbOffImage = createStaticImage(
0908: IMAGE__DEPLOYED_APPLICATION,
0909: ConsoleTemplateParameters.GIF_PANE_LIGHTBULB_OFF,
0910: null, null);
0911: //
0912: //
0913: //
0914: PageSetupContext localPsc = inCps.getPageSetupContext();
0915:
0916: //
0917: CreationParameterContext undeployedServerAppCpc = CreationParameterContext
0918: .newInstance(nextPs.getName(), SubmitActionContext
0919: .newInstance(this ), false, true);
0920: localPsc.registerCreationParameter(inCps,
0921: undeployedServerAppCpc,
0922: CRE_PARAM_CALL__UNDEP_APP_OPTIONS);
0923: //
0924: undeployedServerAppCpc.addInputAsButton(
0925: ConsoleParameterContext.FIRST_INPUT, "Deploy",
0926: submitActionCall(sacMarkDeployable));
0927: //
0928: undeployedServerAppCpc.addInputAsButton(
0929: ConsoleParameterContext.SECOND_INPUT, "Delete",
0930: submitActionCall(sacDelete));
0931: //
0932: startTable(3);
0933: startRow();
0934: if (i > 0) {
0935: startAndEndCell(1, padNbsp(1));
0936: } else {
0937: startAndEndCell(1, padNbsp(2) + "Undeployed Apps",
0938: getFontStyle(11, ARIAL, BLACK));
0939: }
0940: startAndEndCell(1, lightbulbOffImage + padNbsp(1)
0941: + nextPs.getName());
0942: startCell(1, alignCenter(null));
0943: createButton(BUTTON__SER_MARK_DEP, "Options", 100,
0944: undeployedServerAppCpc.createParameterCall(), null,
0945: null, null, null);
0946: endCell();
0947: endRow();
0948: endTable();
0949: //
0950: //
0951: //
0952: inCps.popToggleLink();
0953: //
0954: //
0955: }
0956: if (availableList.size() == 0) {
0957: startTable(3);
0958: startRow();
0959: startAndEndCell(1, padNbsp(2) + "Undeployed Apps",
0960: getFontStyle(11, ARIAL, BLACK));
0961: startAndEndCell(2, "(There are no available applications)");
0962: endRow();
0963: endTable();
0964: }
0965: //
0966: //
0967: inCps.popToggleLink();
0968: //
0969: //
0970: //
0971: //
0972: //
0973: //
0974: //
0975: //inCs.pushToggleLink(INPUT_PROJECT_DEPLOY_DIR);
0976: //String inputProjectDeployDirId = inCs.getToggleLink();
0977: //inCs.popToggleLink();
0978: //String inputProjectDeployDirTextBox = createTextBox(
0979: // INPUT_PROJECT_DEPLOY_DIR, "Directory", null, null,
0980: // new Integer(30), null, null);
0981: //String inputProjectDeployDirId = inCs.getPreviousToggleLink();
0982: //
0983: //
0984: //
0985: //inCs.pushToggleLink(INPUT_PROJECT_USER_SOURCE);
0986: //String inputProjectUserSourceId = inCs.getToggleLink();
0987: //inCs.popToggleLink();
0988: //String inputProjectUserSourceTextBox = createTextBox(
0989: // INPUT_PROJECT_USER_SOURCE, "User", null, null, null, null, null);
0990: //String inputProjectUserSourceId = inCs.getPreviousToggleLink();
0991: //
0992: //
0993: //
0994: //
0995: //
0996: //inCs.pushToggleLink(INPUT_PROJECT_NAME_SOURCE);
0997: //String inputProjectNameSourceId = inCs.getToggleLink();
0998: //inCs.popToggleLink();
0999: //String inputProjectNameSourceTextBox = createTextBox(
1000: // INPUT_PROJECT_NAME_SOURCE, "Name", null, null, null, null, null);
1001: //String inputProjectNameSourceId = inCs.getPreviousToggleLink();
1002: //
1003: //
1004: //
1005: //
1006: //
1007: //inCs.pushToggleLink(INPUT_PROJECT_DEPLOY_VISIBLE);
1008: //String inputProjectDeployVisibleId = inCs.getToggleLink();
1009: //inCs.popToggleLink();
1010: //
1011: //String inputProjectDeployVisibleDropDownBox = createDropDownBox(
1012: // INPUT_PROJECT_DEPLOY_VISIBLE, inputProjectDeployVisibleLabels,
1013: // inputProjectDeployVisibleValues, null, null, 1, null, null, null);
1014: //String inputProjectDeployVisibleId = inCs.getPreviousToggleLink();
1015: //
1016: //
1017: //
1018: //
1019: //
1020: //
1021: //
1022: //
1023: //createHorizontalRow(1);
1024: startAndEndSimpleTableAndRowAndCell(3, createHorizontalRow(3,
1025: new Integer(10)), alignRight(null));
1026: //
1027: //startAndEndSimpleTableAndRowAndCell(3, createHorizontalRow(3, null));
1028: HashMap deployableProjects = inCps.getDeployableProjects();
1029: HashMap deployableUiMap = new HashMap();
1030: ArrayList deployableList = new ArrayList();
1031: Iterator deployableProjectsIter = deployableProjects.keySet()
1032: .iterator();
1033: while (deployableProjectsIter.hasNext()) {
1034: UserIdentity nextUi = (UserIdentity) deployableProjectsIter
1035: .next();
1036: deployableUiMap.put(nextUi.getName().toUpperCase(), nextUi);
1037: if (!deployableList
1038: .contains(nextUi.getName().toUpperCase())) {
1039: deployableList.add(nextUi.getName().toUpperCase());
1040: }
1041: }
1042: Collections.sort(deployableList);
1043: for (int i = 0; i < deployableList.size(); i++) {
1044: //
1045: UserIdentity nextUi = (UserIdentity) deployableUiMap
1046: .get(deployableList.get(i));
1047: //
1048: //
1049: inCps.pushToggleLink(convertUserNameToToggleLinkPart(nextUi
1050: .getName()));
1051: //
1052: //
1053: //
1054: HashMap projectNameAttrs = new HashMap();
1055: projectNameAttrs.put("style", "text-decoration: underline");
1056: //
1057: //
1058: startTable(3);
1059: startRow();
1060: if (i > 0) {
1061: startAndEndCell(1, padNbsp(1));
1062: } else {
1063: startAndEndCell(1, padNbsp(2) + "Available Apps",
1064: getFontStyle(11, ARIAL, BLACK));
1065: }
1066: startAndEndCell(2, formatText(nextUi.getName(),
1067: projectNameAttrs), getFontStyle(11, ARIAL, BLACK));
1068: endRow();
1069: endTable();
1070: //
1071: ArrayList nextPsList = (ArrayList) deployableProjects
1072: .get(nextUi);
1073: HashMap nextPsMap = new HashMap();
1074: for (int j = 0; j < nextPsList.size(); j++) {
1075: ProjectSystem nextPs = (ProjectSystem) nextPsList
1076: .get(j);
1077: nextPsMap.put(nextPs.getName().toUpperCase(), nextPs);
1078: }
1079: ArrayList nextPsNamesList = new ArrayList(nextPsMap
1080: .keySet());
1081: Collections.sort(nextPsNamesList);
1082: for (int j = 0; j < nextPsNamesList.size(); j++) {
1083: //
1084: //
1085: //
1086: ProjectSystem nextPs = (ProjectSystem) nextPsMap
1087: .get(nextPsNamesList.get(j));
1088: //
1089: //
1090: inCps
1091: .pushToggleLink(convertUserNameToToggleLinkPart(nextPs
1092: .getName()));
1093: //
1094: //
1095: //
1096: //String nextLabel = "<a onclick=\""
1097: // + getPageComponentValue(inputProjectUserSourceId)
1098: // + " = '" + nextUi.getName() + "'; "
1099: // + getPageComponentValue(inputProjectNameSourceId)
1100: // + " = '" + nextPs.getName() + "'; "
1101: // + getPageComponentValue(inputProjectDeployDirId)
1102: // + " = '" + nextPs.getName() + "';"
1103: // + "\">" + nextPs.getName() + "</a>";
1104: //
1105: //
1106: //
1107: String projectName = nextPs.getName();
1108: projectName = MiscHelper.shortenString(projectName, 20);
1109: projectName = XMLHelper.fromStringToCData(projectName);
1110: //
1111: //
1112: //SubmitActionContext sacCopyToServer =
1113: // SubmitActionContext.newInstance(this);
1114: //
1115: //sacCopyToServer.addAction(
1116: // sacCopyToServer.FIRST_INPUT,
1117: // singleQuotes(SubmitActionParameters.COPY_TO_SERVER));
1118: //
1119: CreationParameterContext availableServerAppCpc = createDeploymentBox(
1120: nextPs, nextUi);
1121:
1122: //
1123: // CreationParameterContext.newInstance(
1124: // nextPs.getName(), sacCopyToServer, true, false);
1125: //
1126: //availableServerAppCpc.addInputAsHiddenBox(
1127: // availableServerAppCpc.FIRST_INPUT, nextUi.getName());
1128: //availableServerAppCpc.addInputAsHiddenBox(
1129: // availableServerAppCpc.SECOND_INPUT, nextPs.getName());
1130: //availableServerAppCpc.addInputAsTextBox(
1131: // availableServerAppCpc.THIRD_INPUT,
1132: // "Deployed Name", nextPs.getName());
1133: //
1134: //
1135: //
1136: //
1137: //ArrayList inputProjectDeployVisibleLabels = new ArrayList();
1138: //inputProjectDeployVisibleLabels.add("Deploy Immediately");
1139: //inputProjectDeployVisibleLabels.add("Delay Deployment");
1140: //
1141: //String deployLabels[] =
1142: // new String[]{"Deploy Immediately", "Delay Deployment"};
1143: //String deployValues[] =
1144: // new String[]{SubmitActionParameters.DEPLOY_VISIBLE,
1145: // SubmitActionParameters.DEPLOY_NOT_VISIBLE};
1146: //
1147: //ArrayList inputProjectDeployVisibleValues = new ArrayList();
1148: //inputProjectDeployVisibleValues.add(
1149: // SubmitActionParameters.DEPLOY_VISIBLE);
1150: //inputProjectDeployVisibleValues.add(
1151: // SubmitActionParameters.DEPLOY_NOT_VISIBLE);
1152: //
1153: //availableServerAppCpc.addInputAsExclusive(
1154: // availableServerAppCpc.FOURTH_INPUT,
1155: // "Deployed Status", deployValues, deployLabels);
1156: //
1157: //
1158: startTable(3);
1159: startRow();
1160: startAndEndCell(1, padNbsp(1));
1161: startAndEndCell(1, padNbsp(2) + projectName,
1162: getFontStyle(10, ARIAL, BLACK));
1163: //createButton
1164: //startAndEndCell(1, nextLabel);
1165: //
1166: //
1167: startCell(1, alignCenter(null));
1168: createButton(AVAILABLE_SERVER_APPLICATIONS, "Options",
1169: 100, availableServerAppCpc
1170: .createParameterCall(), null, null,
1171: null, null);
1172: endCell();
1173: endRow();
1174: endTable();
1175: //
1176: //
1177: //
1178: inCps.popToggleLink();
1179: //
1180: //
1181: }
1182: //
1183: //
1184: //
1185: //
1186: //
1187: inCps.popToggleLink();
1188: //
1189: //
1190: }
1191: if (deployableList.size() == 0) {
1192: startTable(3);
1193: startRow();
1194: startAndEndCell(1, padNbsp(2) + "Available Apps",
1195: getFontStyle(11, ARIAL, BLACK));
1196: startAndEndCell(2,
1197: "(There are no deployable user applications)");
1198: endRow();
1199: endTable();
1200: }
1201: //
1202: //
1203: inCps.popToggleLink();
1204: endEnclosingTableAndRowAndCell();
1205: }
1206:
1207: private final static String convertUserNameToToggleLinkPart(
1208: String inUser) {
1209:
1210: StringBuffer outValue = new StringBuffer();
1211:
1212: for (int i = 0; i < inUser.length(); i++) {
1213: char nextChar = inUser.charAt(i);
1214: //if (Character.isDigit(nextChar) || Character.isDigit(nextChar)) {
1215: //
1216: outValue.append(nextChar);
1217: //}
1218: //else {
1219: // outValue.append("_");
1220: //}
1221: }
1222:
1223: return outValue.toString();
1224: }
1225:
1226: private void subDevelop(ConsolePageSession inCps)
1227: throws IOException {
1228:
1229: getConsolePageSession().pushToggleLink(APPLICATIONS);
1230:
1231: createHorizontalRow(0);
1232: startAndEndSimpleTableAndRowAndCell(1,
1233: getAutoTogglingLinkWithTargetId(TOG_CALL__DEV_APPS,
1234: "Applications"), getFontStyle(20, ARIAL, BLUE));
1235:
1236: subDevelopApps(inCps);
1237:
1238: getConsolePageSession().popToggleLink();
1239: }
1240:
1241: private void subDevelopApps(ConsolePageSession inCps)
1242: throws IOException {
1243:
1244: startAutoTogglingTableAndRowAndCell();
1245:
1246: subDevelopAppsExisting(inCps);
1247: subDevelopAppsNew(inCps);
1248: //subDevelopAppsDeploy(inCps);
1249: subDevelopAppsImport(inCps);
1250:
1251: endEnclosingTableAndRowAndCell();
1252:
1253: }
1254:
1255: private void subDevelopAppsExisting(ConsolePageSession inCps)
1256: throws IOException {
1257:
1258: //ProjectApplicationSet was = inCs.getProjectSystemCount();
1259:
1260: for (int i = 0; i < inCps.getUserProjectSystemCount(); i++) {
1261:
1262: startAndEndStretchTableAndRowAndCell("<hr/>");
1263:
1264: ConsolePageSession localCps = getConsolePageSession();
1265: PageSetupContext localPsc = localCps.getPageSetupContext();
1266: ProjectSystem wa = inCps.getUserProjectSystem(i);
1267: UserIdentity ui = localCps.getUserHolder()
1268: .getUserIdentity();
1269:
1270: getConsolePageSession().pushToggleLink(wa.getName());
1271:
1272: String description = wa.getDescription();
1273: if (description == null) {
1274: description = "(No description available)";
1275: }
1276:
1277: //if (i > 0) {
1278: // startAndEndStretchTableAndRowAndCell("<hr/>");
1279: //}
1280:
1281: startTable(3);
1282: startRow();
1283: //startCell(1);
1284: //
1285: SubLimitTextConsolePageContext.newInstance(
1286: "USER_APPLICATION_" + wa.getName(), 1, 50, null,
1287: this , formatText(padNbsp(2)
1288: + getAutoTogglingLinkWithTargetId(
1289: TOG_CALL__USER_APP, wa.getName()),
1290: getFontStyle(14, ARIAL, BLUE)), false, 4);
1291: //startAndEndCell(1, padNbsp(2) + getAutoTogglingLink(wa.getName()),
1292: // getFontStyle(16, ARIAL, BLUE));
1293: //
1294: //endCell();
1295: //startCell(1);
1296: SubLimitTextConsolePageContext.newInstance(
1297: "USER_APPLICATION_DESC_" + wa.getName(), 1, 50,
1298: null, this , formatText(description, getFontStyle(
1299: 12, ARIAL, BLACK)), true, 4);
1300: //
1301: //
1302: //
1303: //
1304: //
1305: //
1306: startCell(1, alignCenter(null));
1307: //
1308: //
1309: //
1310: SubmitActionContext sacDelete = SubmitActionContext
1311: .newInstance(this );
1312: //
1313: sacDelete.addAction(ConsoleParameterContext.FIRST_INPUT,
1314: singleQuotes(SubmitActionParameters.DELETE));
1315: sacDelete.addAction(ConsoleParameterContext.SECOND_INPUT,
1316: singleQuotes(SubmitActionParameters.APPLICATION));
1317: //
1318: sacDelete.addParameter(ConsoleParameterContext.FIRST_INPUT,
1319: singleQuotes(SubmitActionParameters.USER));
1320: sacDelete.addParameter(
1321: ConsoleParameterContext.SECOND_INPUT,
1322: singleQuotes(wa.getName()));
1323: //
1324: sacDelete
1325: .setConfirm("'Are you sure you want to delete this application?'");
1326: //
1327: //
1328: //
1329: //
1330: //
1331: SubmitActionContext sacExport = SubmitActionContext
1332: .newInstance(this );
1333: //
1334: sacExport.addAction(ConsoleParameterContext.FIRST_INPUT,
1335: singleQuotes(SubmitActionParameters.EXPORT));
1336: sacExport.addAction(ConsoleParameterContext.SECOND_INPUT,
1337: singleQuotes(SubmitActionParameters.APPLICATION));
1338: //
1339: sacExport.addParameter(ConsoleParameterContext.FIRST_INPUT,
1340: singleQuotes(SubmitActionParameters.USER));
1341: sacExport.addParameter(
1342: ConsoleParameterContext.SECOND_INPUT,
1343: singleQuotes(wa.getName()));
1344: //
1345: //
1346: //SubmitActionContext sacUpdate =
1347: // SubmitActionContext.newInstance(this);
1348: //
1349: //
1350: //sacUpdate.addParameter(
1351: // sacUpdate.FIRST_INPUT,
1352: // singleQuotes(SubmitActionParameters.USER));
1353: //sacUpdate.addParameter(
1354: // sacUpdate.SECOND_INPUT,
1355: // singleQuotes(inWa.getName()));
1356: //sacUpdate.addParameter(
1357: // sacUpdate.THIRD_INPUT,
1358: // "getPageComponent('"
1359: // + (ConsolePageParameters.CONSOLE_DESCRIPTION_ENTITY
1360: // + XMLHelper.fromStringToCData(inWa.getName()))
1361: // + "').value");
1362: String descValue = wa.getDescription();
1363: if (descValue == null) {
1364: descValue = "(No description available.)";
1365: }
1366: //descValue = "";
1367: //
1368: SubmitActionContext sacUserAppOptions = SubmitActionContext
1369: .newInstance(this );
1370: //
1371: sacUserAppOptions.addAction(
1372: ConsoleParameterContext.FIRST_INPUT,
1373: singleQuotes(SubmitActionParameters.UPDATE));
1374: sacUserAppOptions.addAction(
1375: ConsoleParameterContext.SECOND_INPUT,
1376: singleQuotes(SubmitActionParameters.DESCRIPTION));
1377: //sacUserAppOptions.addAction(
1378: // sacUserAppOptions.FIRST_INPUT,
1379: // singleQuotes(SubmitActionParameters.COPY_TO_SERVER));
1380: //
1381: CreationParameterContext availableServerAppCpc = CreationParameterContext
1382: .newInstance(wa.getName(), sacUserAppOptions, true,
1383: true);
1384: localPsc.registerCreationParameter(localCps,
1385: availableServerAppCpc, CRE_PARAM_CALL__APP_OPTIONS);
1386: //
1387: availableServerAppCpc.addInputAsHiddenBox(
1388: ConsoleParameterContext.FIRST_INPUT,
1389: SubmitActionParameters.USER);
1390: availableServerAppCpc.addInputAsHiddenBox(
1391: ConsoleParameterContext.SECOND_INPUT, wa.getName());
1392: availableServerAppCpc.addInputAsTextArea(
1393: ConsoleParameterContext.THIRD_INPUT, "Description",
1394: descValue);
1395: availableServerAppCpc.addInputAsButton(
1396: ConsoleParameterContext.FOURTH_INPUT,
1397: "Update Descr", CreationParameterContext
1398: .getCreationSubmit(sacUserAppOptions, true,
1399: 8));
1400: //
1401: //
1402: if (!wa.isDeployVisible()) {
1403: SubmitActionContext sacMarkDeployable = SubmitActionContext
1404: .newInstance(this );
1405: //
1406: sacMarkDeployable.addAction(
1407: ConsoleParameterContext.FIRST_INPUT,
1408: singleQuotes(SubmitActionParameters.MARK));
1409: sacMarkDeployable
1410: .addAction(
1411: ConsoleParameterContext.SECOND_INPUT,
1412: singleQuotes(SubmitActionParameters.APPLICATION));
1413: sacMarkDeployable
1414: .addAction(
1415: ConsoleParameterContext.THIRD_INPUT,
1416: singleQuotes(SubmitActionParameters.DEPLOY_VISIBLE));
1417: //
1418: sacMarkDeployable.addParameter(
1419: ConsoleParameterContext.FIRST_INPUT,
1420: singleQuotes(SubmitActionParameters.USER));
1421: sacMarkDeployable.addParameter(
1422: ConsoleParameterContext.SECOND_INPUT,
1423: singleQuotes(wa.getName()));
1424: //createButton(BUTTON__US_MARK_DEP, "Mark Deployable", 175,
1425: // sacMarkDeployable.submitActionCall(),
1426: // null, null, null, null);
1427: availableServerAppCpc.addInputAsButton(
1428: ConsoleParameterContext.FIFTH_INPUT,
1429: "Can Deploy",
1430: submitActionCall(sacMarkDeployable));
1431: } else {
1432: SubmitActionContext sacMarkUndeployable = SubmitActionContext
1433: .newInstance(this );
1434: //
1435: sacMarkUndeployable.addAction(
1436: ConsoleParameterContext.FIRST_INPUT,
1437: singleQuotes(SubmitActionParameters.MARK));
1438: sacMarkUndeployable
1439: .addAction(
1440: ConsoleParameterContext.SECOND_INPUT,
1441: singleQuotes(SubmitActionParameters.APPLICATION));
1442: sacMarkUndeployable
1443: .addAction(
1444: ConsoleParameterContext.THIRD_INPUT,
1445: singleQuotes(SubmitActionParameters.DEPLOY_NOT_VISIBLE));
1446: //
1447: sacMarkUndeployable.addParameter(
1448: ConsoleParameterContext.FIRST_INPUT,
1449: singleQuotes(SubmitActionParameters.USER));
1450: sacMarkUndeployable.addParameter(
1451: ConsoleParameterContext.SECOND_INPUT,
1452: singleQuotes(wa.getName()));
1453: //createButton(BUTTON__US_MARK_UND, "Mark Undeployable", 175,
1454: // sacMarkUndeployable.submitActionCall(),
1455: // null, null, null, null);
1456: availableServerAppCpc.addInputAsButton(
1457: ConsoleParameterContext.FIFTH_INPUT,
1458: "Cannot Deploy",
1459: submitActionCall(sacMarkUndeployable));
1460: }
1461: availableServerAppCpc.addInputAsButton(
1462: ConsoleParameterContext.SIXTH_INPUT, "Delete App",
1463: submitActionCall(sacDelete));
1464: availableServerAppCpc.addInputAsButton(
1465: ConsoleParameterContext.SEVENTH_INPUT,
1466: "Export App", submitActionCall(sacExport));
1467: //
1468: availableServerAppCpc.addInputAsButton(
1469: ConsoleParameterContext.EIGHTH_INPUT, "Deploy Now",
1470: createDeploymentBox(wa, ui).createParameterCall());
1471: //
1472: //
1473: //
1474: createButton(BUTTON__USER_APP_OPTIONS, "Options", 100,
1475: availableServerAppCpc.createParameterCall(),
1476: //XMLHelper.fromStringToCData(
1477: // availableServerAppCpc.createParameterCall()),
1478: null, null, null, null);
1479: //
1480: endCell();
1481: //simpleAndPrint(description);
1482: //endCell();
1483: //startCell(1, alignCenter(null));
1484: //endCell();
1485: endRow();
1486: endTable();
1487:
1488: //
1489: /*
1490: startTable(3);
1491: startRow();
1492: startAndEndCell(1, padNbsp(1));
1493: startCell(2);
1494: simpleAndPrint(createHorizontalRow(2, null));
1495: endCell();
1496: endRow();
1497: endTable();
1498: //
1499:
1500:
1501:
1502:
1503: startTable(3);
1504: startRow();
1505: startAndEndCell(1, padNbsp(1));
1506: startCell(1, alignCenter(null));
1507:
1508:
1509: //
1510: //
1511: printAndIndent("<table>");
1512: printAndIndent("<tr>");
1513: printAndIndent("<td width=\"95\" align=\"center\">");
1514: //
1515: SubmitActionContext sacDelete =
1516: SubmitActionContext.newInstance(this);
1517: //
1518: sacDelete.addAction(
1519: sacDelete.FIRST_INPUT,
1520: singleQuotes(SubmitActionParameters.DELETE));
1521: sacDelete.addAction(
1522: sacDelete.SECOND_INPUT,
1523: singleQuotes(SubmitActionParameters.APPLICATION));
1524: //
1525: sacDelete.addParameter(
1526: sacDelete.FIRST_INPUT,
1527: singleQuotes(SubmitActionParameters.USER));
1528: sacDelete.addParameter(
1529: sacDelete.SECOND_INPUT,
1530: singleQuotes(wa.getName()));
1531: createButton(BUTTON__US_APP_DEL, "Delete", 75,
1532: sacDelete.submitActionCall(), null, null, null, null);
1533: //
1534: revertAndPrint("</td>");
1535: printAndIndent("<td width=\"95\" align=\"center\">");
1536: //
1537: SubmitActionContext sacExport =
1538: SubmitActionContext.newInstance(this);
1539: //
1540: sacExport.addAction(
1541: sacExport.FIRST_INPUT,
1542: singleQuotes(SubmitActionParameters.EXPORT));
1543: sacExport.addAction(
1544: sacExport.SECOND_INPUT,
1545: singleQuotes(SubmitActionParameters.APPLICATION));
1546: //
1547: sacExport.addParameter(
1548: sacExport.FIRST_INPUT,
1549: singleQuotes(SubmitActionParameters.USER));
1550: sacExport.addParameter(
1551: sacExport.SECOND_INPUT,
1552: singleQuotes(wa.getName()));
1553: createButton(BUTTON__US_APP_EXP, "Export", 75,
1554: sacExport.submitActionCall(), null, null, null, null);
1555: //
1556: revertAndPrint("</td>");
1557: revertAndPrint("</tr>");
1558: revertAndPrint("</table>");
1559: //
1560:
1561:
1562: endCell();
1563: startCell(1, alignCenter(null));
1564: if (!wa.isDeployVisible()) {
1565: SubmitActionContext sacMarkDeployable =
1566: SubmitActionContext.newInstance(this);
1567: //
1568: sacMarkDeployable.addAction(
1569: sacMarkDeployable.FIRST_INPUT,
1570: singleQuotes(SubmitActionParameters.MARK));
1571: sacMarkDeployable.addAction(
1572: sacMarkDeployable.SECOND_INPUT,
1573: singleQuotes(SubmitActionParameters.APPLICATION));
1574: sacMarkDeployable.addAction(
1575: sacMarkDeployable.THIRD_INPUT,
1576: singleQuotes(SubmitActionParameters.DEPLOY_VISIBLE));
1577: //
1578: sacMarkDeployable.addParameter(
1579: sacMarkDeployable.FIRST_INPUT,
1580: singleQuotes(SubmitActionParameters.USER));
1581: sacMarkDeployable.addParameter(
1582: sacMarkDeployable.SECOND_INPUT,
1583: singleQuotes(wa.getName()));
1584: createButton(BUTTON__US_MARK_DEP, "Mark Deployable", 175,
1585: sacMarkDeployable.submitActionCall(),
1586: null, null, null, null);
1587: }
1588: else {
1589: SubmitActionContext sacMarkUndeployable =
1590: SubmitActionContext.newInstance(this);
1591: //
1592: sacMarkUndeployable.addAction(
1593: sacMarkUndeployable.FIRST_INPUT,
1594: singleQuotes(SubmitActionParameters.MARK));
1595: sacMarkUndeployable.addAction(
1596: sacMarkUndeployable.SECOND_INPUT,
1597: singleQuotes(SubmitActionParameters.APPLICATION));
1598: sacMarkUndeployable.addAction(
1599: sacMarkUndeployable.THIRD_INPUT,
1600: singleQuotes(SubmitActionParameters.DEPLOY_NOT_VISIBLE));
1601: //
1602: sacMarkUndeployable.addParameter(
1603: sacMarkUndeployable.FIRST_INPUT,
1604: singleQuotes(SubmitActionParameters.USER));
1605: sacMarkUndeployable.addParameter(
1606: sacMarkUndeployable.SECOND_INPUT,
1607: singleQuotes(wa.getName()));
1608: createButton(BUTTON__US_MARK_UND, "Mark Undeployable", 175,
1609: sacMarkUndeployable.submitActionCall(),
1610: null, null, null, null);
1611: }
1612: endCell();
1613: endRow();
1614: endTable();
1615: //
1616: //startTable(3);
1617: //startRow();
1618: //startAndEndCell(1, padNbsp(1));
1619: //startCell(2);
1620: //simpleAndPrint(createHorizontalRow(2, null));
1621: //endCell();
1622: //endRow();
1623: //startRow();
1624: //startAndEndCell(1, padNbsp(1));
1625: //startCell(2);
1626: //simpleAndPrint("Here is where to determine deploy application");
1627: //endCell();
1628: //endRow();
1629: //startRow();
1630: //startAndEndCell(1, padNbsp(1));
1631: //startCell(2);
1632: //simpleAndPrint(createHorizontalRow(2, null));
1633: //endCell();
1634: //endRow();
1635: //endTable();
1636: */
1637:
1638: startAutoTogglingTableAndRowAndCell();
1639:
1640: subDevelopAppsWeb(inCps, wa);
1641: //subDevelopAppsExistingFiles(inCs, wa);
1642: subDevelopAppsProps(inCps, wa);
1643: //subDevelopAppsWorkflow(inCs, wa);
1644: //subDevelopAppsDesc(inCs, wa);
1645:
1646: getConsolePageSession().popToggleLink();
1647:
1648: endEnclosingTableAndRowAndCell();
1649: }
1650: }
1651:
1652: /*
1653: private void subDevelopAppsWorkflow(
1654: ConsolePageSession inCs, ProjectSystem inWa) throws IOException {
1655:
1656: startAndEndStretchTableAndRowAndCell("<hr/>");
1657:
1658: startTable(3);
1659: startRow();
1660: startAndEndCell(1, padNbsp(4) + "Workflow",
1661: getFontStyle(14, ARIAL, BLACK));
1662:
1663: //startAndEndCell(1, inWa.getFormattedDate(),
1664: // getFontStyle(14, ARIAL, BLACK));
1665: startAndEndCell(1, padNbsp(1),
1666: getFontStyle(14, ARIAL, BLACK));
1667: startCell(1, alignCenter(null));
1668:
1669: SubmitActionContext sacEditScript =
1670: SubmitActionContext.newInstance(this);
1671: sacEditScript.setGoToPage(
1672: ConsolePageParameters.SERVLET_DEVELOP_WORKFLOW_TEMPLATE);
1673: //
1674: sacEditScript.addAction(
1675: sacEditScript.FIRST_INPUT,
1676: singleQuotes(SubmitActionParameters.OPEN));
1677: //
1678: sacEditScript.addParameter(
1679: sacEditScript.FIRST_INPUT,
1680: singleQuotes(SubmitActionParameters.USER));
1681: sacEditScript.addParameter(
1682: sacEditScript.SECOND_INPUT,
1683: singleQuotes(inWa.getName()));
1684: createButton(BUTTON__US_EDIT_WORK, "Edit", 75,
1685: submitActionCall(sacEditScript), null, null, null, null);
1686:
1687: endCell();
1688: endRow();
1689: endTable();
1690: }
1691: */
1692: private void subDevelopAppsWeb(ConsolePageSession inCps,
1693: ProjectSystem inWa) throws IOException {
1694:
1695: getConsolePageSession().pushToggleLink(WEB);
1696: //String devAppsWebPagesSelect =
1697: // DEVELOP_APPLICATIONS_WEB_PAGES_ + inWa.getName() + _SELECT;
1698: //HashMap styleSelect = getFontStyle(9, COURIER, BLACK);
1699: //
1700: //getConsolePageSession().pushToggleLink(INPUT_DIRECTORY_NAME);
1701: //String inputDirectoryNameId = getConsolePageSession().getToggleLink();
1702: //getConsolePageSession().popToggleLink();
1703: String inputDirectoryNameTextBox = createTextBox(
1704: INPUT_DIRECTORY_NAME, "/", null, null, null, null, null);
1705: String inputDirectoryNameId = inCps.getPreviousToggleLink();
1706: //
1707: //
1708: //
1709: //
1710: //
1711: //getConsolePageSession().pushToggleLink(INPUT_FILE_UPLOAD);
1712: //String inputFileUploadId = getConsolePageSession().getToggleLink();
1713: //getConsolePageSession().popToggleLink();
1714: HashMap fileUploadStyles = new HashMap();
1715: fileUploadStyles.put("font-size", "6pt");
1716: String inputFileUploadFileUpload = createFileUpload(
1717: INPUT_FILE_UPLOAD, new Integer(1), null,
1718: fileUploadStyles);
1719: String inputFileUploadId = inCps.getPreviousToggleLink();
1720: //
1721: //
1722: //
1723: //
1724: //
1725: //getConsolePageSession().pushToggleLink(INPUT_CREATE_PAGE);
1726: //String inputCreatePageId = getConsolePageSession().getToggleLink();
1727: //getConsolePageSession().popToggleLink();
1728: //
1729: //
1730: String inputCreatePageTextBox = createTextBox(
1731: INPUT_CREATE_PAGE, "WebPage", null, null, new Integer(
1732: 10), null, null);
1733: String inputCreatePageId = inCps.getPreviousToggleLink();
1734: //
1735: //
1736: //getConsolePageSession().pushToggleLink(INPUT_SERVLET_NAME);
1737: //String inputServletNameId = getConsolePageSession().getToggleLink();
1738: //getConsolePageSession().popToggleLink();
1739: //
1740: //getConsolePageSession().pushToggleLink(INPUT_SERVLET_CLASS);
1741: //String inputServletClassId = getConsolePageSession().getToggleLink();
1742: //getConsolePageSession().popToggleLink();
1743:
1744: startAndEndStretchTableAndRowAndCell("<hr/>");
1745:
1746: startTable(1);
1747: startRow();
1748: startAndEndCell(1,
1749: padNbsp(4)
1750: + getAutoTogglingLinkWithTargetId(
1751: TOG_CALL__WEB, "Web"), getFontStyle(14,
1752: ARIAL, BLUE));
1753:
1754: //startAndEndCell(1, createTextBox(
1755: // (ConsolePageParameters.CONSOLE_WEB_PAGE_ENTITY + inWa.getName()),
1756: // "NewWebPage", null, null, null, null));
1757: //
1758: //startCell(1, alignCenter(null));
1759: //SubmitActionContext sacCreate = SubmitActionContext.newInstance(this);
1760: //sacCreate.setAction(singleQuotes(SubmitActionParameters.CREATE));
1761: //sacCreate.setSubAction(singleQuotes(SubmitActionParameters.WEB_PAGE));
1762: //sacCreate.setParameter(singleQuotes(inWa.getName()));
1763: //sacCreate.setSecondParameter("getPageComponent('"
1764: // + (ConsolePageParameters.CONSOLE_WEB_PAGE_ENTITY
1765: // + XMLHelper.fromStringToCData(inWa.getName())) + "').value");
1766: //createButton("Create", 75, sacCreate.submitActionCall(),
1767: // null, null, null, null);
1768: //endCell();
1769: //
1770: endRow();
1771: endTable();
1772:
1773: startAutoTogglingTableAndRowAndCell();
1774: int topLeftMargin = getLeftMargin();
1775: setLeftMargin(topLeftMargin + 1);
1776: startAndEndStretchTableAndRowAndCell("<hr/>");
1777: //
1778: startTable(2);
1779: startRow();
1780: //startCell(2);
1781: //
1782: SubAppDirConsolePageContext.newInstance(inWa, 2, 100,
1783: "#999999", this , inputDirectoryNameId);
1784: //
1785: //endCell();
1786: endRow();
1787: endTable();
1788: //
1789: createHorizontalRow(0);
1790: //
1791: startTable(2);
1792: startRow();
1793: startAndEndCell(1, "In Directory .....", getFontStyle(12,
1794: ARIAL, BLACK));
1795: //
1796: //
1797: startAndEndCell(1, inputDirectoryNameTextBox, alignCenter(null));
1798: //
1799: endRow();
1800: endTable();
1801: //
1802: createHorizontalRow(1);
1803: //
1804: startTable(2);
1805: startRow();
1806: startAndEndCell(1, padNbsp(4) + "..... Create Page"
1807: + padNbsp(2), getFontStyle(12, ARIAL, BLACK));
1808: startCell(1, alignCenter(null));
1809: printAndIndent("<table width=\"" + (getColumnWidth() - 4)
1810: + "\">");
1811: printAndIndent("<tr>");
1812: printAndIndent("<td width=\"110\" align=\"center\">");
1813: simpleAndPrint(inputCreatePageTextBox);
1814: revertAndPrint("</td>");
1815: printAndIndent("<td width=\"80\" align=\"center\">");
1816: //
1817: //
1818: SubmitActionContext sacCreateWebPage = SubmitActionContext
1819: .newInstance(this );
1820: //
1821: initializeCreateWebPageSac(sacCreateWebPage, singleQuotes(inWa
1822: .getName()), "getPageComponent('"
1823: + inputDirectoryNameId + "').value",
1824: "getPageComponent('" + inputCreatePageId + "').value",
1825: true);
1826: //
1827: //sacCreateWebPage.addAction(
1828: // sacCreateWebPage.FIRST_INPUT,
1829: // singleQuotes(SubmitActionParameters.CREATE));
1830: //sacCreateWebPage.addAction(
1831: // sacCreateWebPage.SECOND_INPUT,
1832: // singleQuotes(SubmitActionParameters.WEB_PAGE));
1833: //
1834: //sacCreateWebPage.addParameter(
1835: // sacCreateWebPage.FIRST_INPUT,
1836: // singleQuotes(SubmitActionParameters.USER));
1837: //sacCreateWebPage.addParameter(
1838: // sacCreateWebPage.SECOND_INPUT,
1839: // singleQuotes(inWa.getName()));
1840: //sacCreateWebPage.addParameter(
1841: // sacCreateWebPage.THIRD_INPUT,
1842: // "getPageComponent('" + inputDirectoryNameId + "').value");
1843: //sacCreateWebPage.addParameter(
1844: // sacCreateWebPage.FOURTH_INPUT,
1845: // "getPageComponent('" + inputCreatePageId + "').value");
1846: //
1847: createButton(BUTTON__US_CRE_PAGE, "Create", 75,
1848: submitActionCall(sacCreateWebPage), null, null, null,
1849: null);
1850: revertAndPrint("</td>");
1851: revertAndPrint("</tr>");
1852: revertAndPrint("</table>");
1853:
1854: //
1855: endCell();
1856: endRow();
1857: endTable();
1858: //
1859: createHorizontalRow(1);
1860: //
1861: startTable(2);
1862: startRow();
1863: startAndEndCell(1, padNbsp(4) + "..... Upload File"
1864: + padNbsp(2), getFontStyle(12, ARIAL, BLACK));
1865: startCell(1, alignCenter(null));
1866: printAndIndent("<table width=\"" + (getColumnWidth() - 4)
1867: + "\">");
1868: printAndIndent("<tr>");
1869: printAndIndent("<td width=\"110\" align=\"center\">");
1870: simpleAndPrint(inputFileUploadFileUpload);
1871: revertAndPrint("</td>");
1872: printAndIndent("<td width=\"80\" align=\"center\">");
1873: //
1874: //
1875: SubmitActionContext sacUploadFilePage = SubmitActionContext
1876: .newInstance(this );
1877: //
1878: initializeCreateWebFileSac(sacUploadFilePage, inWa.getName(),
1879: "getPageComponent('" + inputDirectoryNameId
1880: + "').value", inputFileUploadId, true);
1881: //
1882: //sacUploadFilePage.addAction(
1883: // ConsoleParameterContext.FIRST_INPUT,
1884: // singleQuotes(SubmitActionParameters.UPLOAD));
1885: //sacUploadFilePage.addAction(
1886: // ConsoleParameterContext.SECOND_INPUT,
1887: // singleQuotes(SubmitActionParameters.WEB_FILE));
1888: //
1889: //sacUploadFilePage.addParameter(
1890: // ConsoleParameterContext.FIRST_INPUT,
1891: // singleQuotes(SubmitActionParameters.USER));
1892: //sacUploadFilePage.addParameter(
1893: // ConsoleParameterContext.SECOND_INPUT,
1894: // singleQuotes(inWa.getName()));
1895: //sacUploadFilePage.addParameter(
1896: // ConsoleParameterContext.THIRD_INPUT,
1897: // "getPageComponent('" + inputDirectoryNameId + "').value");
1898: //sacUploadFilePage.addParameter(
1899: // ConsoleParameterContext.FOURTH_INPUT,
1900: // singleQuotes(inputFileUploadId));
1901: createButton(BUTTON__US_UPL_FILE, "Upload", 75,
1902: submitActionCall(sacUploadFilePage), null, null, null,
1903: null);
1904: revertAndPrint("</td>");
1905: revertAndPrint("</tr>");
1906: revertAndPrint("</table>");
1907: //
1908: //
1909: endCell();
1910: endRow();
1911: endTable();
1912: //
1913: //createHorizontalRow(1);
1914: //
1915: //startTable(2);
1916: //startRow();
1917: //startAndEndCell(1, padNbsp(4) + "..... Define Servlet" + padNbsp(2),
1918: // getFontStyle(12, ARIAL, BLACK));
1919: //startCell(1, alignCenter(null));
1920: //printAndIndent("<table width=\"" + (getColumnWidth() - 4) + "\">");
1921: //printAndIndent("<tr>");
1922: //printAndIndent("<td width=\"110\" align=\"center\">");
1923: //simpleAndPrint(createTextBox(
1924: // inputServletNameId, "ServletName",
1925: // null, new Integer(10), null, null));
1926: //revertAndPrint("</td>");
1927: //printAndIndent("<td width=\"80\" align=\"center\">");
1928: ////
1929: ////
1930: //SubmitActionContext sacDefineServletPage =
1931: // SubmitActionContext.newInstance(this);
1932: //sacDefineServletPage.setAction(
1933: // singleQuotes(SubmitActionParameters.DEFINE));
1934: //sacDefineServletPage.setSubAction(
1935: // singleQuotes(SubmitActionParameters.WEB_SERVLET));
1936: //sacDefineServletPage.setFirstParameter(
1937: // singleQuotes(SubmitActionParameters.USER));
1938: //sacDefineServletPage.setSecondParameter(singleQuotes(inWa.getName()));
1939: //sacDefineServletPage.setThirdParameter(
1940: // "getPageComponent('" + inputDirectoryNameId + "').value");
1941: //sacDefineServletPage.setFourthParameter(
1942: // "getPageComponent('" + inputServletNameId + "').value");
1943: //sacDefineServletPage.setFifthParameter(
1944: // "getPageComponent('" + inputServletClassId + "').value");
1945: //createButton(
1946: // "Define", 75, sacDefineServletPage.submitActionCall(),
1947: // null, null, null, null);
1948: //revertAndPrint("</td>");
1949: //revertAndPrint("</tr>");
1950: //revertAndPrint("</table>");
1951: ////
1952: ////
1953: //endCell();
1954: //endRow();
1955: //startRow();
1956: //startAndEndCell(1, padNbsp(1));
1957: //startCell(1, alignCenter(null));
1958: //simpleAndPrint(createTextBox(
1959: // inputServletClassId, "serlvet.class", null, null, null, null));
1960: //endCell();
1961: //endRow();
1962: //endTable();
1963: //
1964: //startAndEndStretchTableAndRowAndCell("<hr/>");
1965: //
1966: setLeftMargin(topLeftMargin);
1967: getConsolePageSession().popToggleLink();
1968: endEnclosingTableAndRowAndCell();
1969:
1970: }
1971:
1972: public final static void initializeCreateWebPageSac(
1973: SubmitActionContext inSac, String inAppName, String inDir,
1974: String inWebPage, boolean inUseQuotes) {
1975: //
1976: inSac
1977: .addAction(ConsoleParameterContext.FIRST_INPUT,
1978: singleQuotes(SubmitActionParameters.CREATE,
1979: inUseQuotes));
1980: inSac.addAction(ConsoleParameterContext.SECOND_INPUT,
1981: singleQuotes(SubmitActionParameters.WEB_PAGE,
1982: inUseQuotes));
1983: //
1984: inSac.addParameter(ConsoleParameterContext.FIRST_INPUT,
1985: singleQuotes(SubmitActionParameters.USER, inUseQuotes));
1986: inSac.addParameter(ConsoleParameterContext.SECOND_INPUT,
1987: inAppName);
1988: inSac.addParameter(ConsoleParameterContext.THIRD_INPUT, inDir);
1989: inSac.addParameter(ConsoleParameterContext.FOURTH_INPUT,
1990: inWebPage);
1991: }
1992:
1993: public final static void initializeCreateWebFileSac(
1994: SubmitActionContext inSac, String inAppName, String inDir,
1995: String inWebFileId, boolean inUseQuotes) {
1996: //
1997: inSac
1998: .addAction(ConsoleParameterContext.FIRST_INPUT,
1999: singleQuotes(SubmitActionParameters.UPLOAD,
2000: inUseQuotes));
2001: inSac.addAction(ConsoleParameterContext.SECOND_INPUT,
2002: singleQuotes(SubmitActionParameters.WEB_FILE,
2003: inUseQuotes));
2004: //
2005: inSac.addParameter(ConsoleParameterContext.FIRST_INPUT,
2006: singleQuotes(SubmitActionParameters.USER, inUseQuotes));
2007: inSac.addParameter(ConsoleParameterContext.SECOND_INPUT,
2008: singleQuotes(inAppName, inUseQuotes));
2009: inSac.addParameter(ConsoleParameterContext.THIRD_INPUT, inDir);
2010: inSac.addParameter(ConsoleParameterContext.FOURTH_INPUT,
2011: singleQuotes(inWebFileId, inUseQuotes));
2012: }
2013:
2014: private void subDevelopAppsProps(ConsolePageSession inCps,
2015: ProjectSystem inPs) throws IOException {
2016:
2017: //ArrayList propNames = new ArrayList();
2018: //ArrayList propValues = new ArrayList();
2019: //
2020: //propNames.add("");
2021: //propValues.add("");
2022:
2023: //
2024: //
2025: //
2026: getConsolePageSession().pushToggleLink(PROPERTY);
2027: startAndEndStretchTableAndRowAndCell("<hr/>");
2028: startAndEndSimpleTableAndRowAndCell(1, padNbsp(4)
2029: + getAutoTogglingLinkWithTargetId(TOG_CALL__PROPERTY,
2030: "Property"), getFontStyle(14, ARIAL, BLUE));
2031: startAutoTogglingTableAndRowAndCell();
2032: startAndEndStretchTableAndRowAndCell("<hr/>");
2033: //
2034: startTable(3);
2035: startRow();
2036: startAndEndCell(1, padNbsp(6) + "New Property", addAttr(
2037: getFontStyle(12, ARIAL, BLACK), "valign", "top"));
2038: //startCell(2);
2039: SubAppPropConsolePageContext.newInstance(inCps, inPs, 2, 100,
2040: "#999999", this );
2041: //endCell();
2042: endRow();
2043: endTable();
2044: //displayNewProperty(inCs, inPs);
2045: //
2046: //
2047: //
2048: SystemEntityProperties propValues = inPs
2049: .getUserPropertiesValues();
2050: SystemEntityProperties propRegExs = inPs
2051: .getUserPropertiesRegExes();
2052: SystemEntityProperties propDescs = inPs
2053: .getUserPropertiesDescriptions();
2054: SystemEntityProperties propErrMess = inPs
2055: .getUserPropertiesErrorMessages();
2056: //
2057: int propertyCount = propValues.getPropertyCount();
2058: //
2059: for (int i = 0; i < propValues.getPropertyCount(); i++) {
2060: String propName = propValues.getPropertyName(i);
2061: String propValue = propValues.getPropertyValue(propName);
2062: String propRegEx = propRegExs.getPropertyValue(propName);
2063: String propDesc = propDescs.getPropertyValue(propName);
2064: String propErrMes = propErrMess.getPropertyValue(propName);
2065: //
2066: //
2067: if (i == 0) {
2068: createHorizontalRow(1);
2069: }
2070: createHorizontalRow(1);
2071:
2072: startTable(3);
2073: startRow();
2074: //startCell(1);
2075: SubLimitTextConsolePageContext.newInstance(
2076: "USER_APPLICATION_" + inPs.getName() + "_PROPERTY_"
2077: + propName, 1, 70, null, this , formatText(
2078: padNbsp(6) + propName, getFontStyle(12,
2079: ARIAL, BLACK)), false, 4);
2080: //startAndEndCell(1, padNbsp(6) + propName,
2081: // addAttr(getFontStyle(12, ARIAL, BLACK), "valign", "top"));
2082: //endCell();
2083: startCell(2);
2084: //
2085: SubAppPropConsolePageContext.newInstance(inCps, inPs,
2086: propName, propValue, propRegEx, propDesc,
2087: propErrMes, 2, 70, "#999999", this );
2088: //
2089: //displayExistingProperty(
2090: // inPs, propName, propValue, propRegEx, propDesc, propErrMes);
2091: endCell();
2092: endRow();
2093: endTable();
2094: }
2095: endEnclosingTableAndRowAndCell();
2096: getConsolePageSession().popToggleLink();
2097:
2098: }
2099:
2100: /*
2101: private void subDevelopAppsDesc(
2102: ConsolePageSession inCs, ProjectSystem inWa) throws IOException {
2103:
2104: //HashMap styleSelect = getFontStyleAsStyles(9, COURIER, BLACK);
2105: HashMap styleSelect = new HashMap();
2106: styleSelect.put("width", (getColumnWidth() - 4) + "px");
2107: //String styleSelectString = XMLHelper.fromStylesToAttr(styleSelect);
2108: //styleSelect = new HashMap();
2109: //styleSelect.put("style", styleSelectString);
2110:
2111: String description = inWa.getDescription();
2112: if (description == null) {
2113: description = "(No description available.)";
2114: }
2115:
2116: startAndEndStretchTableAndRowAndCell("<hr/>");
2117:
2118: startTable(3);
2119: startRow();
2120: startAndEndCell(1, padNbsp(4) + "Description",
2121: addAttr(getFontStyle(14, ARIAL, BLACK), "valign", "top"));
2122: startCell(1, alignCenter(null));
2123:
2124: simpleAndPrint(createTextArea(
2125: (ConsolePageParameters.CONSOLE_DESCRIPTION_ENTITY + inWa.getName()),
2126: description, null, styleSelect, new Integer(3), null, null));
2127: endCell();
2128: startCell(1, addAttr(alignCenter(null), "valign", "top"));
2129: //
2130: SubmitActionContext sacUpdate =
2131: SubmitActionContext.newInstance(this);
2132: //
2133: sacUpdate.addAction(
2134: sacUpdate.FIRST_INPUT,
2135: singleQuotes(SubmitActionParameters.UPDATE));
2136: sacUpdate.addAction(
2137: sacUpdate.SECOND_INPUT,
2138: singleQuotes(SubmitActionParameters.DESCRIPTION));
2139: //
2140: sacUpdate.addParameter(
2141: sacUpdate.FIRST_INPUT,
2142: singleQuotes(SubmitActionParameters.USER));
2143: sacUpdate.addParameter(
2144: sacUpdate.SECOND_INPUT,
2145: singleQuotes(inWa.getName()));
2146: sacUpdate.addParameter(
2147: sacUpdate.THIRD_INPUT,
2148: "getPageComponent('"
2149: + (ConsolePageParameters.CONSOLE_DESCRIPTION_ENTITY
2150: + XMLHelper.fromStringToCData(inWa.getName())) + "').value");
2151: createButton(BUTTON__US_UPD_DESC, "Update", new Integer(75),
2152: submitActionCall(sacUpdate), null, null, null, null);
2153: //
2154:
2155: endCell();
2156: endRow();
2157: endTable();
2158: }
2159: */
2160: private void subDevelopAppsNew(ConsolePageSession inCps)
2161: throws IOException {
2162:
2163: String applicationToCreateTextBox = createTextBox(
2164: ConsolePageParameters.APPLICATION_TO_CREATE,
2165: "NewApplication", null, null, null, null, null);
2166: String applicationToCreateId = inCps.getPreviousToggleLink();
2167:
2168: startAndEndStretchTableAndRowAndCell("<hr/>");
2169:
2170: startTable(3);
2171: startRow();
2172: startAndEndCell(1, padNbsp(2) + "New", getFontStyle(14, ARIAL,
2173: BLACK));
2174: startAndEndCell(1, applicationToCreateTextBox);
2175: startCell(1, alignCenter(null));
2176: //
2177: SubmitActionContext sacCreate = SubmitActionContext
2178: .newInstance(this );
2179: initializeCreateAppSac(sacCreate, "getPageComponent('"
2180: + applicationToCreateId + "').value", true);
2181: //
2182: createButton(BUTTON__US_NEW_APP, "Create", new Integer(75),
2183: submitActionCall(sacCreate), null, null, null, null);
2184: endCell();
2185: endRow();
2186: endTable();
2187: }
2188:
2189: public final static void initializeCreateAppSac(
2190: SubmitActionContext inSac, String inName,
2191: boolean inUseQuotes) {
2192: //
2193: inSac
2194: .addAction(ConsoleParameterContext.FIRST_INPUT,
2195: singleQuotes(SubmitActionParameters.CREATE,
2196: inUseQuotes));
2197: //
2198: inSac.addAction(ConsoleParameterContext.SECOND_INPUT,
2199: singleQuotes(SubmitActionParameters.APPLICATION,
2200: inUseQuotes));
2201: //
2202: inSac.addParameter(ConsoleParameterContext.FIRST_INPUT,
2203: singleQuotes(SubmitActionParameters.USER, inUseQuotes));
2204: //
2205: inSac
2206: .addParameter(ConsoleParameterContext.SECOND_INPUT,
2207: inName);
2208: }
2209:
2210: /*
2211: private void subDevelopAppsDeploy(ConsolePageSession inCs)
2212: throws IOException {
2213:
2214: //ProjectSystem was = inCs.getProjectApplicationSet();
2215:
2216: HashMap styleSelect = getFontStyle(9, COURIER, BLACK);
2217:
2218: if (inCs.getUserProjectSystemCount() > 0) {
2219:
2220: //ProjectSystem nextProject
2221:
2222: startAndEndStretchTableAndRowAndCell("<hr/>");
2223:
2224: startTable(3);
2225: startRow();
2226:
2227: startAndEndCell(1, padNbsp(2) + "Deploy",
2228: getFontStyle(14, ARIAL, BLACK));
2229: startCell(1);
2230: printAndIndent("<table cellspacing=\"0\" cellpadding=\"0\">");
2231: printAndIndent("<tr>");
2232: printAndIndent("<td>");
2233:
2234: String deploySelectOnChange = "getPageComponent('"
2235: + ConsolePageParameters.APPLICATION_CONTEXT_PATH
2236: + "').value = this.value";
2237: ArrayList deploySelectLabels = new ArrayList();
2238: ArrayList deploySelectValues = new ArrayList();
2239:
2240: //
2241: deploySelectLabels.add("---------");
2242: deploySelectValues.add("");
2243: for (int i = 0; i < inCs.getUserProjectSystemCount(); i++) {
2244: ProjectSystem wa = inCs.getUserProjectSystem(i);
2245: deploySelectLabels.add(MiscHelper.fixString(wa.getName(), 9));
2246: deploySelectValues.add(wa.getName());
2247: }
2248: //
2249:
2250: String deploySelect =
2251: createDropDownBox(ConsolePageParameters.APPLICATION_TO_DEPLOY,
2252: deploySelectLabels, deploySelectValues,
2253: null, styleSelect, 0,
2254: new Integer(1), deploySelectOnChange, null);
2255: simpleAndPrint(deploySelect);
2256:
2257: revertAndPrint("</td>");
2258: printAndIndent("<td>");
2259: simpleAndPrint(XMLHelper.NBSP_XML + XMLHelper.NBSP_XML);
2260: revertAndPrint("</td>");
2261: printAndIndent("<td>");
2262: simpleAndPrint(
2263: createTextBox(ConsolePageParameters.APPLICATION_CONTEXT_PATH,
2264: "ContextPath", null, null, new Integer(9), null, null));
2265: revertAndPrint("</td>");
2266: revertAndPrint("</tr>");
2267: revertAndPrint("</table>");
2268: endCell();
2269: startCell(1, alignCenter(null));
2270: SubmitActionContext sacDeploy =
2271: SubmitActionContext.newInstance(this);
2272: //
2273: sacDeploy.addAction(
2274: sacDeploy.FIRST_INPUT,
2275: singleQuotes(SubmitActionParameters.DEPLOY));
2276: sacDeploy.addAction(
2277: sacDeploy.SECOND_INPUT,
2278: singleQuotes(SubmitActionParameters.APPLICATION));
2279: //
2280: sacDeploy.addParameter(
2281: sacDeploy.FIRST_INPUT,
2282: "getPageComponent('"
2283: + ConsolePageParameters.APPLICATION_TO_DEPLOY + "').value");
2284: sacDeploy.addParameter(
2285: sacDeploy.SECOND_INPUT,
2286: "getPageComponent('"
2287: + ConsolePageParameters.APPLICATION_CONTEXT_PATH
2288: + "').value");
2289: createButton(BUTTON__US_DEPLOY, "Deploy", 75,
2290: submitActionCall(sacDeploy), null, null, null, null);
2291: endCell();
2292: endRow();
2293: endTable();
2294: }
2295: }
2296: */
2297: private void subDevelopAppsImport(ConsolePageSession inCps)
2298: throws IOException {
2299:
2300: startAndEndStretchTableAndRowAndCell("<hr/>");
2301:
2302: startTable(3);
2303: startRow();
2304:
2305: //
2306: String appToImportFileUpload = createFileUpload(
2307: ConsolePageParameters.APPLICATION_TO_IMPORT,
2308: new Integer(7));
2309: String appToImportId = getConsolePageSession()
2310: .getPreviousToggleLink();
2311: //
2312: startAndEndCell(1, padNbsp(2) + "Import", getFontStyle(14,
2313: ARIAL, BLACK));
2314: startAndEndCell(1, appToImportFileUpload);
2315: //
2316:
2317: startCell(1, alignCenter(null));
2318: SubmitActionContext sacImport = SubmitActionContext
2319: .newInstance(this );
2320: //
2321: sacImport.addAction(ConsoleParameterContext.FIRST_INPUT,
2322: singleQuotes(SubmitActionParameters.IMPORT));
2323: sacImport.addAction(ConsoleParameterContext.SECOND_INPUT,
2324: singleQuotes(SubmitActionParameters.APPLICATION));
2325: //
2326: sacImport.addParameter(ConsoleParameterContext.FIRST_INPUT,
2327: singleQuotes(SubmitActionParameters.USER));
2328: sacImport.addParameter(ConsoleParameterContext.SECOND_INPUT,
2329: singleQuotes(appToImportId));
2330: //
2331: createButton(BUTTON__US_IMPORT, "Import", 75,
2332: submitActionCall(sacImport), null, null, null, null);
2333: endCell();
2334:
2335: endRow();
2336: endTable();
2337: }
2338:
2339: private CreationParameterContext createDeploymentBox(
2340: ProjectSystem inPs, UserIdentity inUi) throws IOException {
2341:
2342: //
2343: CreationParameterContext outValue = null;
2344: //
2345: //
2346: //
2347: ConsolePageSession localCps = getConsolePageSession();
2348: PageSetupContext localPsc = localCps.getPageSetupContext();
2349: //
2350: //
2351: SubmitActionContext sacCopyToServer = SubmitActionContext
2352: .newInstance(this );
2353: //
2354: sacCopyToServer.addAction(ConsoleParameterContext.FIRST_INPUT,
2355: singleQuotes(SubmitActionParameters.COPY_TO_SERVER));
2356: //
2357: outValue = CreationParameterContext.newInstance(inPs.getName(),
2358: sacCopyToServer, true, false);
2359: localPsc.registerCreationParameter(localCps, outValue,
2360: CRE_PARAM_CALL__DEPLOY);
2361: //
2362: outValue.addInputAsHiddenBox(
2363: ConsoleParameterContext.FIRST_INPUT, inUi.getName());
2364: outValue.addInputAsHiddenBox(
2365: ConsoleParameterContext.SECOND_INPUT, inPs.getName());
2366: outValue.addInputAsTextBox(ConsoleParameterContext.THIRD_INPUT,
2367: "Deployed Name", inPs.getName());
2368: //
2369: //
2370: //
2371: //
2372: //ArrayList inputProjectDeployVisibleLabels = new ArrayList();
2373: //inputProjectDeployVisibleLabels.add("Deploy Immediately");
2374: //inputProjectDeployVisibleLabels.add("Delay Deployment");
2375: //
2376: String deployLabels[] = new String[] { "Deploy Immediately",
2377: "Delay Deployment" };
2378: String deployValues[] = new String[] {
2379: SubmitActionParameters.DEPLOY_VISIBLE,
2380: SubmitActionParameters.DEPLOY_NOT_VISIBLE };
2381: //
2382: //ArrayList inputProjectDeployVisibleValues = new ArrayList();
2383: //inputProjectDeployVisibleValues.add(
2384: // SubmitActionParameters.DEPLOY_VISIBLE);
2385: //inputProjectDeployVisibleValues.add(
2386: // SubmitActionParameters.DEPLOY_NOT_VISIBLE);
2387: //
2388: outValue.addInputAsExclusive(
2389: ConsoleParameterContext.FOURTH_INPUT,
2390: "Deployed Status", deployValues, deployLabels);
2391:
2392: return outValue;
2393: }
2394: }
|