Last change
on this file since 151 was
151,
checked in by vmipsl, 13 years ago
|
Import medias files and cleanup
|
-
Property svn:executable set to
*
|
File size:
1.1 KB
|
Line | |
---|
1 | package com.medias.megapoli.struts.actions; |
---|
2 | |
---|
3 | import java.io.IOException; |
---|
4 | |
---|
5 | import javax.servlet.ServletException; |
---|
6 | import javax.servlet.http.HttpServletRequest; |
---|
7 | import javax.servlet.http.HttpServletResponse; |
---|
8 | |
---|
9 | import org.apache.struts.action.Action; |
---|
10 | import org.apache.struts.action.ActionForm; |
---|
11 | import org.apache.struts.action.ActionForward; |
---|
12 | import org.apache.struts.action.ActionMapping; |
---|
13 | import com.medias.megapoli.struts.forms.MetadataForm; |
---|
14 | |
---|
15 | /** |
---|
16 | * @author pignot |
---|
17 | * |
---|
18 | * Action appelée au moment d'ajouter un contact dans le formulaire de métadonnées |
---|
19 | */ |
---|
20 | public class NewContactAction extends Action{ |
---|
21 | public ActionForward execute (ActionMapping mapping, ActionForm form, |
---|
22 | HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { |
---|
23 | |
---|
24 | if(this.isCancelled(request) || form == null) |
---|
25 | return mapping.findForward("index"); |
---|
26 | |
---|
27 | String target = "success"; |
---|
28 | MetadataForm mform = (MetadataForm)form; |
---|
29 | mform.getMetadata().getPres().addContact(); |
---|
30 | // mform.getMetadata().createXmlFile(); |
---|
31 | return mapping.findForward(target); |
---|
32 | } |
---|
33 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.