Changeset 856
- Timestamp:
- Apr 1, 2010, 2:06:38 PM (15 years ago)
- Location:
- vanHelsing/trunk/gui
- Files:
-
- 5 added
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
vanHelsing/trunk/gui/WebContent/WEB-INF/faces-config.xml
r848 r856 6 6 xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-facesconfig_1_2.xsd" 7 7 version="1.2"> 8 <application> 9 <locale-config> 10 <default-locale>en</default-locale> 11 <supported-locale>en</supported-locale> 12 </locale-config> 13 <message-bundle>de.dass_it.vanhelsing.gui.messages</message-bundle> 14 15 </application> 8 16 <managed-bean> 9 17 <description>backend bean of the configuration tree view</description> -
vanHelsing/trunk/gui/WebContent/css/rime.css
r854 r856 2664 2664 2665 2665 .iceMsgInfo { 2666 2667 2666 } 2668 2667 -
vanHelsing/trunk/gui/WebContent/index.jsp
r849 r856 1 <!-- <html>2 <head>3 </head>4 <frameset cols="250,*">5 <frame src="viewConfig.iface" name="links">6 <frame src="leereSeite.iface" name="rechts">7 <noframes>8 <body>9 <p>Alternativ-Inhalt (Zusammenfassung, Sitemap ...)</p>10 </body>11 </noframes>12 </frameset>13 </html> -->14 1 <html> 15 2 <head></head> 16 3 <body> 17 <jsp:forward page=" viewConfig.iface" />4 <jsp:forward page="menu.iface" /> 18 5 </body> 19 6 </html> -
vanHelsing/trunk/gui/WebContent/viewConfig.jspx
r854 r856 14 14 <html> 15 15 <head> 16 <title>vanHelsing GUI</title> 17 <!-- <link rel="stylesheet" type="text/css" href="css/treeComponents.css"/> --> 18 <link rel="stylesheet" type="text/css" href="css/showcase_style.css" /> 19 <link rel="stylesheet" type="text/css" href="css/showcase_overrides.css"/> 20 <link rel="stylesheet" type="text/css" href="css/showcase_layout.css"/> 21 <link rel="stylesheet" type="text/css" href="css/rime.css" /> 22 23 16 <ice:outputStyle href="./xmlhttp/css/rime/rime.css" /> 17 <title>van Helsing</title> 24 18 </head> 25 19 26 20 <body> 27 <h1 style="color:grey">van Helsing GUI</h1>28 <ice:panelDivider dividerPosition="45" style="float:left; height:85%">29 <f:facet name="first" >30 <ice:panelGroup style="exampleBox;float:left;width:350px ">21 <h1 style="color:grey">van Helsing</h1> 22 <ice:panelDivider dividerPosition="45" style="float:left; height:85%"> 23 <f:facet name="first" style="height:85%"> 24 <ice:panelGroup style="exampleBox;float:left;width:350px; height:85%"> 31 25 <ice:form> 32 26 <ice:tree id="baum" … … 62 56 63 57 <ice:panelGroup style="float:left;margin: 0; padding: 0" > 58 <ice:panelGroup rendered="#{configurationBean.selectedObject != null}"> 59 <ice:commandButton id="newRes" 60 value="Neu2" 61 actionListener="#{configurationBean.newResourceButtonListener}"/> 62 <ice:commandButton id="saveRes" 63 value="Speichern" 64 actionListener="#{configurationBean.saveButtonListener}"/> 65 </ice:panelGroup> 66 64 67 <ice:panelGrid cellpadding="0" cellspacing="3" 65 68 columns="2" rendered="#{configurationBean.selectedObject != null}"> … … 79 82 <ice:outputText value="Value" /> 80 83 </f:facet> 81 <ice:inputText partialSubmit="true" value="#{item.keyValue}" /> 84 <ice:inputText rendered="#{item.inputText != null}" partialSubmit="true" value="#{item.keyValue}" /> 85 <ice:selectOneMenu id="SlctCompTyp" rendered="#{item.inputSelectOne != null}" valueChangeListener="#{selectionTags.effectChangeListener}" 86 value="#{selectionTags.selectedComponent}" partialSubmit="true"> 87 <f:selectItems id="SlctcompTypeItms" value="#{selectionTags.componentItems}"/> 88 </ice:selectOneMenu> 82 89 </ice:column> 83 90 84 91 </ice:dataTable> 85 <ice:panelGroup> 86 <ice:commandButton id="saveRes" 87 value="Speichern" 88 actionListener="#{configurationBean.saveButtonListener}"/> 89 </ice:panelGroup> 90 <ice:panelGroup rendered="#{configurationBean.selectedObject != null}"> 91 <ice:commandButton id="newRes" 92 value="Neu" 93 actionListener="#{configurationBean.newResourceButtonListener}"/> 94 </ice:panelGroup> 95 </ice:form> 92 </ice:form> 96 93 </ice:panelGrid> 97 94 </ice:panelGroup> -
vanHelsing/trunk/gui/src/de/dass_it/vanhelsing/gui/BeanUtil.java
r848 r856 1 1 package de.dass_it.vanhelsing.gui; 2 2 3 4 5 import javax.faces.application.FacesMessage; 6 import javax.faces.application.FacesMessage.Severity; 3 7 import javax.faces.context.FacesContext; 8 import javax.faces.model.SelectItem; 9 import java.util.ResourceBundle; 10 4 11 5 12 … … 17 24 18 25 //Messagebundles 26 27 28 //Statusmeldungen an den Client 29 public static void setInfoMessage(String client, String message){ 30 FacesContext.getCurrentInstance().addMessage(client, new FacesMessage(FacesMessage.SEVERITY_INFO, message, message)); 31 } 32 public static void setErrorMessage(String client, String message){ 33 FacesContext.getCurrentInstance().addMessage(client, new FacesMessage(FacesMessage.SEVERITY_ERROR, message, message)); 34 } 19 35 20 36 //Linkout to Bacula documentation … … 27 43 return (String) FacesContext.getCurrentInstance().getExternalContext().getRequestParameterMap().get(name); 28 44 } 45 29 46 } -
vanHelsing/trunk/gui/src/de/dass_it/vanhelsing/gui/ConfigurationBean.java
r854 r856 96 96 String Id = BeanUtil.getRequestParameter("userObject.resId"); 97 97 node = getNode(Id, tree); 98 Validation validation = new Validation(); 98 99 String type = ((UserObjectItem) ((UserObjectItemType) node 99 100 .getUserObject()).getUserObject()).getResType(); … … 107 108 UserObjectItem item = ((UserObjectItemType) (node.getUserObject())) 108 109 .getUserObject(); 109 110 110 Class c = ((UserObjectItemType) (node.getUserObject())) 111 111 .getUserObject().getClass(); … … 127 127 vi.setResName(resName); 128 128 vi.setDirector(director); 129 if (type.equals("Client") && 1 == 0){ 130 131 vi.setRendererFlag(validation.getRenderer(classType+":"+key)); 132 vi.setNecessary(validation.getNecessary(classType+":"+key)); 133 } 129 134 selectedObject.add(vi); 130 135 } … … 136 141 } 137 142 public void newResourceButtonListener(ActionEvent ae){ 143 138 144 } 139 145 … … 160 166 s2r.setResInfo(ri); 161 167 s2r2 = c.setSimpleResource(s2r); 168 System.err.println("Status setSimpleRes: "+s2r2.getStatus()); 169 BeanUtil.setErrorMessage(null, "Status setSimpleRessource: "+s2r2.getStatus()); 170 162 171 /*String status = s2r2.getStatus(); 163 172 if (selectedObject.get(0) != null){ -
vanHelsing/trunk/gui/src/de/dass_it/vanhelsing/gui/TreeNavigation.java
r854 r856 27 27 UserObjectItemType item = new UserObjectItemType(root); 28 28 item.setLeaf(false); 29 item.setExpanded(true); 29 30 UserObjectItem uoi = new TreeItem("Configuration"); 30 31 uoi.setResType("Tree"); -
vanHelsing/trunk/gui/src/de/dass_it/vanhelsing/gui/ViewItem.java
r849 r856 3 3 import de.dass_it.vanhelsing.gui.items.ItemType; 4 4 import de.dass_it.vanhelsing.gui.items.UserObjectItem; 5 import de.dass_it.vanhelsing.gui.ValidationItem.*; 5 6 6 7 public class ViewItem extends ItemType implements UserObjectItem { 7 8 private String key; 8 9 private String keyValue; 10 private String inputText; 11 private String selectOneMenu; 12 private boolean necessary; 13 private String renderer; 14 private String dataType; 15 16 public ViewItem(){ 17 inputText = null; 18 selectOneMenu = null; 19 } 20 21 public boolean isNecessary() { 22 return necessary; 23 } 9 24 10 public ViewItem(){ 25 public void setNecessary(boolean necessary) { 26 this.necessary = necessary; 11 27 } 28 29 public String getRenderer() { 30 return renderer; 31 } 32 33 public void setRenderer(String renderer) { 34 this.renderer = renderer; 35 } 36 37 public String getDataType() { 38 return dataType; 39 } 40 41 public void setDataType(String dataType) { 42 this.dataType = dataType; 43 } 44 12 45 13 46 //Methoden aus ItemType für die Zuordnung von Änderungen … … 40 73 this.keyValue = keyValue; 41 74 } 75 76 public void setInputText(String inputText) { 77 this.inputText = inputText; 78 } 79 80 public String getInputText() { 81 return inputText; 82 } 83 84 public void setSelectOneMenu(String selectOneMenu) { 85 this.selectOneMenu = selectOneMenu; 86 } 87 88 public String getSelectOneMenu() { 89 return selectOneMenu; 90 } 91 public void setRendererFlag(String r){ 92 if (r.equals("inputText")) { 93 this.inputText = new String("bernd"); 94 this.selectOneMenu = null; 95 } 96 if (r.equals("selectOneMenu")){ 97 this.selectOneMenu = new String ("bernd"); 98 this.inputText = null; 99 } 100 } 42 101 }
Note:
See TracChangeset
for help on using the changeset viewer.