main
parent
f27fc0d903
commit
1d35589693
@ -0,0 +1,105 @@
|
|||||||
|
package com.ruoyi.server.evaluate.controller;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.server.evaluate.domain.ProjectEvaluate;
|
||||||
|
import com.ruoyi.server.evaluate.service.IProjectEvaluateService;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PutMapping;
|
||||||
|
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PathVariable;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
import com.ruoyi.common.annotation.Log;
|
||||||
|
import com.ruoyi.common.core.controller.BaseController;
|
||||||
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.enums.BusinessType;
|
||||||
|
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||||
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 绩效评价信息Controller
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-07-02
|
||||||
|
*/
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/evaluate/evaluate")
|
||||||
|
public class ProjectEvaluateController extends BaseController
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private IProjectEvaluateService projectEvaluateService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询绩效评价信息列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('evaluate:evaluate:list')")
|
||||||
|
@GetMapping("/list")
|
||||||
|
public TableDataInfo list(ProjectEvaluate projectEvaluate)
|
||||||
|
{
|
||||||
|
startPage();
|
||||||
|
List<ProjectEvaluate> list = projectEvaluateService.selectProjectEvaluateList(projectEvaluate);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出绩效评价信息列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('evaluate:evaluate:export')")
|
||||||
|
@Log(title = "绩效评价信息", businessType = BusinessType.EXPORT)
|
||||||
|
@PostMapping("/export")
|
||||||
|
public void export(HttpServletResponse response, ProjectEvaluate projectEvaluate)
|
||||||
|
{
|
||||||
|
List<ProjectEvaluate> list = projectEvaluateService.selectProjectEvaluateList(projectEvaluate);
|
||||||
|
ExcelUtil<ProjectEvaluate> util = new ExcelUtil<ProjectEvaluate>(ProjectEvaluate.class);
|
||||||
|
util.exportExcel(response, list, "绩效评价信息数据");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取绩效评价信息详细信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('evaluate:evaluate:query')")
|
||||||
|
@GetMapping(value = "/{id}")
|
||||||
|
public AjaxResult getInfo(@PathVariable("id") String id)
|
||||||
|
{
|
||||||
|
return success(projectEvaluateService.selectProjectEvaluateById(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增绩效评价信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('evaluate:evaluate:add')")
|
||||||
|
@Log(title = "绩效评价信息", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping
|
||||||
|
public AjaxResult add(@RequestBody ProjectEvaluate projectEvaluate)
|
||||||
|
{
|
||||||
|
return toAjax(projectEvaluateService.insertProjectEvaluate(projectEvaluate));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改绩效评价信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('evaluate:evaluate:edit')")
|
||||||
|
@Log(title = "绩效评价信息", businessType = BusinessType.UPDATE)
|
||||||
|
@PutMapping
|
||||||
|
public AjaxResult edit(@RequestBody ProjectEvaluate projectEvaluate)
|
||||||
|
{
|
||||||
|
return toAjax(projectEvaluateService.updateProjectEvaluate(projectEvaluate));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除绩效评价信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('evaluate:evaluate:remove')")
|
||||||
|
@Log(title = "绩效评价信息", businessType = BusinessType.DELETE)
|
||||||
|
@DeleteMapping("/{ids}")
|
||||||
|
public AjaxResult remove(@PathVariable String[] ids)
|
||||||
|
{
|
||||||
|
return toAjax(projectEvaluateService.deleteProjectEvaluateByIds(ids));
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,62 @@
|
|||||||
|
package com.ruoyi.server.evaluate.mapper;
|
||||||
|
|
||||||
|
import com.ruoyi.server.evaluate.domain.ProjectEvaluate;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 绩效评价信息Mapper接口
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-07-02
|
||||||
|
*/
|
||||||
|
public interface ProjectEvaluateMapper
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询绩效评价信息
|
||||||
|
*
|
||||||
|
* @param id 绩效评价信息主键
|
||||||
|
* @return 绩效评价信息
|
||||||
|
*/
|
||||||
|
public ProjectEvaluate selectProjectEvaluateById(String id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询绩效评价信息列表
|
||||||
|
*
|
||||||
|
* @param projectEvaluate 绩效评价信息
|
||||||
|
* @return 绩效评价信息集合
|
||||||
|
*/
|
||||||
|
public List<ProjectEvaluate> selectProjectEvaluateList(ProjectEvaluate projectEvaluate);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增绩效评价信息
|
||||||
|
*
|
||||||
|
* @param projectEvaluate 绩效评价信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertProjectEvaluate(ProjectEvaluate projectEvaluate);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改绩效评价信息
|
||||||
|
*
|
||||||
|
* @param projectEvaluate 绩效评价信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateProjectEvaluate(ProjectEvaluate projectEvaluate);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除绩效评价信息
|
||||||
|
*
|
||||||
|
* @param id 绩效评价信息主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteProjectEvaluateById(String id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除绩效评价信息
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteProjectEvaluateByIds(String[] ids);
|
||||||
|
}
|
@ -0,0 +1,62 @@
|
|||||||
|
package com.ruoyi.server.evaluate.service;
|
||||||
|
|
||||||
|
import com.ruoyi.server.evaluate.domain.ProjectEvaluate;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 绩效评价信息Service接口
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-07-02
|
||||||
|
*/
|
||||||
|
public interface IProjectEvaluateService
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询绩效评价信息
|
||||||
|
*
|
||||||
|
* @param id 绩效评价信息主键
|
||||||
|
* @return 绩效评价信息
|
||||||
|
*/
|
||||||
|
public ProjectEvaluate selectProjectEvaluateById(String id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询绩效评价信息列表
|
||||||
|
*
|
||||||
|
* @param projectEvaluate 绩效评价信息
|
||||||
|
* @return 绩效评价信息集合
|
||||||
|
*/
|
||||||
|
public List<ProjectEvaluate> selectProjectEvaluateList(ProjectEvaluate projectEvaluate);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增绩效评价信息
|
||||||
|
*
|
||||||
|
* @param projectEvaluate 绩效评价信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertProjectEvaluate(ProjectEvaluate projectEvaluate);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改绩效评价信息
|
||||||
|
*
|
||||||
|
* @param projectEvaluate 绩效评价信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateProjectEvaluate(ProjectEvaluate projectEvaluate);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除绩效评价信息
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的绩效评价信息主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteProjectEvaluateByIds(String[] ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除绩效评价信息信息
|
||||||
|
*
|
||||||
|
* @param id 绩效评价信息主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteProjectEvaluateById(String id);
|
||||||
|
}
|
@ -0,0 +1,102 @@
|
|||||||
|
package com.ruoyi.server.evaluate.service.impl;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.ruoyi.common.utils.DateUtils;
|
||||||
|
import com.ruoyi.common.utils.uuid.IdUtils;
|
||||||
|
import com.ruoyi.server.evaluate.domain.ProjectEvaluate;
|
||||||
|
import com.ruoyi.server.evaluate.mapper.ProjectEvaluateMapper;
|
||||||
|
import com.ruoyi.server.evaluate.service.IProjectEvaluateService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import static com.ruoyi.common.utils.SecurityUtils.getUsername;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 绩效评价信息Service业务层处理
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-07-02
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class ProjectEvaluateServiceImpl implements IProjectEvaluateService
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private ProjectEvaluateMapper projectEvaluateMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询绩效评价信息
|
||||||
|
*
|
||||||
|
* @param id 绩效评价信息主键
|
||||||
|
* @return 绩效评价信息
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public ProjectEvaluate selectProjectEvaluateById(String id)
|
||||||
|
{
|
||||||
|
return projectEvaluateMapper.selectProjectEvaluateById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询绩效评价信息列表
|
||||||
|
*
|
||||||
|
* @param projectEvaluate 绩效评价信息
|
||||||
|
* @return 绩效评价信息
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<ProjectEvaluate> selectProjectEvaluateList(ProjectEvaluate projectEvaluate)
|
||||||
|
{
|
||||||
|
return projectEvaluateMapper.selectProjectEvaluateList(projectEvaluate);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增绩效评价信息
|
||||||
|
*
|
||||||
|
* @param projectEvaluate 绩效评价信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertProjectEvaluate(ProjectEvaluate projectEvaluate)
|
||||||
|
{
|
||||||
|
projectEvaluate.setId(IdUtils.simpleUUID());
|
||||||
|
projectEvaluate.setUpdateBy(getUsername());
|
||||||
|
projectEvaluate.setCreateTime(DateUtils.getNowDate());
|
||||||
|
return projectEvaluateMapper.insertProjectEvaluate(projectEvaluate);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改绩效评价信息
|
||||||
|
*
|
||||||
|
* @param projectEvaluate 绩效评价信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updateProjectEvaluate(ProjectEvaluate projectEvaluate)
|
||||||
|
{
|
||||||
|
projectEvaluate.setUpdateBy(getUsername());
|
||||||
|
projectEvaluate.setUpdateTime(DateUtils.getNowDate());
|
||||||
|
return projectEvaluateMapper.updateProjectEvaluate(projectEvaluate);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除绩效评价信息
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的绩效评价信息主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteProjectEvaluateByIds(String[] ids)
|
||||||
|
{
|
||||||
|
return projectEvaluateMapper.deleteProjectEvaluateByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除绩效评价信息信息
|
||||||
|
*
|
||||||
|
* @param id 绩效评价信息主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteProjectEvaluateById(String id)
|
||||||
|
{
|
||||||
|
return projectEvaluateMapper.deleteProjectEvaluateById(id);
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,106 @@
|
|||||||
|
package com.ruoyi.server.evaluationrules.controller;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.common.utils.uuid.IdUtils;
|
||||||
|
import com.ruoyi.server.evaluationrules.domain.ProjectEvaluationRules;
|
||||||
|
import com.ruoyi.server.evaluationrules.service.IProjectEvaluationRulesService;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PutMapping;
|
||||||
|
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PathVariable;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
import com.ruoyi.common.annotation.Log;
|
||||||
|
import com.ruoyi.common.core.controller.BaseController;
|
||||||
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.enums.BusinessType;
|
||||||
|
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||||
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 绩效评价规则Controller
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-07-02
|
||||||
|
*/
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/evaluationrules/evaluationrules")
|
||||||
|
public class ProjectEvaluationRulesController extends BaseController
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private IProjectEvaluationRulesService projectEvaluationRulesService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询绩效评价规则列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('evaluationrules:evaluationrules:list')")
|
||||||
|
@GetMapping("/list")
|
||||||
|
public TableDataInfo list(ProjectEvaluationRules projectEvaluationRules)
|
||||||
|
{
|
||||||
|
startPage();
|
||||||
|
List<ProjectEvaluationRules> list = projectEvaluationRulesService.selectProjectEvaluationRulesList(projectEvaluationRules);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出绩效评价规则列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('evaluationrules:evaluationrules:export')")
|
||||||
|
@Log(title = "绩效评价规则", businessType = BusinessType.EXPORT)
|
||||||
|
@PostMapping("/export")
|
||||||
|
public void export(HttpServletResponse response, ProjectEvaluationRules projectEvaluationRules)
|
||||||
|
{
|
||||||
|
List<ProjectEvaluationRules> list = projectEvaluationRulesService.selectProjectEvaluationRulesList(projectEvaluationRules);
|
||||||
|
ExcelUtil<ProjectEvaluationRules> util = new ExcelUtil<ProjectEvaluationRules>(ProjectEvaluationRules.class);
|
||||||
|
util.exportExcel(response, list, "绩效评价规则数据");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取绩效评价规则详细信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('evaluationrules:evaluationrules:query')")
|
||||||
|
@GetMapping(value = "/{id}")
|
||||||
|
public AjaxResult getInfo(@PathVariable("id") String id)
|
||||||
|
{
|
||||||
|
return success(projectEvaluationRulesService.selectProjectEvaluationRulesById(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增绩效评价规则
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('evaluationrules:evaluationrules:add')")
|
||||||
|
@Log(title = "绩效评价规则", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping
|
||||||
|
public AjaxResult add(@RequestBody ProjectEvaluationRules projectEvaluationRules)
|
||||||
|
{
|
||||||
|
return toAjax(projectEvaluationRulesService.insertProjectEvaluationRules(projectEvaluationRules));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改绩效评价规则
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('evaluationrules:evaluationrules:edit')")
|
||||||
|
@Log(title = "绩效评价规则", businessType = BusinessType.UPDATE)
|
||||||
|
@PutMapping
|
||||||
|
public AjaxResult edit(@RequestBody ProjectEvaluationRules projectEvaluationRules)
|
||||||
|
{
|
||||||
|
return toAjax(projectEvaluationRulesService.updateProjectEvaluationRules(projectEvaluationRules));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除绩效评价规则
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('evaluationrules:evaluationrules:remove')")
|
||||||
|
@Log(title = "绩效评价规则", businessType = BusinessType.DELETE)
|
||||||
|
@DeleteMapping("/{ids}")
|
||||||
|
public AjaxResult remove(@PathVariable String[] ids)
|
||||||
|
{
|
||||||
|
return toAjax(projectEvaluationRulesService.deleteProjectEvaluationRulesByIds(ids));
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,62 @@
|
|||||||
|
package com.ruoyi.server.evaluationrules.mapper;
|
||||||
|
|
||||||
|
import com.ruoyi.server.evaluationrules.domain.ProjectEvaluationRules;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 绩效评价规则Mapper接口
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-07-02
|
||||||
|
*/
|
||||||
|
public interface ProjectEvaluationRulesMapper
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询绩效评价规则
|
||||||
|
*
|
||||||
|
* @param id 绩效评价规则主键
|
||||||
|
* @return 绩效评价规则
|
||||||
|
*/
|
||||||
|
public ProjectEvaluationRules selectProjectEvaluationRulesById(String id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询绩效评价规则列表
|
||||||
|
*
|
||||||
|
* @param projectEvaluationRules 绩效评价规则
|
||||||
|
* @return 绩效评价规则集合
|
||||||
|
*/
|
||||||
|
public List<ProjectEvaluationRules> selectProjectEvaluationRulesList(ProjectEvaluationRules projectEvaluationRules);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增绩效评价规则
|
||||||
|
*
|
||||||
|
* @param projectEvaluationRules 绩效评价规则
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertProjectEvaluationRules(ProjectEvaluationRules projectEvaluationRules);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改绩效评价规则
|
||||||
|
*
|
||||||
|
* @param projectEvaluationRules 绩效评价规则
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateProjectEvaluationRules(ProjectEvaluationRules projectEvaluationRules);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除绩效评价规则
|
||||||
|
*
|
||||||
|
* @param id 绩效评价规则主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteProjectEvaluationRulesById(String id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除绩效评价规则
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteProjectEvaluationRulesByIds(String[] ids);
|
||||||
|
}
|
@ -0,0 +1,62 @@
|
|||||||
|
package com.ruoyi.server.evaluationrules.service;
|
||||||
|
|
||||||
|
import com.ruoyi.server.evaluationrules.domain.ProjectEvaluationRules;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 绩效评价规则Service接口
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-07-02
|
||||||
|
*/
|
||||||
|
public interface IProjectEvaluationRulesService
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询绩效评价规则
|
||||||
|
*
|
||||||
|
* @param id 绩效评价规则主键
|
||||||
|
* @return 绩效评价规则
|
||||||
|
*/
|
||||||
|
public ProjectEvaluationRules selectProjectEvaluationRulesById(String id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询绩效评价规则列表
|
||||||
|
*
|
||||||
|
* @param projectEvaluationRules 绩效评价规则
|
||||||
|
* @return 绩效评价规则集合
|
||||||
|
*/
|
||||||
|
public List<ProjectEvaluationRules> selectProjectEvaluationRulesList(ProjectEvaluationRules projectEvaluationRules);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增绩效评价规则
|
||||||
|
*
|
||||||
|
* @param projectEvaluationRules 绩效评价规则
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertProjectEvaluationRules(ProjectEvaluationRules projectEvaluationRules);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改绩效评价规则
|
||||||
|
*
|
||||||
|
* @param projectEvaluationRules 绩效评价规则
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateProjectEvaluationRules(ProjectEvaluationRules projectEvaluationRules);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除绩效评价规则
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的绩效评价规则主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteProjectEvaluationRulesByIds(String[] ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除绩效评价规则信息
|
||||||
|
*
|
||||||
|
* @param id 绩效评价规则主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteProjectEvaluationRulesById(String id);
|
||||||
|
}
|
@ -0,0 +1,102 @@
|
|||||||
|
package com.ruoyi.server.evaluationrules.service.impl;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.ruoyi.common.utils.DateUtils;
|
||||||
|
import com.ruoyi.common.utils.uuid.IdUtils;
|
||||||
|
import com.ruoyi.server.evaluationrules.domain.ProjectEvaluationRules;
|
||||||
|
import com.ruoyi.server.evaluationrules.mapper.ProjectEvaluationRulesMapper;
|
||||||
|
import com.ruoyi.server.evaluationrules.service.IProjectEvaluationRulesService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import static com.ruoyi.common.utils.SecurityUtils.getUsername;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 绩效评价规则Service业务层处理
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-07-02
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class ProjectEvaluationRulesServiceImpl implements IProjectEvaluationRulesService
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private ProjectEvaluationRulesMapper projectEvaluationRulesMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询绩效评价规则
|
||||||
|
*
|
||||||
|
* @param id 绩效评价规则主键
|
||||||
|
* @return 绩效评价规则
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public ProjectEvaluationRules selectProjectEvaluationRulesById(String id)
|
||||||
|
{
|
||||||
|
return projectEvaluationRulesMapper.selectProjectEvaluationRulesById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询绩效评价规则列表
|
||||||
|
*
|
||||||
|
* @param projectEvaluationRules 绩效评价规则
|
||||||
|
* @return 绩效评价规则
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<ProjectEvaluationRules> selectProjectEvaluationRulesList(ProjectEvaluationRules projectEvaluationRules)
|
||||||
|
{
|
||||||
|
return projectEvaluationRulesMapper.selectProjectEvaluationRulesList(projectEvaluationRules);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增绩效评价规则
|
||||||
|
*
|
||||||
|
* @param projectEvaluationRules 绩效评价规则
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertProjectEvaluationRules(ProjectEvaluationRules projectEvaluationRules)
|
||||||
|
{
|
||||||
|
projectEvaluationRules.setId(IdUtils.simpleUUID());
|
||||||
|
projectEvaluationRules.setCreateBy(getUsername());
|
||||||
|
projectEvaluationRules.setCreateTime(DateUtils.getNowDate());
|
||||||
|
return projectEvaluationRulesMapper.insertProjectEvaluationRules(projectEvaluationRules);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改绩效评价规则
|
||||||
|
*
|
||||||
|
* @param projectEvaluationRules 绩效评价规则
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updateProjectEvaluationRules(ProjectEvaluationRules projectEvaluationRules)
|
||||||
|
{
|
||||||
|
projectEvaluationRules.setUpdateBy(getUsername());
|
||||||
|
projectEvaluationRules.setUpdateTime(DateUtils.getNowDate());
|
||||||
|
return projectEvaluationRulesMapper.updateProjectEvaluationRules(projectEvaluationRules);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除绩效评价规则
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的绩效评价规则主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteProjectEvaluationRulesByIds(String[] ids)
|
||||||
|
{
|
||||||
|
return projectEvaluationRulesMapper.deleteProjectEvaluationRulesByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除绩效评价规则信息
|
||||||
|
*
|
||||||
|
* @param id 绩效评价规则主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteProjectEvaluationRulesById(String id)
|
||||||
|
{
|
||||||
|
return projectEvaluationRulesMapper.deleteProjectEvaluationRulesById(id);
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,133 @@
|
|||||||
|
<?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.ruoyi.server.evaluate.mapper.ProjectEvaluateMapper">
|
||||||
|
|
||||||
|
<resultMap type="com.ruoyi.server.evaluate.domain.ProjectEvaluate" id="ProjectEvaluateResult">
|
||||||
|
<result property="id" column="id" />
|
||||||
|
<result property="createBy" column="create_by" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="updateBy" column="update_by" />
|
||||||
|
<result property="updateTime" column="update_time" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
<result property="status" column="status" />
|
||||||
|
<result property="employeeNum" column="employee_num" />
|
||||||
|
<result property="name" column="name" />
|
||||||
|
<result property="deptName" column="dept_name" />
|
||||||
|
<result property="position" column="position" />
|
||||||
|
<result property="checkCycle" column="check_cycle" />
|
||||||
|
<result property="workGoal" column="work_goal" />
|
||||||
|
<result property="completionDecl" column="completion_decl" />
|
||||||
|
<result property="completionRate" column="completion_rate" />
|
||||||
|
<result property="checkScore" column="check_score" />
|
||||||
|
<result property="checkLv" column="check_lv" />
|
||||||
|
<result property="signatureSupervisor" column="signature_supervisor" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectProjectEvaluateVo">
|
||||||
|
select id, create_by, create_time, update_by, update_time, remark, status, employee_num, name, dept_name, position, check_cycle, work_goal, completion_decl, completion_rate, check_score, check_lv, signature_supervisor from project_evaluate
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectProjectEvaluateList" parameterType="com.ruoyi.server.evaluate.domain.ProjectEvaluate" resultMap="ProjectEvaluateResult">
|
||||||
|
<include refid="selectProjectEvaluateVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="status != null and status != ''"> and status = #{status}</if>
|
||||||
|
<if test="employeeNum != null and employeeNum != ''"> and employee_num = #{employeeNum}</if>
|
||||||
|
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
|
||||||
|
<if test="deptName != null and deptName != ''"> and dept_name like concat('%', #{deptName}, '%')</if>
|
||||||
|
<if test="position != null and position != ''"> and position = #{position}</if>
|
||||||
|
<if test="checkCycle != null and checkCycle != ''"> and check_cycle = #{checkCycle}</if>
|
||||||
|
<if test="workGoal != null and workGoal != ''"> and work_goal = #{workGoal}</if>
|
||||||
|
<if test="completionDecl != null and completionDecl != ''"> and completion_decl = #{completionDecl}</if>
|
||||||
|
<if test="completionRate != null and completionRate != ''"> and completion_rate = #{completionRate}</if>
|
||||||
|
<if test="checkScore != null and checkScore != ''"> and check_score = #{checkScore}</if>
|
||||||
|
<if test="checkLv != null and checkLv != ''"> and check_lv = #{checkLv}</if>
|
||||||
|
<if test="signatureSupervisor != null and signatureSupervisor != ''"> and signature_supervisor = #{signatureSupervisor}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectProjectEvaluateById" parameterType="String" resultMap="ProjectEvaluateResult">
|
||||||
|
<include refid="selectProjectEvaluateVo"/>
|
||||||
|
where id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertProjectEvaluate" parameterType="com.ruoyi.server.evaluate.domain.ProjectEvaluate">
|
||||||
|
insert into project_evaluate
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="id != null">id,</if>
|
||||||
|
<if test="createBy != null">create_by,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="updateBy != null">update_by,</if>
|
||||||
|
<if test="updateTime != null">update_time,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
<if test="status != null">status,</if>
|
||||||
|
<if test="employeeNum != null">employee_num,</if>
|
||||||
|
<if test="name != null">name,</if>
|
||||||
|
<if test="deptName != null">dept_name,</if>
|
||||||
|
<if test="position != null">position,</if>
|
||||||
|
<if test="checkCycle != null">check_cycle,</if>
|
||||||
|
<if test="workGoal != null">work_goal,</if>
|
||||||
|
<if test="completionDecl != null">completion_decl,</if>
|
||||||
|
<if test="completionRate != null">completion_rate,</if>
|
||||||
|
<if test="checkScore != null">check_score,</if>
|
||||||
|
<if test="checkLv != null">check_lv,</if>
|
||||||
|
<if test="signatureSupervisor != null">signature_supervisor,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="id != null">#{id},</if>
|
||||||
|
<if test="createBy != null">#{createBy},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="updateBy != null">#{updateBy},</if>
|
||||||
|
<if test="updateTime != null">#{updateTime},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
<if test="status != null">#{status},</if>
|
||||||
|
<if test="employeeNum != null">#{employeeNum},</if>
|
||||||
|
<if test="name != null">#{name},</if>
|
||||||
|
<if test="deptName != null">#{deptName},</if>
|
||||||
|
<if test="position != null">#{position},</if>
|
||||||
|
<if test="checkCycle != null">#{checkCycle},</if>
|
||||||
|
<if test="workGoal != null">#{workGoal},</if>
|
||||||
|
<if test="completionDecl != null">#{completionDecl},</if>
|
||||||
|
<if test="completionRate != null">#{completionRate},</if>
|
||||||
|
<if test="checkScore != null">#{checkScore},</if>
|
||||||
|
<if test="checkLv != null">#{checkLv},</if>
|
||||||
|
<if test="signatureSupervisor != null">#{signatureSupervisor},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateProjectEvaluate" parameterType="com.ruoyi.server.evaluate.domain.ProjectEvaluate">
|
||||||
|
update project_evaluate
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="createBy != null">create_by = #{createBy},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="updateBy != null">update_by = #{updateBy},</if>
|
||||||
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
<if test="status != null">status = #{status},</if>
|
||||||
|
<if test="employeeNum != null">employee_num = #{employeeNum},</if>
|
||||||
|
<if test="name != null">name = #{name},</if>
|
||||||
|
<if test="deptName != null">dept_name = #{deptName},</if>
|
||||||
|
<if test="position != null">position = #{position},</if>
|
||||||
|
<if test="checkCycle != null">check_cycle = #{checkCycle},</if>
|
||||||
|
<if test="workGoal != null">work_goal = #{workGoal},</if>
|
||||||
|
<if test="completionDecl != null">completion_decl = #{completionDecl},</if>
|
||||||
|
<if test="completionRate != null">completion_rate = #{completionRate},</if>
|
||||||
|
<if test="checkScore != null">check_score = #{checkScore},</if>
|
||||||
|
<if test="checkLv != null">check_lv = #{checkLv},</if>
|
||||||
|
<if test="signatureSupervisor != null">signature_supervisor = #{signatureSupervisor},</if>
|
||||||
|
</trim>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteProjectEvaluateById" parameterType="String">
|
||||||
|
delete from project_evaluate where id = #{id}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteProjectEvaluateByIds" parameterType="String">
|
||||||
|
delete from project_evaluate where id in
|
||||||
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
@ -0,0 +1,138 @@
|
|||||||
|
<?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.ruoyi.server.evaluationrules.mapper.ProjectEvaluationRulesMapper">
|
||||||
|
|
||||||
|
<resultMap type="com.ruoyi.server.evaluationrules.domain.ProjectEvaluationRules" id="ProjectEvaluationRulesResult">
|
||||||
|
<result property="id" column="id" />
|
||||||
|
<result property="createBy" column="create_by" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="updateBy" column="update_by" />
|
||||||
|
<result property="updateTime" column="update_time" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
<result property="status" column="status" />
|
||||||
|
<result property="ruleName" column="rule_name" />
|
||||||
|
<result property="checkCycle" column="check_cycle" />
|
||||||
|
<result property="checkObject" column="check_object" />
|
||||||
|
<result property="checkTarget" column="check_target" />
|
||||||
|
<result property="weightAllocationRule" column="weight_allocation_rule" />
|
||||||
|
<result property="checkDetails" column="check_details" />
|
||||||
|
<result property="checkLv" column="check_lv" />
|
||||||
|
<result property="conduct" column="conduct" />
|
||||||
|
<result property="demand" column="demand" />
|
||||||
|
<result property="declare" column="declare" />
|
||||||
|
<result property="takeeffectTime" column="takeeffect_time" />
|
||||||
|
<result property="loseEfficacy" column="lose_efficacy" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectProjectEvaluationRulesVo">
|
||||||
|
select id, create_by, create_time, update_by, update_time, remark, status, rule_name, check_cycle, check_object, check_target, weight_allocation_rule, check_details, check_lv, conduct, demand, `declare`, takeeffect_time, lose_efficacy from project_evaluation_rules
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectProjectEvaluationRulesList" parameterType="com.ruoyi.server.evaluationrules.domain.ProjectEvaluationRules" resultMap="ProjectEvaluationRulesResult">
|
||||||
|
<include refid="selectProjectEvaluationRulesVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="status != null and status != ''"> and status = #{status}</if>
|
||||||
|
<if test="ruleName != null and ruleName != ''"> and rule_name like concat('%', #{ruleName}, '%')</if>
|
||||||
|
<if test="checkCycle != null and checkCycle != ''"> and check_cycle = #{checkCycle}</if>
|
||||||
|
<if test="checkObject != null and checkObject != ''"> and check_object = #{checkObject}</if>
|
||||||
|
<if test="checkTarget != null and checkTarget != ''"> and check_target = #{checkTarget}</if>
|
||||||
|
<if test="weightAllocationRule != null and weightAllocationRule != ''"> and weight_allocation_rule = #{weightAllocationRule}</if>
|
||||||
|
<if test="checkDetails != null and checkDetails != ''"> and check_details = #{checkDetails}</if>
|
||||||
|
<if test="checkLv != null and checkLv != ''"> and check_lv = #{checkLv}</if>
|
||||||
|
<if test="conduct != null and conduct != ''"> and conduct = #{conduct}</if>
|
||||||
|
<if test="demand != null and demand != ''"> and demand = #{demand}</if>
|
||||||
|
<if test="declare != null and declare != ''"> and `declare` = #{declare}</if>
|
||||||
|
<if test="takeeffectTime != null "> and takeeffect_time = #{takeeffectTime}</if>
|
||||||
|
<if test="loseEfficacy != null"> and lose_efficacy = #{loseEfficacy}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectProjectEvaluationRulesById" parameterType="String" resultMap="ProjectEvaluationRulesResult">
|
||||||
|
<include refid="selectProjectEvaluationRulesVo"/>
|
||||||
|
where id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertProjectEvaluationRules" parameterType="com.ruoyi.server.evaluationrules.domain.ProjectEvaluationRules">
|
||||||
|
insert into project_evaluation_rules
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="id != null">id,</if>
|
||||||
|
<if test="createBy != null">create_by,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="updateBy != null">update_by,</if>
|
||||||
|
<if test="updateTime != null">update_time,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
<if test="status != null">status,</if>
|
||||||
|
<if test="ruleName != null">rule_name,</if>
|
||||||
|
<if test="checkCycle != null">check_cycle,</if>
|
||||||
|
<if test="checkObject != null">check_object,</if>
|
||||||
|
<if test="checkTarget != null">check_target,</if>
|
||||||
|
<if test="weightAllocationRule != null">weight_allocation_rule,</if>
|
||||||
|
<if test="checkDetails != null">check_details,</if>
|
||||||
|
<if test="checkLv != null">check_lv,</if>
|
||||||
|
<if test="conduct != null">conduct,</if>
|
||||||
|
<if test="demand != null">demand,</if>
|
||||||
|
<if test="declare != null">`declare`,</if>
|
||||||
|
<if test="takeeffectTime != null">takeeffect_time,</if>
|
||||||
|
<if test="loseEfficacy != null">lose_efficacy,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="id != null">#{id},</if>
|
||||||
|
<if test="createBy != null">#{createBy},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="updateBy != null">#{updateBy},</if>
|
||||||
|
<if test="updateTime != null">#{updateTime},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
<if test="status != null">#{status},</if>
|
||||||
|
<if test="ruleName != null">#{ruleName},</if>
|
||||||
|
<if test="checkCycle != null">#{checkCycle},</if>
|
||||||
|
<if test="checkObject != null">#{checkObject},</if>
|
||||||
|
<if test="checkTarget != null">#{checkTarget},</if>
|
||||||
|
<if test="weightAllocationRule != null">#{weightAllocationRule},</if>
|
||||||
|
<if test="checkDetails != null">#{checkDetails},</if>
|
||||||
|
<if test="checkLv != null">#{checkLv},</if>
|
||||||
|
<if test="conduct != null">#{conduct},</if>
|
||||||
|
<if test="demand != null">#{demand},</if>
|
||||||
|
<if test="declare != null">#{declare},</if>
|
||||||
|
<if test="takeeffectTime != null">#{takeeffectTime},</if>
|
||||||
|
<if test="loseEfficacy != null">#{loseEfficacy},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateProjectEvaluationRules" parameterType="com.ruoyi.server.evaluationrules.domain.ProjectEvaluationRules">
|
||||||
|
update project_evaluation_rules
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="createBy != null">create_by = #{createBy},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="updateBy != null">update_by = #{updateBy},</if>
|
||||||
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
<if test="status != null">status = #{status},</if>
|
||||||
|
<if test="ruleName != null">rule_name = #{ruleName},</if>
|
||||||
|
<if test="checkCycle != null">check_cycle = #{checkCycle},</if>
|
||||||
|
<if test="checkObject != null">check_object = #{checkObject},</if>
|
||||||
|
<if test="checkTarget != null">check_target = #{checkTarget},</if>
|
||||||
|
<if test="weightAllocationRule != null">weight_allocation_rule = #{weightAllocationRule},</if>
|
||||||
|
<if test="checkDetails != null">check_details = #{checkDetails},</if>
|
||||||
|
<if test="checkLv != null">check_lv = #{checkLv},</if>
|
||||||
|
<if test="conduct != null">conduct = #{conduct},</if>
|
||||||
|
<if test="demand != null">demand = #{demand},</if>
|
||||||
|
<if test="declare != null">`declare` = #{declare},</if>
|
||||||
|
<if test="takeeffectTime != null">takeeffect_time = #{takeeffectTime},</if>
|
||||||
|
<if test="loseEfficacy != null">lose_efficacy = #{loseEfficacy},</if>
|
||||||
|
</trim>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteProjectEvaluationRulesById" parameterType="String">
|
||||||
|
delete from project_evaluation_rules where id = #{id}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteProjectEvaluationRulesByIds" parameterType="String">
|
||||||
|
delete from project_evaluation_rules where id in
|
||||||
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
@ -0,0 +1,44 @@
|
|||||||
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
// 查询绩效评价信息列表
|
||||||
|
export function listEvaluate(query) {
|
||||||
|
return request({
|
||||||
|
url: '/evaluate/evaluate/list',
|
||||||
|
method: 'get',
|
||||||
|
params: query
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 查询绩效评价信息详细
|
||||||
|
export function getEvaluate(id) {
|
||||||
|
return request({
|
||||||
|
url: '/evaluate/evaluate/' + id,
|
||||||
|
method: 'get'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 新增绩效评价信息
|
||||||
|
export function addEvaluate(data) {
|
||||||
|
return request({
|
||||||
|
url: '/evaluate/evaluate',
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 修改绩效评价信息
|
||||||
|
export function updateEvaluate(data) {
|
||||||
|
return request({
|
||||||
|
url: '/evaluate/evaluate',
|
||||||
|
method: 'put',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 删除绩效评价信息
|
||||||
|
export function delEvaluate(id) {
|
||||||
|
return request({
|
||||||
|
url: '/evaluate/evaluate/' + id,
|
||||||
|
method: 'delete'
|
||||||
|
})
|
||||||
|
}
|
@ -0,0 +1,44 @@
|
|||||||
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
// 查询绩效评价规则列表
|
||||||
|
export function listEvaluationrules(query) {
|
||||||
|
return request({
|
||||||
|
url: '/evaluationrules/evaluationrules/list',
|
||||||
|
method: 'get',
|
||||||
|
params: query
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 查询绩效评价规则详细
|
||||||
|
export function getEvaluationrules(id) {
|
||||||
|
return request({
|
||||||
|
url: '/evaluationrules/evaluationrules/' + id,
|
||||||
|
method: 'get'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 新增绩效评价规则
|
||||||
|
export function addEvaluationrules(data) {
|
||||||
|
return request({
|
||||||
|
url: '/evaluationrules/evaluationrules',
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 修改绩效评价规则
|
||||||
|
export function updateEvaluationrules(data) {
|
||||||
|
return request({
|
||||||
|
url: '/evaluationrules/evaluationrules',
|
||||||
|
method: 'put',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 删除绩效评价规则
|
||||||
|
export function delEvaluationrules(id) {
|
||||||
|
return request({
|
||||||
|
url: '/evaluationrules/evaluationrules/' + id,
|
||||||
|
method: 'delete'
|
||||||
|
})
|
||||||
|
}
|
@ -0,0 +1,408 @@
|
|||||||
|
<template>
|
||||||
|
<div class="app-container">
|
||||||
|
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
|
||||||
|
<el-form-item label="员工编号" prop="employeeNum">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.employeeNum"
|
||||||
|
placeholder="请输入员工编号"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="姓名" prop="name">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.name"
|
||||||
|
placeholder="请输入姓名"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="部门名称" prop="deptName">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.deptName"
|
||||||
|
placeholder="请输入部门名称"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="职位" prop="position">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.position"
|
||||||
|
placeholder="请输入职位"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="考核周期" prop="checkCycle">
|
||||||
|
<el-select v-model="queryParams.checkCycle" placeholder="请选择考核周期" clearable>
|
||||||
|
<el-option
|
||||||
|
v-for="dict in dict.type.khzq_check"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="完成率" prop="completionRate">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.completionRate"
|
||||||
|
placeholder="请输入完成率"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="评分" prop="checkScore">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.checkScore"
|
||||||
|
placeholder="请输入评分"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="评分等级" prop="checkLv">
|
||||||
|
<el-select v-model="queryParams.checkLv" placeholder="请选择评分等级" clearable>
|
||||||
|
<el-option
|
||||||
|
v-for="dict in dict.type.jxdj_check"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="主管签字" prop="signatureSupervisor">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.signatureSupervisor"
|
||||||
|
placeholder="请输入主管签字"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||||
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
|
||||||
|
<el-row :gutter="10" class="mb8">
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
plain
|
||||||
|
icon="el-icon-plus"
|
||||||
|
size="mini"
|
||||||
|
@click="handleAdd"
|
||||||
|
v-hasPermi="['evaluate:evaluate:add']"
|
||||||
|
>新增</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button
|
||||||
|
type="success"
|
||||||
|
plain
|
||||||
|
icon="el-icon-edit"
|
||||||
|
size="mini"
|
||||||
|
:disabled="single"
|
||||||
|
@click="handleUpdate"
|
||||||
|
v-hasPermi="['evaluate:evaluate:edit']"
|
||||||
|
>修改</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button
|
||||||
|
type="danger"
|
||||||
|
plain
|
||||||
|
icon="el-icon-delete"
|
||||||
|
size="mini"
|
||||||
|
:disabled="multiple"
|
||||||
|
@click="handleDelete"
|
||||||
|
v-hasPermi="['evaluate:evaluate:remove']"
|
||||||
|
>删除</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button
|
||||||
|
type="warning"
|
||||||
|
plain
|
||||||
|
icon="el-icon-download"
|
||||||
|
size="mini"
|
||||||
|
@click="handleExport"
|
||||||
|
v-hasPermi="['evaluate:evaluate:export']"
|
||||||
|
>导出</el-button>
|
||||||
|
</el-col>
|
||||||
|
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-table v-loading="loading" :data="evaluateList" @selection-change="handleSelectionChange">
|
||||||
|
<el-table-column type="selection" width="55" align="center" />
|
||||||
|
<el-table-column label="主键id" align="center" prop="id" />
|
||||||
|
<el-table-column label="备注" align="center" prop="remark" />
|
||||||
|
<el-table-column label="删除标志" align="center" prop="status" />
|
||||||
|
<el-table-column label="员工编号" align="center" prop="employeeNum" />
|
||||||
|
<el-table-column label="姓名" align="center" prop="name" />
|
||||||
|
<el-table-column label="部门名称" align="center" prop="deptName" />
|
||||||
|
<el-table-column label="职位" align="center" prop="position" />
|
||||||
|
<el-table-column label="考核周期" align="center" prop="checkCycle">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<dict-tag :options="dict.type.khzq_check" :value="scope.row.checkCycle"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="工作目标" align="center" prop="workGoal" />
|
||||||
|
<el-table-column label="完成情况" align="center" prop="completionDecl" />
|
||||||
|
<el-table-column label="完成率" align="center" prop="completionRate" />
|
||||||
|
<el-table-column label="评分" align="center" prop="checkScore" />
|
||||||
|
<el-table-column label="评分等级" align="center" prop="checkLv">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<dict-tag :options="dict.type.jxdj_check" :value="scope.row.checkLv"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="主管签字" align="center" prop="signatureSupervisor" />
|
||||||
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
icon="el-icon-edit"
|
||||||
|
@click="handleUpdate(scope.row)"
|
||||||
|
v-hasPermi="['evaluate:evaluate:edit']"
|
||||||
|
>修改</el-button>
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
icon="el-icon-delete"
|
||||||
|
@click="handleDelete(scope.row)"
|
||||||
|
v-hasPermi="['evaluate:evaluate:remove']"
|
||||||
|
>删除</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
|
||||||
|
<pagination
|
||||||
|
v-show="total>0"
|
||||||
|
:total="total"
|
||||||
|
:page.sync="queryParams.pageNum"
|
||||||
|
:limit.sync="queryParams.pageSize"
|
||||||
|
@pagination="getList"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<!-- 添加或修改绩效评价信息对话框 -->
|
||||||
|
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
||||||
|
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
||||||
|
<el-form-item label="备注" prop="remark">
|
||||||
|
<el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="员工编号" prop="employeeNum">
|
||||||
|
<el-input v-model="form.employeeNum" placeholder="请输入员工编号" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="姓名" prop="name">
|
||||||
|
<el-input v-model="form.name" placeholder="请输入姓名" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="部门名称" prop="deptName">
|
||||||
|
<el-input v-model="form.deptName" placeholder="请输入部门名称" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="职位" prop="position">
|
||||||
|
<el-input v-model="form.position" placeholder="请输入职位" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="考核周期" prop="checkCycle">
|
||||||
|
<el-select v-model="form.checkCycle" placeholder="请选择考核周期">
|
||||||
|
<el-option
|
||||||
|
v-for="dict in dict.type.khzq_check"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="工作目标" prop="workGoal">
|
||||||
|
<el-input v-model="form.workGoal" type="textarea" placeholder="请输入内容" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="完成情况" prop="completionDecl">
|
||||||
|
<el-input v-model="form.completionDecl" type="textarea" placeholder="请输入内容" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="完成率" prop="completionRate">
|
||||||
|
<el-input v-model="form.completionRate" placeholder="请输入完成率" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="评分" prop="checkScore">
|
||||||
|
<el-input v-model="form.checkScore" placeholder="请输入评分" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="评分等级" prop="checkLv">
|
||||||
|
<el-select v-model="form.checkLv" placeholder="请选择评分等级">
|
||||||
|
<el-option
|
||||||
|
v-for="dict in dict.type.jxdj_check"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="主管签字" prop="signatureSupervisor">
|
||||||
|
<el-input v-model="form.signatureSupervisor" placeholder="请输入主管签字" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button type="primary" @click="submitForm">确 定</el-button>
|
||||||
|
<el-button @click="cancel">取 消</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import { listEvaluate, getEvaluate, delEvaluate, addEvaluate, updateEvaluate } from "@/api/evaluate/evaluate";
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: "Evaluate",
|
||||||
|
dicts: ['khzq_check', 'jxdj_check'],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
// 遮罩层
|
||||||
|
loading: true,
|
||||||
|
// 选中数组
|
||||||
|
ids: [],
|
||||||
|
// 非单个禁用
|
||||||
|
single: true,
|
||||||
|
// 非多个禁用
|
||||||
|
multiple: true,
|
||||||
|
// 显示搜索条件
|
||||||
|
showSearch: true,
|
||||||
|
// 总条数
|
||||||
|
total: 0,
|
||||||
|
// 绩效评价信息表格数据
|
||||||
|
evaluateList: [],
|
||||||
|
// 弹出层标题
|
||||||
|
title: "",
|
||||||
|
// 是否显示弹出层
|
||||||
|
open: false,
|
||||||
|
// 查询参数
|
||||||
|
queryParams: {
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 10,
|
||||||
|
status: null,
|
||||||
|
employeeNum: null,
|
||||||
|
name: null,
|
||||||
|
deptName: null,
|
||||||
|
position: null,
|
||||||
|
checkCycle: null,
|
||||||
|
workGoal: null,
|
||||||
|
completionDecl: null,
|
||||||
|
completionRate: null,
|
||||||
|
checkScore: null,
|
||||||
|
checkLv: null,
|
||||||
|
signatureSupervisor: null
|
||||||
|
},
|
||||||
|
// 表单参数
|
||||||
|
form: {},
|
||||||
|
// 表单校验
|
||||||
|
rules: {
|
||||||
|
}
|
||||||
|
};
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.getList();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
/** 查询绩效评价信息列表 */
|
||||||
|
getList() {
|
||||||
|
this.loading = true;
|
||||||
|
listEvaluate(this.queryParams).then(response => {
|
||||||
|
this.evaluateList = response.rows;
|
||||||
|
this.total = response.total;
|
||||||
|
this.loading = false;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
// 取消按钮
|
||||||
|
cancel() {
|
||||||
|
this.open = false;
|
||||||
|
this.reset();
|
||||||
|
},
|
||||||
|
// 表单重置
|
||||||
|
reset() {
|
||||||
|
this.form = {
|
||||||
|
id: null,
|
||||||
|
createBy: null,
|
||||||
|
createTime: null,
|
||||||
|
updateBy: null,
|
||||||
|
updateTime: null,
|
||||||
|
remark: null,
|
||||||
|
status: null,
|
||||||
|
employeeNum: null,
|
||||||
|
name: null,
|
||||||
|
deptName: null,
|
||||||
|
position: null,
|
||||||
|
checkCycle: null,
|
||||||
|
workGoal: null,
|
||||||
|
completionDecl: null,
|
||||||
|
completionRate: null,
|
||||||
|
checkScore: null,
|
||||||
|
checkLv: null,
|
||||||
|
signatureSupervisor: null
|
||||||
|
};
|
||||||
|
this.resetForm("form");
|
||||||
|
},
|
||||||
|
/** 搜索按钮操作 */
|
||||||
|
handleQuery() {
|
||||||
|
this.queryParams.pageNum = 1;
|
||||||
|
this.getList();
|
||||||
|
},
|
||||||
|
/** 重置按钮操作 */
|
||||||
|
resetQuery() {
|
||||||
|
this.resetForm("queryForm");
|
||||||
|
this.handleQuery();
|
||||||
|
},
|
||||||
|
// 多选框选中数据
|
||||||
|
handleSelectionChange(selection) {
|
||||||
|
this.ids = selection.map(item => item.id)
|
||||||
|
this.single = selection.length!==1
|
||||||
|
this.multiple = !selection.length
|
||||||
|
},
|
||||||
|
/** 新增按钮操作 */
|
||||||
|
handleAdd() {
|
||||||
|
this.reset();
|
||||||
|
this.open = true;
|
||||||
|
this.title = "添加绩效评价信息";
|
||||||
|
},
|
||||||
|
/** 修改按钮操作 */
|
||||||
|
handleUpdate(row) {
|
||||||
|
this.reset();
|
||||||
|
const id = row.id || this.ids
|
||||||
|
getEvaluate(id).then(response => {
|
||||||
|
this.form = response.data;
|
||||||
|
this.open = true;
|
||||||
|
this.title = "修改绩效评价信息";
|
||||||
|
});
|
||||||
|
},
|
||||||
|
/** 提交按钮 */
|
||||||
|
submitForm() {
|
||||||
|
this.$refs["form"].validate(valid => {
|
||||||
|
if (valid) {
|
||||||
|
if (this.form.id != null) {
|
||||||
|
updateEvaluate(this.form).then(response => {
|
||||||
|
this.$modal.msgSuccess("修改成功");
|
||||||
|
this.open = false;
|
||||||
|
this.getList();
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
addEvaluate(this.form).then(response => {
|
||||||
|
this.$modal.msgSuccess("新增成功");
|
||||||
|
this.open = false;
|
||||||
|
this.getList();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
/** 删除按钮操作 */
|
||||||
|
handleDelete(row) {
|
||||||
|
const ids = row.id || this.ids;
|
||||||
|
this.$modal.confirm('是否确认删除绩效评价信息编号为"' + ids + '"的数据项?').then(function() {
|
||||||
|
return delEvaluate(ids);
|
||||||
|
}).then(() => {
|
||||||
|
this.getList();
|
||||||
|
this.$modal.msgSuccess("删除成功");
|
||||||
|
}).catch(() => {});
|
||||||
|
},
|
||||||
|
/** 导出按钮操作 */
|
||||||
|
handleExport() {
|
||||||
|
this.download('evaluate/evaluate/export', {
|
||||||
|
...this.queryParams
|
||||||
|
}, `evaluate_${new Date().getTime()}.xlsx`)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
@ -0,0 +1,436 @@
|
|||||||
|
<template>
|
||||||
|
<div class="app-container">
|
||||||
|
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
|
||||||
|
<el-form-item label="规则名称" prop="ruleName">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.ruleName"
|
||||||
|
placeholder="请输入规则名称"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="考核周期" prop="checkCycle">
|
||||||
|
<el-select v-model="queryParams.checkCycle" placeholder="请选择考核周期" clearable>
|
||||||
|
<el-option
|
||||||
|
v-for="dict in dict.type.khzq_check"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="考核对象" prop="checkObject">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.checkObject"
|
||||||
|
placeholder="请输入考核对象"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="考核指标" prop="checkTarget">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.checkTarget"
|
||||||
|
placeholder="请输入考核指标"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="权重分配规则" prop="weightAllocationRule">
|
||||||
|
<el-select v-model="queryParams.weightAllocationRule" placeholder="请选择权重分配规则" clearable>
|
||||||
|
<el-option
|
||||||
|
v-for="dict in dict.type.qzfp_rule"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="绩效等级划分" prop="checkLv">
|
||||||
|
<el-select v-model="queryParams.checkLv" placeholder="请选择绩效等级划分" clearable>
|
||||||
|
<el-option
|
||||||
|
v-for="dict in dict.type.jxdj_check"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="结果应用说明" prop="declare">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.declare"
|
||||||
|
placeholder="请输入结果应用说明"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="生效日期" prop="takeeffectTime">
|
||||||
|
<el-date-picker clearable
|
||||||
|
v-model="queryParams.takeeffectTime"
|
||||||
|
type="date"
|
||||||
|
value-format="yyyy-MM-dd"
|
||||||
|
placeholder="请选择生效日期">
|
||||||
|
</el-date-picker>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="失效日期" prop="loseEfficacy">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.loseEfficacy"
|
||||||
|
placeholder="请输入失效日期"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||||
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
|
||||||
|
<el-row :gutter="10" class="mb8">
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
plain
|
||||||
|
icon="el-icon-plus"
|
||||||
|
size="mini"
|
||||||
|
@click="handleAdd"
|
||||||
|
v-hasPermi="['evaluationrules:evaluationrules:add']"
|
||||||
|
>新增</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button
|
||||||
|
type="success"
|
||||||
|
plain
|
||||||
|
icon="el-icon-edit"
|
||||||
|
size="mini"
|
||||||
|
:disabled="single"
|
||||||
|
@click="handleUpdate"
|
||||||
|
v-hasPermi="['evaluationrules:evaluationrules:edit']"
|
||||||
|
>修改</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button
|
||||||
|
type="danger"
|
||||||
|
plain
|
||||||
|
icon="el-icon-delete"
|
||||||
|
size="mini"
|
||||||
|
:disabled="multiple"
|
||||||
|
@click="handleDelete"
|
||||||
|
v-hasPermi="['evaluationrules:evaluationrules:remove']"
|
||||||
|
>删除</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button
|
||||||
|
type="warning"
|
||||||
|
plain
|
||||||
|
icon="el-icon-download"
|
||||||
|
size="mini"
|
||||||
|
@click="handleExport"
|
||||||
|
v-hasPermi="['evaluationrules:evaluationrules:export']"
|
||||||
|
>导出</el-button>
|
||||||
|
</el-col>
|
||||||
|
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-table v-loading="loading" :data="evaluationrulesList" @selection-change="handleSelectionChange">
|
||||||
|
<el-table-column type="selection" width="55" align="center" />
|
||||||
|
<el-table-column label="主键id" align="center" prop="id" />
|
||||||
|
<el-table-column label="备注" align="center" prop="remark" />
|
||||||
|
<el-table-column label="删除标志" align="center" prop="status" />
|
||||||
|
<el-table-column label="规则名称" align="center" prop="ruleName" />
|
||||||
|
<el-table-column label="考核周期" align="center" prop="checkCycle">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<dict-tag :options="dict.type.khzq_check" :value="scope.row.checkCycle"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="考核对象" align="center" prop="checkObject" />
|
||||||
|
<el-table-column label="考核指标" align="center" prop="checkTarget" />
|
||||||
|
<el-table-column label="权重分配规则" align="center" prop="weightAllocationRule">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<dict-tag :options="dict.type.qzfp_rule" :value="scope.row.weightAllocationRule"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="考核标准说明" align="center" prop="checkDetails" />
|
||||||
|
<el-table-column label="绩效等级划分" align="center" prop="checkLv">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<dict-tag :options="dict.type.jxdj_check" :value="scope.row.checkLv"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="特殊情况处理" align="center" prop="conduct" />
|
||||||
|
<el-table-column label="考核者要求" align="center" prop="demand" />
|
||||||
|
<el-table-column label="结果应用说明" align="center" prop="declare" />
|
||||||
|
<el-table-column label="生效日期" align="center" prop="takeeffectTime" width="180">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ parseTime(scope.row.takeeffectTime, '{y}-{m}-{d}') }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="失效日期" align="center" prop="loseEfficacy" />
|
||||||
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
icon="el-icon-edit"
|
||||||
|
@click="handleUpdate(scope.row)"
|
||||||
|
v-hasPermi="['evaluationrules:evaluationrules:edit']"
|
||||||
|
>修改</el-button>
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
icon="el-icon-delete"
|
||||||
|
@click="handleDelete(scope.row)"
|
||||||
|
v-hasPermi="['evaluationrules:evaluationrules:remove']"
|
||||||
|
>删除</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
|
||||||
|
<pagination
|
||||||
|
v-show="total>0"
|
||||||
|
:total="total"
|
||||||
|
:page.sync="queryParams.pageNum"
|
||||||
|
:limit.sync="queryParams.pageSize"
|
||||||
|
@pagination="getList"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<!-- 添加或修改绩效评价规则对话框 -->
|
||||||
|
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
||||||
|
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
||||||
|
<el-form-item label="备注" prop="remark">
|
||||||
|
<el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="规则名称" prop="ruleName">
|
||||||
|
<el-input v-model="form.ruleName" placeholder="请输入规则名称" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="考核周期" prop="checkCycle">
|
||||||
|
<el-select v-model="form.checkCycle" placeholder="请选择考核周期">
|
||||||
|
<el-option
|
||||||
|
v-for="dict in dict.type.khzq_check"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="考核对象" prop="checkObject">
|
||||||
|
<el-input v-model="form.checkObject" placeholder="请输入考核对象" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="考核指标" prop="checkTarget">
|
||||||
|
<el-input v-model="form.checkTarget" placeholder="请输入考核指标" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="权重分配规则" prop="weightAllocationRule">
|
||||||
|
<el-select v-model="form.weightAllocationRule" placeholder="请选择权重分配规则">
|
||||||
|
<el-option
|
||||||
|
v-for="dict in dict.type.qzfp_rule"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="考核标准说明" prop="checkDetails">
|
||||||
|
<el-input v-model="form.checkDetails" type="textarea" placeholder="请输入内容" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="绩效等级划分" prop="checkLv">
|
||||||
|
<el-select v-model="form.checkLv" placeholder="请选择绩效等级划分">
|
||||||
|
<el-option
|
||||||
|
v-for="dict in dict.type.jxdj_check"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="特殊情况处理" prop="conduct">
|
||||||
|
<el-input v-model="form.conduct" type="textarea" placeholder="请输入内容" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="考核者要求" prop="demand">
|
||||||
|
<el-input v-model="form.demand" type="textarea" placeholder="请输入内容" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="结果应用说明" prop="declare">
|
||||||
|
<el-input v-model="form.declare" placeholder="请输入结果应用说明" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="生效日期" prop="takeeffectTime">
|
||||||
|
<el-date-picker clearable
|
||||||
|
v-model="form.takeeffectTime"
|
||||||
|
type="date"
|
||||||
|
value-format="yyyy-MM-dd"
|
||||||
|
placeholder="请选择生效日期">
|
||||||
|
</el-date-picker>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="失效日期" prop="loseEfficacy">
|
||||||
|
<el-input v-model="form.loseEfficacy" placeholder="请输入失效日期" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button type="primary" @click="submitForm">确 定</el-button>
|
||||||
|
<el-button @click="cancel">取 消</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import { listEvaluationrules, getEvaluationrules, delEvaluationrules, addEvaluationrules, updateEvaluationrules } from "@/api/evaluationrules/evaluationrules";
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: "Evaluationrules",
|
||||||
|
dicts: ['khzq_check', 'qzfp_rule', 'jxdj_check'],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
// 遮罩层
|
||||||
|
loading: true,
|
||||||
|
// 选中数组
|
||||||
|
ids: [],
|
||||||
|
// 非单个禁用
|
||||||
|
single: true,
|
||||||
|
// 非多个禁用
|
||||||
|
multiple: true,
|
||||||
|
// 显示搜索条件
|
||||||
|
showSearch: true,
|
||||||
|
// 总条数
|
||||||
|
total: 0,
|
||||||
|
// 绩效评价规则表格数据
|
||||||
|
evaluationrulesList: [],
|
||||||
|
// 弹出层标题
|
||||||
|
title: "",
|
||||||
|
// 是否显示弹出层
|
||||||
|
open: false,
|
||||||
|
// 查询参数
|
||||||
|
queryParams: {
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 10,
|
||||||
|
status: null,
|
||||||
|
ruleName: null,
|
||||||
|
checkCycle: null,
|
||||||
|
checkObject: null,
|
||||||
|
checkTarget: null,
|
||||||
|
weightAllocationRule: null,
|
||||||
|
checkDetails: null,
|
||||||
|
checkLv: null,
|
||||||
|
conduct: null,
|
||||||
|
demand: null,
|
||||||
|
declare: null,
|
||||||
|
takeeffectTime: null,
|
||||||
|
loseEfficacy: null
|
||||||
|
},
|
||||||
|
// 表单参数
|
||||||
|
form: {},
|
||||||
|
// 表单校验
|
||||||
|
rules: {
|
||||||
|
}
|
||||||
|
};
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.getList();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
/** 查询绩效评价规则列表 */
|
||||||
|
getList() {
|
||||||
|
this.loading = true;
|
||||||
|
listEvaluationrules(this.queryParams).then(response => {
|
||||||
|
this.evaluationrulesList = response.rows;
|
||||||
|
this.total = response.total;
|
||||||
|
this.loading = false;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
// 取消按钮
|
||||||
|
cancel() {
|
||||||
|
this.open = false;
|
||||||
|
this.reset();
|
||||||
|
},
|
||||||
|
// 表单重置
|
||||||
|
reset() {
|
||||||
|
this.form = {
|
||||||
|
id: null,
|
||||||
|
createBy: null,
|
||||||
|
createTime: null,
|
||||||
|
updateBy: null,
|
||||||
|
updateTime: null,
|
||||||
|
remark: null,
|
||||||
|
status: null,
|
||||||
|
ruleName: null,
|
||||||
|
checkCycle: null,
|
||||||
|
checkObject: null,
|
||||||
|
checkTarget: null,
|
||||||
|
weightAllocationRule: null,
|
||||||
|
checkDetails: null,
|
||||||
|
checkLv: null,
|
||||||
|
conduct: null,
|
||||||
|
demand: null,
|
||||||
|
declare: null,
|
||||||
|
takeeffectTime: null,
|
||||||
|
loseEfficacy: null
|
||||||
|
};
|
||||||
|
this.resetForm("form");
|
||||||
|
},
|
||||||
|
/** 搜索按钮操作 */
|
||||||
|
handleQuery() {
|
||||||
|
this.queryParams.pageNum = 1;
|
||||||
|
this.getList();
|
||||||
|
},
|
||||||
|
/** 重置按钮操作 */
|
||||||
|
resetQuery() {
|
||||||
|
this.resetForm("queryForm");
|
||||||
|
this.handleQuery();
|
||||||
|
},
|
||||||
|
// 多选框选中数据
|
||||||
|
handleSelectionChange(selection) {
|
||||||
|
this.ids = selection.map(item => item.id)
|
||||||
|
this.single = selection.length!==1
|
||||||
|
this.multiple = !selection.length
|
||||||
|
},
|
||||||
|
/** 新增按钮操作 */
|
||||||
|
handleAdd() {
|
||||||
|
this.reset();
|
||||||
|
this.open = true;
|
||||||
|
this.title = "添加绩效评价规则";
|
||||||
|
},
|
||||||
|
/** 修改按钮操作 */
|
||||||
|
handleUpdate(row) {
|
||||||
|
this.reset();
|
||||||
|
const id = row.id || this.ids
|
||||||
|
getEvaluationrules(id).then(response => {
|
||||||
|
this.form = response.data;
|
||||||
|
this.open = true;
|
||||||
|
this.title = "修改绩效评价规则";
|
||||||
|
});
|
||||||
|
},
|
||||||
|
/** 提交按钮 */
|
||||||
|
submitForm() {
|
||||||
|
this.$refs["form"].validate(valid => {
|
||||||
|
if (valid) {
|
||||||
|
if (this.form.id != null) {
|
||||||
|
updateEvaluationrules(this.form).then(response => {
|
||||||
|
this.$modal.msgSuccess("修改成功");
|
||||||
|
this.open = false;
|
||||||
|
this.getList();
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
addEvaluationrules(this.form).then(response => {
|
||||||
|
this.$modal.msgSuccess("新增成功");
|
||||||
|
this.open = false;
|
||||||
|
this.getList();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
/** 删除按钮操作 */
|
||||||
|
handleDelete(row) {
|
||||||
|
const ids = row.id || this.ids;
|
||||||
|
this.$modal.confirm('是否确认删除绩效评价规则编号为"' + ids + '"的数据项?').then(function() {
|
||||||
|
return delEvaluationrules(ids);
|
||||||
|
}).then(() => {
|
||||||
|
this.getList();
|
||||||
|
this.$modal.msgSuccess("删除成功");
|
||||||
|
}).catch(() => {});
|
||||||
|
},
|
||||||
|
/** 导出按钮操作 */
|
||||||
|
handleExport() {
|
||||||
|
this.download('evaluationrules/evaluationrules/export', {
|
||||||
|
...this.queryParams
|
||||||
|
}, `evaluationrules_${new Date().getTime()}.xlsx`)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
Loading…
Reference in New Issue