04-20-2011 03:10 AM
04-20-2011 04:24 AM
04-20-2011 06:54 AM
<%@ page import="upload.execute" %>
<jsp:useBean id="mybean" scope="page" class="upload.execute" />
<h1>Expense refund</h1>
<p>Please fill in the following fields as detailed as possible, as this will speed up the handling of your request.</p>
<table>
<tr>
<label>
<td>Employee name:</td>
<td><input type='text' name='Employeename' value='' />
<input type='hidden' name='Employeename_required' value='true' </td>
</label>
</tr>
<tr>
<label>
<td>Amount:</td>
<td><input type='number' name='Amount' value='' <input type='hidden' name='Amount_type' value='Integer' <input type='hidden' name='Amount_required' value='true' </td>
</label>
</tr>
<tr>
<label><td>Motivation:</td>
<td><input type='text' name='Motivation' value='' /></td>
</label>
</tr>
<tr>
<label><td>Upload:</td>
<td><input class="button" type="file" name="filedata" id="filedata"/>
</td>
</label>
</tr>
</table>
import java.util.HashMap;
import java.util.Map;
import org.activiti.engine.delegate.DelegateExecution;
import org.activiti.engine.delegate.JavaDelegate;
import org.apache.chemistry.opencmis.client.api.Session;
import org.apache.chemistry.opencmis.client.api.SessionFactory;
import org.apache.chemistry.opencmis.client.runtime.SessionFactoryImpl;
import org.apache.chemistry.opencmis.commons.SessionParameter;
import org.apache.chemistry.opencmis.commons.enums.BindingType;
public class upload implements JavaDelegate{
@Override
public void execute(DelegateExecution execution) throws Exception {
System.out.println("ušlo u metodu upload.execute");
// default factory implementation
SessionFactory factory = SessionFactoryImpl.newInstance();
Map<String, String> parameter = new HashMap<String, String>();
// user credentials
parameter.put(SessionParameter.USER, "admin");
parameter.put(SessionParameter.PASSWORD, "MCop92");
// connection settings
parameter.put(SessionParameter.ATOMPUB_URL, "http://localhost:8090/cmis/atom");
parameter.put(SessionParameter.BINDING_TYPE, BindingType.ATOMPUB.value());
parameter.put(SessionParameter.REPOSITORY_ID, "http://localhost:8090/alfresco/service/cmis/index.html");
// create session
Session session = factory.createSession(parameter);
}
}04-21-2011 04:30 AM
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.