系统薪资项目重名
This commit is contained in:
parent
c7fe4fee23
commit
ce32c6571c
|
|
@ -20,6 +20,13 @@ public interface SysSalaryItemMapper {
|
|||
* @return
|
||||
*/
|
||||
List<SysSalaryItemPO> listSome(SysSalaryItemPO po);
|
||||
|
||||
/**
|
||||
* 条件查询
|
||||
* @param po
|
||||
* @return
|
||||
*/
|
||||
List<SysSalaryItemPO> listLikeName(SysSalaryItemPO po);
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@
|
|||
AND id = #{id}
|
||||
</if>
|
||||
<if test="name != null and name != ''">
|
||||
AND name like '%'+#{name}+'%'
|
||||
AND name = #{name}
|
||||
</if>
|
||||
<if test="code != null and code != ''">
|
||||
AND code = #{code}
|
||||
|
|
@ -143,6 +143,214 @@
|
|||
<if test="id != null and id != ''">
|
||||
AND id = #{id}
|
||||
</if>
|
||||
<if test="name != null and name != ''">
|
||||
AND name = #{name}
|
||||
</if>
|
||||
<if test="code != null and code != ''">
|
||||
AND code = #{code}
|
||||
</if>
|
||||
<if test="systemType != null and systemType != ''">
|
||||
AND system_type = #{systemType}
|
||||
</if>
|
||||
<if test="useDefault != null and useDefault != ''">
|
||||
AND use_default = #{useDefault}
|
||||
</if>
|
||||
<if test="useInEmployeeSalary != null and useInEmployeeSalary != ''">
|
||||
AND use_in_employee_salary = #{useInEmployeeSalary}
|
||||
</if>
|
||||
<if test="roundingMode != null and roundingMode != ''">
|
||||
AND rounding_mode = #{roundingMode}
|
||||
</if>
|
||||
<if test="pattern != null and pattern != ''">
|
||||
AND pattern = #{pattern}
|
||||
</if>
|
||||
<if test="valueType != null and valueType != ''">
|
||||
AND value_type = #{valueType}
|
||||
</if>
|
||||
<if test="formulaId != null and formulaId != ''">
|
||||
AND formula_id = #{formulaId}
|
||||
</if>
|
||||
<if test="description != null and description != ''">
|
||||
AND description = #{description}
|
||||
</if>
|
||||
<if test="canEdit != null and canEdit != ''">
|
||||
AND can_edit = #{canEdit}
|
||||
</if>
|
||||
<if test="dataType != null and dataType != ''">
|
||||
AND data_type = #{dataType}
|
||||
</if>
|
||||
<if test="creator != null and creator != ''">
|
||||
AND creator = #{creator}
|
||||
</if>
|
||||
<if test="deleteType != null and deleteType != ''">
|
||||
AND delete_type = #{deleteType}
|
||||
</if>
|
||||
<if test="tenantKey != null and tenantKey != ''">
|
||||
AND tenant_key = #{tenantKey}
|
||||
</if>
|
||||
<if test="createTime != null and createTime != ''">
|
||||
AND create_time = #{createTime}
|
||||
</if>
|
||||
<if test="updateTime != null and updateTime != ''">
|
||||
AND update_time = #{updateTime}
|
||||
</if>
|
||||
<if test="ids != null and ids.size()>0">
|
||||
AND id IN
|
||||
<foreach collection="ids" open="(" item="id" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</if>
|
||||
ORDER BY id DESC
|
||||
</select>
|
||||
|
||||
|
||||
<select id="listSome" resultMap="BaseResultMap"
|
||||
parameterType="com.engine.salary.entity.salaryitem.po.SysSalaryItemPO" databaseId="oracle">
|
||||
SELECT
|
||||
<include refid="baseColumns"/>
|
||||
FROM hrsa_sys_salary_item t
|
||||
WHERE delete_type = 0
|
||||
<if test="id != null and id != ''">
|
||||
AND id = #{id}
|
||||
</if>
|
||||
<if test="name != null and name != ''">
|
||||
AND name = #{name}
|
||||
</if>
|
||||
<if test="code != null and code != ''">
|
||||
AND code = #{code}
|
||||
</if>
|
||||
<if test="systemType != null and systemType != ''">
|
||||
AND system_type = #{systemType}
|
||||
</if>
|
||||
<if test="useDefault != null and useDefault != ''">
|
||||
AND use_default = #{useDefault}
|
||||
</if>
|
||||
<if test="useInEmployeeSalary != null and useInEmployeeSalary != ''">
|
||||
AND use_in_employee_salary = #{useInEmployeeSalary}
|
||||
</if>
|
||||
<if test="roundingMode != null and roundingMode != ''">
|
||||
AND rounding_mode = #{roundingMode}
|
||||
</if>
|
||||
<if test="pattern != null and pattern != ''">
|
||||
AND pattern = #{pattern}
|
||||
</if>
|
||||
<if test="valueType != null and valueType != ''">
|
||||
AND value_type = #{valueType}
|
||||
</if>
|
||||
<if test="formulaId != null and formulaId != ''">
|
||||
AND formula_id = #{formulaId}
|
||||
</if>
|
||||
<if test="description != null and description != ''">
|
||||
AND description = #{description}
|
||||
</if>
|
||||
<if test="canEdit != null and canEdit != ''">
|
||||
AND can_edit = #{canEdit}
|
||||
</if>
|
||||
<if test="dataType != null and dataType != ''">
|
||||
AND data_type = #{dataType}
|
||||
</if>
|
||||
<if test="creator != null and creator != ''">
|
||||
AND creator = #{creator}
|
||||
</if>
|
||||
<if test="deleteType != null and deleteType != ''">
|
||||
AND delete_type = #{deleteType}
|
||||
</if>
|
||||
<if test="tenantKey != null and tenantKey != ''">
|
||||
AND tenant_key = #{tenantKey}
|
||||
</if>
|
||||
<if test="createTime != null and createTime != ''">
|
||||
AND create_time = #{createTime}
|
||||
</if>
|
||||
<if test="updateTime != null and updateTime != ''">
|
||||
AND update_time = #{updateTime}
|
||||
</if>
|
||||
<if test="ids != null and ids.size()>0">
|
||||
AND id IN
|
||||
<foreach collection="ids" open="(" item="id" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</if>
|
||||
ORDER BY id DESC
|
||||
</select>
|
||||
|
||||
<select id="listLikeName" resultMap="BaseResultMap"
|
||||
parameterType="com.engine.salary.entity.salaryitem.po.SysSalaryItemPO" databaseId="sqlserver">
|
||||
SELECT
|
||||
<include refid="baseColumns"/>
|
||||
FROM hrsa_sys_salary_item t
|
||||
WHERE delete_type = 0
|
||||
<if test="id != null and id != ''">
|
||||
AND id = #{id}
|
||||
</if>
|
||||
<if test="name != null and name != ''">
|
||||
AND name like '%'+#{name}+'%'
|
||||
</if>
|
||||
<if test="code != null and code != ''">
|
||||
AND code = #{code}
|
||||
</if>
|
||||
<if test="systemType != null and systemType != ''">
|
||||
AND system_type = #{systemType}
|
||||
</if>
|
||||
<if test="useDefault != null and useDefault != ''">
|
||||
AND use_default = #{useDefault}
|
||||
</if>
|
||||
<if test="useInEmployeeSalary != null and useInEmployeeSalary != ''">
|
||||
AND use_in_employee_salary = #{useInEmployeeSalary}
|
||||
</if>
|
||||
<if test="roundingMode != null and roundingMode != ''">
|
||||
AND rounding_mode = #{roundingMode}
|
||||
</if>
|
||||
<if test="pattern != null and pattern != ''">
|
||||
AND pattern = #{pattern}
|
||||
</if>
|
||||
<if test="valueType != null and valueType != ''">
|
||||
AND value_type = #{valueType}
|
||||
</if>
|
||||
<if test="formulaId != null and formulaId != ''">
|
||||
AND formula_id = #{formulaId}
|
||||
</if>
|
||||
<if test="description != null and description != ''">
|
||||
AND description = #{description}
|
||||
</if>
|
||||
<if test="canEdit != null and canEdit != ''">
|
||||
AND can_edit = #{canEdit}
|
||||
</if>
|
||||
<if test="dataType != null and dataType != ''">
|
||||
AND data_type = #{dataType}
|
||||
</if>
|
||||
<if test="creator != null and creator != ''">
|
||||
AND creator = #{creator}
|
||||
</if>
|
||||
<if test="deleteType != null and deleteType != ''">
|
||||
AND delete_type = #{deleteType}
|
||||
</if>
|
||||
<if test="tenantKey != null and tenantKey != ''">
|
||||
AND tenant_key = #{tenantKey}
|
||||
</if>
|
||||
<if test="createTime != null and createTime != ''">
|
||||
AND create_time = #{createTime}
|
||||
</if>
|
||||
<if test="updateTime != null and updateTime != ''">
|
||||
AND update_time = #{updateTime}
|
||||
</if>
|
||||
<if test="ids != null and ids.size()>0">
|
||||
AND id IN
|
||||
<foreach collection="ids" open="(" item="id" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</if>
|
||||
ORDER BY id DESC
|
||||
</select>
|
||||
|
||||
<select id="listLikeName" resultMap="BaseResultMap"
|
||||
parameterType="com.engine.salary.entity.salaryitem.po.SysSalaryItemPO" >
|
||||
SELECT
|
||||
<include refid="baseColumns"/>
|
||||
FROM hrsa_sys_salary_item t
|
||||
WHERE delete_type = 0
|
||||
<if test="id != null and id != ''">
|
||||
AND id = #{id}
|
||||
</if>
|
||||
<if test="name != null and name != ''">
|
||||
AND name like CONCAT('%',#{name},'%')
|
||||
</if>
|
||||
|
|
@ -204,7 +412,7 @@
|
|||
</select>
|
||||
|
||||
|
||||
<select id="listSome" resultMap="BaseResultMap"
|
||||
<select id="listLikeName" resultMap="BaseResultMap"
|
||||
parameterType="com.engine.salary.entity.salaryitem.po.SysSalaryItemPO" databaseId="oracle">
|
||||
SELECT
|
||||
<include refid="baseColumns"/>
|
||||
|
|
|
|||
|
|
@ -57,4 +57,6 @@ public interface SysSalaryItemService {
|
|||
List<SysSalaryItemPO> listAll();
|
||||
|
||||
List<SysSalaryItemPO> listSome(SysSalaryItemPO po);
|
||||
|
||||
List<SysSalaryItemPO> listLikeName(SysSalaryItemPO po);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -111,4 +111,9 @@ public class SysSalaryItemServiceImpl extends Service implements SysSalaryItemSe
|
|||
public List<SysSalaryItemPO> listSome(SysSalaryItemPO po) {
|
||||
return getSysSalaryItemMapper().listSome(po);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<SysSalaryItemPO> listLikeName(SysSalaryItemPO po) {
|
||||
return getSysSalaryItemMapper().listLikeName(po);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ public class SysSalaryItemWrapper extends Service {
|
|||
Set<Long> sysSalaryItemIds = SalaryEntityUtil.properties(salaryItemPOS, SalaryItemPO::getSysSalaryItemId);
|
||||
searchParam.setExcludeIds(sysSalaryItemIds);
|
||||
|
||||
List<SysSalaryItemPO> sysSalaryItemPOS = getSysSalaryItemService(user).listSome(SysSalaryItemPO.builder().name(searchParam.getName()).build());
|
||||
List<SysSalaryItemPO> sysSalaryItemPOS = getSysSalaryItemService(user).listLikeName(SysSalaryItemPO.builder().name(searchParam.getName()).build());
|
||||
List<SysSalaryItemPO> finalItems = sysSalaryItemPOS.stream().filter(item -> !sysSalaryItemIds.contains(item.getId())).collect(Collectors.toList());
|
||||
List<SysSalaryItemListDTO> sysSalaryItemListDTOS = SysSalaryItemBO.convert2ListDTO(finalItems);
|
||||
// 分页参数
|
||||
|
|
|
|||
Loading…
Reference in New Issue