From 77cf91bb81047edfaa534e6b5574e3a6c3f7c732 Mon Sep 17 00:00:00 2001 From: shameem_z Date: Mon, 29 Oct 2007 12:43:05 +0000 Subject: [PATCH] Refactoring of Create Client/U_WebMenu in Posterita --- .../core/action/login/GenericLoginAction.java | 1 - .../src/main/org/posterita/core/bean/ClientBean.java | 11 ++++++++++- .../src/main/org/posterita/core/form/ClientForm.java | 2 +- 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/posterita/src/main/org/posterita/core/action/login/GenericLoginAction.java b/posterita/src/main/org/posterita/core/action/login/GenericLoginAction.java index 1bfb3a27ef..272831ca67 100644 --- a/posterita/src/main/org/posterita/core/action/login/GenericLoginAction.java +++ b/posterita/src/main/org/posterita/core/action/login/GenericLoginAction.java @@ -31,7 +31,6 @@ import javax.servlet.http.HttpServletResponse; import org.apache.struts.action.ActionForm; import org.apache.struts.action.ActionForward; import org.apache.struts.action.ActionMapping; - import org.posterita.struts.login.LoginAction; public class GenericLoginAction extends LoginAction diff --git a/posterita/src/main/org/posterita/core/bean/ClientBean.java b/posterita/src/main/org/posterita/core/bean/ClientBean.java index 3ee3e05479..62a423bf8d 100644 --- a/posterita/src/main/org/posterita/core/bean/ClientBean.java +++ b/posterita/src/main/org/posterita/core/bean/ClientBean.java @@ -27,6 +27,7 @@ package org.posterita.core.bean; +import org.apache.struts.upload.FormFile; import org.posterita.beans.UDIBean; public class ClientBean extends UDIBean @@ -160,5 +161,13 @@ public class ClientBean extends UDIBean { this.city = city; } - + + public FormFile getFile() + { + return file; + } + public void setFile(FormFile file) + { + this.file = file; + } } diff --git a/posterita/src/main/org/posterita/core/form/ClientForm.java b/posterita/src/main/org/posterita/core/form/ClientForm.java index 85f0c69cfb..6ae9f6ba25 100644 --- a/posterita/src/main/org/posterita/core/form/ClientForm.java +++ b/posterita/src/main/org/posterita/core/form/ClientForm.java @@ -37,6 +37,6 @@ public class ClientForm extends DefaultForm public ClientForm() { this.setBean(new ClientBean()); - this.addRequiredFields(new String[]{"clientName", "address1", "countryId", "currencyId", "email", "orgName", "postalAddress", "confirmPassword", "password", "userPIN", "roleName", "username", "city"}); + this.addRequiredFields(new String[]{"clientName", "address1", "countryId", "currencyId", "email", "orgName", "postalAddress", "confirmPassword", "password", "userPIN", "roleName", "username", "city","file"}); } }