private void _jspService(
      javax.servlet.http.HttpServletRequest request,
      javax.servlet.http.HttpServletResponse response,
      com.caucho.jsp.PageContextImpl pageContext,
      javax.servlet.ServletContext application,
      javax.servlet.http.HttpSession session,
      TagState _jsp_state)
      throws Throwable {
    javax.servlet.jsp.JspWriter out = pageContext.getOut();
    final javax.el.ELContext _jsp_env = pageContext.getELContext();
    javax.servlet.ServletConfig config = getServletConfig();
    javax.servlet.Servlet page = this;
    javax.servlet.jsp.tagext.JspTag _jsp_parent_tag = null;
    com.caucho.jsp.PageContextImpl _jsp_parentContext = pageContext;
    response.setContentType("text/html");
    response.setCharacterEncoding("utf-8");

    out.write(_jsp_string0, 0, _jsp_string0.length);
    if (false == session.getAttribute("loggedin")) {
      response.sendRedirect("login.jsp");
    } else if (null == session.getAttribute("loggedin")) {
      response.sendRedirect("login.jsp");
    }
    out.write(_jsp_string1, 0, _jsp_string1.length);
  }
 public void _jspService(
     javax.servlet.http.HttpServletRequest request,
     javax.servlet.http.HttpServletResponse response)
     throws java.io.IOException, javax.servlet.ServletException {
   com.caucho.server.webapp.WebApp _jsp_application = _caucho_getApplication();
   javax.servlet.ServletContext application = _jsp_application;
   com.caucho.jsp.PageContextImpl pageContext =
       _jsp_application
           .getJspApplicationContext()
           .allocatePageContext(
               this, _jsp_application, request, response, null, null, 8192, true, false);
   javax.servlet.jsp.PageContext _jsp_parentContext = pageContext;
   javax.servlet.jsp.JspWriter out = pageContext.getOut();
   final javax.el.ELContext _jsp_env = pageContext.getELContext();
   javax.servlet.ServletConfig config = getServletConfig();
   javax.servlet.Servlet page = this;
   response.setContentType("text/html;charset=UTF-8");
   request.setCharacterEncoding("UTF-8");
   try {
     out.write(_jsp_string0, 0, _jsp_string0.length);
   } catch (java.lang.Throwable _jsp_e) {
     pageContext.handlePageException(_jsp_e);
   } finally {
     _jsp_application.getJspApplicationContext().freePageContext(pageContext);
   }
 }
  public void
  _jspService(javax.servlet.http.HttpServletRequest request,
              javax.servlet.http.HttpServletResponse response)
    throws java.io.IOException, javax.servlet.ServletException
  {
    javax.servlet.http.HttpSession session = request.getSession(true);
    com.caucho.server.webapp.WebApp _jsp_application = _caucho_getApplication();
    javax.servlet.ServletContext application = _jsp_application;
    com.caucho.jsp.PageContextImpl pageContext = _jsp_application.getJspApplicationContext().allocatePageContext(this, _jsp_application, request, response, null, session, 8192, true, false);
    javax.servlet.jsp.PageContext _jsp_parentContext = pageContext;
    javax.servlet.jsp.JspWriter out = pageContext.getOut();
    final javax.el.ELContext _jsp_env = pageContext.getELContext();
    javax.servlet.ServletConfig config = getServletConfig();
    javax.servlet.Servlet page = this;
    response.setContentType("text/html;charset=EUC-KR");
    request.setCharacterEncoding("EUC-KR");
    try {
      out.write(_jsp_string0, 0, _jsp_string0.length);
      
	String filename = request.getParameter("filename");
	String downname = request.getParameter("downname");
	FormDataDownload formData = new FormDataDownload(response, new File(filename), null, null);
	try
	{
		formData.download();
	}catch(FileNotFoundException e)
	{
		
      out.write(_jsp_string1, 0, _jsp_string1.length);
      out.print(( e ));
      out.write(_jsp_string2, 0, _jsp_string2.length);
      
		return;
	}catch(IOException e)
	{
		
      out.write(_jsp_string3, 0, _jsp_string3.length);
      out.print(( e ));
      out.write(_jsp_string4, 0, _jsp_string4.length);
      
		return;
	}catch(Exception e)
	{
		System.out.println("Exception Error~~" + e);
	}

      out.write('\n');
    } catch (java.lang.Throwable _jsp_e) {
      pageContext.handlePageException(_jsp_e);
    } finally {
      _jsp_application.getJspApplicationContext().freePageContext(pageContext);
    }
  }
  public void _jspService(
      javax.servlet.http.HttpServletRequest request,
      javax.servlet.http.HttpServletResponse response)
      throws java.io.IOException, javax.servlet.ServletException {
    javax.servlet.http.HttpSession session = request.getSession(true);
    com.caucho.server.webapp.WebApp _jsp_application = _caucho_getApplication();
    com.caucho.jsp.PageContextImpl pageContext =
        _jsp_pageManager.allocatePageContext(
            this, _jsp_application, request, response, null, session, 8192, true, false);

    TagState _jsp_state = null;

    try {
      _jspService(request, response, pageContext, _jsp_application, session, _jsp_state);
    } catch (java.lang.Throwable _jsp_e) {
      pageContext.handlePageException(_jsp_e);
    } finally {
      _jsp_pageManager.freePageContext(pageContext);
    }
  }
  public void _jspService(
      javax.servlet.http.HttpServletRequest request,
      javax.servlet.http.HttpServletResponse response)
      throws java.io.IOException, javax.servlet.ServletException {
    javax.servlet.http.HttpSession session = request.getSession(true);
    com.caucho.server.webapp.WebApp _jsp_application = _caucho_getApplication();
    javax.servlet.ServletContext application = _jsp_application;
    com.caucho.jsp.PageContextImpl pageContext =
        _jsp_application
            .getJspApplicationContext()
            .allocatePageContext(
                this, _jsp_application, request, response, null, session, 8192, true, false);
    javax.servlet.jsp.PageContext _jsp_parentContext = pageContext;
    javax.servlet.jsp.JspWriter out = pageContext.getOut();
    final javax.el.ELContext _jsp_env = pageContext.getELContext();
    javax.servlet.ServletConfig config = getServletConfig();
    javax.servlet.Servlet page = this;
    response.setContentType("text/html");
    try {

      response.setHeader("Pragma", "no-cache"); // HTTP 1.0
      response.setDateHeader("Expires", 0);
      response.setHeader("Cache-Control", "no-cache"); // HTTP 1.1

      String scmid = "";
      String scmnm = "";
      String usertype = "";
      String usergroup = "";
      // String scmsubids = "";
      String _adminid = "";
      String _adminname = "";
      String _admingroup = "";
      String _apessid = "";
      String _apessname = "";

      try {
        scmid = (String) session.getAttribute("scmid");
        _adminid = (String) session.getAttribute("adminid");

        if ((scmid == null || scmid.length() == 0 || scmid.equals("null"))
            && (_adminid == null || _adminid.length() == 0 || _adminid.equals("null"))) {
          response.sendRedirect("/login_first.html");
          return;
        }

        _adminname = (String) session.getAttribute("adminname");

        _apessid = (String) session.getAttribute("apessid");
        _apessname = (String) session.getAttribute("apessname");

        scmnm = (String) session.getAttribute("scmnm");

        usertype = (String) session.getAttribute("usertype");
        if (usertype == null) usertype = "";

        usergroup = (String) session.getAttribute("usergroup");
        if (usergroup == null) usergroup = "";

        // scmsubids = (String) session.getAttribute("scmsubids");
        // session.setMaxInactiveInterval(60*60);

      } catch (Exception e) {
        response.sendRedirect("/login_first.html");
        return;
      }

      out.write('\n');

      String id = request.getParameter("id");

      out.write(_jsp_string0, 0, _jsp_string0.length);
      out.print((id));
      out.write(_jsp_string1, 0, _jsp_string1.length);
      out.print((id));
      out.write(_jsp_string2, 0, _jsp_string2.length);
    } catch (java.lang.Throwable _jsp_e) {
      pageContext.handlePageException(_jsp_e);
    } finally {
      _jsp_application.getJspApplicationContext().freePageContext(pageContext);
    }
  }
  private void _jspService(
      javax.servlet.http.HttpServletRequest request,
      javax.servlet.http.HttpServletResponse response,
      com.caucho.jsp.PageContextImpl pageContext,
      javax.servlet.ServletContext application,
      javax.servlet.http.HttpSession session,
      TagState _jsp_state)
      throws Throwable {
    javax.servlet.jsp.JspWriter out = pageContext.getOut();
    final javax.el.ELContext _jsp_env = pageContext.getELContext();
    javax.servlet.ServletConfig config = getServletConfig();
    javax.servlet.Servlet page = this;
    javax.servlet.jsp.tagext.JspTag _jsp_parent_tag = null;
    com.caucho.jsp.PageContextImpl _jsp_parentContext = pageContext;
    response.setContentType("text/html");
    response.setCharacterEncoding("utf-8");

    out.write(_jsp_string0, 0, _jsp_string0.length);
    CP_Classes.EthnicGroup ethnic;
    synchronized (pageContext.getSession()) {
      ethnic = (CP_Classes.EthnicGroup) pageContext.getSession().getAttribute("ethnic");
      if (ethnic == null) {
        ethnic = new CP_Classes.EthnicGroup();
        pageContext.getSession().setAttribute("ethnic", ethnic);
      }
    }
    out.write(_jsp_string1, 0, _jsp_string1.length);
    CP_Classes.Login logchk;
    synchronized (pageContext.getSession()) {
      logchk = (CP_Classes.Login) pageContext.getSession().getAttribute("logchk");
      if (logchk == null) {
        logchk = new CP_Classes.Login();
        pageContext.getSession().setAttribute("logchk", logchk);
      }
    }
    out.write(_jsp_string1, 0, _jsp_string1.length);
    CP_Classes.Translate trans;
    synchronized (pageContext.getSession()) {
      trans = (CP_Classes.Translate) pageContext.getSession().getAttribute("trans");
      if (trans == null) {
        trans = new CP_Classes.Translate();
        pageContext.getSession().setAttribute("trans", trans);
      }
    }
    out.write(_jsp_string1, 0, _jsp_string1.length);
    // added to check whether organisation is a consulting company
    // Mark Oei 09 Mar 2010
    out.write(_jsp_string1, 0, _jsp_string1.length);
    CP_Classes.Organization Org;
    synchronized (pageContext.getSession()) {
      Org = (CP_Classes.Organization) pageContext.getSession().getAttribute("Org");
      if (Org == null) {
        Org = new CP_Classes.Organization();
        pageContext.getSession().setAttribute("Org", Org);
      }
    }
    out.write(_jsp_string1, 0, _jsp_string1.length);
    CP_Classes.Create_Edit_Survey CE_Survey;
    synchronized (pageContext.getSession()) {
      CE_Survey =
          (CP_Classes.Create_Edit_Survey) pageContext.getSession().getAttribute("CE_Survey");
      if (CE_Survey == null) {
        CE_Survey = new CP_Classes.Create_Edit_Survey();
        pageContext.getSession().setAttribute("CE_Survey", CE_Survey);
      }
    }
    out.write(_jsp_string2, 0, _jsp_string2.length);
    // by lydia Date 05/09/2008 Fix jsp file to support Thai language
    out.write(_jsp_string3, 0, _jsp_string3.length);
    out.print((trans.tslt("Delete Ethnic Group")));
    out.write(_jsp_string4, 0, _jsp_string4.length);
    out.print((trans.tslt("Edit Ethnic Group")));
    out.write(_jsp_string5, 0, _jsp_string5.length);
    out.print((trans.tslt("Please enter Ethnic Group")));
    out.write(_jsp_string6, 0, _jsp_string6.length);
    out.print((trans.tslt("Add Ethnic Group")));
    out.write(_jsp_string7, 0, _jsp_string7.length);
    out.print((trans.tslt("Please enter Ethnic Group")));
    out.write(_jsp_string8, 0, _jsp_string8.length);

    String username = (String) session.getAttribute("username");

    if (!logchk.isUsable(username)) {
      out.write(_jsp_string9, 0, _jsp_string9.length);
    } else {

      if (request.getParameter("proceed") != null) {
        int PKOrg = new Integer(request.getParameter("proceed")).intValue();
        logchk.setOrg(PKOrg);
      }

      if (request.getParameter("Delete") != null) {

        int Ethnic_ID = new Integer(request.getParameter("ethnic_ID")).intValue();
        boolean bIsDeleted = ethnic.deleteRecord(Ethnic_ID, logchk.getPKUser());

        if (bIsDeleted) {

          out.write(_jsp_string10, 0, _jsp_string10.length);
        }
      }

      if (request.getParameter("Edit") != null) {
        int Ethnic_ID = new Integer(request.getParameter("ethnic_ID")).intValue();

        String txtEthnic = request.getParameter("txtEthnic");
        boolean bIsEdited =
            ethnic.editRecord(Ethnic_ID, txtEthnic, logchk.getOrg(), logchk.getPKUser());

        if (bIsEdited) {

          out.write(_jsp_string11, 0, _jsp_string11.length);

        } else {

          out.write(_jsp_string12, 0, _jsp_string12.length);
        }
      }

      if (request.getParameter("Add") != null) {

        String txtEthnic = request.getParameter("txtEthnic");

        boolean bExist = ethnic.existRecord(txtEthnic, logchk.getOrg());

        if (!bExist) {
          boolean bIsAdded = ethnic.addRecord(txtEthnic, logchk.getOrg(), logchk.getPKUser());

          if (bIsAdded) {

            out.write(_jsp_string13, 0, _jsp_string13.length);
          }
        } else {

          out.write(_jsp_string14, 0, _jsp_string14.length);
        }
      }

      out.write(_jsp_string15, 0, _jsp_string15.length);
      out.print((trans.tslt("Ethnic Group")));
      out.write(_jsp_string16, 0, _jsp_string16.length);
      out.print((trans.tslt("To Add, click on the Add button")));
      out.write(_jsp_string17, 0, _jsp_string17.length);
      out.print(
          (trans.tslt("To Edit, click on the relevant radio button and click on the Edit button")));
      out.write(_jsp_string17, 0, _jsp_string17.length);
      out.print(
          (trans.tslt(
              "To Delete, click on the relevant radio button and click on the Delete button")));
      out.write(_jsp_string18, 0, _jsp_string18.length);
      out.print((trans.tslt("Organisation")));
      out.write(_jsp_string19, 0, _jsp_string19.length);

      // Added to check whether organisation is also a consulting company
      // if yes, will display a dropdown list of organisation managed by this company
      // else, it will display the current organisation only
      // Mark Oei 09 Mar 2010
      String[] UserDetail = new String[14];
      UserDetail = CE_Survey.getUserDetail(logchk.getPKUser());
      boolean isConsulting = true;
      isConsulting =
          Org.isConsulting(UserDetail[10]); // check whether organisation is a consulting company
      if (isConsulting) {
        Vector vOrg = logchk.getOrgList(logchk.getCompany());

        for (int i = 0; i < vOrg.size(); i++) {
          votblOrganization vo = (votblOrganization) vOrg.elementAt(i);
          int PKOrg = vo.getPKOrganization();
          String OrgName = vo.getOrganizationName();

          if (logchk.getOrg() == PKOrg) {
            out.write(_jsp_string20, 0, _jsp_string20.length);
            out.print((PKOrg));
            out.write(_jsp_string21, 0, _jsp_string21.length);
            out.print((OrgName));
            out.write(_jsp_string22, 0, _jsp_string22.length);
          } else {
            out.write(_jsp_string20, 0, _jsp_string20.length);
            out.print((PKOrg));
            out.write('>');
            out.print((OrgName));
            out.write(_jsp_string22, 0, _jsp_string22.length);
          }
        }
      } else {
        out.write(_jsp_string23, 0, _jsp_string23.length);
        out.print((logchk.getSelfOrg()));
        out.write('>');
        out.print((UserDetail[10]));
        out.write(_jsp_string24, 0, _jsp_string24.length);
      } // End of isConsulting
      out.write(_jsp_string25, 0, _jsp_string25.length);
      out.print((trans.tslt("Ethnic Group")));
      out.write(_jsp_string26, 0, _jsp_string26.length);

      /** ****************** Edited by James 17 Oct 2007 ********************** */
      Vector v = ethnic.getAllEthnics(logchk.getOrg());

      for (int i = 0; i < v.size(); i++) {
        voEthnic vo = (voEthnic) v.elementAt(i);

        int ethnic_ID = vo.getPKEthnic();
        String ethnic_Desc = vo.getEthnicDesc();

        out.write(_jsp_string27, 0, _jsp_string27.length);
        out.print((ethnic_ID));
        out.write(_jsp_string28, 0, _jsp_string28.length);
        out.print((ethnic_Desc));
        out.write(_jsp_string29, 0, _jsp_string29.length);
        out.print((ethnic_Desc));
        out.write(_jsp_string30, 0, _jsp_string30.length);
      }

      out.write(_jsp_string31, 0, _jsp_string31.length);
      out.print((trans.tslt("Ethnic Group")));
      out.write(_jsp_string32, 0, _jsp_string32.length);
      out.print((trans.tslt("Add")));
      out.write(_jsp_string33, 0, _jsp_string33.length);
      out.print((trans.tslt("Edit")));
      out.write(_jsp_string34, 0, _jsp_string34.length);
      out.print((trans.tslt("Delete")));
      out.write(_jsp_string35, 0, _jsp_string35.length);
    }
    out.write(_jsp_string36, 0, _jsp_string36.length);
    // by lydia Date 05/09/2008 Fix jsp file to support Thai language
    out.write(_jsp_string37, 0, _jsp_string37.length);

    Calendar c = Calendar.getInstance();
    int year = c.get(Calendar.YEAR);

    out.write(_jsp_string38, 0, _jsp_string38.length);
    // Denise 05/01/2010 update new email address
    out.write(_jsp_string39, 0, _jsp_string39.length);
    out.print((year));
    out.write(_jsp_string40, 0, _jsp_string40.length);
  }
  public void _jspService(
      javax.servlet.http.HttpServletRequest request,
      javax.servlet.http.HttpServletResponse response)
      throws java.io.IOException, javax.servlet.ServletException {
    javax.servlet.http.HttpSession session = request.getSession(true);
    com.caucho.server.webapp.Application _jsp_application = _caucho_getApplication();
    javax.servlet.ServletContext application = _jsp_application;
    com.caucho.jsp.PageContextImpl pageContext =
        com.caucho.jsp.QJspFactory.allocatePageContext(
            this, _jsp_application, request, response, "/error.jsp", session, 8192, true);
    javax.servlet.jsp.JspWriter out = pageContext.getOut();
    javax.servlet.ServletConfig config = getServletConfig();
    javax.servlet.Servlet page = this;
    response.setContentType("text/html");
    try {
      out.write(_jsp_string0, 0, _jsp_string0.length);
      out.print(((String) session.getAttribute("user")));
      out.write(_jsp_string1, 0, _jsp_string1.length);
      out.print(((String) session.getAttribute("db")));
      out.write(_jsp_string2, 0, _jsp_string2.length);

      // get all tables in the database
      ConDB dbcon = (ConDB) session.getAttribute("dbcon");
      Connection conn = dbcon.get();
      int total_rec = 0;
      int total_table = 0;
      String sql = "show tables";
      PreparedStatement pstm = null;
      ResultSet rs = null;
      try {
        pstm = conn.prepareStatement(sql);
        rs = pstm.executeQuery();
      } catch (SQLException e) {
        out.println(e);
      }

      // count the records of each table
      while (rs.next()) {
        String curr_tb = rs.getString(1);
        int curr_rec = 0;
        PreparedStatement pstm_rec = null;
        ResultSet rs_rec = null;
        sql = "select count(*) from " + curr_tb;

        try {
          pstm_rec = conn.prepareStatement(sql);
          rs_rec = pstm_rec.executeQuery();
        } catch (SQLException e) {
          out.println(e);
        }

        try {
          if (rs_rec.next()) {
            curr_rec = rs_rec.getInt(1);
            total_rec += curr_rec;
          }
        } catch (SQLException e) {
          out.println(e.getErrorCode() + "---" + e.getSQLState());
        }

        total_table++;

        out.write(_jsp_string3, 0, _jsp_string3.length);
        out.print((total_table & 1));
        out.write(_jsp_string4, 0, _jsp_string4.length);
        out.print((curr_tb));
        out.write(_jsp_string5, 0, _jsp_string5.length);
        out.print((curr_tb));
        out.write(_jsp_string6, 0, _jsp_string6.length);
        out.print((curr_tb));
        out.write(_jsp_string7, 0, _jsp_string7.length);
        out.print((curr_tb));
        out.write(_jsp_string8, 0, _jsp_string8.length);
        out.print((curr_tb));
        out.write(_jsp_string9, 0, _jsp_string9.length);
        out.print((curr_rec));
        out.write(_jsp_string10, 0, _jsp_string10.length);
      }

      out.write(_jsp_string11, 0, _jsp_string11.length);
      out.print((total_table));
      out.write(_jsp_string12, 0, _jsp_string12.length);
      out.print((total_rec));
      out.write(_jsp_string13, 0, _jsp_string13.length);
      out.print((session.getAttribute("db")));
      out.write(_jsp_string14, 0, _jsp_string14.length);
    } catch (java.lang.Throwable _jsp_e) {
      pageContext.handlePageException(_jsp_e);
    } finally {
      com.caucho.jsp.QJspFactory.freePageContext(pageContext);
    }
  }
  private void _jspService(
      javax.servlet.http.HttpServletRequest request,
      javax.servlet.http.HttpServletResponse response,
      com.caucho.jsp.PageContextImpl pageContext,
      javax.servlet.ServletContext application,
      javax.servlet.http.HttpSession session,
      TagState _jsp_state)
      throws Throwable {
    javax.servlet.jsp.JspWriter out = pageContext.getOut();
    final javax.el.ELContext _jsp_env = pageContext.getELContext();
    javax.servlet.ServletConfig config = getServletConfig();
    javax.servlet.Servlet page = this;
    javax.servlet.jsp.tagext.JspTag _jsp_parent_tag = null;
    com.caucho.jsp.PageContextImpl _jsp_parentContext = pageContext;
    response.setContentType("text/html");
    response.setCharacterEncoding("utf-8");

    out.write(_jsp_string0, 0, _jsp_string0.length);
    CP_Classes.Login logchk;
    synchronized (pageContext.getSession()) {
      logchk = (CP_Classes.Login) pageContext.getSession().getAttribute("logchk");
      if (logchk == null) {
        logchk = new CP_Classes.Login();
        pageContext.getSession().setAttribute("logchk", logchk);
      }
    }
    out.write(_jsp_string1, 0, _jsp_string1.length);
    CP_Classes.Create_Edit_Survey CE_Survey;
    synchronized (pageContext.getSession()) {
      CE_Survey =
          (CP_Classes.Create_Edit_Survey) pageContext.getSession().getAttribute("CE_Survey");
      if (CE_Survey == null) {
        CE_Survey = new CP_Classes.Create_Edit_Survey();
        pageContext.getSession().setAttribute("CE_Survey", CE_Survey);
      }
    }
    out.write(_jsp_string2, 0, _jsp_string2.length);
    CP_Classes.Translate trans;
    synchronized (pageContext.getSession()) {
      trans = (CP_Classes.Translate) pageContext.getSession().getAttribute("trans");
      if (trans == null) {
        trans = new CP_Classes.Translate();
        pageContext.getSession().setAttribute("trans", trans);
      }
    }
    out.write(_jsp_string2, 0, _jsp_string2.length);
    CP_Classes.RatingTask RT;
    synchronized (pageContext.getSession()) {
      RT = (CP_Classes.RatingTask) pageContext.getSession().getAttribute("RT");
      if (RT == null) {
        RT = new CP_Classes.RatingTask();
        pageContext.getSession().setAttribute("RT", RT);
      }
    }
    out.write(_jsp_string2, 0, _jsp_string2.length);
    CP_Classes.RatingScale RS;
    synchronized (pageContext.getSession()) {
      RS = (CP_Classes.RatingScale) pageContext.getSession().getAttribute("RS");
      if (RS == null) {
        RS = new CP_Classes.RatingScale();
        pageContext.getSession().setAttribute("RS", RS);
      }
    }
    out.write(_jsp_string2, 0, _jsp_string2.length);
    CP_Classes.Purpose PRP;
    synchronized (pageContext.getSession()) {
      PRP = (CP_Classes.Purpose) pageContext.getSession().getAttribute("PRP");
      if (PRP == null) {
        PRP = new CP_Classes.Purpose();
        pageContext.getSession().setAttribute("PRP", PRP);
      }
    }
    out.write(_jsp_string2, 0, _jsp_string2.length);
    CP_Classes.SurveyRating SVR;
    synchronized (pageContext.getSession()) {
      SVR = (CP_Classes.SurveyRating) pageContext.getSession().getAttribute("SVR");
      if (SVR == null) {
        SVR = new CP_Classes.SurveyRating();
        pageContext.getSession().setAttribute("SVR", SVR);
      }
    }
    out.write(_jsp_string3, 0, _jsp_string3.length);
    // by lydia Date 05/09/2008 Fix jsp file to support Thai language
    out.write(_jsp_string4, 0, _jsp_string4.length);
    out.print((trans.tslt("Please choose a rating task")));
    out.write(_jsp_string5, 0, _jsp_string5.length);

    response.setHeader("Pragma", "no-cache");
    response.setHeader("Cache-Control", "no-cache");
    response.setDateHeader("expires", 0);

    String username = (String) session.getAttribute("username");
    if (!logchk.isUsable(username)) {
      out.write(_jsp_string6, 0, _jsp_string6.length);
    } else {

      if (request.getParameter("purpose") != null) {
        int var1 = new Integer(request.getParameter("purpose")).intValue();
        CE_Survey.setPurpose(var1);

        System.out.println("Purpose ID" + var1);
      } else {
        // Edited by Eric Lu 22/5/08
        // Resets purpose if first time accessing this page
        CE_Survey.setPurpose(0);
      }
      if (request.getParameter("add") != null) {
        String rating = "";
        String scale = "";
        boolean RequiredChosen = false;
        String[] chkSelect = new String[10];
        String[] ScaleDesc = new String[10];
        String[] radioSelect = new String[10];

        int SurveyID = CE_Survey.getSurvey_ID();
        ScaleDesc = request.getParameterValues("selScaleDesc");
        chkSelect = request.getParameterValues("chkRat");
        radioSelect = request.getParameterValues("radioRat");
        int count = 0; // count shifted, Mark Oei 16 April 2010

        /*------------------------------------------------- for checkbox ------------------------------------------------*/

        // Changed by Ha 28/05/09 to pop out message when action is done successfully
        if (chkSelect != null) {
          boolean added = false;
          count = 0; // change to declare variable outside if statement, Mark Oei 16 April 2010
          for (int i = 0; i < chkSelect.length; i++) {
            rating = chkSelect[i];

            if (rating != null) {

              String RatName = " ";
              RatName = RT.getRatingTask(Integer.parseInt(rating));

              ScaleDesc = new String[10];
              ScaleDesc = request.getParameterValues("selScaleDesc" + rating);
              for (int j = 0; j < ScaleDesc.length; j++) {
                scale = ScaleDesc[j];
                CE_Survey.editPurpose(SurveyID, CE_Survey.getPurpose());
                added = CE_Survey.addRating(SurveyID, scale, rating, RatName);
                if (added) count++;
              }
            }
          }
          // Added to insert default values into database when rating tasks are added
          // Mark Oei 16 April 2010
          int lLimit = 0;
          int uLimit = 0;
          int scaleRange = CE_Survey.getRatScale();

          int taskCount = (Integer) session.getAttribute("taskCount") + count;

          if ((taskCount == 1 && Integer.parseInt(rating) == 1)) {
            lLimit = scaleRange / 2 - 1;
            uLimit = scaleRange / 2 + 1;
          } else {
            lLimit = -1;
            uLimit = 1;
          }
          boolean isSuccessful = CE_Survey.setMinPassScore(SurveyID, lLimit, uLimit);
          if (isSuccessful) {
            System.out.println(
                "Default Limits " + lLimit + ", " + uLimit + " has been inserted successfully");
          }
          if (count == chkSelect.length) {
            out.write(_jsp_string7, 0, _jsp_string7.length);
          }
        }

        /*-------------------------------------------------------- for radiobox ----------------------------------------------*/

        rating = "";

        if (radioSelect != null) {
          for (int i = 0; i < radioSelect.length; i++) {
            rating = radioSelect[i];

            if (rating != null) {

              String RatName = RT.getRatingTask(Integer.parseInt(rating));

              ScaleDesc = new String[10];
              ScaleDesc = request.getParameterValues("selScaleDesc" + rating);
              for (int j = 0; j < ScaleDesc.length; j++) {
                scale = ScaleDesc[j];
                CE_Survey.addRating(SurveyID, scale, rating, RatName);
              }
            }
          }
        }

        out.write(_jsp_string8, 0, _jsp_string8.length);
      }

      out.write(_jsp_string9, 0, _jsp_string9.length);
      out.print((trans.tslt("To Select Rating Task, checked on the provided boxes under Select")));
      out.write(_jsp_string10, 0, _jsp_string10.length);
      out.print((trans.tslt("Purpose of Survey")));
      out.write(_jsp_string11, 0, _jsp_string11.length);
      out.print((trans.tslt("Choose one")));
      out.write(_jsp_string12, 0, _jsp_string12.length);

      Vector v = PRP.getAllPurpose();

      for (int i = 0; i < v.size(); i++) {
        votblPurpose vo = (votblPurpose) v.elementAt(i);
        int PurposeID = vo.getPurposeID();
        String PurposeName = vo.getPurposeName();

        if (CE_Survey.getPurpose() == PurposeID) {

          out.write(_jsp_string13, 0, _jsp_string13.length);
          out.print((PurposeID));
          out.write(_jsp_string14, 0, _jsp_string14.length);
          out.print((PurposeName));
          out.write(_jsp_string12, 0, _jsp_string12.length);
        } else {

          out.write(_jsp_string15, 0, _jsp_string15.length);
          out.print((PurposeID));
          out.write('>');
          out.print((PurposeName));
          out.write(_jsp_string12, 0, _jsp_string12.length);
        }
      }
      out.write(_jsp_string16, 0, _jsp_string16.length);
      out.print((trans.tslt("Scale Range Chosen")));
      out.write(_jsp_string17, 0, _jsp_string17.length);
      out.print((CE_Survey.getRatScale()));
      out.write(_jsp_string18, 0, _jsp_string18.length);
      out.print((trans.tslt("Rating Task")));
      out.write(_jsp_string19, 0, _jsp_string19.length);
      out.print((trans.tslt("Select")));
      out.write(_jsp_string20, 0, _jsp_string20.length);
      out.print((trans.tslt("Rating Task")));
      out.write(_jsp_string21, 0, _jsp_string21.length);
      out.print((trans.tslt("Scale Description")));
      out.write(_jsp_string22, 0, _jsp_string22.length);

      String query2 = "";
      boolean dunAddPR = false;

      int iRatingTaskID = SVR.getRatingTaskID(CE_Survey.getSurvey_ID());
      if (iRatingTaskID != 0) dunAddPR = true;

      boolean anyRecord = false;
      boolean anyscale = false;

      Vector vRT = RT.getRatingTask(CE_Survey.getSurvey_ID(), dunAddPR, CE_Survey.getPurpose());

      for (int i = 0; i < vRT.size(); i++) {
        anyRecord = true;
        votblRatingTask vo = (votblRatingTask) vRT.elementAt(i);
        int RatID = vo.getRatingTaskID();
        String RatName = vo.getRatingTask();
        String ScaleType = vo.getScaleType();

        out.write(_jsp_string23, 0, _jsp_string23.length);
        if (CE_Survey.getPurpose() != 9) {
          out.write(_jsp_string24, 0, _jsp_string24.length);
          out.print((RatID));
          out.write(_jsp_string25, 0, _jsp_string25.length);
        } else {
          if (RatID != 2 && RatID != 3) {
            out.write(_jsp_string26, 0, _jsp_string26.length);
            out.print((RatID));
            out.write(_jsp_string27, 0, _jsp_string27.length);
          } else {
            out.write(_jsp_string28, 0, _jsp_string28.length);
            out.print((RatID));
            out.write(_jsp_string29, 0, _jsp_string29.length);
          }
        }
        out.write(_jsp_string30, 0, _jsp_string30.length);
        out.print((RatName));
        out.write(_jsp_string31, 0, _jsp_string31.length);
        out.print(("selScaleDesc" + RatID));
        out.write(_jsp_string32, 0, _jsp_string32.length);

        Vector vScale =
            RS.getRatingScale(CE_Survey.getRatScale(), ScaleType, CE_Survey.get_survOrg());

        for (int j = 0; j < vScale.size(); j++) {
          votblScale voS = (votblScale) vScale.elementAt(j);
          anyscale = true;
          int ScaleID = voS.getScaleID();
          String ScaleDesc = voS.getScaleDescription();

          out.write(_jsp_string33, 0, _jsp_string33.length);
          out.print((ScaleID));
          out.write('>');
          out.print((ScaleDesc));
          out.write(_jsp_string34, 0, _jsp_string34.length);
        }
        out.write(_jsp_string35, 0, _jsp_string35.length);
      }

      if (anyRecord == false && CE_Survey.getPurpose() != 0) {

        out.write(_jsp_string36, 0, _jsp_string36.length);
        out.print(
            (trans.tslt("All the rating tasks under this purpose of survey have been added")));
        out.write(_jsp_string37, 0, _jsp_string37.length);
      }
      out.write(_jsp_string38, 0, _jsp_string38.length);
      if (anyRecord && anyscale) {

        out.write(_jsp_string39, 0, _jsp_string39.length);
        out.print((trans.tslt("Add")));
        out.write(_jsp_string40, 0, _jsp_string40.length);
      }
      out.write(_jsp_string41, 0, _jsp_string41.length);
      out.print((trans.tslt("Close")));
      out.write(_jsp_string42, 0, _jsp_string42.length);
    }
    out.write(_jsp_string43, 0, _jsp_string43.length);
  }
  private void _jspService(
      javax.servlet.http.HttpServletRequest request,
      javax.servlet.http.HttpServletResponse response,
      com.caucho.jsp.PageContextImpl pageContext,
      javax.servlet.ServletContext application,
      javax.servlet.http.HttpSession session,
      TagState _jsp_state)
      throws Throwable {
    javax.servlet.jsp.JspWriter out = pageContext.getOut();
    final javax.el.ELContext _jsp_env = pageContext.getELContext();
    javax.servlet.ServletConfig config = getServletConfig();
    javax.servlet.Servlet page = this;
    javax.servlet.jsp.tagext.JspTag _jsp_parent_tag = null;
    com.caucho.jsp.PageContextImpl _jsp_parentContext = pageContext;
    response.setContentType("text/html");
    response.setCharacterEncoding("utf-8");

    // Author: Dai Yong in June 2013
    out.write(_jsp_string0, 0, _jsp_string0.length);
    CP_Classes.Database Database;
    synchronized (pageContext.getSession()) {
      Database = (CP_Classes.Database) pageContext.getSession().getAttribute("Database");
      if (Database == null) {
        Database = new CP_Classes.Database();
        pageContext.getSession().setAttribute("Database", Database);
      }
    }
    out.write(_jsp_string1, 0, _jsp_string1.length);
    CP_Classes.Login logchk;
    synchronized (pageContext.getSession()) {
      logchk = (CP_Classes.Login) pageContext.getSession().getAttribute("logchk");
      if (logchk == null) {
        logchk = new CP_Classes.Login();
        pageContext.getSession().setAttribute("logchk", logchk);
      }
    }
    out.write(_jsp_string2, 0, _jsp_string2.length);
    Coach.LoginStatus LoginStatus;
    synchronized (pageContext.getSession()) {
      LoginStatus = (Coach.LoginStatus) pageContext.getSession().getAttribute("LoginStatus");
      if (LoginStatus == null) {
        LoginStatus = new Coach.LoginStatus();
        pageContext.getSession().setAttribute("LoginStatus", LoginStatus);
      }
    }
    out.write(_jsp_string1, 0, _jsp_string1.length);
    Coach.Coach Coach;
    synchronized (pageContext.getSession()) {
      Coach = (Coach.Coach) pageContext.getSession().getAttribute("Coach");
      if (Coach == null) {
        Coach = new Coach.Coach();
        pageContext.getSession().setAttribute("Coach", Coach);
      }
    }
    out.write(_jsp_string3, 0, _jsp_string3.length);

    String username = (String) session.getAttribute("username");

    if (!logchk.isUsable(username)) {

      out.write(_jsp_string4, 0, _jsp_string4.length);
    } else {

      if (request.getParameter("add") != null) {
        if (request.getParameter("Name") != null) {
          String name = request.getParameter("Name");
          String link = "";
          if (request.getParameter("Link") != "") {
            link = request.getParameter("Link");
          }

          // check whether SlotGroup name already exists in database
          Boolean Exist = false;

          Vector v = Coach.getAllCoach();
          for (int i = 0; i < v.size(); i++) {
            voCoach vo = (voCoach) v.elementAt(i);

            String coachName = vo.getCoachName();
            // System.out.println("Existing Schedule Name:"+slotGroupName);
            if (name.trim().equalsIgnoreCase((coachName.trim()))) {
              Exist = true;
              System.out.println("Same Coach Name");
            }
          }

          if (!Exist) {
            try {
              boolean add = Coach.addCoach(name, link);

              if (add) {

                out.write(_jsp_string5, 0, _jsp_string5.length);

              } else {

              }
            } catch (Exception SE) {
              System.out.println(SE);
            }
          } else {

            out.write(_jsp_string6, 0, _jsp_string6.length);
          }
        }
      }

      out.write(_jsp_string7, 0, _jsp_string7.length);
    }
    out.write(_jsp_string8, 0, _jsp_string8.length);
  }
  public void _jspService(
      javax.servlet.http.HttpServletRequest request,
      javax.servlet.http.HttpServletResponse response)
      throws java.io.IOException, javax.servlet.ServletException {
    javax.servlet.http.HttpSession session = request.getSession(true);
    com.caucho.server.webapp.Application _jsp_application = _caucho_getApplication();
    javax.servlet.ServletContext application = _jsp_application;
    com.caucho.jsp.PageContextImpl pageContext =
        com.caucho.jsp.QJspFactory.allocatePageContext(
            this, _jsp_application, request, response, null, session, 8192, true, false);
    javax.servlet.jsp.JspWriter out = pageContext.getOut();
    javax.servlet.ServletConfig config = getServletConfig();
    javax.servlet.Servlet page = this;
    response.setContentType("text/html");
    try {
      uk.ac.dundee.computing.stewarttaylor.UserBean userBean;
      synchronized (session) {
        userBean = (uk.ac.dundee.computing.stewarttaylor.UserBean) session.getAttribute("userBean");
        if (userBean == null) {
          userBean = new uk.ac.dundee.computing.stewarttaylor.UserBean();
          session.setAttribute("userBean", userBean);
        }
      }
      out.write(_jsp_string0, 0, _jsp_string0.length);
      uk.ac.dundee.computing.stewarttaylor.UserBean userBean2;
      synchronized (session) {
        userBean2 =
            (uk.ac.dundee.computing.stewarttaylor.UserBean) session.getAttribute("userBean2");
        if (userBean2 == null) {
          userBean2 = new uk.ac.dundee.computing.stewarttaylor.UserBean();
          session.setAttribute("userBean2", userBean2);
        }
      }
      out.write(_jsp_string1, 0, _jsp_string1.length);

      uk.ac.dundee.computing.stewarttaylor.UserBean uBean2 =
          (uk.ac.dundee.computing.stewarttaylor.UserBean) session.getAttribute("userBean");
      String sName = uBean2.getUsername();

      out.write(_jsp_string2, 0, _jsp_string2.length);
      out.print(sName);
      out.write(_jsp_string3, 0, _jsp_string3.length);
      out.print(sName);
      out.write(_jsp_string4, 0, _jsp_string4.length);
      uk.ac.dundee.computing.stewarttaylor.MessageBean msgBean;
      synchronized (session) {
        msgBean =
            (uk.ac.dundee.computing.stewarttaylor.MessageBean) session.getAttribute("msgBean");
        if (msgBean == null) {
          msgBean = new uk.ac.dundee.computing.stewarttaylor.MessageBean();
          session.setAttribute("msgBean", msgBean);
        }
      }
      out.write(_jsp_string5, 0, _jsp_string5.length);

      try {

        String[] names = msgBean.getUsername();
        String[] dates = msgBean.getDate();
        String[] messages = msgBean.getMessage();
        String[] images = msgBean.getImage();
        boolean[] canDelete = msgBean.getCanDelete();
        int[] id = msgBean.getID();

        for (int i = 0; i < names.length; i++) {

          out.write(_jsp_string6, 0, _jsp_string6.length);
          out.println(names[i]);
          out.write(_jsp_string3, 0, _jsp_string3.length);
          out.println(names[i]);
          out.write(_jsp_string7, 0, _jsp_string7.length);

          if (canDelete[i] == true) {

            out.write(_jsp_string8, 0, _jsp_string8.length);
            out.println(id[i]);
            out.write(_jsp_string9, 0, _jsp_string9.length);
          }

          out.write(_jsp_string10, 0, _jsp_string10.length);
          out.println(images[i]);
          out.write(_jsp_string11, 0, _jsp_string11.length);
          out.println(dates[i]);
          out.write(_jsp_string12, 0, _jsp_string12.length);
          out.println(messages[i]);
          out.write(_jsp_string13, 0, _jsp_string13.length);
        }
      } catch (Exception E) {
        out.println("<h3> No Posts Retrieved</h3>");
      }

      out.write(_jsp_string14, 0, _jsp_string14.length);
    } catch (java.lang.Throwable _jsp_e) {
      pageContext.handlePageException(_jsp_e);
    } finally {
      com.caucho.jsp.QJspFactory.freePageContext(pageContext);
    }
  }
 public void init(ServletConfig config) throws ServletException {
   com.caucho.server.webapp.WebApp webApp =
       (com.caucho.server.webapp.WebApp) config.getServletContext();
   super.init(config);
   com.caucho.jsp.TaglibManager manager = webApp.getJspApplicationContext().getTaglibManager();
   manager.addTaglibFunctions(_jsp_functionMap, "c", "http://java.sun.com/jstl/core");
   manager.addTaglibFunctions(_jsp_functionMap, "fmt", "http://java.sun.com/jstl/fmt");
   manager.addTaglibFunctions(_jsp_functionMap, "fn", "http://java.sun.com/jstl/functions");
   manager.addTaglibFunctions(_jsp_functionMap, "mytld", "/tld/MyTld");
   com.caucho.jsp.PageContextImpl pageContext = new com.caucho.jsp.PageContextImpl(webApp, this);
   _caucho_expr_0 = com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.id}");
   _caucho_expr_1 =
       com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.category}");
   _caucho_expr_2 = com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.city}");
   _caucho_expr_3 = com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.siteId}");
   _caucho_expr_4 =
       com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.service}");
   _caucho_expr_5 = com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.group}");
   _caucho_expr_6 = com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.url1}");
   _caucho_expr_7 =
       com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.startTime}");
   _caucho_expr_8 =
       com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.endTime}");
   _caucho_expr_9 =
       com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.orgPrice}");
   _caucho_expr_10 =
       com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.sellPrice}");
   _caucho_expr_11 =
       com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.discount}");
   _caucho_expr_12 = com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.title}");
   _caucho_expr_13 =
       com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.address}");
   _caucho_expr_14 =
       com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.userCount}");
   _caucho_expr_15 =
       com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.viewFlag==1}");
   _caucho_expr_16 = com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.phone}");
   _caucho_expr_17 =
       com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.webSite}");
   _caucho_expr_18 =
       com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.trafficInfo}");
   _caucho_expr_19 = com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.biefe}");
   _caucho_expr_20 =
       com.caucho.jsp.JspUtil.createExpr(pageContext.getELContext(), "${obj.ifTest==0}");
 }
  public void _jspService(
      javax.servlet.http.HttpServletRequest request,
      javax.servlet.http.HttpServletResponse response)
      throws java.io.IOException, javax.servlet.ServletException {
    javax.servlet.http.HttpSession session = request.getSession(true);
    com.caucho.server.webapp.WebApp _jsp_application = _caucho_getApplication();
    javax.servlet.ServletContext application = _jsp_application;
    com.caucho.jsp.PageContextImpl pageContext =
        _jsp_application
            .getJspApplicationContext()
            .allocatePageContext(
                this, _jsp_application, request, response, null, session, 8192, true, false);
    javax.servlet.jsp.PageContext _jsp_parentContext = pageContext;
    javax.servlet.jsp.JspWriter out = pageContext.getOut();
    final javax.el.ELContext _jsp_env = pageContext.getELContext();
    javax.servlet.ServletConfig config = getServletConfig();
    javax.servlet.Servlet page = this;
    response.setContentType("text/html; charset=utf-8");
    request.setCharacterEncoding("UTF-8");
    dms.tag.CategorySelectTag _jsp_CategorySelectTag_0 = null;
    dms.tag.CitySelectTag _jsp_CitySelectTag_1 = null;
    dms.tag.DomainSelectTag _jsp_DomainSelectTag_2 = null;
    dms.tag.ServiceSelectTag _jsp_ServiceSelectTag_3 = null;
    dms.tag.GroupSelectTag _jsp_GroupSelectTag_4 = null;
    org.apache.taglibs.standard.tag.rt.fmt.FormatDateTag _jsp_FormatDateTag_5 = null;
    try {
      out.write(_jsp_string0, 0, _jsp_string0.length);
      _caucho_expr_0.print(out, _jsp_env, false);
      out.write(_jsp_string1, 0, _jsp_string1.length);
      if (_jsp_CategorySelectTag_0 == null) {
        _jsp_CategorySelectTag_0 = new dms.tag.CategorySelectTag();
        _jsp_CategorySelectTag_0.setPageContext(pageContext);
        _jsp_CategorySelectTag_0.setParent((javax.servlet.jsp.tagext.Tag) null);
        _jsp_CategorySelectTag_0.setName("category");
      }

      _jsp_CategorySelectTag_0.setCatId(new java.lang.Long(_caucho_expr_1.evalLong(_jsp_env)));
      _jsp_CategorySelectTag_0.doStartTag();
      out.write(_jsp_string2, 0, _jsp_string2.length);
      if (_jsp_CitySelectTag_1 == null) {
        _jsp_CitySelectTag_1 = new dms.tag.CitySelectTag();
        _jsp_CitySelectTag_1.setPageContext(pageContext);
        _jsp_CitySelectTag_1.setParent((javax.servlet.jsp.tagext.Tag) null);
        _jsp_CitySelectTag_1.setName("city");
      }

      _jsp_CitySelectTag_1.setCityId(new java.lang.Long(_caucho_expr_2.evalLong(_jsp_env)));
      _jsp_CitySelectTag_1.doStartTag();
      out.write(_jsp_string3, 0, _jsp_string3.length);
      if (_jsp_DomainSelectTag_2 == null) {
        _jsp_DomainSelectTag_2 = new dms.tag.DomainSelectTag();
        _jsp_DomainSelectTag_2.setPageContext(pageContext);
        _jsp_DomainSelectTag_2.setParent((javax.servlet.jsp.tagext.Tag) null);
        _jsp_DomainSelectTag_2.setName("siteId");
      }

      _jsp_DomainSelectTag_2.setDomainId(new java.lang.Long(_caucho_expr_3.evalLong(_jsp_env)));
      _jsp_DomainSelectTag_2.doStartTag();
      out.write(_jsp_string4, 0, _jsp_string4.length);
      if (_jsp_ServiceSelectTag_3 == null) {
        _jsp_ServiceSelectTag_3 = new dms.tag.ServiceSelectTag();
        _jsp_ServiceSelectTag_3.setPageContext(pageContext);
        _jsp_ServiceSelectTag_3.setParent((javax.servlet.jsp.tagext.Tag) null);
        _jsp_ServiceSelectTag_3.setName("service");
      }

      _jsp_ServiceSelectTag_3.setService(new java.lang.Long(_caucho_expr_4.evalLong(_jsp_env)));
      _jsp_ServiceSelectTag_3.doStartTag();
      out.write(_jsp_string5, 0, _jsp_string5.length);
      if (_jsp_GroupSelectTag_4 == null) {
        _jsp_GroupSelectTag_4 = new dms.tag.GroupSelectTag();
        _jsp_GroupSelectTag_4.setPageContext(pageContext);
        _jsp_GroupSelectTag_4.setParent((javax.servlet.jsp.tagext.Tag) null);
        _jsp_GroupSelectTag_4.setName("group");
      }

      _jsp_GroupSelectTag_4.setGroup(new java.lang.Long(_caucho_expr_5.evalLong(_jsp_env)));
      _jsp_GroupSelectTag_4.doStartTag();
      out.write(_jsp_string6, 0, _jsp_string6.length);
      _caucho_expr_6.print(out, _jsp_env, false);
      out.write(_jsp_string7, 0, _jsp_string7.length);
      if (_jsp_FormatDateTag_5 == null) {
        _jsp_FormatDateTag_5 = new org.apache.taglibs.standard.tag.rt.fmt.FormatDateTag();
        _jsp_FormatDateTag_5.setPageContext(pageContext);
        _jsp_FormatDateTag_5.setParent((javax.servlet.jsp.tagext.Tag) null);
        _jsp_FormatDateTag_5.setPattern("yy-MM-dd HH:mm:ss");
      }

      _jsp_FormatDateTag_5.setValue((java.util.Date) _caucho_expr_7.evalObject(_jsp_env));
      _jsp_FormatDateTag_5.doEndTag();
      out.write(_jsp_string8, 0, _jsp_string8.length);
      _jsp_FormatDateTag_5.setValue((java.util.Date) _caucho_expr_8.evalObject(_jsp_env));
      _jsp_FormatDateTag_5.doEndTag();
      out.write(_jsp_string9, 0, _jsp_string9.length);
      _caucho_expr_9.print(out, _jsp_env, false);
      out.write(_jsp_string10, 0, _jsp_string10.length);
      _caucho_expr_10.print(out, _jsp_env, false);
      out.write(_jsp_string11, 0, _jsp_string11.length);
      _caucho_expr_11.print(out, _jsp_env, false);
      out.write(_jsp_string12, 0, _jsp_string12.length);
      _caucho_expr_12.print(out, _jsp_env, false);
      out.write(_jsp_string13, 0, _jsp_string13.length);
      _caucho_expr_13.print(out, _jsp_env, false);
      out.write(_jsp_string14, 0, _jsp_string14.length);
      _caucho_expr_14.print(out, _jsp_env, false);
      out.write(_jsp_string15, 0, _jsp_string15.length);
      if (_caucho_expr_15.evalBoolean(_jsp_env)) {
        out.write(_jsp_string16, 0, _jsp_string16.length);
      } else {
        out.write(_jsp_string17, 0, _jsp_string17.length);
      }
      out.write(_jsp_string18, 0, _jsp_string18.length);
      _caucho_expr_16.print(out, _jsp_env, false);
      out.write(_jsp_string19, 0, _jsp_string19.length);
      _caucho_expr_17.print(out, _jsp_env, false);
      out.write(_jsp_string20, 0, _jsp_string20.length);
      _caucho_expr_18.print(out, _jsp_env, false);
      out.write(_jsp_string21, 0, _jsp_string21.length);
      _caucho_expr_19.print(out, _jsp_env, false);
      out.write(_jsp_string22, 0, _jsp_string22.length);
      if (_caucho_expr_20.evalBoolean(_jsp_env)) {
        out.write(_jsp_string23, 0, _jsp_string23.length);
      } else {
        out.write(_jsp_string24, 0, _jsp_string24.length);
      }
      out.write(_jsp_string25, 0, _jsp_string25.length);
    } catch (java.lang.Throwable _jsp_e) {
      pageContext.handlePageException(_jsp_e);
    } finally {
      if (_jsp_CategorySelectTag_0 != null) _jsp_CategorySelectTag_0.release();
      if (_jsp_CitySelectTag_1 != null) _jsp_CitySelectTag_1.release();
      if (_jsp_DomainSelectTag_2 != null) _jsp_DomainSelectTag_2.release();
      if (_jsp_ServiceSelectTag_3 != null) _jsp_ServiceSelectTag_3.release();
      if (_jsp_GroupSelectTag_4 != null) _jsp_GroupSelectTag_4.release();
      if (_jsp_FormatDateTag_5 != null) _jsp_FormatDateTag_5.release();
      _jsp_application.getJspApplicationContext().freePageContext(pageContext);
    }
  }