add:单据回传,流程实例搜索条件

This commit is contained in:
2025-01-08 20:11:04 +08:00
parent d53691ffec
commit f1d434c200
5 changed files with 25 additions and 2 deletions

View File

@@ -11,13 +11,17 @@
FROM act_ru_execution exe FROM act_ru_execution exe
left join act_re_procdef def on exe.deployment_id = def.deployment_id left join act_re_procdef def on exe.deployment_id = def.deployment_id
<where> <where>
exe.parent_id is null 1=1
<if test="query.search != null and query.search != ''"> <if test="query.search != null and query.search != ''">
and def.model_key LIKE '%${query.search}%' and def.model_key LIKE '%${query.search}%'
</if> </if>
<if test="query.proc_inst_id != null and query.proc_inst_id != ''"> <if test="query.proc_inst_id != null and query.proc_inst_id != ''">
and exe.parent_id is null
and exe.proc_inst_id like '%${query.proc_inst_id}%' and exe.proc_inst_id like '%${query.proc_inst_id}%'
</if> </if>
<if test="query.child_id != null and query.child_id != ''">
and exe.proc_inst_id like '%${query.child_id}%'
</if>
</where> </where>
ORDER BY exe.create_time DESC ORDER BY exe.create_time DESC
</select> </select>

View File

@@ -18,6 +18,7 @@ public class ExecutionQuery extends BaseQuery<ActRuExecution> {
private String search; private String search;
private String proc_inst_id; private String proc_inst_id;
private String child_id;
@Override @Override
public void paramMapping() { public void paramMapping() {

View File

@@ -53,6 +53,9 @@ public class ActRuExecutionServiceImpl extends ServiceImpl<ActRuExecutionMapper,
@Override @Override
public Object getAll(ExecutionQuery query, PageQuery pageQuery) { public Object getAll(ExecutionQuery query, PageQuery pageQuery) {
Page<Object> page = PageHelper.startPage(pageQuery.getPage() + 1, pageQuery.getSize()); Page<Object> page = PageHelper.startPage(pageQuery.getPage() + 1, pageQuery.getSize());
query.setChild_id(StringUtils.isNotBlank(query.getChild_id())?query.getChild_id().trim():query.getChild_id());
query.setProc_inst_id(StringUtils.isNotBlank(query.getProc_inst_id())?query.getProc_inst_id().trim():query.getProc_inst_id());
query.setSearch(StringUtils.isNotBlank(query.getSearch())?query.getSearch().trim():query.getSearch());
List<Map> list = actRuExecutionMapper.pageGetAll(query, pageQuery); List<Map> list = actRuExecutionMapper.pageGetAll(query, pageQuery);
TableDataInfo<Map> build = TableDataInfo.build(list); TableDataInfo<Map> build = TableDataInfo.build(list);
build.setTotalElements(page.getTotal()); build.setTotalElements(page.getTotal());

View File

@@ -120,6 +120,18 @@
<if test="query.code != null and query.code != ''"> <if test="query.code != null and query.code != ''">
and code = #{query.code} and code = #{query.code}
</if> </if>
<if test="query.mater != null and query.mater != ''">
and md_me_materialbase.material_code like '%${query.mater}%'
</if>
<if test="query.start_time != null and query.start_time != ''">
and pm_form_data.create_time >= #{query.start_time}
</if>
<if test="query.end_time != null and query.end_time != ''">
and #{query.end_time} >= pm_form_data.create_time
</if>
<if test="query.code != null and query.code != ''">
and code = #{query.code}
</if>
<if test="query.search != null and query.search != ''"> <if test="query.search != null and query.search != ''">
and code = #{query.search} and code = #{query.search}
</if> </if>

View File

@@ -14,12 +14,15 @@ import java.util.Map;
*/ */
@Data @Data
public class FormDataQuery extends BaseQuery<PmFormData> { public class FormDataQuery extends BaseQuery<PmFormData> {
private String form_type; private String form_type;
private String code; private String code;
private String search; private String search;
private String parent_id; private String parent_id;
private String mater;
private String[] status; private String[] status;
private String start_time;
private String end_time;
private Map<String,String> form_query; private Map<String,String> form_query;
@Override @Override