update
This commit is contained in:
@@ -1,11 +0,0 @@
|
||||
package digital.laboratory.platform.reagent.entity;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class Cabinetcell {
|
||||
|
||||
private String cabinetId;
|
||||
private String location;
|
||||
private String id;
|
||||
}
|
||||
-2
@@ -4,7 +4,6 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Constants;
|
||||
import digital.laboratory.platform.reagent.entity.Cabinetcell;
|
||||
import digital.laboratory.platform.reagent.entity.ReagentConsumableInventory;
|
||||
import digital.laboratory.platform.reagent.entity.ReferenceMaterial;
|
||||
import digital.laboratory.platform.reagent.vo.ReagentConsumableInventoryFullVO;
|
||||
@@ -30,7 +29,6 @@ public interface ReagentConsumableInventoryMapper extends BaseMapper<ReagentCons
|
||||
|
||||
List<UserVO> getUserList();
|
||||
|
||||
Cabinetcell getCabinetCell(String location);
|
||||
|
||||
IPage<ReferenceMaterialFullVO> getReferenceMaterialPage (IPage<ReagentConsumableInventory>page, @Param (Constants.WRAPPER) QueryWrapper<ReferenceMaterial> qw);
|
||||
}
|
||||
|
||||
+3
-8
@@ -290,7 +290,7 @@ public class CentralizedRequestServiceImpl extends ServiceImpl<CentralizedReques
|
||||
|
||||
CentralizedRequestVO centralizedRequest = this.getCentralizedRequestVO(id);
|
||||
|
||||
if (centralizedRequest.getStatus()!=4){
|
||||
if (centralizedRequest.getStatus() != 4) {
|
||||
|
||||
throw new RuntimeException(String.format("当前采购还未被制定为清单,无法打印"));
|
||||
}
|
||||
@@ -322,7 +322,7 @@ public class CentralizedRequestServiceImpl extends ServiceImpl<CentralizedReques
|
||||
|
||||
DecentralizedRequestVO requestById = decentralizedRequestService.getRequestById(id);
|
||||
|
||||
if (requestById.getStatus()!=6){
|
||||
if (requestById.getStatus() != 6) {
|
||||
throw new RuntimeException(String.format("当前采购还未被制定为清单,无法打印"));
|
||||
}
|
||||
|
||||
@@ -422,9 +422,8 @@ public class CentralizedRequestServiceImpl extends ServiceImpl<CentralizedReques
|
||||
String finalCommitTime = commitTime;
|
||||
Calendar instance = Calendar.getInstance();
|
||||
int year = instance.get(Calendar.YEAR);
|
||||
|
||||
XWPFTemplate template = XWPFTemplate.compile(bis, builder.build()).render(
|
||||
|
||||
|
||||
new HashMap<String, Object>() {{
|
||||
put("voList", voList);
|
||||
put("year", year);
|
||||
@@ -451,19 +450,15 @@ public class CentralizedRequestServiceImpl extends ServiceImpl<CentralizedReques
|
||||
Response response = remoteWord2PDFService.word2pdf(mockMultipartFile);
|
||||
fisWord.close();
|
||||
|
||||
|
||||
ByteArrayOutputStream outPDF = new ByteArrayOutputStream();
|
||||
IoUtil.copy(response.body().asInputStream(), outPDF, IoUtil.DEFAULT_MIDDLE_BUFFER_SIZE);
|
||||
ByteArrayInputStream isPDF = new ByteArrayInputStream(outPDF.toByteArray());
|
||||
outPDF.close();
|
||||
|
||||
|
||||
ossFile.fileSave("document" + "/" + "purchaseRequest" + "/" + id + "/" + applyFileName + ".pdf", isPDF);
|
||||
isPDF.close();
|
||||
|
||||
|
||||
System.out.println(String.format("转换为 PDF 结束"));
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+6
-6
@@ -233,12 +233,12 @@ public class CheckScheduleServiceImpl extends ServiceImpl<CheckScheduleMapper, C
|
||||
|
||||
periodVerificationPlanVO.setI(x);
|
||||
|
||||
if (periodVerificationPlanVO.getVerificationResult().equals("P")){
|
||||
periodVerificationPlanVO.setP("P");
|
||||
}else if (periodVerificationPlanVO.getVerificationResult().equals("D")){
|
||||
periodVerificationPlanVO.setD("D");
|
||||
}else if (periodVerificationPlanVO.getVerificationResult().equals("F")){
|
||||
periodVerificationPlanVO.setF("F");
|
||||
if (periodVerificationPlanVO.getVerificationResult()!=null&&periodVerificationPlanVO.getVerificationResult().equals("P")){
|
||||
periodVerificationPlanVO.setP("√");
|
||||
}else if (periodVerificationPlanVO.getVerificationResult()!=null&&periodVerificationPlanVO.getVerificationResult().equals("D")){
|
||||
periodVerificationPlanVO.setD("√");
|
||||
}else if (periodVerificationPlanVO.getVerificationResult()!=null&&periodVerificationPlanVO.getVerificationResult().equals("F")){
|
||||
periodVerificationPlanVO.setF("√");
|
||||
}
|
||||
x++;
|
||||
}
|
||||
|
||||
+6
-4
@@ -23,6 +23,7 @@ import digital.laboratory.platform.reagent.entity.*;
|
||||
import digital.laboratory.platform.reagent.mapper.ReagentConsumableInventoryMapper;
|
||||
import digital.laboratory.platform.reagent.service.*;
|
||||
import digital.laboratory.platform.reagent.vo.*;
|
||||
import digital.laboratory.platform.sys.entity.CabinetCell;
|
||||
import digital.laboratory.platform.sys.entity.CellAndStoreSupplyData;
|
||||
import digital.laboratory.platform.sys.feign.RemoteCabinetService;
|
||||
import feign.Response;
|
||||
@@ -32,6 +33,7 @@ import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.mock.web.MockMultipartFile;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
@@ -547,7 +549,7 @@ public class ReagentConsumableInventoryServiceImpl extends ServiceImpl<ReagentCo
|
||||
}
|
||||
|
||||
@Override
|
||||
@GlobalTransactional//盘点导入,需提供柜子系统数据
|
||||
@Transactional//盘点导入,需提供柜子系统数据
|
||||
public void inventoryEntry(List<ReagentConsumableInventoryDTO> reagentConsumableInventoryDTOList) {
|
||||
for (ReagentConsumableInventoryDTO reagentConsumableInventoryDTO : reagentConsumableInventoryDTOList) {
|
||||
|
||||
@@ -570,6 +572,7 @@ public class ReagentConsumableInventoryServiceImpl extends ServiceImpl<ReagentCo
|
||||
.eq(StrUtil.isNotBlank(reagentConsumableInventoryDTO.getMinimumUnit()), "minimum_unit", reagentConsumableInventoryDTO.getMinimumUnit())
|
||||
);
|
||||
|
||||
|
||||
BatchDetails batchDetails = new BatchDetails();
|
||||
|
||||
batchDetails.setServiceStatus(1);
|
||||
@@ -589,9 +592,8 @@ public class ReagentConsumableInventoryServiceImpl extends ServiceImpl<ReagentCo
|
||||
batchDetails.setExpirationDate(LocalDate.now().plusYears(99));
|
||||
}
|
||||
|
||||
R cell = remoteCabinetService.queryCellByRoomNoAndLocation(reagentConsumableInventoryDTO.getRoomNo(), reagentConsumableInventoryDTO.getLocation());
|
||||
Cabinetcell cabinetCell = (Cabinetcell) cell.getData();
|
||||
|
||||
R<CabinetCell> cabinetCellR = remoteCabinetService.queryCellByRoomNoAndLocation(reagentConsumableInventoryDTO.getRoomNo(), reagentConsumableInventoryDTO.getLocation());
|
||||
CabinetCell cabinetCell = cabinetCellR.getData();
|
||||
batchDetails.setLatticeId(cabinetCell.getId());
|
||||
batchDetails.setBoxId(cabinetCell.getCabinetId());
|
||||
batchDetails.setLocation(location);
|
||||
|
||||
+19
-2
@@ -125,18 +125,35 @@ public class RequisitionRecordServiceImpl extends ServiceImpl<RequisitionRecordM
|
||||
|
||||
LoopRowTableRenderPolicy policy = new LoopRowTableRenderPolicy();
|
||||
|
||||
int x = 1;
|
||||
Integer x = 1;
|
||||
for (RequisitionRecordVO requisitionRecordVO : voList) {
|
||||
|
||||
LocalDateTime dateOfClaim = requisitionRecordVO.getDateOfClaim();
|
||||
|
||||
requisitionRecordVO.setDateOfClaims(LocalDateTimeUtil.format(dateOfClaim, "yyyy年MM月dd日"));
|
||||
|
||||
requisitionRecordVO.setI(x);
|
||||
requisitionRecordVO.setIndex(x.toString());
|
||||
|
||||
x++;
|
||||
}
|
||||
|
||||
if (voList.size() < 28) {
|
||||
int s = 28 - voList.size();
|
||||
for (int i = 0; i < s; i++) {
|
||||
RequisitionRecordVO requisitionRecordVO = new RequisitionRecordVO();
|
||||
requisitionRecordVO.setIndex("");
|
||||
voList.add(requisitionRecordVO);
|
||||
}
|
||||
}else {
|
||||
int s = 28-voList.size()%28;
|
||||
|
||||
for (int i = 0; i < s; i++) {
|
||||
RequisitionRecordVO requisitionRecordVO = new RequisitionRecordVO();
|
||||
requisitionRecordVO.setIndex("");
|
||||
voList.add(requisitionRecordVO);
|
||||
}
|
||||
}
|
||||
|
||||
Configure config = Configure.builder().
|
||||
bind("voList", policy).build();
|
||||
|
||||
|
||||
+18
-2
@@ -202,12 +202,12 @@ public class StandardMaterialApplicationServiceImpl extends ServiceImpl<Standard
|
||||
public void standardMaterialApplicationTablePDF(List<StandardMaterialApplicationVO> voList, String ids, HttpServletRequest theHttpServletRequest, HttpServletResponse httpServletResponse) throws Exception {
|
||||
System.out.println("standardMaterialApplicationTablePDF.................");
|
||||
|
||||
int x = 1;
|
||||
Integer x = 1;
|
||||
for (StandardMaterialApplicationVO standardMaterialApplicationVO : voList) {
|
||||
|
||||
standardMaterialApplicationVO.setDateOfClaims(LocalDateTimeUtil.format(standardMaterialApplicationVO.getDateOfClaim(), "yyyy年MM月dd日"));
|
||||
standardMaterialApplicationVO.setDateOfReturns(LocalDateTimeUtil.format(standardMaterialApplicationVO.getDateOfReturn(), "yyyy年MM月dd日"));
|
||||
standardMaterialApplicationVO.setX(x);
|
||||
standardMaterialApplicationVO.setIndex(x.toString());
|
||||
if (standardMaterialApplicationVO.getPurpose() == 0) {
|
||||
standardMaterialApplicationVO.setPurposeAndQuantity("案件," + standardMaterialApplicationVO.getPurposeAndQuantity());
|
||||
|
||||
@@ -238,6 +238,22 @@ public class StandardMaterialApplicationServiceImpl extends ServiceImpl<Standard
|
||||
bind("voList", policy).build();
|
||||
Calendar instance = Calendar.getInstance();
|
||||
int year = instance.get(Calendar.YEAR);
|
||||
|
||||
if (voList.size()<8){
|
||||
int s = 8-voList.size();
|
||||
for (int i = 0; i < s; i++) {
|
||||
StandardMaterialApplicationVO standardMaterialApplicationVO = new StandardMaterialApplicationVO();
|
||||
standardMaterialApplicationVO.setIndex("");
|
||||
voList.add(standardMaterialApplicationVO);
|
||||
}
|
||||
}else {
|
||||
int s = 8-voList.size()%8;
|
||||
for (int i = 0; i < s; i++) {
|
||||
StandardMaterialApplicationVO standardMaterialApplicationVO = new StandardMaterialApplicationVO();
|
||||
standardMaterialApplicationVO.setIndex("");
|
||||
voList.add(standardMaterialApplicationVO);
|
||||
}
|
||||
}
|
||||
/**
|
||||
* 循环表格
|
||||
*/
|
||||
|
||||
+20
-8
@@ -43,10 +43,7 @@ import java.text.SimpleDateFormat;
|
||||
import java.time.LocalDate;
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.util.Calendar;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* (标准储备溶液配制及使用记录表)服务实现类
|
||||
@@ -379,6 +376,25 @@ public class StandardReserveSolutionServiceImpl extends ServiceImpl<StandardRese
|
||||
solutionUseFormVO.setFormat(format);
|
||||
}
|
||||
|
||||
if (voList.size()<7){
|
||||
int s = 7-voList.size();
|
||||
for (int i = 0; i < s; i++) {
|
||||
SolutionUseFormVO solutionUseFormVO = new SolutionUseFormVO();
|
||||
solutionUseFormVO.setOrderOfUse(voList.size()+1);
|
||||
voList.add(solutionUseFormVO);
|
||||
}
|
||||
}else {
|
||||
int s = 7-voList.size()%7;
|
||||
for (int i = 0; i < s; i++) {
|
||||
SolutionUseFormVO solutionUseFormVO = new SolutionUseFormVO();
|
||||
voList.add(solutionUseFormVO);
|
||||
}
|
||||
}
|
||||
|
||||
HashMap<String, String > solutionUseFormVOMap = new HashMap<>();
|
||||
|
||||
List<HashMap> solutionUseFormVOMapList = new ArrayList<>();
|
||||
|
||||
String applyFileName = "标准储备溶液配制及使用记录表-" + id;
|
||||
//-----------------------------
|
||||
// 生成 word 版本的 验收记录表
|
||||
@@ -419,8 +435,6 @@ public class StandardReserveSolutionServiceImpl extends ServiceImpl<StandardRese
|
||||
put("validityPeriod", standardReserveSolutionVO.getValidityPeriod());
|
||||
put("remarks", standardReserveSolutionVO.getRemarks());
|
||||
put("configurationDate", LocalDateTimeUtil.format(standardReserveSolutionVO.getConfigurationDate(), "yyyy年MM月dd日"));
|
||||
|
||||
|
||||
}}
|
||||
);
|
||||
bis.close();
|
||||
@@ -438,7 +452,6 @@ public class StandardReserveSolutionServiceImpl extends ServiceImpl<StandardRese
|
||||
Response response = remoteWord2PDFService.word2pdf(mockMultipartFile);
|
||||
fisWord.close();
|
||||
|
||||
|
||||
ByteArrayOutputStream outPDF = new ByteArrayOutputStream();
|
||||
IoUtil.copy(response.body().asInputStream(), outPDF, IoUtil.DEFAULT_MIDDLE_BUFFER_SIZE);
|
||||
ByteArrayInputStream isPDF = new ByteArrayInputStream(outPDF.toByteArray());
|
||||
@@ -448,7 +461,6 @@ public class StandardReserveSolutionServiceImpl extends ServiceImpl<StandardRese
|
||||
ossFile.fileSave("document" + "/" + "standardReserveSolution" + "/" + id + "/" + applyFileName + ".pdf", isPDF);
|
||||
isPDF.close();
|
||||
|
||||
|
||||
System.out.println(String.format("转换为 PDF 结束"));
|
||||
|
||||
}
|
||||
|
||||
@@ -13,5 +13,5 @@ public class RequisitionRecordVO extends RequisitionRecord {
|
||||
private String dateOfClaims;
|
||||
|
||||
@ApiModelProperty(value = "序号")
|
||||
private int i ;
|
||||
private String index ;
|
||||
}
|
||||
|
||||
+1
-1
@@ -30,7 +30,7 @@ public class StandardMaterialApplicationVO extends StandardMaterialApplication {
|
||||
private ReagentConsumables reagentConsumables;
|
||||
|
||||
@ApiModelProperty(value="(序号")
|
||||
private int x ;
|
||||
private String index ;
|
||||
|
||||
@ApiModelProperty(value="(领用日期)")
|
||||
private String dateOfClaims;
|
||||
|
||||
@@ -59,7 +59,7 @@ spring:
|
||||
# 文件上传相关 支持阿里云、华为云、腾讯、minio
|
||||
oss:
|
||||
endpoint: http://192.168.9.74:9000
|
||||
accessKey: dlp
|
||||
accessKey: admin
|
||||
secretKey: 87990016
|
||||
bucket-name: dlpfiles
|
||||
|
||||
@@ -72,4 +72,12 @@ oss:
|
||||
# pub-sub-domain: true
|
||||
# msgListener:
|
||||
# reagentTopicName: reagent
|
||||
|
||||
# 配置feign 的超时时间
|
||||
feign:
|
||||
okhttp:
|
||||
enabled: true
|
||||
client:
|
||||
config:
|
||||
default:
|
||||
connect-timeout: 600000
|
||||
read-timeout: 600000
|
||||
|
||||
@@ -62,22 +62,6 @@
|
||||
FROM dlp_base.sys_user user
|
||||
</select>
|
||||
|
||||
<select id="getRoomInfo" resultType="digital.laboratory.platform.reagent.entity.Cabinetcell">
|
||||
SELECT id
|
||||
FROM b_cabinet
|
||||
WHERE room_no = #{roomNo}
|
||||
</select>
|
||||
|
||||
<select id="getCabinetCell" parameterType="String"
|
||||
resultType="digital.laboratory.platform.reagent.entity.Cabinetcell">
|
||||
SELECT *
|
||||
FROM dlp_cabinet.b_cabinetcell
|
||||
WHERE cabinet_Id in (SELECT id FROM dlp_cabinet.b_cabinet WHERE room_no = '707')
|
||||
and location = #{location}
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
<!-- <sql id="getReferenceMaterialPageSQL">-->
|
||||
<!-- SELECT r1.*, r2.*, b1.*-->
|
||||
<!-- FROM reference_material r1,-->
|
||||
|
||||
Reference in New Issue
Block a user