|
|
|
@ -89,8 +89,8 @@ public class IoCollectOrderBackupController extends BaseController {
|
|
|
|
|
return ResultVOUtils.error(500, "未找到单据");
|
|
|
|
|
}
|
|
|
|
|
List<CollectOrderBizResponse> collectOrderBizResponses = ioCollectOrderBackupService.combieOrderDetail(collectOrderBizRequest);
|
|
|
|
|
for (CollectOrderBizResponse response : collectOrderBizResponses){
|
|
|
|
|
if (response.getGgxh() == null){
|
|
|
|
|
for (CollectOrderBizResponse response : collectOrderBizResponses) {
|
|
|
|
|
if (response.getGgxh() == null) {
|
|
|
|
|
response.setGgxh(response.getSpec());
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -134,39 +134,40 @@ public class IoCollectOrderBackupController extends BaseController {
|
|
|
|
|
List<IoCollectOrderCodeMan> list = ioCollectOrderBackupService.codeDetail(collectOrderBizRequest.getId());
|
|
|
|
|
return ResultVOUtils.success(list);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 获取单据上传医保统计信息
|
|
|
|
|
*
|
|
|
|
|
* @param collectOrderUploadCountRequest
|
|
|
|
|
* @return
|
|
|
|
|
*/
|
|
|
|
|
@PostMapping ("/udiwms/basic/collect/orderFinish/uploadCount")
|
|
|
|
|
@PostMapping("/udiwms/basic/collect/orderFinish/uploadCount")
|
|
|
|
|
public BaseResponse uploadCount(@RequestBody CollectOrderUploadCountRequest collectOrderUploadCountRequest) {
|
|
|
|
|
CollectOrderUploadCountResponse collectOrderUploadCountResponse = new CollectOrderUploadCountResponse();
|
|
|
|
|
if(collectOrderUploadCountRequest.getStartTime()!=null
|
|
|
|
|
&& collectOrderUploadCountRequest.getEndTime() !=null){
|
|
|
|
|
collectOrderUploadCountRequest.setStartTime(collectOrderUploadCountRequest.getStartTime()+" 00:00:00");
|
|
|
|
|
collectOrderUploadCountRequest.setEndTime(collectOrderUploadCountRequest.getEndTime()+" 23:59:59");
|
|
|
|
|
if (collectOrderUploadCountRequest.getStartTime() != null
|
|
|
|
|
&& collectOrderUploadCountRequest.getEndTime() != null) {
|
|
|
|
|
collectOrderUploadCountRequest.setStartTime(collectOrderUploadCountRequest.getStartTime() + " 00:00:00");
|
|
|
|
|
collectOrderUploadCountRequest.setEndTime(collectOrderUploadCountRequest.getEndTime() + " 23:59:59");
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
List<Map<String, Object>> list = ioCollectOrderBackupService.listMaps(new QueryWrapper<IoCollectOrderBackup>()
|
|
|
|
|
.groupBy("uploadStatus")
|
|
|
|
|
.between(collectOrderUploadCountRequest.getStartTime()!=null
|
|
|
|
|
&& collectOrderUploadCountRequest.getEndTime() !=null
|
|
|
|
|
,"updateTime",collectOrderUploadCountRequest.getStartTime(),collectOrderUploadCountRequest.getEndTime())
|
|
|
|
|
.select("uploadStatus","count(1) as count")
|
|
|
|
|
.between(collectOrderUploadCountRequest.getStartTime() != null
|
|
|
|
|
&& collectOrderUploadCountRequest.getEndTime() != null
|
|
|
|
|
, "updateTime", collectOrderUploadCountRequest.getStartTime(), collectOrderUploadCountRequest.getEndTime())
|
|
|
|
|
.select("uploadStatus", "count(1) as count")
|
|
|
|
|
);
|
|
|
|
|
Long notUploadingCount=0L;
|
|
|
|
|
Long alreadyUploadingCount=0L;
|
|
|
|
|
Long uploadingFailCount=0L;
|
|
|
|
|
if(list!=null && list.size() >0){
|
|
|
|
|
Long notUploadingCount = 0L;
|
|
|
|
|
Long alreadyUploadingCount = 0L;
|
|
|
|
|
Long uploadingFailCount = 0L;
|
|
|
|
|
if (list != null && list.size() > 0) {
|
|
|
|
|
for (Map<String, Object> stringObjectMap : list) {
|
|
|
|
|
if(1 == (Integer)stringObjectMap.get("uploadStatus")){
|
|
|
|
|
if (1 == (Integer) stringObjectMap.get("uploadStatus")) {
|
|
|
|
|
notUploadingCount += (Long) stringObjectMap.get("count");
|
|
|
|
|
}else if(2 == (Integer)stringObjectMap.get("uploadStatus")){
|
|
|
|
|
alreadyUploadingCount += (Long)stringObjectMap.get("count");
|
|
|
|
|
}else if(3 == (Integer)stringObjectMap.get("uploadStatus")){
|
|
|
|
|
uploadingFailCount += (Long)stringObjectMap.get("count");
|
|
|
|
|
} else if (2 == (Integer) stringObjectMap.get("uploadStatus")) {
|
|
|
|
|
alreadyUploadingCount += (Long) stringObjectMap.get("count");
|
|
|
|
|
} else if (3 == (Integer) stringObjectMap.get("uploadStatus")) {
|
|
|
|
|
uploadingFailCount += (Long) stringObjectMap.get("count");
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -176,7 +177,7 @@ public class IoCollectOrderBackupController extends BaseController {
|
|
|
|
|
collectOrderUploadCountResponse.setAlreadyUploadingCount(alreadyUploadingCount);
|
|
|
|
|
collectOrderUploadCountResponse.setUploadingFailCount(uploadingFailCount);
|
|
|
|
|
// 总上传码数量 获取采购上传率 销售上传率 计算
|
|
|
|
|
ioCollectOrderBizBackupService.CalculatedUploadRate( collectOrderUploadCountRequest,collectOrderUploadCountResponse);
|
|
|
|
|
ioCollectOrderBizBackupService.CalculatedUploadRate(collectOrderUploadCountRequest, collectOrderUploadCountResponse);
|
|
|
|
|
return ResultVOUtils.success(collectOrderUploadCountResponse);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|