}
if(user!=null&&user.getUsertype()==User.USER_TYPE_NORMAL) {
ApplicationContext ac = WebApplicationContextUtils.getWebApplicationContext(this.getServletContext());
IOrderProductDao orderProductDao = (IOrderProductDao) ac.getBean("orderProductDao");
if(orderProductDao.checkOrderProduct(Long.parseLong(productid), user.getId(), "0"))
{
out.write("2");
}else
{
out.write("1");