src/com/controller/XuanzedaoshiController.java

(开头部分) 10KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

package com.controller;

import java.io.File;
import java.io.IOException;

import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.io.PrintWriter;

import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;

import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.multipart.MultipartFile;

import com.entity.Xuanzedaoshi;
import com.server.XuanzedaoshiServer;
import com.util.PageBean;
import net.sf.json.JSONObject;
import com.util.db;
import java.sql.SQLException;
import java.sql.*;
@Controller
public class XuanzedaoshiController {
	@Resource
	private XuanzedaoshiServer xuanzedaoshiService;


   
	@RequestMapping("addXuanzedaoshi.do")
	public String addXuanzedaoshi(HttpServletRequest request,Xuanzedaoshi xuanzedaoshi,HttpSession session) throws SQLException{
		Timestamp time=new Timestamp(System.currentTimeMillis());
		String sql="";
		sql="select id from xuanzedaoshi where 1=1  and gonghao='"+xuanzedaoshi.getGonghao()+"' and xuesheng='"+xuanzedaoshi.getXuesheng()+"'";
		db dbo = new db();
		ResultSet rs=null;
		rs=dbo.executeQuery(sql);
		int tt=0;
		while(rs.next()){

				tt++;
		}

		if(tt>=1)
		{
			
			session.setAttribute("backxx", "你已申请过该导师!");
			session.setAttribute("backurl", request.getHeader("Referer"));
			
			//session.setAttribute("backurl", "xuanzedaoshiList.do");
			
			return "redirect:postback.jsp";
后面还有 202 行代码,购买后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。