2022-12-05 19:22:01 +08:00
|
|
|
package aiyh.utils.apirequest.mapper;
|
|
|
|
|
|
|
|
import aiyh.utils.annotation.recordset.CaseConversion;
|
|
|
|
import aiyh.utils.annotation.recordset.ParamMapper;
|
|
|
|
import aiyh.utils.annotation.recordset.Select;
|
|
|
|
import aiyh.utils.annotation.recordset.SqlMapper;
|
|
|
|
|
|
|
|
import java.util.List;
|
|
|
|
import java.util.Map;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* <p>数据来源逻辑处理查询数据库</p>
|
|
|
|
* <p>create 2022/1/26 0026 14:10</p>
|
|
|
|
*
|
|
|
|
* @author EBU7-dev1-ayh
|
|
|
|
*/
|
|
|
|
|
|
|
|
@SqlMapper
|
|
|
|
public interface DataSourceMapper {
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 根据流程id查询流程表
|
|
|
|
* @param versionIds 流程所有版本的id
|
|
|
|
* @return 流程对应的表名
|
|
|
|
*/
|
|
|
|
@Select("select distinct tablename from workflow_base wb " +
|
|
|
|
"left join workflow_bill wbi on wbi.id = wb.formid " +
|
|
|
|
"where wb.id in (${versionIds})")
|
|
|
|
public String selectWorkflowTableById(@ParamMapper("versionIds") String[] versionIds);
|
|
|
|
|
|
|
|
@Select("select * from $t{workflowTable} where requestid = #{requestid}")
|
|
|
|
@CaseConversion(false)
|
|
|
|
Map<String,Object> selectMainData(@ParamMapper("workflowTable") String workflowTable,
|
|
|
|
@ParamMapper("requestId") String requestId);
|
|
|
|
|
|
|
|
@Select("select * from $t{detailTable} where mainid = #{mainId}")
|
|
|
|
@CaseConversion(false)
|
|
|
|
List<Map<String, Object>> selectDetailData(@ParamMapper("detailTable") String requestDetailTableName,
|
|
|
|
@ParamMapper("mainId") String mainId);
|
|
|
|
}
|