<%@ page language="java" import="java.util.*,com.letousky.lottery.action.AuxiliaryData,com.letousky.exception.LotteryException" pageEncoding="UTF-8"%>
<%
	String Arrz = request.getParameter("Arrz");
	String ArrStrNum = request.getParameter("ArrStrNum");
	String ArrSp = request.getParameter("ArrSp");
	String ArrXh = request.getParameter("ArrXh");
	String FMCN = request.getParameter("FMCN");
	String gamecode = request.getParameter("gamecode");
	String[] params = {Arrz,ArrStrNum,ArrSp,ArrXh,FMCN,gamecode};
	try{
		List list = new AuxiliaryData().yhCommit(params,request,response);
		Object[] obj=list.toArray();
		String[] sn = (String[])obj[1];
		String[] bts = (String[])obj[0];
		out.print("{\"result\":\"0000\",\"price\":\""+sn[0]+"\",\"uid\":\""+sn[1]+"\",\"serialno\":\""+bts[0]+"\"}");
	}catch(LotteryException e){
		out.print("{\"result\":\""+e.getMessage()+"\"}");
	}
%>