|
@ -24,6 +24,7 @@ import com.qs.serve.modules.tbs.entity.TbsCostApply; |
|
|
import com.qs.serve.modules.tbs.entity.bo.TbsAffairCommitBo; |
|
|
import com.qs.serve.modules.tbs.entity.bo.TbsAffairCommitBo; |
|
|
import com.qs.serve.modules.tbs.entity.vo.CtpAffairVo; |
|
|
import com.qs.serve.modules.tbs.entity.vo.CtpAffairVo; |
|
|
import com.qs.serve.task.SysTask; |
|
|
import com.qs.serve.task.SysTask; |
|
|
|
|
|
import org.jetbrains.annotations.NotNull; |
|
|
|
|
|
|
|
|
import java.util.*; |
|
|
import java.util.*; |
|
|
import java.util.stream.Collectors; |
|
|
import java.util.stream.Collectors; |
|
@ -165,8 +166,21 @@ public interface SeeYonOperationService extends SeeYonBaseService{ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
default R<List<CtpAffairVo>> pageAffairV2(String targetId,String targetCode){ |
|
|
default R<List<CtpAffairVo>> pageAffairV2(String targetId,String targetCode){ |
|
|
return null; |
|
|
boolean existFormId = checkSyFormIdIsNotNull(targetId); |
|
|
|
|
|
if (!existFormId){ |
|
|
|
|
|
return R.ok(new ArrayList<>()); |
|
|
} |
|
|
} |
|
|
|
|
|
String templateCode = getTemplateCode(); |
|
|
|
|
|
R<List<CtpAffair>> syResult = getRequestService().commonListAffairsV2(targetId,targetCode,null,templateCode); |
|
|
|
|
|
List<CtpAffair> ctpAffairs = syResult.getData(); |
|
|
|
|
|
if(ctpAffairs.size()>0){ |
|
|
|
|
|
List<CtpAffairVo> result = getCtpAffairVos(ctpAffairs); |
|
|
|
|
|
return R.ok(result); |
|
|
|
|
|
} |
|
|
|
|
|
return R.ok(new ArrayList<>()); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 审批列表(用于详情页) |
|
|
* 审批列表(用于详情页) |
|
@ -182,6 +196,19 @@ public interface SeeYonOperationService extends SeeYonBaseService{ |
|
|
R<List<CtpAffair>> syResult = getRequestService().commonListAffairs(targetId,null,templateCode); |
|
|
R<List<CtpAffair>> syResult = getRequestService().commonListAffairs(targetId,null,templateCode); |
|
|
List<CtpAffair> ctpAffairs = syResult.getData(); |
|
|
List<CtpAffair> ctpAffairs = syResult.getData(); |
|
|
if(ctpAffairs.size()>0){ |
|
|
if(ctpAffairs.size()>0){ |
|
|
|
|
|
List<CtpAffairVo> result = getCtpAffairVos(ctpAffairs); |
|
|
|
|
|
return R.ok(result); |
|
|
|
|
|
} |
|
|
|
|
|
return R.ok(new ArrayList<>()); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
|
* 通用的审批列表封装 |
|
|
|
|
|
* @param ctpAffairs |
|
|
|
|
|
* @return |
|
|
|
|
|
*/ |
|
|
|
|
|
@NotNull |
|
|
|
|
|
default List<CtpAffairVo> getCtpAffairVos(List<CtpAffair> ctpAffairs) { |
|
|
DataAffairCommitMapper dataAffairCommitMapper = SpringUtils.getBean(DataAffairCommitMapper.class); |
|
|
DataAffairCommitMapper dataAffairCommitMapper = SpringUtils.getBean(DataAffairCommitMapper.class); |
|
|
SysAttachMapper sysAttachMapper = SpringUtils.getBean(SysAttachMapper.class); |
|
|
SysAttachMapper sysAttachMapper = SpringUtils.getBean(SysAttachMapper.class); |
|
|
List<DataAffairCommit> affairCommits = dataAffairCommitMapper.selectBatchIds(ctpAffairs.stream() |
|
|
List<DataAffairCommit> affairCommits = dataAffairCommitMapper.selectBatchIds(ctpAffairs.stream() |
|
@ -215,9 +242,7 @@ public interface SeeYonOperationService extends SeeYonBaseService{ |
|
|
} |
|
|
} |
|
|
result.add(ctpAffairVo); |
|
|
result.add(ctpAffairVo); |
|
|
} |
|
|
} |
|
|
return R.ok(result); |
|
|
return result; |
|
|
} |
|
|
|
|
|
return R.ok(new ArrayList<>()); |
|
|
|
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|