Author: konstantin.mishin
Date: 2010-11-18 21:34:15 -0500 (Thu, 18 Nov 2010)
New Revision: 20110
Added:
sandbox/trunk/examples/fileupload-demo/src/main/java/org/richfaces/demo/SkinBean.java
Modified:
sandbox/trunk/examples/fileupload-demo/src/main/webapp/fileupload.xhtml
Log:
RF-9501
Added:
sandbox/trunk/examples/fileupload-demo/src/main/java/org/richfaces/demo/SkinBean.java
===================================================================
--- sandbox/trunk/examples/fileupload-demo/src/main/java/org/richfaces/demo/SkinBean.java
(rev 0)
+++
sandbox/trunk/examples/fileupload-demo/src/main/java/org/richfaces/demo/SkinBean.java 2010-11-19
02:34:15 UTC (rev 20110)
@@ -0,0 +1,29 @@
+package org.richfaces.demo;
+
+import javax.faces.bean.ManagedBean;
+import javax.faces.bean.SessionScoped;
+
+@ManagedBean(name = "skinBean")
+@SessionScoped
+public class SkinBean {
+
+ private static final String[] SKINS = {"blueSky", "deepMarine",
"emeraldTown", "NULL", "ruby", "classic",
+ "DEFAULT", "japanCherry", "plain", "wine"
};
+
+ private String skin = "blueSky";
+
+ public SkinBean() {
+ skin = "blueSky";
+ }
+ public String getSkin() {
+ return skin;
+ }
+
+ public void setSkin(String skin) {
+ this.skin = skin;
+ }
+
+ public String[] getSkins() {
+ return SKINS;
+ }
+}
Modified: sandbox/trunk/examples/fileupload-demo/src/main/webapp/fileupload.xhtml
===================================================================
--- sandbox/trunk/examples/fileupload-demo/src/main/webapp/fileupload.xhtml 2010-11-19
00:24:09 UTC (rev 20109)
+++ sandbox/trunk/examples/fileupload-demo/src/main/webapp/fileupload.xhtml 2010-11-19
02:34:15 UTC (rev 20110)
@@ -33,18 +33,12 @@
<title>Richfaces FileUpload Demo</title>
</h:head>
<h:body>
- <h:form id="form" enctype="multipart/form-data">
- <script type="text/javascript">
- <!--
- var myForm = document.getElementById("form");
- myForm.action = myForm.action + "?_richfaces_upload_uid=1";
- //-->
- </script>
- <!--h:outputText value="Skin: "/>
+ <h:form id="form">
+ <h:outputText value="Skin: "/>
<h:selectOneMenu value="#{skinBean.skin}"
onchange="submit();">
<f:selectItems value="#{skinBean.skins}"/>
</h:selectOneMenu>
- <br /-->
+ <br />
<fu:fileUpload fileUploadListener="#{fileUploadBean.listener}"/>
<h:outputText value="File name:" />
<h:outputText value="#{fileUploadBean.item.fileName}" />
Show replies by date