| | |
| | | import com.ruoyi.common.core.controller.BaseController; |
| | | import com.ruoyi.common.core.domain.AjaxResult; |
| | | import com.ruoyi.common.core.page.TableDataInfo; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | |
| | | * @author makejava |
| | | * @since 2023-09-13 16:11:04 |
| | | */ |
| | | @Api(tags = "考点接口") |
| | | @RestController |
| | | @RequestMapping("exam/site") |
| | | public class ExamSiteController extends BaseController { |
| | |
| | | * @param query 查询实体 |
| | | * @return 所有数据 |
| | | */ |
| | | @ApiOperation(value = "分页查询列表") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "pageNum", dataTypeClass = String.class,value = "页码",required = true), |
| | | @ApiImplicitParam(name = "pageSize", dataTypeClass = String.class,value = "页数",required = true), |
| | | }) |
| | | @GetMapping("page/list") |
| | | public TableDataInfo listByPage(ExamSiteQuery query) { |
| | | startPage(); |
| | |
| | | * @param siteId 主键 |
| | | * @return 单条数据 |
| | | */ |
| | | @GetMapping("{get/siteId}") |
| | | @ApiOperation(value = "通过主键查询单条数据") |
| | | @GetMapping("get/{siteId}") |
| | | public AjaxResult selectOne(@PathVariable Long siteId) { |
| | | return success(this.examSiteService.getById(siteId)); |
| | | } |
| | |
| | | * @param addForm 实体对象 |
| | | * @return 新增结果 |
| | | */ |
| | | @ApiOperation(value = "新增数据") |
| | | @PostMapping("add") |
| | | public AjaxResult add(@Validated @RequestBody ExamSiteAddForm addForm) { |
| | | return toAjax(this.examSiteService.add(addForm)); |
| | |
| | | * @param modForm 实体对象 |
| | | * @return 修改结果 |
| | | */ |
| | | @PutMapping("mod") |
| | | @ApiOperation(value = "修改数据") |
| | | @PostMapping("mod") |
| | | public AjaxResult mod(@Validated @RequestBody ExamSiteModForm modForm) { |
| | | return toAjax(this.examSiteService.mod(modForm)); |
| | | } |
| | |
| | | * @param siteIds 主键结合 |
| | | * @return 删除结果 |
| | | */ |
| | | @ApiOperation(value = "删除数据") |
| | | @DeleteMapping("/del/batch/{siteIds}") |
| | | public AjaxResult delete(@PathVariable("siteIds") List<Long> siteIds) { |
| | | return toAjax(this.examSiteService.removeByIds(siteIds)); |
| | | public AjaxResult delBatch(@PathVariable("siteIds") List<Long> siteIds) { |
| | | this.examSiteService.delBatch(siteIds); |
| | | return success(); |
| | | } |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.controller; |
| | | |
| | | import com.gkhy.exam.noncoalmine.model.query.NcCertQuery; |
| | | import com.gkhy.exam.noncoalmine.service.NcCertService; |
| | | import com.ruoyi.common.core.controller.BaseController; |
| | | import com.ruoyi.common.core.domain.AjaxResult; |
| | | import com.ruoyi.common.core.page.TableDataInfo; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | |
| | | /** |
| | | * (NcCert)表控制层 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-15 17:14:35 |
| | | */ |
| | | @Api(tags = "证书接口") |
| | | @RestController |
| | | @RequestMapping("nc/cert") |
| | | public class NcCertController extends BaseController { |
| | | /** |
| | | * 服务对象 |
| | | */ |
| | | @Resource |
| | | private NcCertService ncCertService; |
| | | |
| | | /** |
| | | * 分页查询所有数据 |
| | | * |
| | | * @param query 查询实体 |
| | | * @return 所有数据 |
| | | */ |
| | | @GetMapping("page/list") |
| | | @ApiOperation(value = "分页查询列表") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "pageNum", dataTypeClass = String.class,value = "页码",required = true), |
| | | @ApiImplicitParam(name = "pageSize", dataTypeClass = String.class,value = "页数",required = true), |
| | | }) |
| | | public TableDataInfo listByPage(NcCertQuery query) { |
| | | startPage(); |
| | | return getDataTable(this.ncCertService.getList(query)); |
| | | } |
| | | /** |
| | | * 同步证书数据 |
| | | */ |
| | | @GetMapping("sync/data") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "idcardNum", dataTypeClass = String.class,value = "身份证号",required = true), |
| | | }) |
| | | @ApiOperation(value = "同步证书数据") |
| | | public AjaxResult syncCert(NcCertQuery query){ |
| | | this.ncCertService.syncCert(query); |
| | | return success(); |
| | | } |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.controller; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.gkhy.exam.noncoalmine.entity.NcExamPlan; |
| | | import com.gkhy.exam.noncoalmine.model.query.NcExamPlanQuery; |
| | | import com.gkhy.exam.noncoalmine.service.NcExamPlanService; |
| | | import com.ruoyi.common.core.controller.BaseController; |
| | | import com.ruoyi.common.core.domain.AjaxResult; |
| | | import com.ruoyi.common.core.page.TableDataInfo; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | |
| | | /** |
| | | * (NcExamPlan)表控制层 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 13:21:48 |
| | | */ |
| | | @Api(tags = "批次管理接口") |
| | | @RestController |
| | | @RequestMapping("nc/exam/plan") |
| | | public class NcExamPlanController extends BaseController { |
| | | /** |
| | | * 服务对象 |
| | | */ |
| | | @Autowired |
| | | private NcExamPlanService ncExamPlanService; |
| | | |
| | | /** |
| | | * 分页查询所有数据 |
| | | * |
| | | * @param query 查询实体 |
| | | * @return 所有数据 |
| | | */ |
| | | @ApiOperation(value = "分页查询") |
| | | @GetMapping("page/list") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "pageNum", dataTypeClass = String.class,value = "页码",required = true), |
| | | @ApiImplicitParam(name = "pageSize", dataTypeClass = String.class,value = "页数",required = true), |
| | | }) |
| | | public TableDataInfo listByPage(NcExamPlanQuery query) { |
| | | startPage(); |
| | | return getDataTable(this.ncExamPlanService.selectNcExamPlanList(query)); |
| | | } |
| | | /** |
| | | * 同步考试计划 |
| | | */ |
| | | @ApiOperation(value = "同步考试计划") |
| | | @GetMapping("sync/data") |
| | | public AjaxResult syncExamPlan(){ |
| | | ncExamPlanService.syncExamPlan(); |
| | | return success(); |
| | | } |
| | | |
| | | |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.controller; |
| | | |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.gkhy.exam.noncoalmine.entity.NcExaminees; |
| | | import com.gkhy.exam.noncoalmine.service.NcExamineesService; |
| | | import com.ruoyi.common.core.controller.BaseController; |
| | | import com.ruoyi.common.core.domain.AjaxResult; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import javax.annotation.Resource; |
| | | import java.io.Serializable; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (NcExaminees)表控制层 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 10:01:22 |
| | | */ |
| | | @RestController |
| | | @RequestMapping("nc/examinees") |
| | | public class NcExamineesController extends BaseController { |
| | | /** |
| | | * 服务对象 |
| | | */ |
| | | @Resource |
| | | private NcExamineesService ncExamineesService; |
| | | |
| | | |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.controller; |
| | | |
| | | import com.gkhy.exam.noncoalmine.model.addForm.NcStaffAddForm; |
| | | import com.gkhy.exam.noncoalmine.model.modForm.NcStaffModForm; |
| | | import com.gkhy.exam.noncoalmine.model.query.NcStaffQuery; |
| | | import com.gkhy.exam.noncoalmine.service.NcStaffService; |
| | | import com.ruoyi.common.core.controller.BaseController; |
| | | import com.ruoyi.common.core.domain.AjaxResult; |
| | | import com.ruoyi.common.core.page.TableDataInfo; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (NcStaff)表控制层 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 09:59:58 |
| | | */ |
| | | @Api(tags = "非煤人员接口") |
| | | @RestController |
| | | @RequestMapping("nc/staff") |
| | | public class NcStaffController extends BaseController { |
| | | /** |
| | | * 服务对象 |
| | | */ |
| | | @Autowired |
| | | private NcStaffService ncStaffService; |
| | | |
| | | /** |
| | | * 分页查询所有数据 |
| | | * |
| | | * @param query 查询实体 |
| | | * @return 所有数据 |
| | | */ |
| | | @ApiOperation(value = "分页查询") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "pageNum", dataTypeClass = String.class,value = "页码",required = true), |
| | | @ApiImplicitParam(name = "pageSize", dataTypeClass = String.class,value = "页数",required = true), |
| | | }) |
| | | @GetMapping("list/page") |
| | | public TableDataInfo listByPage(NcStaffQuery query) { |
| | | startPage(); |
| | | return getDataTable(this.ncStaffService.selectStaffList(query)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 新增数据 |
| | | * |
| | | * @param addForm 实体对象 |
| | | * @return 新增结果 |
| | | */ |
| | | @ApiOperation(value = "新增数据") |
| | | @PostMapping("add") |
| | | public AjaxResult add(@RequestBody NcStaffAddForm addForm) { |
| | | return toAjax(this.ncStaffService.add(addForm)); |
| | | } |
| | | |
| | | /** |
| | | * 修改数据 |
| | | * |
| | | * @param modForm 实体对象 |
| | | * @return 修改结果 |
| | | */ |
| | | @ApiOperation(value = "修改数据") |
| | | @PostMapping("mod") |
| | | public AjaxResult mod(@RequestBody NcStaffModForm modForm) { |
| | | this.ncStaffService.mod(modForm); |
| | | return success(); |
| | | } |
| | | |
| | | /** |
| | | * 删除数据 |
| | | * |
| | | * @param staffIds 主键结合 |
| | | * @return 删除结果 |
| | | */ |
| | | @ApiOperation(value = "删除数据") |
| | | @DeleteMapping("del/batch/{staffIds}") |
| | | public AjaxResult delBatch(@PathVariable("staffIds") List<Long> staffIds) { |
| | | this.ncStaffService.delBatch(staffIds); |
| | | return success(); |
| | | } |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.controller; |
| | | |
| | | import com.gkhy.exam.noncoalmine.service.NcStaffResumeService; |
| | | import com.ruoyi.common.core.controller.BaseController; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | |
| | | /** |
| | | * (NcStaffResume)表控制层 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 14:06:43 |
| | | */ |
| | | @RestController |
| | | @RequestMapping("nc/staff/resume") |
| | | public class NcStaffResumeController extends BaseController { |
| | | /** |
| | | * 服务对象 |
| | | */ |
| | | @Autowired |
| | | private NcStaffResumeService ncStaffResumeService; |
| | | |
| | | |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.controller; |
| | | |
| | | import com.gkhy.exam.noncoalmine.service.NcStaffTrainService; |
| | | import com.ruoyi.common.core.controller.BaseController; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | |
| | | /** |
| | | * (NcStaffTrain)表控制层 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 10:00:25 |
| | | */ |
| | | @RestController |
| | | @RequestMapping("nc/staff/train") |
| | | public class NcStaffTrainController extends BaseController { |
| | | /** |
| | | * 服务对象 |
| | | */ |
| | | @Autowired |
| | | private NcStaffTrainService ncStaffTrainService; |
| | | |
| | | } |
| | | |
| | |
| | | import com.ruoyi.common.core.controller.BaseController; |
| | | import com.ruoyi.common.core.domain.AjaxResult; |
| | | import com.ruoyi.common.core.page.TableDataInfo; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | |
| | | * @author makejava |
| | | * @since 2023-09-13 16:12:31 |
| | | */ |
| | | @Api(tags = "培训机构接口") |
| | | @RestController |
| | | @RequestMapping("training/institution") |
| | | public class TrainingInstitutionController extends BaseController { |
| | |
| | | * @param query 查询实体 |
| | | * @return 所有数据 |
| | | */ |
| | | @ApiOperation(value = "分页查询") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "pageNum", dataTypeClass = String.class,value = "页码",required = true), |
| | | @ApiImplicitParam(name = "pageSize", dataTypeClass = String.class,value = "页数",required = true), |
| | | }) |
| | | @GetMapping("page/list") |
| | | public TableDataInfo listByPage(TrainingInstitutionQuery query) { |
| | | startPage(); |
| | |
| | | * @param institutionId 主键 |
| | | * @return 单条数据 |
| | | */ |
| | | @ApiOperation(value = "通过主键查询单条数据") |
| | | @GetMapping("get/{institutionId}") |
| | | public AjaxResult selectOne(@PathVariable Long institutionId) { |
| | | return success(this.trainingInstitutionService.getById(institutionId)); |
| | |
| | | * @param addForm 实体对象 |
| | | * @return 新增结果 |
| | | */ |
| | | @ApiOperation(value = "新增数据") |
| | | @PostMapping("add") |
| | | public AjaxResult add(@Validated @RequestBody TrainingInstitutionAddForm addForm) { |
| | | return toAjax(this.trainingInstitutionService.add(addForm)); |
| | |
| | | * @param modForm 实体对象 |
| | | * @return 修改结果 |
| | | */ |
| | | @PutMapping("mod") |
| | | @ApiOperation(value = "修改数据") |
| | | @PostMapping("mod") |
| | | public AjaxResult mod(@Validated @RequestBody TrainingInstitutionModForm modForm) { |
| | | return toAjax(this.trainingInstitutionService.mod(modForm)); |
| | | } |
| | |
| | | * @param institutionIds 主键结合 |
| | | * @return 删除结果 |
| | | */ |
| | | @ApiOperation(value = "删除数据") |
| | | @DeleteMapping("/del/batch/{institutionIds}") |
| | | public AjaxResult delete(@PathVariable("institutionIds") List<Long> institutionIds) { |
| | | return toAjax(this.trainingInstitutionService.removeByIds(institutionIds)); |
| | | public AjaxResult delBatch(@PathVariable("institutionIds") List<Long> institutionIds) { |
| | | this.trainingInstitutionService.delBatch(institutionIds); |
| | | return success(); |
| | | } |
| | | /** |
| | | * 选择列表 |
| | | */ |
| | | @ApiOperation(value = "选择列表") |
| | | @GetMapping("select") |
| | | public AjaxResult selectList(TrainingInstitutionQuery query){ |
| | | return success(this.trainingInstitutionService.listByPage(query)); |
| | |
| | | import com.ruoyi.common.core.controller.BaseController; |
| | | import com.ruoyi.common.core.domain.AjaxResult; |
| | | import com.ruoyi.common.core.page.TableDataInfo; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import javax.annotation.Resource; |
| | |
| | | * @author makejava |
| | | * @since 2023-09-11 16:59:05 |
| | | */ |
| | | @Api(tags = "违规登记接口") |
| | | @RestController |
| | | @RequestMapping("violation/registration") |
| | | public class ViolationRegistrationController extends BaseController { |
| | |
| | | * @param query 查询实体 |
| | | * @return 所有数据 |
| | | */ |
| | | @ApiOperation(value = "分页查询") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "pageNum", dataTypeClass = String.class,value = "页码",required = true), |
| | | @ApiImplicitParam(name = "pageSize", dataTypeClass = String.class,value = "页数",required = true), |
| | | @ApiImplicitParam(name = "dept", dataTypeClass = String.class,value = "部门名"), |
| | | @ApiImplicitParam(name = "name", dataTypeClass = String.class,value = "姓名"), |
| | | @ApiImplicitParam(name = "idCard", dataTypeClass = String.class,value = "身份证号"), |
| | | @ApiImplicitParam(name = "operateTypeId", dataTypeClass = Long.class,value = "作业类型Id"), |
| | | }) |
| | | @GetMapping("page/list") |
| | | public TableDataInfo listByPage(ViolationRegistrationQuery query) { |
| | | startPage(); |
| | |
| | | * @param violationId 主键 |
| | | * @return 单条数据 |
| | | */ |
| | | @ApiOperation(value = "通过主键查询单条数据") |
| | | @GetMapping("get/{violationId}") |
| | | public AjaxResult selectOne(@PathVariable Long violationId) { |
| | | return success(this.violationRegistrationService.getById(violationId)); |
| | |
| | | * @param addForm 实体对象 |
| | | * @return 新增结果 |
| | | */ |
| | | @ApiOperation(value = "新增数据") |
| | | @PostMapping("add") |
| | | public AjaxResult add(@Validated @RequestBody ViolationRegistrationAddForm addForm) { |
| | | return toAjax(this.violationRegistrationService.add(addForm)); |
| | |
| | | * @param modForm 实体对象 |
| | | * @return 修改结果 |
| | | */ |
| | | @PutMapping("mod") |
| | | @ApiOperation(value = "修改数据") |
| | | @PostMapping("mod") |
| | | public AjaxResult mod(@Validated @RequestBody ViolationRegistrationModForm modForm) { |
| | | return toAjax(this.violationRegistrationService.mod(modForm)); |
| | | } |
| | |
| | | * @param violationIds 主键结合 |
| | | * @return 删除结果 |
| | | */ |
| | | @ApiOperation(value = "删除数据") |
| | | @DeleteMapping("/del/batch/{violationIds}") |
| | | public AjaxResult delete(@PathVariable("violationIds") List<Long> violationIds) { |
| | | return success(this.violationRegistrationService.removeByIds(violationIds)); |
| | | public AjaxResult delBatch(@PathVariable("violationIds") List<Long> violationIds) { |
| | | this.violationRegistrationService.delBatch(violationIds); |
| | | return success(); |
| | | } |
| | | } |
| | | |
| | |
| | | import com.ruoyi.common.core.controller.BaseController; |
| | | import com.ruoyi.common.core.domain.AjaxResult; |
| | | import com.ruoyi.common.core.page.TableDataInfo; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import javax.annotation.Resource; |
| | | import java.lang.reflect.Array; |
| | | import java.util.List; |
| | | |
| | | /** |
| | |
| | | * @author makejava |
| | | * @since 2023-09-11 16:59:58 |
| | | */ |
| | | |
| | | @Api(tags = "作业登记接口") |
| | | @RestController |
| | | @RequestMapping("work/registration") |
| | | public class WorkRegistrationController extends BaseController { |
| | |
| | | * @param query 查询实体 |
| | | * @return 所有数据 |
| | | */ |
| | | @ApiOperation(value = "分页查询列表") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "pageNum", dataTypeClass = String.class,value = "页码",required = true), |
| | | @ApiImplicitParam(name = "pageSize", dataTypeClass = String.class,value = "页数",required = true), |
| | | @ApiImplicitParam(name = "dept", dataTypeClass = String.class,value = "部门名"), |
| | | @ApiImplicitParam(name = "name", dataTypeClass = String.class,value = "姓名"), |
| | | @ApiImplicitParam(name = "idCard", dataTypeClass = String.class,value = "身份证号"), |
| | | @ApiImplicitParam(name = "operateTypeId", dataTypeClass = Long.class,value = "作业类型Id"), |
| | | }) |
| | | @GetMapping("/list/page") |
| | | public TableDataInfo listByPage(WorkRegistrationQuery query) { |
| | | startPage(); |
| | |
| | | /** |
| | | * 通过主键查询单条数据 |
| | | * |
| | | * @param id 主键 |
| | | * @param workId 主键 |
| | | * @return 单条数据 |
| | | */ |
| | | @GetMapping("get/{id}") |
| | | public AjaxResult selectOne(@PathVariable Long id) { |
| | | return success(this.workRegistrationService.getById(id)); |
| | | @ApiOperation(value = "根据id查询") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "workId", dataTypeClass = Long.class,value = "作业登记Id"), |
| | | }) |
| | | @GetMapping("get/{workId}") |
| | | public AjaxResult selectOne(@PathVariable Long workId) { |
| | | return success(this.workRegistrationService.getById(workId)); |
| | | } |
| | | |
| | | /** |
| | |
| | | * @param addForm 实体对象 |
| | | * @return 新增结果 |
| | | */ |
| | | @ApiOperation(value = "新增") |
| | | @PostMapping("add") |
| | | public AjaxResult add(@Validated @RequestBody WorkRegistrationAddForm addForm) { |
| | | return toAjax(this.workRegistrationService.add(addForm)); |
| | |
| | | * @param modForm |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "修改") |
| | | @PostMapping("mod") |
| | | public AjaxResult mod(@Validated @RequestBody WorkRegistrationModForm modForm) { |
| | | return toAjax(this.workRegistrationService.mod(modForm)); |
| | |
| | | * @param workIds 主键结合 |
| | | * @return 删除结果 |
| | | */ |
| | | @ApiOperation(value = "批量删除") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "workIds", dataTypeClass = List.class,value = "作业登记Ids"), |
| | | }) |
| | | @DeleteMapping("del/batch/{workIds}") |
| | | public AjaxResult delete(@PathVariable List<Long> workIds) { |
| | | return success(this.workRegistrationService.removeByIds(workIds)); |
| | | public AjaxResult delBatch(@PathVariable List<Long> workIds) { |
| | | this.workRegistrationService.delBatch(workIds); |
| | | return success(); |
| | | } |
| | | } |
| | | |
| | |
| | | package com.gkhy.exam.noncoalmine.entity; |
| | | |
| | | import java.util.Date; |
| | | import java.time.LocalDateTime; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.FieldFill; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.extension.activerecord.Model; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import com.ruoyi.common.core.domain.BaseEntity; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * (ExamSite)表实体类 |
| | |
| | | private String updateBy; |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date createTime; |
| | | private LocalDateTime createTime; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date updateTime; |
| | | |
| | | |
| | | private LocalDateTime updateTime; |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.entity; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.FieldFill; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.extension.activerecord.Model; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * (NcCert)表实体类 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-15 17:14:35 |
| | | */ |
| | | @Data |
| | | public class NcCert extends Model<NcCert> { |
| | | @TableId(type = IdType.AUTO) |
| | | private Long id; |
| | | //证书id(国家数据) |
| | | private Long certId; |
| | | //姓名 |
| | | private String name; |
| | | //性别 |
| | | private String sex; |
| | | //证件类型 |
| | | private String idcardTypeCode; |
| | | //证件类型名称 |
| | | private String idcardTypeName; |
| | | //身份证号 |
| | | private String idcardNum; |
| | | //档案编号 |
| | | private String archivesNum; |
| | | //证书编号 |
| | | private String certNum; |
| | | //证书状态 |
| | | private String certStatus; |
| | | //人员类型代码 |
| | | private String personTypeCode; |
| | | //人员类型名称 |
| | | private String personTypeName; |
| | | //作业类别名称 |
| | | private String jobTypeCode; |
| | | //作业类别名称 |
| | | private String jobTypeName; |
| | | //操作项目代码 |
| | | private String operItemCode; |
| | | //操作项目名称 |
| | | private String operItemName; |
| | | //签发机关ID |
| | | private Long issueOrgId; |
| | | //签发机关编码 |
| | | private String issueOrgCode; |
| | | //初领日期 |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date firstCertDate; |
| | | //应复审日期 |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date shouldReviewDate; |
| | | //签发机关名称 |
| | | private String issueOrgName; |
| | | //实际复审日期 |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date reviewDate; |
| | | //有效开始时间 |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date validBeginDate; |
| | | //有效结束时间 |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date validEndDate; |
| | | //复审机关ID |
| | | private Long reviewOrgId; |
| | | //复审机关编码 |
| | | private String reviewOrgCode; |
| | | //复审机关名称 |
| | | private String reviewOrgName; |
| | | //二维码字符串 |
| | | private String qrcode; |
| | | //二维码图片路径 |
| | | private String qrcodePath; |
| | | //照片名称 |
| | | private String imgName; |
| | | //照片数据,base64编码 |
| | | private String imgData; |
| | | private String imgPath; |
| | | |
| | | private Byte delFlag; |
| | | |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private String createBy; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private String updateBy; |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime createTime; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime updateTime; |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.entity; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.FieldFill; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.extension.activerecord.Model; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * (NcExamPlan)表实体类 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 13:21:48 |
| | | */ |
| | | @Data |
| | | public class NcExamPlan { |
| | | //考试计划id |
| | | @TableId(type = IdType.AUTO) |
| | | private Long id; |
| | | //考试计划id(国家数据) |
| | | private Long examPlanId; |
| | | //考试计划名称 |
| | | private String examPlanName; |
| | | //人员类型ID |
| | | private String personTypeCode; |
| | | //人员类型 |
| | | private String personTypeName; |
| | | //作业类别(行业类别)ID:(字典:考核对象第二级) |
| | | private String jobTypeCode; |
| | | //作业类别(行业类别) 字典:考核对象第二级 |
| | | private String jobTypeName; |
| | | //操作项目ID 字典:考核对象第三级 人员类型为特种作业操作人员时必填 |
| | | private String operitemCode; |
| | | //操作项目 字典:考核对象第三级 人员类型为特种作业操作人员时必填 |
| | | private String operitemName; |
| | | //考试类型 1:初训 2:复训 |
| | | private String examType; |
| | | //计划考试人数 |
| | | private Long plannedExamNumber; |
| | | //考试计划备案机关id |
| | | private String filingOrgId; |
| | | //考试计划备案机关名称 |
| | | private String filingOrg; |
| | | //理论考试点代码 |
| | | private String theoryExamPlaceCode; |
| | | //理论考试点名称 |
| | | private String theoryExamPlaceName; |
| | | //理论考试实施方式 1:流水考试 2:固定场次 |
| | | private String theoryExamUseMethod; |
| | | //理论考试时间(开始) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date theoryExamStartTime; |
| | | //理论考试时间(截止) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date theoryExamEndTime; |
| | | //理论考试是否当场补考 |
| | | private String isTheoryMakeupImmediate; |
| | | //理论考试补考时间(开始) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date theoryExamMakeupStartTime; |
| | | //理论考试补考时间(截止) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date theoryExamMakeupEndTime; |
| | | //实操考试点代码 |
| | | private String practicalExamPlaceCode; |
| | | //实操考试点名称 |
| | | private String practicalExamPlaceName; |
| | | //实操考试方式 1:人工考评 2:实操设备考评 |
| | | private String practicalExamMethod; |
| | | //实操考试时间(开始) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date practicalExamStartTime; |
| | | //实操考试时间(截止) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date practicalExamEndTime; |
| | | //实操考试是否当场补考 |
| | | private String isPracticalMakeupImmediate; |
| | | //实操考试补考时间(开始) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date practicalExamMakeupStartTime; |
| | | //实操考试补考时间(截止) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date practicalExamMakeupEndTime; |
| | | |
| | | private Byte delFlag; |
| | | |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private String createBy; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private String updateBy; |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime createTime; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.entity; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.FieldFill; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.extension.activerecord.Model; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * (NcExaminees)表实体类 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 10:01:22 |
| | | */ |
| | | @Data |
| | | public class NcExaminees { |
| | | //主键 |
| | | @TableId(type = IdType.AUTO) |
| | | private Long id; |
| | | //本系统中人员id |
| | | private Long staffId; |
| | | //培训系统中学员id 当学员被报名审核确认后,直接将相关档案信息从培训中取出放入该表,为0则为自主报名,不关联培训信息 |
| | | private Long trainStudentId; |
| | | //姓名 |
| | | private String name; |
| | | //性别描述 |
| | | private String sexName; |
| | | //性别 字典,性别 |
| | | private String sex; |
| | | //证件类型 字典,证件类型 |
| | | private String cardType; |
| | | //证件类型名称 |
| | | private String cardName; |
| | | //证件号码 |
| | | private String cardNum; |
| | | //考试计划(国家系统) |
| | | private Long examPlanId; |
| | | //培训机构id |
| | | private Long trainOrgId; |
| | | //培训机构名称 |
| | | private String trainOrgAme; |
| | | //民族 字典 |
| | | private String nationCode; |
| | | //民族名称 |
| | | private String nationName; |
| | | //理论场次ID |
| | | private Long theorySessionId; |
| | | //实操场次ID |
| | | private Long practicalSessionId; |
| | | //理论准考证号 |
| | | private String examCard; |
| | | //实操准考证号 |
| | | private String pracExamCard; |
| | | //考试中心 |
| | | private String examCenter; |
| | | //科目 |
| | | private String subject; |
| | | //考试结果;0-通过;1-未通过;2未知 |
| | | private String result; |
| | | //考试日期 |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date examTime; |
| | | |
| | | private Byte delFlag; |
| | | |
| | | private Long createOrgId; |
| | | |
| | | private String createOrgName; |
| | | |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private String createBy; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private String updateBy; |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime createTime; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.entity; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.FieldFill; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.extension.activerecord.Model; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * (NcStaff)表实体类 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 09:59:58 |
| | | */ |
| | | @Data |
| | | public class NcStaff { |
| | | @TableId(type = IdType.AUTO) |
| | | private Long id; |
| | | //姓名 |
| | | private String name; |
| | | //性别 |
| | | private String sex; |
| | | //民族 |
| | | private String nationCode; |
| | | //身份证 |
| | | private String idCardNum; |
| | | //手机号 |
| | | private String phone; |
| | | //最高学历 |
| | | private String highestEducation; |
| | | //证件照 |
| | | private String photoPath; |
| | | //删除标志(0代表存在 2代表删除) |
| | | private Byte delFlag; |
| | | |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private String createBy; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private String updateBy; |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime createTime; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.entity; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.FieldFill; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.extension.activerecord.Model; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * (NcStaffResume)表实体类 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 14:06:43 |
| | | */ |
| | | @Data |
| | | public class NcStaffResume { |
| | | @TableId(type = IdType.AUTO) |
| | | private Long id; |
| | | //人员id |
| | | private Long staffId; |
| | | //开始时间 |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date startTime; |
| | | //结束时间 |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date endTime; |
| | | //单位 |
| | | private String unit; |
| | | //删除标志(0代表存在 2代表删除) |
| | | private Byte delFlag; |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private String createBy; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private String updateBy; |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime createTime; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime updateTime; |
| | | |
| | | |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.entity; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.FieldFill; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.extension.activerecord.Model; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import com.ruoyi.common.core.domain.BaseEntity; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * (NcStaffTrain)表实体类 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 10:00:25 |
| | | */ |
| | | @Data |
| | | public class NcStaffTrain { |
| | | @TableId(type = IdType.AUTO) |
| | | private Long id; |
| | | //人员id |
| | | private Long staffId; |
| | | //开始时间 |
| | | private Date startTime; |
| | | //结束时间 |
| | | private Date endTime; |
| | | |
| | | private Long trainInstitutionId; |
| | | //培训机构名称 |
| | | private String trainInstitutionName; |
| | | //计划名称 |
| | | private String examPlanName; |
| | | //所属批次(本系统中计划id) |
| | | private String planId; |
| | | //科目 |
| | | private String subject; |
| | | |
| | | //培训类型 1:初训 2:复训 |
| | | private String trianTypeCode; |
| | | |
| | | private String personTypeCode; |
| | | |
| | | private String personTypeName; |
| | | |
| | | private String jobTypeCode; |
| | | |
| | | private String jobTypeName; |
| | | |
| | | private String operItemCode; |
| | | |
| | | private String operItemName; |
| | | //删除标志(0代表存在 2代表删除) |
| | | private Byte delFlag; |
| | | |
| | | private String name; |
| | | |
| | | private String idCardNum; |
| | | |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private String createBy; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private String updateBy; |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime createTime; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
| | |
| | | package com.gkhy.exam.noncoalmine.entity; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.FieldFill; |
| | |
| | | private String updateBy; |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date createTime; |
| | | private LocalDateTime createTime; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date updateTime; |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
| | |
| | | package com.gkhy.exam.noncoalmine.entity; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.FieldFill; |
| | |
| | | private String updateBy; |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date createTime; |
| | | private LocalDateTime createTime; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date updateTime; |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
| | |
| | | package com.gkhy.exam.noncoalmine.entity; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.FieldFill; |
| | |
| | | private String updateBy; |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date createTime; |
| | | private LocalDateTime createTime; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date updateTime; |
| | | |
| | | |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.gkhy.exam.noncoalmine.entity.NcCert; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | /** |
| | | * (NcCert)表数据库访问层 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-15 17:14:35 |
| | | */ |
| | | @Repository |
| | | @Mapper |
| | | public interface NcCertMapper extends BaseMapper<NcCert> { |
| | | |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.gkhy.exam.noncoalmine.entity.NcExamPlan; |
| | | import com.gkhy.exam.noncoalmine.model.query.NcExamPlanQuery; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (NcExamPlan)表数据库访问层 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 13:21:48 |
| | | */ |
| | | @Repository |
| | | @Mapper |
| | | public interface NcExamPlanMapper extends BaseMapper<NcExamPlan> { |
| | | List<NcExamPlan> selectNcExamPlanList(@Param("query") NcExamPlanQuery query); |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.gkhy.exam.noncoalmine.entity.NcExaminees; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | /** |
| | | * (NcExaminees)表数据库访问层 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 10:01:22 |
| | | */ |
| | | @Repository |
| | | @Mapper |
| | | public interface NcExamineesMapper extends BaseMapper<NcExaminees> { |
| | | |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.gkhy.exam.noncoalmine.entity.NcStaff; |
| | | import com.gkhy.exam.noncoalmine.model.query.NcStaffQuery; |
| | | import com.gkhy.exam.noncoalmine.model.vo.NcStaffVO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (NcStaff)表数据库访问层 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 09:59:58 |
| | | */ |
| | | @Repository |
| | | @Mapper |
| | | public interface NcStaffMapper extends BaseMapper<NcStaff> { |
| | | |
| | | List<NcStaffVO> getList(@Param("query") NcStaffQuery query); |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.gkhy.exam.noncoalmine.entity.NcStaffResume; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | /** |
| | | * (NcStaffResume)表数据库访问层 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 14:06:43 |
| | | */ |
| | | @Repository |
| | | @Mapper |
| | | public interface NcStaffResumeMapper extends BaseMapper<NcStaffResume> { |
| | | |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.gkhy.exam.noncoalmine.entity.NcStaffTrain; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | /** |
| | | * (NcStaffTrain)表数据库访问层 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 10:00:25 |
| | | */ |
| | | @Repository |
| | | @Mapper |
| | | public interface NcStaffTrainMapper extends BaseMapper<NcStaffTrain> { |
| | | |
| | | } |
| | | |
| | |
| | | public interface WorkRegistrationMapper extends BaseMapper<WorkRegistration> { |
| | | |
| | | List<WorkRegistration> listByPage(@Param("query") WorkRegistrationQuery query); |
| | | |
| | | } |
| | | |
| | |
| | | package com.gkhy.exam.noncoalmine.model.addForm; |
| | | |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.NotEmpty; |
| | |
| | | @Data |
| | | public class ExamSiteAddForm { |
| | | |
| | | //机构名称 |
| | | //考点名称 |
| | | @ApiModelProperty(value = "考点名称",required = true) |
| | | @NotEmpty(message = "请输入考点名称") |
| | | private String siteName; |
| | | //地区id |
| | | @ApiModelProperty(value = "地区id",required = true) |
| | | @NotNull(message = "请选择地区") |
| | | private Long districtId; |
| | | //地址 |
| | | @ApiModelProperty(value = "地址") |
| | | private String address; |
| | | //负责人 |
| | | @ApiModelProperty(value = "负责人") |
| | | private String header; |
| | | //负责人电话 |
| | | @ApiModelProperty(value = "负责人电话") |
| | | private String hphone; |
| | | //联系人 |
| | | @ApiModelProperty(value = "联系人") |
| | | private String contact; |
| | | //联系人电话 |
| | | @ApiModelProperty(value = "联系人电话") |
| | | private String cphone; |
| | | //是否为煤矿:0为非,1是 |
| | | @ApiModelProperty(value = "是否为煤矿",required = true,notes = "0为非,1是") |
| | | @NotNull(message = "请选择是否为煤矿") |
| | | private Byte isCm; |
| | | //备注 |
| | | @ApiModelProperty(value = "备注") |
| | | private String remark; |
| | | |
| | | @ApiModelProperty(value = "机构id",required = true) |
| | | @NotNull(message = "请选择机构") |
| | | private Long institutionId; |
| | | } |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.model.addForm; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | | * @author: zf |
| | | * @date: 2023/9/18 |
| | | * @time: 14:45 |
| | | */ |
| | | @ApiModel("考试经历") |
| | | @Data |
| | | public class NcExamineesAddForm { |
| | | @ApiModelProperty(value = "主键") |
| | | private Long id; |
| | | //考试中心 |
| | | @ApiModelProperty(value = "考试中心") |
| | | private String examCenter; |
| | | //科目 |
| | | @ApiModelProperty(value = "科目") |
| | | private String subject; |
| | | //考试结果;0-通过;1-未通过 |
| | | @ApiModelProperty(value = "考试结果;0-通过;1-未通过") |
| | | private String result; |
| | | //考试时间 |
| | | @ApiModelProperty(value = "考试时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date examTime; |
| | | |
| | | } |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.model.addForm; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.NotEmpty; |
| | | import javax.validation.constraints.NotNull; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | | * @author: zf |
| | | * @date: 2023/9/18 |
| | | * @time: 14:04 |
| | | */ |
| | | @ApiModel(value = "人员新增实体") |
| | | @Data |
| | | public class NcStaffAddForm { |
| | | //姓名 |
| | | @ApiModelProperty(value = "姓名",required = true) |
| | | @NotEmpty(message = "姓名不可为空") |
| | | private String name; |
| | | //性别 |
| | | @ApiModelProperty(value = "性别",required = true) |
| | | @NotNull(message = "性别不可为空") |
| | | private String sex; |
| | | //民族 |
| | | @ApiModelProperty(value = "民族",required = true) |
| | | @NotNull(message = "民族不可为空") |
| | | private String nationCode; |
| | | //身份证 |
| | | @ApiModelProperty(value = "身份证",required = true) |
| | | @NotEmpty(message = "身份证号不可为空") |
| | | private String idCardNum; |
| | | //手机号 |
| | | @ApiModelProperty(value = "手机号") |
| | | private String phone; |
| | | //最高学历 |
| | | @ApiModelProperty(value = "最高学历") |
| | | private String highestEducation; |
| | | //证件照 |
| | | @ApiModelProperty(value = "证件照") |
| | | private String photoPath; |
| | | //个人履历 |
| | | @ApiModelProperty(value = "个人履历") |
| | | private List<NcStaffResumeAddForm> resumeList; |
| | | //培训经历 |
| | | @ApiModelProperty(value = "培训经历") |
| | | private List<NcStaffTrainAddForm> trainList; |
| | | //考试经历 |
| | | @ApiModelProperty(value = "考试经历") |
| | | private List<NcExamineesAddForm> examineeList; |
| | | |
| | | } |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.model.addForm; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * (NcStaffResume)表实体类 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 14:06:43 |
| | | */ |
| | | @ApiModel(value = "履历实体") |
| | | @Data |
| | | public class NcStaffResumeAddForm{ |
| | | @ApiModelProperty(value = "主键") |
| | | private Long id; |
| | | |
| | | //开始时间 |
| | | @ApiModelProperty(value = "开始时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date startTime; |
| | | //结束时间 |
| | | @ApiModelProperty(value = "结束时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date endTime; |
| | | //单位 |
| | | @ApiModelProperty(value = "单位") |
| | | private String unit; |
| | | |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.model.addForm; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | | * @author: zf |
| | | * @date: 2023/9/18 |
| | | * @time: 14:27 |
| | | */ |
| | | @ApiModel("培训实体") |
| | | @Data |
| | | public class NcStaffTrainAddForm { |
| | | @ApiModelProperty(value = "主键") |
| | | private Long id; |
| | | //开始时间 |
| | | @ApiModelProperty(value = "开始时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date startTime; |
| | | //结束时间 |
| | | @ApiModelProperty(value = "开始时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date endTime; |
| | | @ApiModelProperty(value = "培训机构id") |
| | | private Long trainInstitutionId; |
| | | //培训机构名称 |
| | | @ApiModelProperty(value = "培训机构名称") |
| | | private String trainInstitutionName; |
| | | //计划名称 |
| | | @ApiModelProperty(value = "计划名称") |
| | | private String examPlanName; |
| | | //所属批次(本系统中计划id) |
| | | @ApiModelProperty(value = "所属批次(本系统中计划id)") |
| | | private Long planId; |
| | | //科目 |
| | | @ApiModelProperty(value = "科目") |
| | | private String subject; |
| | | } |
| | |
| | | import com.baomidou.mybatisplus.annotation.FieldFill; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.NotEmpty; |
| | |
| | | * @date: 2023/9/13 |
| | | * @time: 16:46 |
| | | */ |
| | | @ApiModel(value = "机构新增实体") |
| | | @Data |
| | | public class TrainingInstitutionAddForm { |
| | | //机构名称 |
| | | @ApiModelProperty(value = "机构名称",required = true) |
| | | @NotEmpty(message = "请输入机构名称") |
| | | private String institutionName; |
| | | //地区id |
| | | @ApiModelProperty(value = "地区id",required = true) |
| | | @NotNull(message = "请选择地区") |
| | | private Long districtId; |
| | | //地址 |
| | | @ApiModelProperty(value = "地址") |
| | | private String address; |
| | | //负责人 |
| | | @ApiModelProperty(value = "负责人") |
| | | private String header; |
| | | //负责人电话 |
| | | @ApiModelProperty(value = "负责人电话") |
| | | private String hphone; |
| | | //联系人 |
| | | @ApiModelProperty(value = "联系人") |
| | | private String contact; |
| | | //联系人电话 |
| | | @ApiModelProperty(value = "联系人电话") |
| | | private String cphone; |
| | | //是否为煤矿:0为非,1是 |
| | | @ApiModelProperty(value = "是否为煤矿:0为非,1是", required = true) |
| | | @NotNull(message = "请选择是否为煤矿") |
| | | private Byte isCm; |
| | | //备注 |
| | | @ApiModelProperty(value = "备注") |
| | | private String remark; |
| | | |
| | | } |
| | |
| | | package com.gkhy.exam.noncoalmine.model.addForm; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.NotEmpty; |
| | |
| | | @Data |
| | | public class ViolationRegistrationAddForm { |
| | | //姓名 |
| | | @ApiModelProperty(value = "姓名",required = true) |
| | | @NotEmpty(message = "请填写姓名") |
| | | private String name; |
| | | //身份证 |
| | | @ApiModelProperty(value = "身份证",required = true) |
| | | @NotEmpty(message = "请填写身份证") |
| | | private String idCard; |
| | | //电子证号 |
| | | @ApiModelProperty(value = "电子证号") |
| | | private String electNum; |
| | | //IC卡编号 |
| | | @ApiModelProperty(value = "IC卡编号") |
| | | private String icNum; |
| | | //作业时间 |
| | | @ApiModelProperty(value = "作业时间",required = true) |
| | | @NotNull(message = "请填写做业时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date violationTime; |
| | | //违章附件 |
| | | @ApiModelProperty(value = "违章附件") |
| | | private String violationPath; |
| | | //所属单位 |
| | | @ApiModelProperty(value = "所属单位",required = true) |
| | | @NotEmpty(message = "请填写所属单位") |
| | | private String dept; |
| | | //操作类型id |
| | | @ApiModelProperty(value = "操作类型id",required = true) |
| | | @NotNull(message = "请选择操作类型") |
| | | private Long operateTypeId; |
| | | //是否为煤矿:0为非,1是 |
| | | @ApiModelProperty(value = "是否为煤矿",required = true) |
| | | @NotNull(message = "是否为煤矿不可为空") |
| | | private Integer isCm; |
| | | //描述 |
| | | @ApiModelProperty(value = "描述") |
| | | private String remark; |
| | | } |
| | |
| | | package com.gkhy.exam.noncoalmine.model.addForm; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import javax.validation.constraints.NotEmpty; |
| | | import javax.validation.constraints.NotNull; |
| | | import java.util.Date; |
| | |
| | | * @date: 2023/9/11 |
| | | * @time: 17:09 |
| | | */ |
| | | @ApiModel(value = "作业登记实体") |
| | | @Data |
| | | public class WorkRegistrationAddForm { |
| | | |
| | | //姓名 |
| | | @ApiModelProperty(value = "姓名",required = true) |
| | | @NotEmpty(message = "请填写姓名") |
| | | private String name; |
| | | //身份证 |
| | | @ApiModelProperty(value = "身份证",required = true) |
| | | @NotEmpty(message = "请填写身份证") |
| | | private String idCard; |
| | | //电子证号 |
| | | @ApiModelProperty(value = "电子证号") |
| | | private String electNum; |
| | | //IC卡编号 |
| | | @ApiModelProperty(value = "IC卡编号") |
| | | private String icNum; |
| | | //作业时间 |
| | | @ApiModelProperty(value = "作业时间",required = true) |
| | | @NotNull(message = "请填写做业时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date workTime; |
| | | //所属单位 |
| | | @ApiModelProperty(value = "所属单位") |
| | | @NotEmpty(message = "请填写所属单位") |
| | | private String dept; |
| | | //操作类型id |
| | | @ApiModelProperty(value = "操作类型id",required = true) |
| | | @NotNull(message = "请选择操作类型") |
| | | private Long operateTypeId; |
| | | //是否为煤矿:0为非,1是 |
| | | @ApiModelProperty(value = "是否为煤矿",required = true,notes = "0为非,1是") |
| | | @NotNull(message = "是否为煤矿不可为空") |
| | | private Integer isCm; |
| | | private Byte isCm; |
| | | //描述 |
| | | @ApiModelProperty(value = "描述") |
| | | private String remark; |
| | | |
| | | } |
| | |
| | | package com.gkhy.exam.noncoalmine.model.modForm; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | |
| | | import javax.validation.constraints.NotEmpty; |
| | | import javax.validation.constraints.NotNull; |
| | | |
| | |
| | | * @date: 2023/9/14 |
| | | * @time: 16:47 |
| | | */ |
| | | @ApiModel(value = "考点实体") |
| | | @Data |
| | | public class ExamSiteModForm { |
| | | @ApiModelProperty(value = "考点主键",required = true) |
| | | @NotNull(message = "考点主键不可为空") |
| | | private String siteId; |
| | | private Long siteId; |
| | | //考点名称 |
| | | @ApiModelProperty(value = "考点名称",required = true) |
| | | @NotEmpty(message = "请输入考点名称") |
| | | private String siteName; |
| | | //地区id |
| | | @ApiModelProperty(value = "地区id",required = true) |
| | | @NotNull(message = "请选择地区") |
| | | private Long districtId; |
| | | //地址 |
| | | @ApiModelProperty(value = "地址") |
| | | private String address; |
| | | //负责人 |
| | | @ApiModelProperty(value = "负责人") |
| | | private String header; |
| | | //负责人电话 |
| | | @ApiModelProperty(value = "负责人电话") |
| | | private String hphone; |
| | | //联系人 |
| | | @ApiModelProperty(value = "联系人") |
| | | private String contact; |
| | | //联系人电话 |
| | | @ApiModelProperty(value = "联系人电话") |
| | | private String cphone; |
| | | //是否为煤矿:0为非,1是 |
| | | @ApiModelProperty(value = "是否为煤矿",required = true,notes = "0为非,1是") |
| | | @NotNull(message = "请选择是否为煤矿") |
| | | private Byte isCm; |
| | | //备注 |
| | | @ApiModelProperty(value = "备注") |
| | | private String remark; |
| | | |
| | | @ApiModelProperty(value = "机构id",required = true) |
| | | @NotNull(message = "请选择机构") |
| | | private Long institutionId; |
| | | } |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.model.modForm; |
| | | |
| | | import com.gkhy.exam.noncoalmine.model.addForm.NcExamineesAddForm; |
| | | import com.gkhy.exam.noncoalmine.model.addForm.NcStaffResumeAddForm; |
| | | import com.gkhy.exam.noncoalmine.model.addForm.NcStaffTrainAddForm; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.NotEmpty; |
| | | import javax.validation.constraints.NotNull; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | | * @author: zf |
| | | * @date: 2023/9/18 |
| | | * @time: 14:11 |
| | | */ |
| | | @ApiModel(value = "人员实体") |
| | | @Data |
| | | public class NcStaffModForm { |
| | | @ApiModelProperty(value = "人员主键",required = true) |
| | | @NotNull(message = "人员主键不可为空") |
| | | private Long id; |
| | | //姓名 |
| | | @ApiModelProperty(value = "姓名",required = true) |
| | | @NotEmpty(message = "姓名不可为空") |
| | | private String name; |
| | | //性别 |
| | | @ApiModelProperty(value = "性别",required = true) |
| | | @NotNull(message = "性别不可为空") |
| | | private String sex; |
| | | //民族 |
| | | @ApiModelProperty(value = "民族",required = true) |
| | | @NotNull(message = "民族不可为空") |
| | | private String nationCode; |
| | | //身份证 |
| | | @ApiModelProperty(value = "身份证",required = true) |
| | | @NotEmpty(message = "身份证号不可为空") |
| | | private String idCardNum; |
| | | //手机号 |
| | | @ApiModelProperty(value = "手机号") |
| | | private String phone; |
| | | //最高学历 |
| | | @ApiModelProperty(value = "最高学历") |
| | | private String highestEducation; |
| | | //证件照 |
| | | @ApiModelProperty(value = "证件照") |
| | | private String photoPath; |
| | | //个人履历 |
| | | @ApiModelProperty(value = "个人履历") |
| | | private List<NcStaffResumeAddForm> resumeList; |
| | | //培训经历 |
| | | @ApiModelProperty(value = "培训经历") |
| | | private List<NcStaffTrainAddForm> trainList; |
| | | //考试经历 |
| | | @ApiModelProperty(value = "考试经历") |
| | | private List<NcExamineesAddForm> examineeList; |
| | | |
| | | } |
| | |
| | | package com.gkhy.exam.noncoalmine.model.modForm; |
| | | |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.NotEmpty; |
| | |
| | | */ |
| | | @Data |
| | | public class TrainingInstitutionModForm { |
| | | @ApiModelProperty(value = "机构主键",required = true) |
| | | @NotNull(message = "机构主键不可为空") |
| | | private String institutionId; |
| | | //机构名称 |
| | | @ApiModelProperty(value = "机构名称",required = true) |
| | | @NotEmpty(message = "请输入机构名称") |
| | | private String institutionName; |
| | | //地区id |
| | | @ApiModelProperty(value = "地区id",required = true) |
| | | @NotNull(message = "请选择地区") |
| | | private Long districtId; |
| | | //地址 |
| | | @ApiModelProperty(value = "地址") |
| | | private String address; |
| | | //负责人 |
| | | @ApiModelProperty(value = "负责人") |
| | | private String header; |
| | | //负责人电话 |
| | | @ApiModelProperty(value = "负责人电话") |
| | | private String hphone; |
| | | //联系人 |
| | | @ApiModelProperty(value = "联系人") |
| | | private String contact; |
| | | //联系人电话 |
| | | @ApiModelProperty(value = "联系人电话") |
| | | private String cphone; |
| | | //是否为煤矿:0为非,1是 |
| | | @ApiModelProperty(value = "是否为煤矿:0为非,1是", required = true) |
| | | @NotNull(message = "请选择是否为煤矿") |
| | | private Byte isCm; |
| | | //备注 |
| | | @ApiModelProperty(value = "备注") |
| | | private String remark; |
| | | } |
| | |
| | | package com.gkhy.exam.noncoalmine.model.modForm; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.NotEmpty; |
| | |
| | | */ |
| | | @Data |
| | | public class ViolationRegistrationModForm { |
| | | @ApiModelProperty(value = "违章主键",required = true) |
| | | @NotNull(message = "违章主键不可为空") |
| | | private Long violationId; |
| | | //姓名 |
| | | @ApiModelProperty(value = "姓名",required = true) |
| | | @NotEmpty(message = "请填写姓名") |
| | | private String name; |
| | | //身份证 |
| | | @ApiModelProperty(value = "身份证",required = true) |
| | | @NotEmpty(message = "请填写身份证") |
| | | private String idCard; |
| | | //电子证号 |
| | | @ApiModelProperty(value = "电子证号") |
| | | private String electNum; |
| | | //IC卡编号 |
| | | @ApiModelProperty(value = "IC卡编号") |
| | | private String icNum; |
| | | //作业时间 |
| | | @ApiModelProperty(value = "作业时间",required = true) |
| | | @NotNull(message = "请填写做业时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date violationTime; |
| | | //违章附件 |
| | | @ApiModelProperty(value = "违章附件") |
| | | private String violationPath; |
| | | //所属单位 |
| | | @ApiModelProperty(value = "所属单位",required = true) |
| | | @NotEmpty(message = "请填写所属单位") |
| | | private String dept; |
| | | //操作类型id |
| | | @ApiModelProperty(value = "操作类型id",required = true) |
| | | @NotNull(message = "请选择操作类型") |
| | | private Long operateTypeId; |
| | | //是否为煤矿:0为非,1是 |
| | | @ApiModelProperty(value = "是否为煤矿",required = true) |
| | | @NotNull(message = "是否为煤矿不可为空") |
| | | private Integer isCm; |
| | | //描述 |
| | | @ApiModelProperty(value = "描述") |
| | | private String remark; |
| | | } |
| | |
| | | package com.gkhy.exam.noncoalmine.model.modForm; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.NotEmpty; |
| | | import javax.validation.constraints.NotNull; |
| | | import java.util.Date; |
| | |
| | | */ |
| | | @Data |
| | | public class WorkRegistrationModForm { |
| | | @NotNull(message = "做业主键不可为空") |
| | | @ApiModelProperty(value = "作业主键",required = true) |
| | | @NotNull(message = "作业主键不可为空") |
| | | private Long workId; |
| | | //姓名 |
| | | @ApiModelProperty(value = "姓名",required = true) |
| | | @NotEmpty(message = "请填写姓名") |
| | | private String name; |
| | | //身份证 |
| | | @ApiModelProperty(value = "身份证",required = true) |
| | | @NotEmpty(message = "请填写身份证") |
| | | private String idCard; |
| | | //电子证号 |
| | | @ApiModelProperty(value = "电子证号") |
| | | private String electNum; |
| | | //IC卡编号 |
| | | @ApiModelProperty(value = "IC卡编号") |
| | | private String icNum; |
| | | //作业时间 |
| | | @ApiModelProperty(value = "作业时间",required = true) |
| | | @NotNull(message = "请填写做业时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date violationTime; |
| | | private Date workTime; |
| | | //所属单位 |
| | | @ApiModelProperty(value = "所属单位") |
| | | @NotEmpty(message = "请填写所属单位") |
| | | private String dept; |
| | | //操作类型id |
| | | @ApiModelProperty(value = "操作类型id",required = true) |
| | | @NotNull(message = "请选择操作类型") |
| | | private Long operateTypeId; |
| | | //是否为煤矿:0为非,1是 |
| | | @ApiModelProperty(value = "是否为煤矿",required = true,notes = "0为非,1是") |
| | | @NotNull(message = "是否为煤矿不可为空") |
| | | private Integer isCm; |
| | | private Byte isCm; |
| | | //描述 |
| | | @ApiModelProperty(value = "描述") |
| | | private String remark; |
| | | } |
| | |
| | | package com.gkhy.exam.noncoalmine.model.query; |
| | | |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | |
| | | * @date: 2023/9/14 |
| | | * @time: 16:35 |
| | | */ |
| | | @ApiModel |
| | | @Data |
| | | public class ExamSiteQuery { |
| | | //机构名称 |
| | | @ApiModelProperty(value = "机构名称") |
| | | private String siteName; |
| | | //是否为煤矿:0为非,1是 |
| | | @ApiModelProperty(value = "是否为煤矿",notes = "0为非,1是") |
| | | private Byte isCm; |
| | | //区划编码 |
| | | @ApiModelProperty(value = "区划编码") |
| | | private String districtCode; |
| | | } |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.model.query; |
| | | |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | | * @author: zf |
| | | * @date: 2023/9/15 |
| | | * @time: 17:20 |
| | | */ |
| | | @ApiModel(value = "证书查询实体") |
| | | @Data |
| | | public class NcCertQuery { |
| | | @ApiModelProperty(value = "姓名") |
| | | private String name; |
| | | |
| | | /** 证件类型代码 */ |
| | | @ApiModelProperty(value = "证件类型代码") |
| | | private String idcardTypeCode; |
| | | |
| | | /** 身份证件号 */ |
| | | @ApiModelProperty(value = "身份证件号") |
| | | private String idcardNum; |
| | | } |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.model.query; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | | * @author: zf |
| | | * @date: 2023/9/18 |
| | | * @time: 13:25 |
| | | */ |
| | | @ApiModel("考试计划查询实体") |
| | | @Data |
| | | public class NcExamPlanQuery { |
| | | @ApiModelProperty(value = "考试计划名称") |
| | | private String examPlanName; |
| | | @ApiModelProperty(value = "开始时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private String startTime; |
| | | @ApiModelProperty(value = "结束时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private String endTime; |
| | | } |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.model.query; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | | * @author: zf |
| | | * @date: 2023/9/18 |
| | | * @time: 14:00 |
| | | */ |
| | | @ApiModel(value = "人员查询实体") |
| | | @Data |
| | | public class NcStaffQuery { |
| | | @ApiModelProperty(value = "姓名") |
| | | private String name; |
| | | |
| | | @ApiModelProperty(value = "省份证") |
| | | private String idCardNum; |
| | | } |
| | |
| | | package com.gkhy.exam.noncoalmine.model.query; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | |
| | | * @date: 2023/9/13 |
| | | * @time: 16:33 |
| | | */ |
| | | @ApiModel(value = "机构擦查询实体") |
| | | @Data |
| | | public class TrainingInstitutionQuery { |
| | | //机构名称 |
| | | @ApiModelProperty(value = "机构名称") |
| | | private String institutionName; |
| | | //是否为煤矿:0为非,1是 |
| | | @ApiModelProperty(value = "是否为煤矿:0为非,1是") |
| | | private Byte isCm; |
| | | //区划编码 |
| | | @ApiModelProperty(value = "区划编码") |
| | | private String districtCode; |
| | | } |
| | |
| | | package com.gkhy.exam.noncoalmine.model.query; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.model.vo; |
| | | |
| | | import lombok.Data; |
| | | |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | | * @author: zf |
| | | * @date: 2023/9/20 |
| | | * @time: 10:29 |
| | | */ |
| | | @Data |
| | | public class ExamPlanExaminee { |
| | | private String cardType; |
| | | private String cardNum; |
| | | private String name; |
| | | private String sex; |
| | | } |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.model.vo; |
| | | |
| | | import lombok.Data; |
| | | |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | | * @author: zf |
| | | * @date: 2023/9/20 |
| | | * @time: 10:26 |
| | | */ |
| | | @Data |
| | | public class ExamPlanInfo<T> { |
| | | private Long id; |
| | | //考试计划名称 |
| | | private String examPlanName; |
| | | //人员类型ID |
| | | private String personTypeCode; |
| | | //人员类型 |
| | | private String personTypeName; |
| | | //作业类别(行业类别)ID:(字典:考核对象第二级) |
| | | private String jobTypeCode; |
| | | //作业类别(行业类别) 字典:考核对象第二级 |
| | | private String jobTypeName; |
| | | //操作项目ID 字典:考核对象第三级 人员类型为特种作业操作人员时必填 |
| | | private String operitemCode; |
| | | //操作项目 字典:考核对象第三级 人员类型为特种作业操作人员时必填 |
| | | private String operitemName; |
| | | //考试类型 1:初训 2:复训 |
| | | private String examType; |
| | | //计划考试人数 |
| | | private Long plannedExamNumber; |
| | | //考试计划备案机关id |
| | | private String filingOrgId; |
| | | //考试计划备案机关名称 |
| | | private String filingOrg; |
| | | //理论考试点代码 |
| | | private String theoryExamPlaceCode; |
| | | //理论考试点名称 |
| | | private String theoryExamPlaceName; |
| | | //理论考试实施方式 1:流水考试 2:固定场次 |
| | | private String theoryExamUseMethod; |
| | | //理论考试时间(开始) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date theoryExamStartTime; |
| | | //理论考试时间(截止) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date theoryExamEndTime; |
| | | //理论考试是否当场补考 |
| | | private String isTheoryMakeupImmediate; |
| | | //理论考试补考时间(开始) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date theoryExamMakeupStartTime; |
| | | //理论考试补考时间(截止) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date theoryExamMakeupEndTime; |
| | | //实操考试点代码 |
| | | private String practicalExamPlaceCode; |
| | | //实操考试点名称 |
| | | private String practicalExamPlaceName; |
| | | //实操考试方式 1:人工考评 2:实操设备考评 |
| | | private String practicalExamMethod; |
| | | //实操考试时间(开始) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date practicalExamStartTime; |
| | | //实操考试时间(截止) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date practicalExamEndTime; |
| | | //实操考试是否当场补考 |
| | | private String isPracticalMakeupImmediate; |
| | | //实操考试补考时间(开始) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date practicalExamMakeupStartTime; |
| | | //实操考试补考时间(截止) 格式:yyyy-MM-dd HH:mm:ss |
| | | private Date practicalExamMakeupEndTime; |
| | | /** |
| | | * 考生信息 |
| | | */ |
| | | private List<T> examinees; |
| | | } |
| | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | |
| | | private String createBy; |
| | | private String updateBy; |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date createTime; |
| | | private LocalDateTime createTime; |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date updateTime; |
| | | private LocalDateTime updateTime; |
| | | private String districtName; |
| | | |
| | | } |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.model.vo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.FieldFill; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import com.gkhy.exam.noncoalmine.model.addForm.NcExamineesAddForm; |
| | | import com.gkhy.exam.noncoalmine.model.addForm.NcStaffResumeAddForm; |
| | | import com.gkhy.exam.noncoalmine.model.addForm.NcStaffTrainAddForm; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | | * @author: zf |
| | | * @date: 2023/9/18 |
| | | * @time: 14:03 |
| | | */ |
| | | @Data |
| | | public class NcStaffVO { |
| | | private Long id; |
| | | //姓名 |
| | | private String name; |
| | | //性别 |
| | | private String sex; |
| | | //民族 |
| | | private String nationCode; |
| | | //身份证 |
| | | private String idCardNum; |
| | | //手机号 |
| | | private String phone; |
| | | //最高学历 |
| | | private String highestEducation; |
| | | //证件照 |
| | | private String photoPath; |
| | | //删除标志(0代表存在 2代表删除) |
| | | private Integer delFlag; |
| | | |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private String createBy; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private String updateBy; |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime createTime; |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime updateTime; |
| | | |
| | | //履历 |
| | | private Object resumeList; |
| | | //培训 |
| | | private Object trainList; |
| | | //考试 |
| | | private Object examineeList; |
| | | //证书 |
| | | private Object certList; |
| | | //违章 |
| | | private Object violationList; |
| | | //作业 |
| | | private Object workList; |
| | | //作业数量 |
| | | private Integer workCount; |
| | | //违章数量 |
| | | private Integer violationCount; |
| | | //证书数据量 |
| | | private Integer certCount; |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | } |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.model.vo; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | | |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | | * @author: zf |
| | | * @date: 2023/9/20 |
| | | * @time: 16:03 |
| | | */ |
| | | @Data |
| | | public class ReturnCertVO { |
| | | /** 主键 */ |
| | | private Long id; |
| | | |
| | | /** 姓名 */ |
| | | private String name; |
| | | |
| | | /** 性别 */ |
| | | private String sex; |
| | | |
| | | /** 证件类型代码 */ |
| | | private String idcardTypeCode; |
| | | |
| | | /** 证件类型名称 */ |
| | | private String idcardTypeName; |
| | | |
| | | /** 身份证件号 */ |
| | | private String idcardNum; |
| | | |
| | | /** 档案编号 */ |
| | | private String archivesNum; |
| | | |
| | | /** 证号 */ |
| | | private String certNum; |
| | | |
| | | /** 证书状态 */ |
| | | private String certStatus; |
| | | |
| | | /** 人员类型代码 */ |
| | | private String personTypeCode; |
| | | |
| | | /** 人员类型名称 */ |
| | | private String personTypeName; |
| | | |
| | | /** 作业类别名称 */ |
| | | private String jobTypeCode; |
| | | |
| | | /** 作业类别名称 */ |
| | | private String jobTypeName; |
| | | |
| | | /** 操作项目代码 */ |
| | | private String operItemCode; |
| | | |
| | | /** 操作项目名称 */ |
| | | private String operItemName; |
| | | |
| | | /** 签发机关ID */ |
| | | private Long issueOrgId; |
| | | |
| | | /** 签发机关编码 */ |
| | | private String issueOrgCode; |
| | | |
| | | /** 初领日期 */ |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date firstCertDate; |
| | | |
| | | /** 应复审日期 */ |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date shouldReviewDate; |
| | | |
| | | /** 签发机关名称 */ |
| | | private String issueOrgName; |
| | | |
| | | /** 实际复审日期 */ |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date reviewDate; |
| | | |
| | | /** 有效开始时间 */ |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date validBeginDate; |
| | | |
| | | /** 有效结束时间 */ |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date validEndDate; |
| | | |
| | | /** 复审机关ID */ |
| | | private Long reviewOrgId; |
| | | |
| | | /** 复审机关编码 */ |
| | | private String reviewOrgCode; |
| | | |
| | | /** 复审机关名称 */ |
| | | private String reviewOrgName; |
| | | |
| | | /** 二维码字符串 */ |
| | | private String qrcode; |
| | | |
| | | /** 二维码图片路径 */ |
| | | private String qrcodePath; |
| | | |
| | | /** 创建人名称 */ |
| | | private String createUserName; |
| | | |
| | | /** 照片名称 */ |
| | | private String imgName; |
| | | |
| | | /** 照片数据,base64编码 */ |
| | | private String imgData; |
| | | private String imgPath; |
| | | |
| | | } |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.model.vo; |
| | | |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | | * @author: zf |
| | | * @date: 2023/9/20 |
| | | * @time: 10:57 |
| | | */ |
| | | @Data |
| | | public class ReturnVO<T> { |
| | | private Integer code; |
| | | private String msg; |
| | | private T data; |
| | | } |
| | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | |
| | | private String createBy; |
| | | private String updateBy; |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date createTime; |
| | | private LocalDateTime createTime; |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date updateTime; |
| | | private LocalDateTime updateTime; |
| | | |
| | | private String districtName; |
| | | |
| | |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | |
| | | private String updateBy; |
| | | |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date createTime; |
| | | private LocalDateTime createTime; |
| | | |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date updateTime; |
| | | private LocalDateTime updateTime; |
| | | |
| | | private String qualificationType; |
| | | |
| | |
| | | package com.gkhy.exam.noncoalmine.model.vo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.FieldFill; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | |
| | | |
| | | private String createBy; |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date createTime; |
| | | private LocalDateTime createTime; |
| | | |
| | | private String qualificationType; |
| | | |
| | |
| | | int add(ExamSiteAddForm addForm); |
| | | |
| | | int mod(ExamSiteModForm modForm); |
| | | |
| | | void delBatch(List<Long> siteIds); |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.gkhy.exam.noncoalmine.entity.NcCert; |
| | | import com.gkhy.exam.noncoalmine.model.query.NcCertQuery; |
| | | import com.ruoyi.common.core.domain.AjaxResult; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (NcCert)表服务接口 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-15 17:14:35 |
| | | */ |
| | | public interface NcCertService extends IService<NcCert> { |
| | | |
| | | List<NcCert> getList(NcCertQuery query); |
| | | |
| | | void syncCert(NcCertQuery query); |
| | | |
| | | List<NcCert> getByIdCard(String idCard); |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.gkhy.exam.noncoalmine.entity.NcExamPlan; |
| | | import com.gkhy.exam.noncoalmine.model.query.NcExamPlanQuery; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (NcExamPlan)表服务接口 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 13:21:55 |
| | | */ |
| | | public interface NcExamPlanService extends IService<NcExamPlan> { |
| | | |
| | | List<NcExamPlan> selectNcExamPlanList(NcExamPlanQuery query); |
| | | |
| | | void syncExamPlan(); |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.gkhy.exam.noncoalmine.entity.NcExaminees; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (NcExaminees)表服务接口 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 10:01:22 |
| | | */ |
| | | public interface NcExamineesService extends IService<NcExaminees> { |
| | | |
| | | List<NcExaminees> getByStaffid(Long stuffId); |
| | | |
| | | List<NcExaminees> getByIdCard(String idCard); |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.gkhy.exam.noncoalmine.entity.NcStaffResume; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (NcStaffResume)表服务接口 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 14:06:43 |
| | | */ |
| | | public interface NcStaffResumeService extends IService<NcStaffResume> { |
| | | |
| | | List<NcStaffResume> getByStaffId(Long stuffId); |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.gkhy.exam.noncoalmine.entity.NcStaff; |
| | | import com.gkhy.exam.noncoalmine.model.addForm.NcStaffAddForm; |
| | | import com.gkhy.exam.noncoalmine.model.modForm.NcStaffModForm; |
| | | import com.gkhy.exam.noncoalmine.model.query.NcStaffQuery; |
| | | import com.gkhy.exam.noncoalmine.model.vo.NcStaffVO; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (NcStaff)表服务接口 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 09:59:58 |
| | | */ |
| | | public interface NcStaffService extends IService<NcStaff> { |
| | | |
| | | List<NcStaffVO> selectStaffList(NcStaffQuery query); |
| | | |
| | | int add(NcStaffAddForm addForm); |
| | | |
| | | void mod(NcStaffModForm modForm); |
| | | |
| | | NcStaff getByIdCard(String IdCard); |
| | | |
| | | void delBatch(List<Long> staffIds); |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.gkhy.exam.noncoalmine.entity.NcStaffTrain; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (NcStaffTrain)表服务接口 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 10:00:25 |
| | | */ |
| | | public interface NcStaffTrainService extends IService<NcStaffTrain> { |
| | | |
| | | List<NcStaffTrain> getByStaffId(Long staffId); |
| | | } |
| | | |
| | |
| | | int mod(TrainingInstitutionModForm modForm); |
| | | |
| | | int add(TrainingInstitutionAddForm addForm); |
| | | |
| | | void delBatch(List<Long> institutionIds); |
| | | } |
| | | |
| | |
| | | |
| | | int mod(ViolationRegistrationModForm modForm); |
| | | List<ViolationRegistrationVO> getByIdCard(String idCard,byte isCm); |
| | | |
| | | void delBatch(List<Long> violationIds); |
| | | } |
| | | |
| | |
| | | int mod(WorkRegistrationModForm modForm); |
| | | |
| | | List<WorkRegistrationVO> getByIdCard(String idCard, byte isCm); |
| | | |
| | | void delBatch(List<Long> workIds); |
| | | } |
| | | |
| | |
| | | package com.gkhy.exam.noncoalmine.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.gkhy.exam.noncoalmine.entity.ExamSite; |
| | | import com.gkhy.exam.noncoalmine.entity.WorkRegistration; |
| | | import com.gkhy.exam.noncoalmine.mapper.ExamSiteMapper; |
| | | import com.gkhy.exam.noncoalmine.model.addForm.ExamSiteAddForm; |
| | | import com.gkhy.exam.noncoalmine.model.modForm.ExamSiteModForm; |
| | |
| | | BeanUtils.copyProperties(modForm,examSite); |
| | | return baseMapper.updateById(examSite); |
| | | } |
| | | |
| | | @Override |
| | | public void delBatch(List<Long> siteIds) { |
| | | UpdateWrapper<ExamSite> updateWrapper = new UpdateWrapper<>(); |
| | | updateWrapper.in("site_id",siteIds) |
| | | .set("del_flag",(byte)2); |
| | | this.update(updateWrapper); |
| | | } |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.service.impl; |
| | | |
| | | import com.alibaba.fastjson2.JSON; |
| | | import com.alibaba.fastjson2.JSONObject; |
| | | import com.alibaba.fastjson2.TypeReference; |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.gkhy.exam.noncoalmine.entity.NcCert; |
| | | import com.gkhy.exam.noncoalmine.mapper.NcCertMapper; |
| | | import com.gkhy.exam.noncoalmine.model.query.NcCertQuery; |
| | | import com.gkhy.exam.noncoalmine.model.vo.ExamPlanExaminee; |
| | | import com.gkhy.exam.noncoalmine.model.vo.ExamPlanInfo; |
| | | import com.gkhy.exam.noncoalmine.model.vo.ReturnCertVO; |
| | | import com.gkhy.exam.noncoalmine.model.vo.ReturnVO; |
| | | import com.gkhy.exam.noncoalmine.service.NcCertService; |
| | | import com.ruoyi.common.enums.HttpMethod; |
| | | import com.ruoyi.common.exception.ServiceException; |
| | | import com.ruoyi.common.signature.SignatureUtils; |
| | | import com.ruoyi.common.utils.StringUtils; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.util.CollectionUtils; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (NcCert)表服务实现类 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-15 17:14:35 |
| | | */ |
| | | @Service("ncCertService") |
| | | public class NcCertServiceImpl extends ServiceImpl<NcCertMapper, NcCert> implements NcCertService { |
| | | @Autowired |
| | | private NcCertMapper ncCertMapper; |
| | | |
| | | @Override |
| | | public List<NcCert> getList(NcCertQuery query) { |
| | | List<NcCert> ncCerts = ncCertMapper.selectList(new LambdaQueryWrapper<NcCert>() |
| | | .eq(NcCert::getDelFlag, (byte) 0) |
| | | .eq(StringUtils.isNotEmpty(query.getName()), NcCert::getName, query.getName()) |
| | | ); |
| | | return ncCerts; |
| | | } |
| | | |
| | | @Override |
| | | public void syncCert(NcCertQuery query) { |
| | | if(StringUtils.isEmpty(query.getIdcardNum())){ |
| | | throw new ServiceException("身份证号不能为空"); |
| | | } |
| | | query.setIdcardTypeCode("01"); |
| | | String bodyParam = JSON.toJSONString(query); |
| | | |
| | | String json = SignatureUtils.getObject(bodyParam, "/api/v1/cert/query", HttpMethod.POST); |
| | | ReturnVO<List<ReturnCertVO>> returnVo = JSONObject.parseObject(json, new TypeReference<ReturnVO<List<ReturnCertVO>>>() {}); |
| | | if(returnVo.getCode() == null || returnVo.getCode() != 200){ |
| | | throw new ServiceException("拉取数据异常"); |
| | | } |
| | | if(returnVo.getData() == null){ |
| | | throw new ServiceException("无数据可更新"); |
| | | } |
| | | //同步数据 |
| | | List<ReturnCertVO> returnCertVOList = returnVo.getData(); |
| | | if(!CollectionUtils.isEmpty(returnCertVOList)){ |
| | | for (ReturnCertVO returnCertVo : returnCertVOList) { |
| | | NcCert ncCert = new NcCert(); |
| | | BeanUtils.copyProperties(returnCertVo,ncCert); |
| | | ncCert.setCertId(returnCertVo.getId()); |
| | | ncCert.setId(null); |
| | | ncCert.setDelFlag((byte) 0); |
| | | if(!isExsit(returnCertVo.getId())){ |
| | | baseMapper.insert(ncCert); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | |
| | | @Override |
| | | public List<NcCert> getByIdCard(String idCard) { |
| | | List<NcCert> ncCerts = baseMapper.selectList(new LambdaQueryWrapper<NcCert>().eq(NcCert::getDelFlag, (byte) 0) |
| | | .eq(NcCert::getIdcardNum, idCard)); |
| | | return ncCerts; |
| | | } |
| | | private boolean isExsit(Long certId){ |
| | | NcCert ncCert = baseMapper.selectOne(new LambdaQueryWrapper<NcCert>() |
| | | .eq(NcCert::getDelFlag, (byte) 0) |
| | | .eq(NcCert::getCertId, certId)); |
| | | if (ncCert != null){ |
| | | return true; |
| | | } |
| | | return false; |
| | | } |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.service.impl; |
| | | |
| | | import com.alibaba.fastjson2.JSONObject; |
| | | import com.alibaba.fastjson2.TypeReference; |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.gkhy.exam.noncoalmine.entity.NcExaminees; |
| | | import com.gkhy.exam.noncoalmine.entity.NcStaff; |
| | | import com.gkhy.exam.noncoalmine.mapper.NcExamPlanMapper; |
| | | import com.gkhy.exam.noncoalmine.entity.NcExamPlan; |
| | | import com.gkhy.exam.noncoalmine.model.query.NcExamPlanQuery; |
| | | import com.gkhy.exam.noncoalmine.model.vo.ExamPlanExaminee; |
| | | import com.gkhy.exam.noncoalmine.model.vo.ExamPlanInfo; |
| | | import com.gkhy.exam.noncoalmine.model.vo.ReturnVO; |
| | | import com.gkhy.exam.noncoalmine.service.NcExamPlanService; |
| | | import com.gkhy.exam.noncoalmine.service.NcExamineesService; |
| | | import com.gkhy.exam.noncoalmine.service.NcStaffService; |
| | | import com.ruoyi.common.enums.HttpMethod; |
| | | import com.ruoyi.common.exception.ServiceException; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.util.CollectionUtils; |
| | | |
| | | import java.io.UnsupportedEncodingException; |
| | | import java.net.URLEncoder; |
| | | import java.text.SimpleDateFormat; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | import static com.ruoyi.common.signature.SignatureUtils.getObject; |
| | | |
| | | /** |
| | | * (NcExamPlan)表服务实现类 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 13:21:55 |
| | | */ |
| | | @Service("ncExamPlanService") |
| | | public class NcExamPlanServiceImpl extends ServiceImpl<NcExamPlanMapper, NcExamPlan> implements NcExamPlanService { |
| | | @Autowired |
| | | private NcExamPlanMapper ncExamPlanMapper; |
| | | |
| | | @Autowired |
| | | private NcStaffService ncStaffService; |
| | | @Autowired |
| | | private NcExamineesService ncExamineesService; |
| | | @Override |
| | | public List<NcExamPlan> selectNcExamPlanList(NcExamPlanQuery query) { |
| | | return ncExamPlanMapper.selectNcExamPlanList(query); |
| | | } |
| | | @Transactional |
| | | @Override |
| | | public void syncExamPlan() { |
| | | |
| | | String startTime = "2018-05-25 00:00:00"; |
| | | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); |
| | | String endTime = sdf.format(new Date()); |
| | | try { |
| | | startTime = URLEncoder.encode(startTime, "UTF-8"); |
| | | endTime = URLEncoder.encode(endTime, "UTF-8"); |
| | | } catch (UnsupportedEncodingException e) { |
| | | throw new RuntimeException(e.getCause()); |
| | | } |
| | | String getQueryParam = "startTime=" + startTime + "&endTime=" + endTime; |
| | | String json = getObject(getQueryParam,"/api/v1/exam/plan/enroll/download", HttpMethod.GET); |
| | | ReturnVO<List<ExamPlanInfo<ExamPlanExaminee>>> returnVo = JSONObject.parseObject(json, new TypeReference<ReturnVO<List<ExamPlanInfo<ExamPlanExaminee>>>>() {}); |
| | | if(returnVo.getCode() == null || returnVo.getCode() != 200){ |
| | | throw new ServiceException("拉取数据异常"); |
| | | } |
| | | if(returnVo.getData() == null){ |
| | | throw new ServiceException("无数据可更新"); |
| | | } |
| | | List<ExamPlanInfo<ExamPlanExaminee>> data = returnVo.getData(); |
| | | for (ExamPlanInfo examPlanInfo : data) { |
| | | NcExamPlan ncExamPlan = new NcExamPlan(); |
| | | BeanUtils.copyProperties(examPlanInfo,ncExamPlan); |
| | | ncExamPlan.setDelFlag((byte)0); |
| | | ncExamPlan.setId(null); |
| | | ncExamPlan.setExamPlanId(examPlanInfo.getId()); |
| | | //判断是否已同步 |
| | | if(!this.isExsit(examPlanInfo.getId())){ |
| | | //插入 |
| | | ncExamPlanMapper.insert(ncExamPlan); |
| | | List<ExamPlanExaminee> examPlanExaminees = examPlanInfo.getExaminees(); |
| | | if(!CollectionUtils.isEmpty(examPlanInfo.getExaminees())){ |
| | | for (ExamPlanExaminee examPlanExaminee : examPlanExaminees) { |
| | | NcExaminees ncExaminees = new NcExaminees(); |
| | | ncExaminees.setExamPlanId(examPlanInfo.getId()); |
| | | ncExaminees.setDelFlag((byte)0); |
| | | ncExaminees.setCardNum(examPlanExaminee.getCardNum()); |
| | | ncExaminees.setCardType(examPlanExaminee.getCardType()); |
| | | ncExaminees.setName(examPlanExaminee.getName()); |
| | | //判断人员是否存在 |
| | | NcStaff ncStaff = ncStaffService.getByIdCard(examPlanExaminee.getCardNum()); |
| | | if(ncStaff == null){ |
| | | //插入staff表 |
| | | ncStaff = new NcStaff(); |
| | | ncStaff.setName(examPlanExaminee.getName()); |
| | | ncStaff.setSex(examPlanExaminee.getSex()); |
| | | ncStaff.setIdCardNum(examPlanExaminee.getCardNum()); |
| | | ncStaff.setDelFlag((byte)0); |
| | | ncStaffService.save(ncStaff); |
| | | |
| | | } |
| | | ncExaminees.setStaffId(ncStaff.getId()); |
| | | ncExamineesService.save(ncExaminees); |
| | | } |
| | | |
| | | } |
| | | } |
| | | } |
| | | } |
| | | public boolean isExsit(Long explanId){ |
| | | NcExamPlan ncExamPlan = ncExamPlanMapper.selectOne(new LambdaQueryWrapper<NcExamPlan>() |
| | | .eq(NcExamPlan::getDelFlag, (byte) 0) |
| | | .eq(NcExamPlan::getExamPlanId, explanId)); |
| | | if(ncExamPlan != null){ |
| | | return true; |
| | | } |
| | | return false; |
| | | } |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.gkhy.exam.noncoalmine.entity.NcExaminees; |
| | | import com.gkhy.exam.noncoalmine.mapper.NcExamineesMapper; |
| | | import com.gkhy.exam.noncoalmine.service.NcExamineesService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (NcExaminees)表服务实现类 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 10:01:22 |
| | | */ |
| | | @Service("ncExamineesService") |
| | | public class NcExamineesServiceImpl extends ServiceImpl<NcExamineesMapper, NcExaminees> implements NcExamineesService { |
| | | |
| | | @Override |
| | | public List<NcExaminees> getByStaffid(Long stuffId) { |
| | | List<NcExaminees> examineesList = baseMapper.selectList(new LambdaQueryWrapper<NcExaminees>().eq(NcExaminees::getDelFlag, (byte) 0).eq(NcExaminees::getStaffId, stuffId)); |
| | | return examineesList; |
| | | } |
| | | |
| | | @Override |
| | | public List<NcExaminees> getByIdCard(String idCard) { |
| | | List<NcExaminees> examineesList = baseMapper.selectList(new LambdaQueryWrapper<NcExaminees>().eq(NcExaminees::getDelFlag, (byte) 0).eq(NcExaminees::getCardNum, idCard)); |
| | | return examineesList; |
| | | } |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.gkhy.exam.noncoalmine.entity.NcStaffResume; |
| | | import com.gkhy.exam.noncoalmine.mapper.NcStaffResumeMapper; |
| | | import com.gkhy.exam.noncoalmine.service.NcStaffResumeService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (NcStaffResume)表服务实现类 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 14:06:43 |
| | | */ |
| | | @Service("ncStaffResumeService") |
| | | public class NcStaffResumeServiceImpl extends ServiceImpl<NcStaffResumeMapper, NcStaffResume> implements NcStaffResumeService { |
| | | |
| | | @Override |
| | | public List<NcStaffResume> getByStaffId(Long stuffId) { |
| | | List<NcStaffResume> resumeList = baseMapper.selectList(new LambdaQueryWrapper<NcStaffResume>() |
| | | .eq(NcStaffResume::getDelFlag, (byte)0) |
| | | .eq(NcStaffResume::getStaffId, stuffId)); |
| | | |
| | | return resumeList; |
| | | } |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.gkhy.exam.noncoalmine.entity.*; |
| | | import com.gkhy.exam.noncoalmine.mapper.NcStaffMapper; |
| | | import com.gkhy.exam.noncoalmine.model.addForm.NcExamineesAddForm; |
| | | import com.gkhy.exam.noncoalmine.model.addForm.NcStaffAddForm; |
| | | import com.gkhy.exam.noncoalmine.model.addForm.NcStaffResumeAddForm; |
| | | import com.gkhy.exam.noncoalmine.model.addForm.NcStaffTrainAddForm; |
| | | import com.gkhy.exam.noncoalmine.model.modForm.NcStaffModForm; |
| | | import com.gkhy.exam.noncoalmine.model.query.NcStaffQuery; |
| | | import com.gkhy.exam.noncoalmine.model.vo.NcStaffVO; |
| | | import com.gkhy.exam.noncoalmine.model.vo.ViolationRegistrationVO; |
| | | import com.gkhy.exam.noncoalmine.model.vo.WorkRegistrationVO; |
| | | import com.gkhy.exam.noncoalmine.service.*; |
| | | import com.ruoyi.common.exception.ServiceException; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.util.CollectionUtils; |
| | | |
| | | import java.util.List; |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | | * (NcStaff)表服务实现类 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 09:59:58 |
| | | */ |
| | | @Service("ncStaffService") |
| | | public class NcStaffServiceImpl extends ServiceImpl<NcStaffMapper, NcStaff> implements NcStaffService { |
| | | @Autowired |
| | | private NcStaffMapper ncStaffMapper; |
| | | @Autowired |
| | | private NcStaffResumeService ncStaffResumeService; |
| | | @Autowired |
| | | private NcStaffTrainService ncStaffTrainService; |
| | | @Autowired |
| | | private NcExamineesService ncExamineesService; |
| | | @Autowired |
| | | private ViolationRegistrationService violationRegistrationService; |
| | | @Autowired |
| | | private WorkRegistrationService workRegistrationService; |
| | | @Autowired |
| | | private NcCertService ncCertService; |
| | | @Override |
| | | public List<NcStaffVO> selectStaffList(NcStaffQuery query) { |
| | | List<NcStaffVO> staffVOList = ncStaffMapper.getList(query); |
| | | for (NcStaffVO ncStaffVO : staffVOList) { |
| | | List<NcStaffResume> resumeList = ncStaffResumeService.getByStaffId(ncStaffVO.getId()); |
| | | List<NcStaffTrain> trainList = ncStaffTrainService.getByStaffId(ncStaffVO.getId()); |
| | | List<NcExaminees> examineesList = ncExamineesService.getByIdCard(ncStaffVO.getIdCardNum()); |
| | | List<ViolationRegistrationVO> violationList = violationRegistrationService.getByIdCard(ncStaffVO.getIdCardNum(), (byte) 0); |
| | | List<WorkRegistrationVO> workList = workRegistrationService.getByIdCard(ncStaffVO.getIdCardNum(), (byte) 0); |
| | | List<NcCert> certList = ncCertService.getByIdCard(ncStaffVO.getIdCardNum()); |
| | | ncStaffVO.setResumeList(resumeList); |
| | | ncStaffVO.setTrainList(trainList); |
| | | ncStaffVO.setExamineeList(examineesList); |
| | | ncStaffVO.setViolationList(violationList); |
| | | ncStaffVO.setWorkList(workList); |
| | | ncStaffVO.setCertList(certList); |
| | | ncStaffVO.setCertCount(certList.size()); |
| | | ncStaffVO.setViolationCount(violationList.size()); |
| | | ncStaffVO.setWorkCount(workList.size()); |
| | | } |
| | | return staffVOList; |
| | | } |
| | | |
| | | /** |
| | | * 新增 |
| | | * @param addForm |
| | | * @return |
| | | */ |
| | | @Transactional |
| | | @Override |
| | | public int add(NcStaffAddForm addForm) { |
| | | if(isExist(addForm.getIdCardNum(),null)){ |
| | | throw new ServiceException("人员已存在"); |
| | | } |
| | | NcStaff ncStaff = new NcStaff(); |
| | | BeanUtils.copyProperties(addForm,ncStaff); |
| | | ncStaff.setDelFlag((byte) 0); |
| | | //插入人员 |
| | | int i = ncStaffMapper.insert(ncStaff); |
| | | //插入个人履历 |
| | | saveBatchResume(addForm.getResumeList(),ncStaff.getId()); |
| | | //插入培训经历 |
| | | saveBatchTrain(addForm.getTrainList(),ncStaff); |
| | | //考试经历 |
| | | saveBatchExam(addForm.getExamineeList(),ncStaff); |
| | | return i; |
| | | } |
| | | |
| | | /** |
| | | * 修改 |
| | | * @param modForm |
| | | */ |
| | | @Transactional |
| | | @Override |
| | | public void mod(NcStaffModForm modForm) { |
| | | if(isExist(modForm.getIdCardNum(),modForm.getId())){ |
| | | throw new ServiceException("人员已存在"); |
| | | } |
| | | NcStaff ncStaff = new NcStaff(); |
| | | BeanUtils.copyProperties(modForm,ncStaff); |
| | | //修改人员 |
| | | ncStaffMapper.updateById(ncStaff); |
| | | //个人履历 |
| | | updateBatchResume(modForm.getResumeList(),ncStaff); |
| | | //插入培训经历 |
| | | updateBatchTrain(modForm.getTrainList(),ncStaff); |
| | | //考试经历 |
| | | updateBatchExam(modForm.getExamineeList(),ncStaff); |
| | | |
| | | } |
| | | private boolean isExist(String idCard,Long stuffId){ |
| | | NcStaff ncStaff = baseMapper.selectOne(new LambdaQueryWrapper<NcStaff>() |
| | | .eq(NcStaff::getDelFlag, (byte) 0) |
| | | .eq(NcStaff::getIdCardNum, idCard) |
| | | .ne(stuffId != null,NcStaff::getId,stuffId)); |
| | | if(ncStaff != null){ |
| | | return true; |
| | | } |
| | | return false; |
| | | |
| | | } |
| | | |
| | | @Override |
| | | public NcStaff getByIdCard(String idCard) { |
| | | NcStaff ncStaff = baseMapper.selectOne(new LambdaQueryWrapper<NcStaff>() |
| | | .eq(NcStaff::getDelFlag, (byte) 0) |
| | | .eq(NcStaff::getIdCardNum, idCard)); |
| | | return ncStaff; |
| | | } |
| | | |
| | | @Override |
| | | public void delBatch(List<Long> staffIds) { |
| | | UpdateWrapper<NcStaff> updateWrapper = new UpdateWrapper<>(); |
| | | updateWrapper.in("id",staffIds) |
| | | .set("del_flag",(byte)2); |
| | | this.update(updateWrapper); |
| | | } |
| | | |
| | | //修改履历 |
| | | public void updateBatchResume(List<NcStaffResumeAddForm> resumeFormList,NcStaff ncStaff){ |
| | | if(!CollectionUtils.isEmpty(resumeFormList)){ |
| | | //历史履历 |
| | | List<NcStaffResume> oldResumeList = ncStaffResumeService.list(new LambdaQueryWrapper<NcStaffResume>() |
| | | .eq(NcStaffResume::getDelFlag, (byte) 0) |
| | | .eq(NcStaffResume::getStaffId, ncStaff.getId())); |
| | | if(CollectionUtils.isEmpty(oldResumeList)){ |
| | | //新增 |
| | | saveBatchResume(resumeFormList, ncStaff.getId()); |
| | | }else { |
| | | |
| | | //新增 |
| | | List<NcStaffResumeAddForm> addResumeList = resumeFormList |
| | | .stream() |
| | | .filter(resume -> resume.getId() == null) |
| | | .collect(Collectors.toList()); |
| | | saveBatchResume(addResumeList, ncStaff.getId()); |
| | | //修改 |
| | | List<NcStaffResumeAddForm> modResumeList = resumeFormList |
| | | .stream() |
| | | .filter(resume -> resume.getId() != null) |
| | | .collect(Collectors.toList()); |
| | | if(!CollectionUtils.isEmpty(modResumeList)){ |
| | | List<NcStaffResume> collect = modResumeList.stream().map(modResume -> { |
| | | NcStaffResume ncStaffResume = new NcStaffResume(); |
| | | BeanUtils.copyProperties(modResume, ncStaffResume); |
| | | return ncStaffResume; |
| | | }).collect(Collectors.toList()); |
| | | ncStaffResumeService.updateBatchById(collect); |
| | | } |
| | | //删除 |
| | | for (NcStaffResume ncStaffResume : oldResumeList) { |
| | | List<NcStaffResumeAddForm> selectList = resumeFormList |
| | | .stream() |
| | | .filter(resumeAddForm -> resumeAddForm.getId() != null && resumeAddForm.getId().equals(ncStaffResume.getId())) |
| | | .collect(Collectors.toList()); |
| | | if(selectList.size() == 0){ |
| | | ncStaffResume.setDelFlag((byte) 2); |
| | | ncStaffResumeService.updateById(ncStaffResume); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |
| | | //插入履历 |
| | | private void saveBatchResume(List<NcStaffResumeAddForm> resumeAddFormList, Long stuffId) { |
| | | if(!CollectionUtils.isEmpty(resumeAddFormList)){ |
| | | List<NcStaffResume> resumeList = resumeAddFormList.stream().map(resume -> { |
| | | NcStaffResume ncStaffResume = new NcStaffResume(); |
| | | BeanUtils.copyProperties(resume, ncStaffResume); |
| | | ncStaffResume.setStaffId(stuffId); |
| | | ncStaffResume.setDelFlag((byte) 0); |
| | | return ncStaffResume; |
| | | }).collect(Collectors.toList()); |
| | | ncStaffResumeService.saveBatch(resumeList); |
| | | } |
| | | } |
| | | //修改考试经历 |
| | | public void updateBatchTrain(List<NcStaffTrainAddForm> trainFormList,NcStaff ncStaff){ |
| | | if(!CollectionUtils.isEmpty(trainFormList)){ |
| | | //历史履历 |
| | | List<NcStaffTrain> oldList = ncStaffTrainService.list(new LambdaQueryWrapper<NcStaffTrain>() |
| | | .eq(NcStaffTrain::getDelFlag, (byte) 0) |
| | | .eq(NcStaffTrain::getStaffId, ncStaff.getId())); |
| | | if(CollectionUtils.isEmpty(oldList)){ |
| | | //新增 |
| | | saveBatchTrain(trainFormList, ncStaff); |
| | | }else { |
| | | //新增 |
| | | List<NcStaffTrainAddForm> addList = trainFormList |
| | | .stream() |
| | | .filter(resume -> resume.getId() == null) |
| | | .collect(Collectors.toList()); |
| | | saveBatchTrain(addList, ncStaff); |
| | | //修改 |
| | | List<NcStaffTrainAddForm> modList = trainFormList |
| | | .stream() |
| | | .filter(resume -> resume.getId() != null) |
| | | .collect(Collectors.toList()); |
| | | if(!CollectionUtils.isEmpty(modList)){ |
| | | List<NcStaffTrain> collect = modList.stream().map(modTrain -> { |
| | | NcStaffTrain ncStaffTrain = new NcStaffTrain(); |
| | | BeanUtils.copyProperties(modTrain, ncStaffTrain); |
| | | ncStaffTrain.setIdCardNum(ncStaff.getIdCardNum()); |
| | | ncStaffTrain.setName(ncStaff.getName()); |
| | | return ncStaffTrain; |
| | | }).collect(Collectors.toList()); |
| | | ncStaffTrainService.updateBatchById(collect); |
| | | } |
| | | //删除 |
| | | for (NcStaffTrain ncStaffTrain : oldList) { |
| | | List<NcStaffTrainAddForm> selectList = trainFormList |
| | | .stream() |
| | | .filter(trainForm -> trainForm.getId() != null && trainForm.getId().equals(ncStaffTrain.getId())) |
| | | .collect(Collectors.toList()); |
| | | if(selectList.size() == 0){ |
| | | ncStaffTrain.setDelFlag((byte) 2); |
| | | ncStaffTrainService.updateById(ncStaffTrain); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |
| | | |
| | | //插入考试经历 |
| | | private void saveBatchTrain(List<NcStaffTrainAddForm> trainAddFormList, NcStaff ncStaff) { |
| | | if(!CollectionUtils.isEmpty(trainAddFormList)){ |
| | | List<NcStaffTrain> trainList = trainAddFormList.stream().map(train -> { |
| | | NcStaffTrain ncStaffTrain = new NcStaffTrain(); |
| | | BeanUtils.copyProperties(train, ncStaffTrain); |
| | | ncStaffTrain.setStaffId(ncStaff.getId()); |
| | | ncStaffTrain.setIdCardNum(ncStaff.getIdCardNum()); |
| | | ncStaffTrain.setName(ncStaff.getName()); |
| | | ncStaffTrain.setDelFlag((byte) 0); |
| | | return ncStaffTrain; |
| | | }).collect(Collectors.toList()); |
| | | ncStaffTrainService.saveBatch(trainList); |
| | | } |
| | | } |
| | | //修改培训经历 |
| | | public void updateBatchExam(List<NcExamineesAddForm> examFormList,NcStaff ncStaff){ |
| | | if(!CollectionUtils.isEmpty(examFormList)){ |
| | | //历史履历 |
| | | List<NcExaminees> oldList = ncExamineesService.list(new LambdaQueryWrapper<NcExaminees>() |
| | | .eq(NcExaminees::getDelFlag, (byte) 0) |
| | | .eq(NcExaminees::getStaffId, ncStaff.getId())); |
| | | if(CollectionUtils.isEmpty(oldList)){ |
| | | //新增 |
| | | saveBatchExam(examFormList, ncStaff); |
| | | }else { |
| | | //新增 |
| | | List<NcExamineesAddForm> addList = examFormList |
| | | .stream() |
| | | .filter(resume -> resume.getId() == null) |
| | | .collect(Collectors.toList()); |
| | | saveBatchExam(addList, ncStaff); |
| | | //修改 |
| | | List<NcExamineesAddForm> modList = examFormList |
| | | .stream() |
| | | .filter(resume -> resume.getId() != null) |
| | | .collect(Collectors.toList()); |
| | | if(!CollectionUtils.isEmpty(modList)){ |
| | | List<NcExaminees> collect = modList.stream().map(modExam -> { |
| | | NcExaminees ncExaminees = new NcExaminees(); |
| | | BeanUtils.copyProperties(modExam, ncExaminees); |
| | | ncExaminees.setStaffId(ncStaff.getId()); |
| | | ncExaminees.setDelFlag((byte) 0); |
| | | ncExaminees.setCardNum(ncStaff.getIdCardNum()); |
| | | ncExaminees.setCardName("身份证"); |
| | | ncExaminees.setCardType("01"); |
| | | return ncExaminees; |
| | | }).collect(Collectors.toList()); |
| | | ncExamineesService.updateBatchById(collect); |
| | | } |
| | | //删除 |
| | | for (NcExaminees ncExaminees : oldList) { |
| | | List<NcExamineesAddForm> selectList = examFormList |
| | | .stream() |
| | | .filter(examForm -> examForm.getId() != null && examForm.getId().equals(ncExaminees.getId())) |
| | | .collect(Collectors.toList()); |
| | | if(selectList.size() == 0){ |
| | | ncExaminees.setDelFlag((byte) 2); |
| | | ncExamineesService.updateById(ncExaminees); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |
| | | //插入培训经历 |
| | | private void saveBatchExam(List<NcExamineesAddForm> examineesAddFormList, NcStaff ncStaff) { |
| | | if(!CollectionUtils.isEmpty(examineesAddFormList)){ |
| | | List<NcExaminees> examineesList = examineesAddFormList.stream().map(examinees -> { |
| | | NcExaminees ncExaminees = new NcExaminees(); |
| | | BeanUtils.copyProperties(examinees, ncExaminees); |
| | | ncExaminees.setStaffId(ncStaff.getId()); |
| | | ncExaminees.setDelFlag((byte) 0); |
| | | ncExaminees.setCardNum(ncStaff.getIdCardNum()); |
| | | ncExaminees.setName(ncStaff.getName()); |
| | | ncExaminees.setCardName("身份证"); |
| | | ncExaminees.setCardType("01"); |
| | | ncExaminees.setSex(ncStaff.getSex()); |
| | | return ncExaminees; |
| | | }).collect(Collectors.toList()); |
| | | ncExamineesService.saveBatch(examineesList); |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.exam.noncoalmine.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.gkhy.exam.noncoalmine.entity.NcStaffTrain; |
| | | import com.gkhy.exam.noncoalmine.mapper.NcStaffTrainMapper; |
| | | import com.gkhy.exam.noncoalmine.service.NcStaffTrainService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (NcStaffTrain)表服务实现类 |
| | | * |
| | | * @author makejava |
| | | * @since 2023-09-18 10:00:25 |
| | | */ |
| | | @Service("ncStaffTrainService") |
| | | public class NcStaffTrainServiceImpl extends ServiceImpl<NcStaffTrainMapper, NcStaffTrain> implements NcStaffTrainService { |
| | | |
| | | @Override |
| | | public List<NcStaffTrain> getByStaffId(Long staffId) { |
| | | List<NcStaffTrain> trainList = baseMapper.selectList(new LambdaQueryWrapper<NcStaffTrain>() |
| | | .eq(NcStaffTrain::getDelFlag, (byte) 0) |
| | | .eq(NcStaffTrain::getStaffId, staffId)); |
| | | return trainList; |
| | | } |
| | | } |
| | | |
| | |
| | | package com.gkhy.exam.noncoalmine.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.gkhy.exam.noncoalmine.entity.TrainingInstitution; |
| | | import com.gkhy.exam.noncoalmine.entity.ViolationRegistration; |
| | | import com.gkhy.exam.noncoalmine.mapper.TrainingInstitutionMapper; |
| | | import com.gkhy.exam.noncoalmine.model.addForm.TrainingInstitutionAddForm; |
| | | import com.gkhy.exam.noncoalmine.model.modForm.TrainingInstitutionModForm; |
| | |
| | | return baseMapper.insert(trainingInstitution); |
| | | } |
| | | |
| | | @Override |
| | | public void delBatch(List<Long> institutionIds) { |
| | | UpdateWrapper<TrainingInstitution> updateWrapper = new UpdateWrapper<>(); |
| | | updateWrapper.in("institution_id",institutionIds) |
| | | .set("del_flag",(byte)2); |
| | | this.update(updateWrapper); |
| | | } |
| | | |
| | | } |
| | | |
| | |
| | | package com.gkhy.exam.noncoalmine.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.gkhy.exam.noncoalmine.entity.ViolationRegistration; |
| | | import com.gkhy.exam.noncoalmine.entity.WorkRegistration; |
| | |
| | | }).collect(Collectors.toList()); |
| | | return list; |
| | | } |
| | | |
| | | /** |
| | | * 新增 |
| | | * @param addForm |
| | |
| | | return list; |
| | | } |
| | | |
| | | @Override |
| | | public void delBatch(List<Long> violationIds) { |
| | | UpdateWrapper<ViolationRegistration> updateWrapper = new UpdateWrapper<>(); |
| | | updateWrapper.in("violation_id",violationIds) |
| | | .set("del_flag",(byte)2); |
| | | this.update(updateWrapper); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 附件转换 |
| | |
| | | package com.gkhy.exam.noncoalmine.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.Wrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; |
| | | import com.baomidou.mybatisplus.extension.conditions.update.UpdateChainWrapper; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.gkhy.exam.noncoalmine.entity.WorkRegistration; |
| | | import com.gkhy.exam.noncoalmine.mapper.WorkRegistrationMapper; |
| | |
| | | }).collect(Collectors.toList()); |
| | | return list; |
| | | } |
| | | |
| | | @Override |
| | | public void delBatch(List<Long> workIds) { |
| | | UpdateWrapper<WorkRegistration> updateWrapper = new UpdateWrapper<>(); |
| | | updateWrapper.in("work_id",workIds) |
| | | .set("del_flag",(byte)2); |
| | | this.update(updateWrapper); |
| | | } |
| | | } |
| | | |
| | |
| | | LEFT JOIN sys_district d ON d.id = s.district_id |
| | | WHERE |
| | | s.del_flag = 0 |
| | | <if test="query.siteName != null and query.siteName = ''"> |
| | | <if test="query.siteName != null and query.siteName != ''"> |
| | | and s.site_name like concat('%', #{query.siteName}, '%') |
| | | </if> |
| | | <if test="query.districtCode != null and query.districtCode = ''"> |
| | | <if test="query.districtCode != null and query.districtCode != ''"> |
| | | AND d.`code` LIKE concat(#{query.districtCode}, '%') |
| | | </if> |
| | | <if test="query.isCm != null and query.isCm = ''"> |
| | | <if test="query.isCm != null and query.isCm != ''"> |
| | | AND s.is_cm = #{query.isCm} |
| | | </if> |
| | | order by s.create_time desc |
对比新文件 |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper |
| | | PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.gkhy.exam.noncoalmine.mapper.NcExamPlanMapper"> |
| | | <select id="selectNcExamPlanList" resultType="com.gkhy.exam.noncoalmine.entity.NcExamPlan"> |
| | | SELECT |
| | | * |
| | | FROM |
| | | nc_exam_plan |
| | | WHERE |
| | | del_flag = 0 |
| | | <if test="query.examPlanName != null and query.examPlanName != ''"> |
| | | and exam_plan_name like concat('%', #{query.examPlanName}, '%') |
| | | </if> |
| | | </select> |
| | | </mapper> |
对比新文件 |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper |
| | | PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.gkhy.exam.noncoalmine.mapper.NcStaffMapper"> |
| | | <select id="getList" resultType="com.gkhy.exam.noncoalmine.model.vo.NcStaffVO"> |
| | | SELECT |
| | | * |
| | | FROM |
| | | nc_staff |
| | | WHERE |
| | | del_flag = 0 |
| | | <if test="query.name != null and query.name != ''"> |
| | | and name like concat('%', #{query.name}, '%') |
| | | </if> |
| | | <if test="query.idCardNum != null and query.idCardNum != ''"> |
| | | and name = #{query.idCardNum} |
| | | </if> |
| | | </select> |
| | | </mapper> |
| | |
| | | LEFT JOIN sys_district d ON d.id = t.district_id |
| | | WHERE |
| | | t.del_flag = 0 |
| | | <if test="query.institutionName != null and query.institutionName = ''"> |
| | | <if test="query.institutionName != null and query.institutionName != ''"> |
| | | and t.institution_name like concat('%', #{query.institutionName}, '%') |
| | | </if> |
| | | <if test="query.districtCode != null and query.districtCode = ''"> |
| | | <if test="query.districtCode != null and query.districtCode != ''"> |
| | | AND d.`code` LIKE concat(#{query.districtCode}, '%') |
| | | </if> |
| | | <if test="query.isCm != null and query.isCm = ''"> |
| | | <if test="query.isCm != null and query.isCm != ''"> |
| | | AND t.is_cm = #{query.isCm} |
| | | </if> |
| | | order by t.create_time desc |
| | |
| | | update_time |
| | | from violation_registration |
| | | where del_flag = 0 |
| | | <if test="query.dept != null and query.dept = ''"> |
| | | <if test="query.dept != null and query.dept != ''"> |
| | | and dept like concat('%', #{query.dept}, '%') |
| | | </if> |
| | | <if test="query.name != null and query.name = ''"> |
| | | <if test="query.name != null and query.name != ''"> |
| | | and name like concat('%', #{query.name}, '%') |
| | | </if> |
| | | <if test="query.idCard != null and query.idCard = ''"> |
| | | <if test="query.idCard != null and query.idCard != ''"> |
| | | and id_card like concat('%', #{query.idCard}, '%') |
| | | </if> |
| | | <if test="query.operateTypeId != null and query.operateTypeId != 0"> |
| | |
| | | update_time |
| | | from work_registration |
| | | where del_flag = 0 |
| | | <if test="query.dept != null and query.dept = ''"> |
| | | <if test="query.dept != null and query.dept != ''"> |
| | | and dept like concat('%', #{query.dept}, '%') |
| | | </if> |
| | | <if test="query.name != null and query.name = ''"> |
| | | <if test="query.name != null and query.name != ''"> |
| | | and name like concat('%', #{query.name}, '%') |
| | | </if> |
| | | <if test="query.idCard != null and query.idCard = ''"> |
| | | <if test="query.idCard != null and query.idCard != ''"> |
| | | and id_card like concat('%', #{query.idCard}, '%') |
| | | </if> |
| | | <if test="query.operateTypeId != null and query.operateTypeId != 0"> |
| | | and (operate_type_id = #{query.operateTypeId} OR operate_type_id IN ( SELECT t.id FROM sys_operate_type t WHERE find_in_set(#{query.operateTypeId}, ancestors))) |
| | | </if> |
| | | order by create_time desc |
| | | |
| | | </select> |
| | | |
| | | </mapper> |
| | |
| | | |
| | | import java.util.List; |
| | | import java.util.Set; |
| | | |
| | | import com.ruoyi.framework.web.domain.login.LoginVo; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | |
| | | * |
| | | * @author ruoyi |
| | | */ |
| | | @Api(tags = "登录相关接口") |
| | | @RestController |
| | | public class SysLoginController |
| | | { |
| | |
| | | ajax.put(Constants.TOKEN, token); |
| | | return ajax; |
| | | } |
| | | @ApiOperation(value = "移动端登录接口") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "username", dataTypeClass = String.class,value = "用户名",required = true), |
| | | @ApiImplicitParam(name = "password", dataTypeClass = String.class,value = "密码",required = true), |
| | | }) |
| | | @PostMapping("/login/move") |
| | | public AjaxResult loginMove(@RequestBody LoginBody loginBody) |
| | | { |
| | | // 生成令牌 |
| | | LoginVo loginVo = loginService.loginMove(loginBody.getUsername(), loginBody.getPassword()); |
| | | return AjaxResult.success(loginVo); |
| | | } |
| | | |
| | | /** |
| | | * 获取用户信息 |
| | |
| | | max-active: 8 |
| | | # #连接池最大阻塞等待时间(使用负值表示没有限制) |
| | | max-wait: -1ms |
| | | tripartite: |
| | | restSever: https://inspurtestcx.saws.org.cn/sjjh |
| | | appKey: hj92qe |
| | | appPwd: dxep6j |
| | | |
| | | #windous测试 |
| | | file: |
| | |
| | | # 是否开启swagger |
| | | enabled: true |
| | | # 请求前缀 |
| | | pathMapping: /dev-api |
| | | pathMapping: / |
| | | |
| | | # 防止XSS攻击 |
| | | xss: |
对比新文件 |
| | |
| | | package com.ruoyi.common.signature; |
| | | |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | | * @author: zf |
| | | * @date: 2023/9/15 |
| | | * @time: 17:20 |
| | | */ |
| | | @Data |
| | | public class NcCertQuery1 { |
| | | |
| | | private String name; |
| | | |
| | | /** 证件类型代码 */ |
| | | private String idcardTypeCode; |
| | | |
| | | /** 身份证件号 */ |
| | | private String idcardNum; |
| | | } |
| | |
| | | package com.ruoyi.common.signature; |
| | | |
| | | import com.alibaba.fastjson2.JSON; |
| | | import com.alibaba.fastjson2.JSONObject; |
| | | import com.ruoyi.common.enums.HttpMethod; |
| | | import com.ruoyi.common.exception.ServiceException; |
| | | import org.apache.commons.lang3.RandomStringUtils; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.apache.http.HttpStatus; |
| | |
| | | import org.apache.http.client.config.RequestConfig; |
| | | import org.apache.http.client.methods.CloseableHttpResponse; |
| | | import org.apache.http.client.methods.HttpGet; |
| | | import org.apache.http.client.methods.HttpPost; |
| | | import org.apache.http.entity.StringEntity; |
| | | import org.apache.http.impl.client.CloseableHttpClient; |
| | | import org.apache.http.util.EntityUtils; |
| | | import org.slf4j.Logger; |
| | |
| | | |
| | | /** |
| | | * 获取数据接口 |
| | | * @param getQueryParam |
| | | * @param queryParam |
| | | * @param url |
| | | * @param method |
| | | * @return |
| | | */ |
| | | public static Object getObject(String getQueryParam,String url){ |
| | | public static String getObject(String queryParam, String url, HttpMethod method){ |
| | | |
| | | if(method.equals(HttpMethod.GET)){ |
| | | return getMethod(url, queryParam); |
| | | } |
| | | if(method.equals(HttpMethod.POST)){ |
| | | return postMethod(url,queryParam); |
| | | } |
| | | return null; |
| | | } |
| | | private static String getMethod(String url,String queryParam){ |
| | | // 时间戳 |
| | | Long ts = Calendar.getInstance().getTime().getTime(); |
| | | // 随机数 |
| | |
| | | // 接口header 中的公共参数 |
| | | String commonParamUrl = String.format("appKey=%s" + "&" + "ts=%s" + "&" + "once=%s" + "&" + "signMethod=%s", appKey, ts, once, signMethod); |
| | | |
| | | String getFullUrl = restSever + url + "?" + getQueryParam; |
| | | String getFullUrl = restSever + url + "?" + queryParam; |
| | | HttpGet httpGet = new HttpGet(getFullUrl); |
| | | // get 请求查询参数, 用在 URL 上的, 这里若是通过 ID 查询的, 接口中 ID 是作为路径存在的, 所以需要将 ID 组成 |
| | | String getAllParamUrl = commonParamUrl + "&" + getQueryParam; |
| | | String getAllParamUrl = commonParamUrl + "&" + queryParam; |
| | | // 创建 HttpClient 对象 |
| | | CloseableHttpClient httpclient = (CloseableHttpClient) SkipHttpsUtils.wrapClient(); |
| | | // 对参数签名, 并放入请求 header 中的 signData 参数中 |
| | |
| | | httpGet.addHeader("ts", ts.toString()); |
| | | httpGet.addHeader("once", once); |
| | | httpGet.addHeader("signMethod", signMethod); |
| | | System.out.println("once:" + once); |
| | | httpGet.addHeader("signData", signData); |
| | | System.out.println("headers:" + httpGet.getAllHeaders()); |
| | | String urlStr = httpGet.getURI().toString(); |
| | | // 公共参数 URL |
| | | System.out.println("commonParamter:" + urlStr); |
| | | if (StringUtils.endsWith(urlStr, "/")) { |
| | | urlStr = StringUtils.removeEnd(urlStr, "/"); |
| | | } |
| | |
| | | RequestConfig requestConfig = RequestConfig.custom().setConnectTimeout(6000) |
| | | .setConnectionRequestTimeout(6000).setSocketTimeout(6000).build(); |
| | | httpGet.setConfig(requestConfig); |
| | | System.out.println("urlStr in request:" + httpGet.getURI().toString()); |
| | | // 执行请求 |
| | | CloseableHttpResponse response = httpclient.execute(httpGet); |
| | | // 取响应的结果 |
| | |
| | | // 打印响应结果 |
| | | if (statusCode == HttpStatus.SC_OK) { |
| | | String resp = EntityUtils.toString(response.getEntity(), "utf-8"); |
| | | System.out.println("status:" + statusCode); |
| | | Object object = JSON.parse(resp); |
| | | System.out.println("result:" + resp); |
| | | return object; |
| | | Object object = JSONObject.parseObject(resp); |
| | | |
| | | return resp; |
| | | } else { |
| | | System.out.println(statusCode); |
| | | throw new ServiceException("同步数据异常"); |
| | | } |
| | | } catch (URISyntaxException e) { |
| | | logger.error("签名失败: ", e); |
| | | } catch (ClientProtocolException e) { |
| | | e.printStackTrace(); |
| | | } catch (IOException e) { |
| | | e.printStackTrace(); |
| | | } |
| | | return null; |
| | | } |
| | | private static String postMethod(String url, String bodyParam){ |
| | | // 时间戳 |
| | | Long ts = Calendar.getInstance().getTime().getTime(); |
| | | // 随机数 |
| | | String once = RandomStringUtils.randomAlphanumeric(32); |
| | | // 接口header 中的公共参数 |
| | | String commonParamUrl = String.format("appKey=%s" + "&" + "ts=%s" + "&" + "once=%s" + "&" + "signMethod=%s", appKey, ts, once, signMethod); |
| | | |
| | | String postFullUrl = restSever + url; |
| | | HttpPost httpPost = new HttpPost(postFullUrl); |
| | | String postAllParamUrl = commonParamUrl + "&bodyData=" + bodyParam; |
| | | // 创建 HttpClient 对象 |
| | | CloseableHttpClient httpclient = (CloseableHttpClient) SkipHttpsUtils.wrapClient(); |
| | | StringEntity bodyData = new StringEntity(bodyParam.toString(), "UTF-8"); |
| | | httpPost.setEntity(bodyData); |
| | | // 对参数签名, 并放入请求 header 中的 signData 参数中 |
| | | try { |
| | | // 签名数据 |
| | | String signData = TokenUtils.getSignature(appPwd, postAllParamUrl); |
| | | // 添加 header 参数 appCode、 timestamp、 signatureNonce、 signature |
| | | httpPost.addHeader("appKey", appKey); |
| | | httpPost.addHeader("ts", ts.toString()); |
| | | httpPost.addHeader("once", once); |
| | | httpPost.addHeader("signMethod", signMethod); |
| | | httpPost.addHeader("signData", signData); |
| | | String urlStr = httpPost.getURI().toString(); |
| | | // 公共参数 URL |
| | | if (StringUtils.endsWith(urlStr, "/")) { |
| | | urlStr = StringUtils.removeEnd(urlStr, "/"); |
| | | } |
| | | httpPost.setURI(new URI(urlStr)); |
| | | RequestConfig requestConfig = RequestConfig.custom().setConnectTimeout(6000) |
| | | .setConnectionRequestTimeout(6000).setSocketTimeout(6000).build(); |
| | | httpPost.setConfig(requestConfig); |
| | | // 执行请求 |
| | | CloseableHttpResponse response = httpclient.execute(httpPost); |
| | | // 取响应的结果 |
| | | int statusCode = response.getStatusLine().getStatusCode(); |
| | | // 打印响应结果 |
| | | if (statusCode == HttpStatus.SC_OK) { |
| | | String resp = EntityUtils.toString(response.getEntity(), "utf-8"); |
| | | Object object = JSON.parse(resp); |
| | | return resp; |
| | | } else { |
| | | throw new ServiceException("同步数据异常"); |
| | | } |
| | | } catch (URISyntaxException e) { |
| | | logger.error("签名失败: ", e); |
| | |
| | | * GET 查询接口演示代码 |
| | | */ |
| | | String startTime = "2018-05-25 00:00:00"; |
| | | String endTime = "2023-06-01 21:00:00"; |
| | | String endTime = "2023-09-01 21:00:00"; |
| | | try { |
| | | startTime = URLEncoder.encode(startTime, "UTF-8"); |
| | | endTime = URLEncoder.encode(endTime, "UTF-8"); |
| | |
| | | } |
| | | String getQueryParam = "startTime=" + startTime + "&endTime=" + endTime; |
| | | System.out.println(getQueryParam); |
| | | Object obj = getObject(getQueryParam,"/api/v1/exam/plan/enroll/download"); |
| | | Object obj = getObject(getQueryParam,"/api/v1/exam/plan/enroll/download",HttpMethod.GET); |
| | | System.out.println(obj); |
| | | System.out.println("********************************************************************************************************************************"); |
| | | System.out.println("********************************************************************************************************************************"); |
| | | NcCertQuery1 ncCertQuery1 = new NcCertQuery1(); |
| | | ncCertQuery1.setIdcardTypeCode("01"); |
| | | ncCertQuery1.setIdcardNum("362421197712217718"); |
| | | String bodyParam = JSON.toJSONString(ncCertQuery1); |
| | | Object obj2 = getObject(bodyParam,"/api/v1/cert/query",HttpMethod.POST); |
| | | System.out.println(obj2); |
| | | |
| | | } |
| | | |
| | |
| | | import com.ruoyi.common.core.domain.AjaxResult; |
| | | import com.ruoyi.file.constants.FileProjectConstants; |
| | | import com.ruoyi.file.service.AttachmentService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | |
| | | * @date: 2023/8/29 |
| | | * @time: 10:53 |
| | | */ |
| | | @Api(tags = "附件") |
| | | @RestController |
| | | @RequestMapping("attachment") |
| | | public class AttachmentController extends BaseController { |
| | |
| | | * @param key |
| | | * @return |
| | | */ |
| | | |
| | | @ApiOperation(value = "根据标识查询文件具体信息") |
| | | @GetMapping("/get/key/{key}") |
| | | public AjaxResult findByKey(@PathVariable String key) { |
| | | return success(attachmentService.findByKey(key)); |
| | |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "删除文件数据") |
| | | @GetMapping("/delete/{id}") |
| | | public AjaxResult delete(@PathVariable Long id) { |
| | | attachmentService.delete(id); |
| | |
| | | * @Description 上传文件(返回文件标识) |
| | | * @Param [file, module] |
| | | **/ |
| | | |
| | | @ApiOperation(value = "上传文件(返回文件标识)") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "file", value = "文件",required = true), |
| | | @ApiImplicitParam(name = "module", dataTypeClass = String.class,value = "模块",required = true,example = "accountPath"), |
| | | }) |
| | | @PostMapping("/upload/key") |
| | | public AjaxResult uploadReturnKey(@RequestParam("file") MultipartFile |
| | | file, @RequestParam("module") String module) { |
| | |
| | | * @Description 上传文件(返回文件信息) |
| | | * @Param [file, module] |
| | | **/ |
| | | @ApiOperation(value = "上传文件(返回文件信息)") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "file",value = "文件",required = true), |
| | | @ApiImplicitParam(name = "module", dataTypeClass = String.class,value = "模块",required = true,example = "accountPath"), |
| | | }) |
| | | @PostMapping("/upload/detail") |
| | | public AjaxResult uploadReturnDetail(@RequestParam("file") MultipartFile |
| | | file, @RequestParam("module") String module) { |
| | |
| | | * @Date 2021/4/20 19:28 |
| | | * @Param [file, module] |
| | | **/ |
| | | @ApiOperation(value = "上传文件(返回访问路径)") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "file",value = "文件",required = true), |
| | | @ApiImplicitParam(name = "module", dataTypeClass = String.class,value = "模块",required = true,example = "accountPath"), |
| | | }) |
| | | @PostMapping("/upload/url") |
| | | public AjaxResult uploadReturnUrl(@RequestParam("file") MultipartFile file, @RequestParam("module") String module) { |
| | | return success(attachmentService.saveFileToPath(file, module, FileProjectConstants.ReturnType.URL)); |
| | |
| | | * @Description 上传文件(返回文件信息) |
| | | * @Param [file, module] |
| | | **/ |
| | | @ApiOperation(value = "批量上传文件(返回文件信息)") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "file", value = "文件",required = true), |
| | | @ApiImplicitParam(name = "module", dataTypeClass = String.class,value = "模块",required = true,example = "accountPath"), |
| | | }) |
| | | @PostMapping("/upload/batch/detail") |
| | | public AjaxResult uploadBatchReturnDetail(@RequestParam("file") MultipartFile[] |
| | | file, @RequestParam("module") String module) { |
| | |
| | | package com.ruoyi.file.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import com.ruoyi.common.core.domain.BaseEntity; |
| | | import lombok.Data; |
| | | import org.springframework.data.annotation.Id; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | |
| | | */ |
| | | @Data |
| | | @TableName("attachment") |
| | | public class AttachmentInfo extends BaseEntity { |
| | | public class AttachmentInfo { |
| | | @Id |
| | | @TableId(type = IdType.AUTO) |
| | | private Long id; |
| | |
| | | //业务id |
| | | private Long businessId; |
| | | |
| | | /** 创建者 */ |
| | | private String createBy; |
| | | |
| | | /** 创建时间 */ |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date createTime; |
| | | |
| | | /** 更新者 */ |
| | | private String updateBy; |
| | | |
| | | /** 更新时间 */ |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date updateTime; |
| | | |
| | | private String remark; |
| | | |
| | | } |
| | |
| | | // 过滤请求 |
| | | .authorizeRequests() |
| | | // 对于登录login 注册register 验证码captchaImage 允许匿名访问 |
| | | .antMatchers("/login", "/register", "/captchaImage").permitAll() |
| | | .antMatchers("/login","/login/move", "/register", "/captchaImage","/uploadfile/**").permitAll() |
| | | // 静态资源,可匿名访问 |
| | | .antMatchers(HttpMethod.GET, "/", "/*.html", "/**/*.html", "/**/*.css", "/**/*.js", "/profile/**").permitAll() |
| | | .antMatchers("/swagger-ui.html", "/swagger-resources/**", "/webjars/**", "/*/api-docs", "/druid/**").permitAll() |
对比新文件 |
| | |
| | | package com.ruoyi.framework.web.domain.login; |
| | | |
| | | import com.ruoyi.common.core.domain.entity.SysUser; |
| | | import lombok.Data; |
| | | |
| | | import java.util.Set; |
| | | |
| | | /** |
| | | * @email 1603559716@qq.com |
| | | * @author: zf |
| | | * @date: 2023/9/22 |
| | | * @time: 10:38 |
| | | */ |
| | | @Data |
| | | public class LoginVo { |
| | | |
| | | /** |
| | | * 用户唯一标识 |
| | | */ |
| | | private String token; |
| | | |
| | | /** |
| | | * 权限列表 |
| | | */ |
| | | private Set<String> permissions; |
| | | |
| | | /** |
| | | * 用户信息 |
| | | */ |
| | | private SysUser user; |
| | | } |
| | |
| | | package com.ruoyi.framework.web.service; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import com.ruoyi.framework.web.domain.login.LoginVo; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.security.authentication.AuthenticationManager; |
| | | import org.springframework.security.authentication.BadCredentialsException; |
| | |
| | | sysUser.setLoginDate(DateUtils.getNowDate()); |
| | | userService.updateUserProfile(sysUser); |
| | | } |
| | | |
| | | public LoginVo loginMove(String username, String password) { |
| | | // 登录前置校验 |
| | | loginPreCheck(username, password); |
| | | // 用户验证 |
| | | Authentication authentication = null; |
| | | try |
| | | { |
| | | UsernamePasswordAuthenticationToken authenticationToken = new UsernamePasswordAuthenticationToken(username, password); |
| | | AuthenticationContextHolder.setContext(authenticationToken); |
| | | // 该方法会去调用UserDetailsServiceImpl.loadUserByUsername |
| | | authentication = authenticationManager.authenticate(authenticationToken); |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | if (e instanceof BadCredentialsException) |
| | | { |
| | | AsyncManager.me().execute(AsyncFactory.recordLogininfor(username, Constants.LOGIN_FAIL, MessageUtils.message("user.password.not.match"))); |
| | | throw new UserPasswordNotMatchException(); |
| | | } |
| | | else |
| | | { |
| | | AsyncManager.me().execute(AsyncFactory.recordLogininfor(username, Constants.LOGIN_FAIL, e.getMessage())); |
| | | throw new ServiceException(e.getMessage()); |
| | | } |
| | | } |
| | | finally |
| | | { |
| | | AuthenticationContextHolder.clearContext(); |
| | | } |
| | | AsyncManager.me().execute(AsyncFactory.recordLogininfor(username, Constants.LOGIN_SUCCESS, MessageUtils.message("user.login.success"))); |
| | | LoginUser loginUser = (LoginUser) authentication.getPrincipal(); |
| | | recordLoginInfo(loginUser.getUserId()); |
| | | // 生成token |
| | | LoginVo loginVo = new LoginVo(); |
| | | BeanUtils.copyProperties(loginUser,loginVo); |
| | | loginVo.setToken(tokenService.createToken(loginUser)); |
| | | return loginVo; |
| | | } |
| | | } |
| | |
| | | @Override |
| | | public List<SysOperateType> selectOperateTypeList(OperateTypeListReqDTO reqDTO) { |
| | | LambdaQueryWrapper<SysOperateType> wrapper = new LambdaQueryWrapper<>(); |
| | | wrapper.eq(SysOperateType::getDelFlag, DeleteStatusEnum.YES.getStatus()); |
| | | wrapper.eq(SysOperateType::getDelFlag, DeleteStatusEnum.NO.getStatus()); |
| | | if (reqDTO != null && !StringUtils.isBlank(reqDTO.getName())){ |
| | | wrapper.eq(SysOperateType::getName,reqDTO.getName()); |
| | | } |