<%@page contentType="text/html;charset=UTF-8" pageEncoding="ISO-8859-1" session="true"
%><%@page errorPage="Exception.jsp"
%><%@page import="com.fujitsu.iflow.model.bpm.BPMSession"
%><%@page import="com.fujitsu.iflow.model.workflow.WorkItem"
%><%
    request.setCharacterEncoding("UTF-8");request.getParameterNames(); //Need dummy call for WL9.1
    BPMSession bps = (BPMSession) session.getAttribute("BPMSession");
    if (bps == null) {
        %><jsp:include page="PasswordPanel.jsp" flush="true"/><%
        return;
    }

    String documentName = request.getParameter("documentName");
    String taskId = request.getParameter("taskId");
    String formName = request.getParameter("Forms");
    if (formName == null)
        formName = "";
%>

<html>
<head><title>Interstage Business Process Manager | Checking in document</title></head>
<jsp:include page="StyleSheet.jsp" flush="true"/>
<script language="javascript" src="styles/clockscripts.js"></script>
<body class="bodyClass" onLoad="goforit();">
<jsp:include page="WorkItemHeader.jsp" flush="true"/> </br>
<br>
<table border="0" align="center" width="450" class="tableClass" cellpadding="4" cellspacing="1" bgcolor="#CCCCCC">
<tr class="headrow">
<td>Checkin : <%= documentName %></td>
</tr>
<%
    String formUrlParam = "&taskId=" + taskId;
    if (formName != null && formName.trim().length() > 0) {
        formUrlParam = formUrlParam + "&Forms="+formName;
    }
%>
    <form enctype="multipart/form-data" method="post"
        action='<%= response.encodeURL("CheckInAction.jsp?documentName=" + documentName + formUrlParam) %>' >
              <tr class="oddrow">
                  <td align="center"><br> Document File:  <input type="file" name="document" width="300"> <br><br></td>
              </tr>
            <tr class="evenrow">
              <td align="center" width="100%">
                      <input class="submitClass" type="submit" value="Check In">
      </td>
  </tr>
 </form>
</table>
</body>
</html>
