I am working on an administrative JSP page that would allow me to Set-State on wtdocuments and/or epmdocuments. I am using the Search-Objects webject to search for and get the information about the documents but, I cannot find a webect that allows me to set-state. Would anyone know how this could be accomplished in a JSP page? Is this something I would need to create a java class to handle? I have limited exposure to java so I would like to stick with the JSP if possible. Here is the search page I have currently. I would like to have the button that is clicked submit the request to the server for the state change.
<%@page language="java" session="false"%>
<%@ taglib uri="http://www.ptc.com/infoengine/taglib/core" prefix="ie" %>
<html>
<head>
<title>WindSearch3.0</title>
<body>
</head>
<body>
<h2> Info*Engine JSP Test Page</h2>
<%
String where = request.getParameter ("where");
if ( where == null )
where = "()";
else if( where != null )
where= "(name='*" + where + "*')";
String wherevalue = request.getParameter ("where");
%>
<div class="main">
<h1>WindENG Search 3.0</h1>
<form action="aindex.jsp" method="POST">
Search: <input type="text" name="where" value="<%=wherevalue%>">
<input type="submit" value="Search">
<link rel="stylesheet" type="text/css" href="jsp.css">
<p><b>
Searching with where clause <%= where%>.
</b></p>
<ie:webject name="Search-Objects" type="OBJ">
<ie:param name="INSTANCE" data="com.ptc.net.HostID.Windchill"/>
<ie:param name="TYPE" data="wt.epm.EPMDocument"/>
<ie:param name="VERSION" data="LATEST"/>
<ie:param name="ITERATION" data="LATEST"/>
<ie:param name="WHERE" data="<%=where%>"/>
<ie:param name="WHERE" data="(state.state='Released')" />
<ie:param name="ATTRIBUTE" data="CADName,name,state.state,versionInfo.identifier.versionId,obid" delim=","/>
<ie:param name="GROUP_OUT" data="epmdocument"/>
</ie:webject>
<br>
<table border="1" cellpadding="2"
<tr>
<td>All<INPUT type=checkbox onclick="selectAll(this)" value=checkbox name=allcheckbox></td>
<td>CADname</td><td>name</td><td>state.state</td><td>versionInfo.identifer.verisonID</td><td>OBID</dt>
</tr>
<ie:forEach groupIn="epmdocument" groupOut="row">
<tr>
<td><input value=" " type="checkbox"></td>
<td><ie:getValue name="CADName"/></td>
<td><ie:getValue name="name"/></td>
<td><ie:getValue name="state.state"/></td>
<td><ie:getValue name="versionInfo.identifier.versionId"/></td>
<td><ie:getValue name="obid"/></td>
<td><input type="submit" value="In Work"></td>
<td><input type="submit" value="Preproduction"></td>
<td><input type="submit" value="Released"></td>
<td><input type="submit" value="Obsolete"></td>
</tr>
</ie:forEach>
</table>
</body>
</html>