代码架构
dao层代码
接口设置:薪资管理与人员调动
package com.jxdinfo.hussar.salary.dao;
import com.jxdinfo.hussar.salary.model.StaffInfo;
import com.baomidou.mybatisplus.mapper.BaseMapper;
/**
* <p>
* Mapper 接口
* </p>
*
* @since 2021-07-06
*/
public interface StaffInfoMapper extends BaseMapper<StaffInfo> {
void transferLogging(String staff_id,String from_d,String to_d);
}
package com.jxdinfo.hussar.salary.dao;
import com.jxdinfo.hussar.salary.model.StaffTransfer;
import com.baomidou.mybatisplus.mapper.BaseMapper;
import org.springframework.data.repository.query.Param;
import java.util.List;
import java.util.Map;
/**
* <p>
* Mapper 接口
* </p>
*
* @since 2021-07-07
*/
public interface StaffTransferMapper extends BaseMapper<StaffTransfer> {
List<StaffTransfer> getStaffTransfer();
}
控制层代码
薪资管理与人员调动
package com.jxdinfo.hussar.salary.controller;
import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.baomidou.mybatisplus.mapper.Wrapper;
import com.baomidou.mybatisplus.plugins.Page;
import com.jxdinfo.hussar.core.base.controller.BaseController;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.beans.factory.annotation.Autowired;
import com.jxdinfo.hussar.core.log.LogObjectHolder;
import org.springframework.web.bind.annotation.RequestParam;
import com.jxdinfo.hussar.common.annotion.BussinessLog;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import com.jxdinfo.hussar.core.log.type.BussinessLogType;
import com.jxdinfo.hussar.salary.model.StaffInfo;
import com.jxdinfo.hussar.salary.service.IStaffInfoService;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
* 人员管理控制器
*
* @Date 2021-07-06 08:57:38
*/
@Controller
@RequestMapping("/staffInfo")
public class StaffInfoController extends BaseController {
private String PREFIX = "/salary/staffInfo/";