基于ssm校园招聘管理系统获取(java毕业设计)

发布于:2022-12-14 ⋅ 阅读:(349) ⋅ 点赞:(0)

基于ssm校园招聘管理系统

校园招聘管理系统是基于java编程语言和MySQL数据库,SSM框架开发的系统,本系统是拥有学生,企业,管理员三个角色;用户学生可以查看招聘信息,在线制作和投简历,查看自己是否被应聘;企业可以发布招聘信息,对投递简历学生进行面试通知,查看面试结果等;管理员管理企业,管理学生,管理通知信息。本设计功能齐全,页面简洁,难度中等,适合作为java毕业设计和课程设计来学习和参考。


一.技术环境

JDK版本:1.8
IDE工具:eclipse
数据库: mysql 5.5
编程语言: Java
tomcat: 8.0
系统框架:SSM
详细技术:HTML+CSS+JS+JSP+JAVA+SSM+MYSQL+JQUERY


二.项目文件(项目获取请看文末官网)

在这里插入图片描述


三.系统功能

在这里插入图片描述


四.代码示例

<?php

	// +----------------------------------------------------------------------
	// | 注册功能
	// | 设计思路,首先判断用户输入的数据是否正确,在判断用户的邮箱有没有注
	// | 过,满足条件,注册成功,ajaxReturn函数在include.php中
	// +----------------------------------------------------------------------

	//引用常用的函数
	require_once('../../../config/config.php');

	//获取前台发来的数据
	$name = $_POST['name'];//获取用户名
	$password = $_POST['password'];//获取密码
	$email = $_POST['email'];//获取游戏
	$password_o = $_POST['password_o'];//获取重复密码

	//判断用户名
	if(!$name) {
		ajaxReturn(0,'用户名格式不正确,英文加数字!');
	}
	//判断密码是否输入正确
	if(!is_password($password)) {
		ajaxReturn(0,'密码格式不正确,不少于6位!');
	}
	//判断邮箱是否输入正确
	if(!is_email($email)) {
		ajaxReturn(0,'邮箱格式不正确!');
	}
	//判断两次密码输入是否一致
	if($password != $password_o) {
		ajaxReturn(0,'两次输入的密码不一致!');
	}

	//查询数据库是否已经注册过此邮箱
	$sql = "SELECT * FROM users WHERE email='$email'";
	$result1 = fetchAll($link,$sql);

	if($result1) {
		ajaxReturn(0,'抱歉,此邮箱已经注册过!');	
	}

	$data = array(
		'name'=>$name,
		'password'=>$password,
		'email'=> $email,
		'addtime'=>date('Y-m-d H:i:s')
	);

	//保存用户的注册信息到users表,其中的$link在include.php里
	$result2 = insert($link,$data,'users');

	//注册成功和失败的话,返回提示
	if(!$result2) {
		ajaxReturn(0,'注册失败!');
	}else{
		ajaxReturn(1,'恭喜你注册成功');
	}
package com.lmu.controller;
/**
 * 和登陆有关的都在这里
 */

import com.opensymphony.xwork2.ActionContext;
import com.opensymphony.xwork2.ActionSupport;
import com.lmu.model.Role;
import com.lmu.model.User;
import com.lmu.service.RoleService;
import com.lmu.service.UserService;
import com.lmu.utils.JsonUtils;
import com.lmu.utils.UserUtils;

import org.apache.commons.collections.map.HashedMap;
import org.apache.struts2.ServletActionContext;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Controller;

import java.io.IOException;
import java.util.HashMap;
import java.util.Map;

@Controller("loginController")
@Scope("prototype")
public class LoginController extends ActionSupport {
    @Autowired
    private UserService userService;
    @Autowired
    private RoleService roleService;
    private User user;
    private Map<String, Object> map = new HashMap();
    public User getUser() {
        return user;
    }

    public void setUser(User user) {
        this.user = user;
    }

    public UserService getUserService() {
        return userService;
    }

    public void setUserService(UserService userService) {
        this.userService = userService;
    }

    /**
 * 用户登陆
 * @return
 */
	public void index() throws IOException {
       User user1 = userService.getUser(user);
        if (user1 != null){
            if (user1.getIsSh() == 1){
                if (user1.getRole().getEnName().equals("admin")){
                    ActionContext.getContext().getSession().put("user", user1);
                }
                if (user1.getRole().getEnName().equals("js")){
                    ActionContext.getContext().getSession().put("user1", user1);
                }
                if (user1.getRole().getEnName().equals("xs")){
                    ActionContext.getContext().getSession().put("user2", user1);
                }
                map.put("flag", 1);
                map.put("url", "login_indexs.do");
                map.put("id", user1.getId());
                JsonUtils.toJson(map);
            } else {
                map.put("flag", 2);
                JsonUtils.toJson(map);
            }
        } else {
            map.put("flag", 3);
            JsonUtils.toJson(map);
        }
    }

    public String indexs() throws IOException {
        User u = UserUtils.getUser();
        if (u != null){
            ActionContext.getContext().put("user", u);
            String ss = u.getRole().getEnName();
            ActionContext.getContext().put("role", u.getRole().getEnName());
        }
        return SUCCESS;
    }
	//登陆页面
	public String login() {

        return SUCCESS;
	}

   //退出
	public String tuichu() {
		ActionContext ac = ActionContext.getContext();
		Map session = ac.getSession();
		session.remove("userName");
		session.remove("userId");
		ServletActionContext.getRequest().getSession().invalidate();
		return "login";
	}

}


五.项目截图

在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述

本文含有隐藏内容,请 开通VIP 后查看

网站公告

今日签到

点亮在社区的每一天
去签到