update
This commit is contained in:
@@ -135,6 +135,9 @@ public class Experiment implements Serializable {
|
||||
@Excel(name = "状态", width = 15)
|
||||
@Schema(description = "状态")
|
||||
private String status;
|
||||
|
||||
@TableField(exist = false)
|
||||
private List<String> statusList;
|
||||
/**
|
||||
* 样品信息
|
||||
*/
|
||||
|
||||
@@ -42,6 +42,18 @@
|
||||
<if test="experiment.status != null and experiment.status != ''">
|
||||
and e.status like concat('%', #{experiment.status}, '%')
|
||||
</if>
|
||||
|
||||
<if test="experiment.status != null and experiment.status != ''">
|
||||
and e.status like concat('%', #{experiment.status}, '%')
|
||||
</if>
|
||||
<if test="experiment.statusList != null and experiment.statusList != ''">
|
||||
and e.status in
|
||||
<foreach item="item" collection="experiment.statusList" index="index" open="(" separator="," close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
|
||||
|
||||
</where>
|
||||
<if test="loginUser.postText != null and loginUser.postText != ''">
|
||||
order by ${loginUser.postText}
|
||||
|
||||
@@ -273,6 +273,10 @@ public class ExperimentServiceImpl extends ServiceImpl<ExperimentMapper, Experim
|
||||
|
||||
@Override
|
||||
public IPage<Experiment> join(Page<Experiment> page, Experiment experiment, SysUser loginUser) {
|
||||
if (StringUtils.contains(experiment.getStatus(), ",")) {
|
||||
experiment.setStatusList(List.of(experiment.getStatus().split(",")));
|
||||
experiment.setStatus(null);
|
||||
}
|
||||
return baseMapper.join(page, experiment, loginUser);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user