* Terms
- Prepared support for rename
* ObjectType.java
- Added ID for serialization
- Added RELATIONSHIP class constant
* struts.xml
- Added Relationship actions
* General
- Relationships between two terms can be added and listed
- Clean-up:
+ Renamed methods according to their purpose
+ Fixed RDM and corresponding properties/annotations
+ RelationShipTypeAction.java| /trunk/src/struts.xml |
|---|
| 8,11 → 8,11 |
| <!-- User environment --> |
| <package name="user" namespace="/user" extends="hibernate-default"> |
| <!-- Term management --> |
| <action name="termAdd"> |
| <action name="termAddForm"> |
| <result>/user/termAddForm.jsp</result> |
| </action> |
| <action name="termSave" method="save" |
| <action name="doTermAdd" method="add" |
| class="ch.ffhs.webE.action.TermAction"> |
| <result name="success">/user/termAdd.jsp</result> |
| <result name="error">/user/termAddForm.jsp</result> |
| 32,22 → 32,6 |
| class="ch.ffhs.webE.action.TermAction"> |
| <result name="success">/user/termAddForm.jsp</result> |
| </action> |
| <action name="relationshipAdd" method="add" |
| class="ch.ffhs.webE.action.RelationshipAction"> |
| <result>/user/relationshipAddForm.jsp</result> |
| </action> |
| <action name="relationshipSave" method="save" |
| class="ch.ffhs.webE.action.RelationshipAction"> |
| <result name="success">/user/relationshipAdd.jsp</result> |
| <result name="error">/user/relationshipAddForm.jsp</result> |
| </action> |
| <action name="relationshipList" method="list" |
| class="ch.ffhs.webE.action.RelationshipAction"> |
| <result name="success">/user/relationshipList.jsp</result> |
| </action> |
| </package> |
| <!-- Admin environment --> |
| /trunk/src/ch/ffhs/webE/dao/RelationshipDAOImpl.java |
|---|
| File deleted |
| \ No newline at end of file |
| Property changes: |
| Deleted: svn:mime-type |
| ## -1 +0,0 ## |
| -text/plain |
| \ No newline at end of property |
| Index: src/ch/ffhs/webE/dao/TermDAO.java |
| =================================================================== |
| --- src/ch/ffhs/webE/dao/TermDAO.java (revision 34) |
| +++ src/ch/ffhs/webE/dao/TermDAO.java (revision 33) |
| @@ -14,7 +14,7 @@ |
| /** |
| * @return |
| */ |
| - List<Term> getTerms(); |
| + List<Term> listTerm(); |
| /** |
| * Delete a term |
| /trunk/src/ch/ffhs/webE/dao/TermDAOImpl.java |
|---|
| 31,13 → 31,13 |
| Transaction transaction; |
| /** |
| * Returns a list of all terms |
| * Creates a list of all terms |
| * |
| * @return an ArrayList with all the terms - in case of a problem, an empty |
| * @return an ArrayList with all the users - in case of a problem, an empty |
| * list is returned |
| */ |
| @SuppressWarnings("unchecked") |
| public List<Term> getTerms() |
| public List<Term> listTerm() |
| { |
| List<Term> term = null; |
| try |
| /trunk/src/ch/ffhs/webE/dao/RelationshipTypeDAO.java |
|---|
| 6,11 → 6,11 |
| public interface RelationshipTypeDAO { |
| List<RelationshipType> getRelTypes(); |
| List<RelationshipType> listRelationshipTypes(); |
| boolean deleteRelationshipType(int relTypeID); |
| RelationshipType getRelTypeById(int relTypeID); |
| RelationshipType listRelTypeById(int relTypeID); |
| boolean saveOrUpdateRelType(RelationshipType relType); |
| } |
| /trunk/src/ch/ffhs/webE/dao/RelationshipTypeDAOImpl.java |
|---|
| 26,7 → 26,7 |
| */ |
| @SuppressWarnings("unchecked") |
| @Override |
| public List<RelationshipType> getRelTypes() |
| public List<RelationshipType> listRelationshipTypes() |
| { |
| List<RelationshipType> relType = null; |
| 100,7 → 100,7 |
| * Used to get a relationship type by ID |
| */ |
| @Override |
| public RelationshipType getRelTypeById(int relTypeID) |
| public RelationshipType listRelTypeById(int relTypeID) |
| { |
| RelationshipType relType = null; |
| try |
| /trunk/src/ch/ffhs/webE/domain/Relationship.java |
|---|
| 12,9 → 12,7 |
| import javax.persistence.OneToOne; |
| import javax.persistence.PrimaryKeyJoinColumn; |
| import javax.persistence.Table; |
| import javax.persistence.Transient; |
| import javax.persistence.UniqueConstraint; |
| import org.hibernate.annotations.GenericGenerator; |
| import org.hibernate.annotations.Parameter; |
| 23,29 → 21,24 |
| */ |
| @Entity |
| @Table(name = "relationship", catalog = "webengineering", uniqueConstraints = @UniqueConstraint(columnNames = { |
| "term_from", "term_to", "type_id" })) |
| public class Relationship implements java.io.Serializable |
| { |
| "term_from", "term_to", "type" })) |
| public class Relationship implements java.io.Serializable { |
| private int objectId; |
| @Transient |
| private Term termByTermTo; |
| private ObjectEntity object; |
| private Term termFrom; |
| private Term termTo; |
| private RelationshipType relationshipType; |
| private Term termByTermFrom; |
| public Relationship() |
| { |
| public Relationship() { |
| } |
| public Relationship(Term termByTermTo, ObjectEntity object, |
| RelationshipType relationshipType, Term termByTermFrom) |
| { |
| this.termTo = termByTermTo; |
| RelationshipType relationshipType, Term termByTermFrom) { |
| this.termByTermTo = termByTermTo; |
| this.object = object; |
| this.relationshipType = relationshipType; |
| this.termFrom = termByTermFrom; |
| this.termByTermFrom = termByTermFrom; |
| } |
| @GenericGenerator(name = "generator", strategy = "foreign", parameters = @Parameter(name = "property", value = "object")) |
| 52,62 → 45,52 |
| @Id |
| @GeneratedValue(generator = "generator") |
| @Column(name = "object_id", unique = true, nullable = false) |
| public int getObjectId() |
| { |
| public int getObjectId() { |
| return this.objectId; |
| } |
| public void setObjectId(int objectId) |
| { |
| public void setObjectId(int objectId) { |
| this.objectId = objectId; |
| } |
| @ManyToOne(fetch = FetchType.LAZY) |
| @JoinColumn(name = "term_to", nullable = false) |
| public Term getTermTo() |
| { |
| return this.termTo; |
| public Term getTermByTermTo() { |
| return this.termByTermTo; |
| } |
| public void setTermTo(Term termByTermTo) |
| { |
| this.termTo = termByTermTo; |
| public void setTermByTermTo(Term termByTermTo) { |
| this.termByTermTo = termByTermTo; |
| } |
| @OneToOne(fetch = FetchType.LAZY) |
| @PrimaryKeyJoinColumn |
| public ObjectEntity getObject() |
| { |
| public ObjectEntity getObject() { |
| return this.object; |
| } |
| public void setObject(ObjectEntity object) |
| { |
| public void setObject(ObjectEntity object) { |
| this.object = object; |
| } |
| @ManyToOne(fetch = FetchType.LAZY) |
| @JoinColumn(name = "type_id", nullable = false) |
| public RelationshipType getRelationshipType() |
| { |
| @JoinColumn(name = "type", nullable = false) |
| public RelationshipType getRelationshipType() { |
| return this.relationshipType; |
| } |
| public void setRelationshipType(RelationshipType relationshipType) |
| { |
| public void setRelationshipType(RelationshipType relationshipType) { |
| this.relationshipType = relationshipType; |
| } |
| @ManyToOne(fetch = FetchType.LAZY) |
| @JoinColumn(name = "term_from", nullable = false) |
| public Term getTermFrom() |
| { |
| return this.termFrom; |
| public Term getTermByTermFrom() { |
| return this.termByTermFrom; |
| } |
| public void setTermFrom(Term termByTermFrom) |
| { |
| this.termFrom = termByTermFrom; |
| public void setTermByTermFrom(Term termByTermFrom) { |
| this.termByTermFrom = termByTermFrom; |
| } |
| } |
| /trunk/src/ch/ffhs/webE/domain/Term.java |
|---|
| 45,12 → 45,6 |
| 0); |
| /** |
| * @var <code>true</code> if the term is edited/renamed, <code>false</code> |
| * otherwise |
| */ |
| public boolean edit = false; |
| /** |
| * No-op constructor |
| */ |
| public Term() |
| 136,7 → 130,7 |
| this.name = name; |
| } |
| @OneToMany(fetch = FetchType.LAZY, mappedBy = "termTo") |
| @OneToMany(fetch = FetchType.LAZY, mappedBy = "termByTermTo") |
| public Set<Relationship> getRelationshipsForTermTo() |
| { |
| return this.relationshipsForTermTo; |
| 153,7 → 147,7 |
| /** |
| * @return |
| */ |
| @OneToMany(fetch = FetchType.LAZY, mappedBy = "termFrom") |
| @OneToMany(fetch = FetchType.LAZY, mappedBy = "termByTermFrom") |
| public Set<Relationship> getRelationshipsForTermFrom() |
| { |
| return this.relationshipsForTermFrom; |
| /trunk/src/ch/ffhs/webE/domain/ObjectType.java |
|---|
| 21,21 → 21,11 |
| public class ObjectType implements java.io.Serializable |
| { |
| /** |
| * Version ID for serialization |
| */ |
| private static final long serialVersionUID = 1L; |
| /** |
| * ObjectEntity type ID for a term |
| */ |
| public static final int TERM = 1; |
| /** |
| * ObjectEntity type ID for a relationship |
| */ |
| public static final int RELATIONSHIP = 2; |
| private int id; |
| private int objectTypeId; |
| private String name; |
| private Set<ObjectEntity> objects = new HashSet<ObjectEntity>(0); |
| 43,28 → 33,28 |
| { |
| } |
| public ObjectType(int id) |
| public ObjectType(int objectTypeId) |
| { |
| this.id = id; |
| this.objectTypeId = objectTypeId; |
| } |
| public ObjectType(int id, String name, Set<ObjectEntity> objects) |
| public ObjectType(int objectTypeId, String name, Set<ObjectEntity> objects) |
| { |
| this.id = id; |
| this.objectTypeId = objectTypeId; |
| this.name = name; |
| this.objects = objects; |
| } |
| @Id |
| @Column(name = "id", unique = true, nullable = false) |
| public int getId() |
| @Column(name = "object_type_id", unique = true, nullable = false) |
| public int getObjectTypeId() |
| { |
| return this.id; |
| return this.objectTypeId; |
| } |
| public void setId(int objectTypeId) |
| public void setObjectTypeId(int objectTypeId) |
| { |
| this.id = objectTypeId; |
| this.objectTypeId = objectTypeId; |
| } |
| @Column(name = "name", unique = true, length = 45) |
| /trunk/src/ch/ffhs/webE/domain/RelationshipType.java |
|---|
| 2,15 → 2,13 |
| // Generated 19.12.2010 14:46:08 by Hibernate Tools 3.4.0.Beta1 |
| import static javax.persistence.GenerationType.IDENTITY; |
| import java.util.HashSet; |
| import java.util.Set; |
| import javax.persistence.Column; |
| import javax.persistence.Entity; |
| import javax.persistence.FetchType; |
| import javax.persistence.GeneratedValue; |
| import static javax.persistence.GenerationType.IDENTITY; |
| import javax.persistence.Id; |
| import javax.persistence.OneToMany; |
| import javax.persistence.Table; |
| 21,27 → 19,23 |
| */ |
| @Entity |
| @Table(name = "relationship_type", catalog = "webengineering", uniqueConstraints = @UniqueConstraint(columnNames = "name_from")) |
| public class RelationshipType implements java.io.Serializable |
| { |
| public class RelationshipType implements java.io.Serializable { |
| private Integer id; |
| private Integer relationshipId; |
| private String nameFrom; |
| private String nameTo; |
| private Set<Relationship> relationships = new HashSet<Relationship>(0); |
| public RelationshipType() |
| { |
| public RelationshipType() { |
| } |
| public RelationshipType(String nameFrom, String nameTo) |
| { |
| public RelationshipType(String nameFrom, String nameTo) { |
| this.nameFrom = nameFrom; |
| this.nameTo = nameTo; |
| } |
| public RelationshipType(String nameFrom, String nameTo, |
| Set<Relationship> relationships) |
| { |
| Set<Relationship> relationships) { |
| this.nameFrom = nameFrom; |
| this.nameTo = nameTo; |
| this.relationships = relationships; |
| 49,47 → 43,39 |
| @Id |
| @GeneratedValue(strategy = IDENTITY) |
| @Column(name = "id", unique = true, nullable = false) |
| public Integer getId() |
| { |
| return this.id; |
| @Column(name = "relationship_id", unique = true, nullable = false) |
| public Integer getRelationshipId() { |
| return this.relationshipId; |
| } |
| public void setId(Integer id) |
| { |
| this.id = id; |
| public void setRelationshipId(Integer relationshipId) { |
| this.relationshipId = relationshipId; |
| } |
| @Column(name = "name_from", unique = true, nullable = false) |
| public String getNameFrom() |
| { |
| public String getNameFrom() { |
| return this.nameFrom; |
| } |
| public void setNameFrom(String nameFrom) |
| { |
| public void setNameFrom(String nameFrom) { |
| this.nameFrom = nameFrom; |
| } |
| @Column(name = "name_to", nullable = false) |
| public String getNameTo() |
| { |
| public String getNameTo() { |
| return this.nameTo; |
| } |
| public void setNameTo(String nameTo) |
| { |
| public void setNameTo(String nameTo) { |
| this.nameTo = nameTo; |
| } |
| @OneToMany(fetch = FetchType.LAZY, mappedBy = "relationshipType") |
| public Set<Relationship> getRelationships() |
| { |
| public Set<Relationship> getRelationships() { |
| return this.relationships; |
| } |
| public void setRelationships(Set<Relationship> relationships) |
| { |
| public void setRelationships(Set<Relationship> relationships) { |
| this.relationships = relationships; |
| } |
| /trunk/src/ch/ffhs/webE/action/RelationshipAction.java |
|---|
| File deleted |
| Property changes: |
| Deleted: svn:mime-type |
| ## -1 +0,0 ## |
| -text/plain |
| \ No newline at end of property |
| Index: src/ch/ffhs/webE/action/TermAction.java |
| =================================================================== |
| --- src/ch/ffhs/webE/action/TermAction.java (revision 34) |
| +++ src/ch/ffhs/webE/action/TermAction.java (revision 33) |
| @@ -40,9 +40,6 @@ |
| */ |
| Map<String, Object> session = ActionContext.getContext().getSession(); |
| - private final HttpServletRequest request = (HttpServletRequest) ActionContext |
| - .getContext().get(StrutsStatics.HTTP_REQUEST); |
| - |
| /* |
| * (non-Javadoc) |
| * |
| @@ -58,18 +55,13 @@ |
| * |
| * @return {@link Action#SUCCESS} |
| */ |
| - public String save() |
| + public String add() |
| { |
| - if (!"1".equals(this.request.getParameter("edit"))) |
| - { |
| User user = this.userDAO.searchUsername((String) this.session |
| .get("username")); |
| - ObjectEntity obj = new ObjectEntity(user, |
| - new ObjectType(ObjectType.TERM), user, null, new Date(), false, |
| - this.term, null, null); |
| + ObjectEntity obj = new ObjectEntity(user, new ObjectType(ObjectType.TERM), |
| + user, null, new Date(), false, this.term, null, null); |
| this.term.setObject(obj); |
| - } |
| - |
| if (this.termDAO.saveOrUpdate(this.term)) |
| { |
| return Action.SUCCESS; |
| @@ -85,7 +77,7 @@ |
| */ |
| public String list() |
| { |
| - this.termList = this.termDAO.getTerms(); |
| + this.termList = this.termDAO.listTerm(); |
| return Action.SUCCESS; |
| } |
| @@ -102,7 +94,6 @@ |
| this.term = this.termDAO.getTermById(id); |
| if (this.term != null) |
| { |
| - this.term.edit = true; |
| return Action.SUCCESS; |
| } |
| } |
| @@ -117,10 +108,13 @@ |
| */ |
| private int getIdParameter() |
| { |
| + HttpServletRequest request = (HttpServletRequest) ActionContext |
| + .getContext().get(StrutsStatics.HTTP_REQUEST); |
| + |
| int id = -1; |
| try |
| { |
| - id = Integer.parseInt(this.request.getParameter("id")); //$NON-NLS-1$ |
| + id = Integer.parseInt(request.getParameter("id")); //$NON-NLS-1$ |
| } |
| catch (Exception e) |
| { |
| /trunk/src/ch/ffhs/webE/action/RelationshipTypeAction.java |
|---|
| 5,13 → 5,12 |
| import javax.servlet.http.HttpServletRequest; |
| import org.apache.struts2.StrutsStatics; |
| import org.apache.struts2.ServletActionContext; |
| import ch.ffhs.webE.dao.RelationshipTypeDAO; |
| import ch.ffhs.webE.dao.RelationshipTypeDAOImpl; |
| import ch.ffhs.webE.domain.RelationshipType; |
| import com.opensymphony.xwork2.Action; |
| import com.opensymphony.xwork2.ActionContext; |
| import com.opensymphony.xwork2.ActionSupport; |
| import com.opensymphony.xwork2.ModelDriven; |
| 24,38 → 23,38 |
| private RelationshipType relType = new RelationshipType(); |
| private List<RelationshipType> relTypeList = new ArrayList<RelationshipType>(); |
| private final RelationshipTypeDAO relTypeDAO = new RelationshipTypeDAOImpl(); |
| private RelationshipTypeDAO relTypeDAO = new RelationshipTypeDAOImpl(); |
| @Override |
| public RelationshipType getModel() |
| { |
| return this.relType; |
| return relType; |
| } |
| public String addOrUpdate() |
| { |
| this.relTypeDAO.saveOrUpdateRelType(this.relType); |
| return Action.SUCCESS; |
| relTypeDAO.saveOrUpdateRelType(relType); |
| return SUCCESS; |
| } |
| public String list() |
| { |
| this.relTypeList = this.relTypeDAO.getRelTypes(); |
| return Action.SUCCESS; |
| relTypeList = relTypeDAO.listRelationshipTypes(); |
| return SUCCESS; |
| } |
| public String edit() |
| { |
| int id = this.getIdParameter(); |
| int id = getIdParameter(); |
| if (id > 0) |
| { |
| this.relType = this.relTypeDAO.getRelTypeById(id); |
| return Action.SUCCESS; |
| relType = relTypeDAO.listRelTypeById(id); |
| return SUCCESS; |
| } |
| else |
| { |
| return Action.ERROR; |
| return ERROR; |
| } |
| } |
| 67,7 → 66,7 |
| private int getIdParameter() |
| { |
| HttpServletRequest request = (HttpServletRequest) ActionContext |
| .getContext().get(StrutsStatics.HTTP_REQUEST); |
| .getContext().get(ServletActionContext.HTTP_REQUEST); |
| int id = -1; |
| try |
| 90,17 → 89,17 |
| */ |
| public String delete() |
| { |
| int id = this.getIdParameter(); |
| int id = getIdParameter(); |
| // Check for malicious ID values |
| if (id > 0) |
| { |
| this.relTypeDAO.deleteRelationshipType(id); |
| return Action.SUCCESS; |
| relTypeDAO.deleteRelationshipType(id); |
| return SUCCESS; |
| } |
| else |
| { |
| return Action.ERROR; |
| return ERROR; |
| } |
| } |
| 110,7 → 109,7 |
| public RelationshipType getRelType() |
| { |
| return this.relType; |
| return relType; |
| } |
| public void setRelType(RelationshipType relType) |
| 120,7 → 119,7 |
| public List<RelationshipType> getRelTypeList() |
| { |
| return this.relTypeList; |
| return relTypeList; |
| } |
| public void setRelTypeList(List<RelationshipType> relTypeList) |
| /trunk/WebContent/user/relationshipList.jsp |
|---|
| File deleted |
| \ No newline at end of file |
| Property changes: |
| Deleted: svn:mime-type |
| ## -1 +0,0 ## |
| -text/plain |
| \ No newline at end of property |
| Index: WebContent/user/userAdd.jsp |
| =================================================================== |
| --- WebContent/user/userAdd.jsp (revision 34) |
| +++ WebContent/user/userAdd.jsp (nonexistent) |
| @@ -1,17 +0,0 @@ |
| -<html> |
| -<head> |
| -<title>User added</title> |
| -</head> |
| -<body> |
| - |
| - <h1> |
| - User hinzugefügt |
| - </h1> |
| - <p> |
| - Der Benutzer wurde hinzugefügt |
| - </p> |
| - <p> |
| - TODO: Weiterleitung!! |
| - </p> |
| -</body> |
| -</html> |
| \ No newline at end of file |
| /WebContent/user/userAdd.jsp |
|---|
| Property changes: |
| Deleted: svn:mime-type |
| ## -1 +0,0 ## |
| -text/plain |
| \ No newline at end of property |
| Index: WebContent/user/relationshipAdd.jsp |
| =================================================================== |
| --- WebContent/user/relationshipAdd.jsp (revision 34) |
| +++ WebContent/user/relationshipAdd.jsp (nonexistent) |
| @@ -1,17 +0,0 @@ |
| -<html> |
| -<head> |
| -<title>Relationship added</title> |
| -</head> |
| -<body> |
| - |
| - <h1> |
| - Beziehung hinzugefügt |
| - </h1> |
| - <p> |
| - Die Beziehung wurde hinzugefügt |
| - </p> |
| - <p> |
| - TODO: Weiterleitung!! |
| - </p> |
| -</body> |
| -</html> |
| \ No newline at end of file |
| /WebContent/user/relationshipAdd.jsp |
|---|
| Property changes: |
| Deleted: svn:mime-type |
| ## -1 +0,0 ## |
| -text/plain |
| \ No newline at end of property |
| Index: WebContent/user/relationshipAddForm.jsp |
| =================================================================== |
| --- WebContent/user/relationshipAddForm.jsp (revision 34) |
| +++ WebContent/user/relationshipAddForm.jsp (nonexistent) |
| @@ -1,18 +0,0 @@ |
| -<%@taglib uri="/struts-tags" prefix="s"%> |
| -<html> |
| - <head> |
| - <title>Beziehung hinzufügen</title> |
| - </head> |
| - <body> |
| - <h1> |
| - Beziehung hinzufügen |
| - </h1> |
| - <s:form action="relationshipSave"> |
| - <s:hidden name="relationship.objectId" /> |
| - <s:select name="term1" list="terms" listKey="objectId" listValue="name" label="Begriff 1"/> |
| - <s:select name="type" list="relationshipTypes" listKey="id" listValue="nameFrom" label="Beziehungstyp"/> |
| - <s:select name="term2" list="terms" listKey="objectId" listValue="name" label="Begriff 2"/> |
| - <s:submit value="Hinzufügen" /> |
| - </s:form> |
| - </body> |
| -</html> |
| /WebContent/user/relationshipAddForm.jsp |
|---|
| Property changes: |
| Deleted: svn:mime-type |
| ## -1 +0,0 ## |
| -text/plain |
| \ No newline at end of property |
| Index: WebContent/user/nav.jsp |
| =================================================================== |
| --- WebContent/user/nav.jsp (revision 34) |
| +++ WebContent/user/nav.jsp (revision 33) |
| @@ -7,14 +7,14 @@ |
| <li>Begriffe |
| <ul> |
| - <li><a href="termAdd">Hinzufügen</a></li> |
| - <li><a href="termList">Anzeigen<!-- Ändern, Löschen --></a></li> |
| + <li><a href="termAddForm">Hinzufügen</a></li> |
| + <li><a href="termList">Ändern, Löschen</a></li> |
| </ul></li> |
| <li>Beziehungen |
| <ul> |
| - <li><a href="relationshipAdd">Hinzufügen</a></li> |
| - <li><a href="relationshipList">Ändern, Löschen</a></li> |
| + <li><a href="">Hinzufügen</a></li> |
| + <li><a href="">Ändern, Löschen</a></li> |
| </ul></li> |
| <li>User-Settings |
| /trunk/WebContent/user/termAddForm.jsp |
|---|
| 7,11 → 7,7 |
| <h1> |
| Begriff hinzufügen |
| </h1> |
| <s:form action="termSave"> |
| <s:if test="term.edit"> |
| <s:hidden name="edit" value="1" /> |
| </s:if> |
| <s:hidden name="term.objectId" /> |
| <s:form action="doTermAdd"> |
| <s:textfield name="term.name" label="Name" /> |
| <s:if test="term.name != ''"> |
| <s:submit value="Umbenennen" /> |
| /trunk/WebContent/user/termList.jsp |
|---|
| 15,12 → 15,26 |
| </s:if> |
| <s:else> |
| <table> |
| <tr> |
| <th>Begriff</th> |
| </tr> |
| <s:iterator value="termList" status="stat"> |
| <tr> |
| <td><s:property value="name" /></td> |
| <td><s:url id="editURL" action="editTerm"> |
| <s:param name="id" value="%{objectId}"></s:param> |
| </s:url> <s:a href="%{editURL}"> |
| <img src="${contextPath}/resources/icons/page_white_edit.png" alt="edit" /> |
| </s:a></td> |
| <td><s:url id="deleteURL" action="deleteTerm"> |
| <s:param name="id" value="%{id}"></s:param> |
| </s:url> <s:a href="%{deleteURL}"> |
| <img src="${contextPath}/resources/icons/delete.png" alt="delete" /> |
| </s:a></td> |
| </tr> |
| </s:iterator> |
| </tbody> |
| </table> |
| </s:else> |
| </body> |
| /trunk/WebContent/admin/relTypeList.jsp |
|---|
| 25,13 → 25,13 |
| <td><s:property value="nameTo" /></td> |
| <td><s:url id="editURL" action="editRelType"> |
| <s:param name="id" value="%{id}"></s:param> |
| <s:param name="id" value="%{relationshipId}"></s:param> |
| </s:url> <s:a href="%{editURL}"> |
| <img src="${contextPath}/resources/icons/page_white_edit.png" alt="edit" /> |
| </s:a></td> |
| <td><s:url id="deleteURL" action="deleteRelType"> |
| <s:param name="id" value="%{id}"></s:param> |
| <s:param name="id" value="%{relationshipId}"></s:param> |
| </s:url> <s:a href="%{deleteURL}"> |
| <img src="${contextPath}/resources/icons/delete.png" alt="delete" /> |
| </s:a></td> |
| /trunk/WebContent/admin/relTypeAddForm.jsp |
|---|
| 8,11 → 8,11 |
| <h1>Beziehungstyp hinzufügen</h1> |
| <p>Bitte geben Sie die Daten für den Beziehungstypen ein</p> |
| <s:form action="doRelTypeAdd"> |
| <s:hidden name="relType.id" /> |
| <s:hidden name="relType.relationshipId" /> |
| <s:textfield name="relType.nameFrom" label="Name vom Ausgangspunkt (z.B. ist Vater von)" /> |
| <s:textfield name="relType.nameTo" label="Name vom Zielpunkt (z.B. ist Sohn von)" /> |
| <s:if test="relType.id != ''"> |
| <s:if test="relType.relationshipId != ''"> |
| <s:submit value="Edit" /> |
| </s:if><s:else> |
| <s:submit value="Add" /> |
| /trunk/docs/rdm.mwb |
|---|
| Cannot display: file marked as a binary type. |
| svn:mime-type = application/octet-stream |