1、推送报告区分类型,不同类型的控件id不同
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
package com.sdm.common.constants;
|
||||
|
||||
/**
|
||||
* 利元亨对接接口的部分参数常量
|
||||
*/
|
||||
public class LyricParamConstants {
|
||||
|
||||
/**
|
||||
* 附件上传(推送报告)
|
||||
*/
|
||||
|
||||
// 系统标识
|
||||
public static final String SYSTEM_CODE = "spdm";
|
||||
// 表名称
|
||||
public static final String TABLE_NAME = "oa_three_d_review";
|
||||
// 字段名称
|
||||
public static final String COLUMN_NAME = "simulation_table";
|
||||
// 权限编码
|
||||
public static final String FILE_POWER = "2456236750149124114";
|
||||
// 系统id
|
||||
public static final Long SYSTEM_ID = 1691399963692630016L;
|
||||
// 表单id
|
||||
public static final Long FORM_ID = 1847115435993071616L;
|
||||
// 有限元控件id
|
||||
public static final Long FINITE_ELEMENT_COMPONENT_INST_ID = 8000004142460000204L;
|
||||
// 机器人控件id
|
||||
public static final Long ROBOT_COMPONENT_INST_ID = 8000004142460000204L;
|
||||
// 公差控件id
|
||||
public static final Long TOLERANCE_COMPONENT_INST_ID = 8000004142460000204L;
|
||||
|
||||
|
||||
}
|
||||
@@ -13,11 +13,25 @@ import java.util.List;
|
||||
@Data
|
||||
public class PushReportReq {
|
||||
|
||||
/**
|
||||
* 文件id列表
|
||||
*/
|
||||
@NotEmpty(message = "文件id不能为空")
|
||||
private List<Long> fileIdList;
|
||||
|
||||
/**
|
||||
* 项目编号
|
||||
*/
|
||||
private String projectCode;
|
||||
|
||||
/**
|
||||
* 工位编号
|
||||
*/
|
||||
private String workspaceCode;
|
||||
|
||||
/**
|
||||
* 推送类型 1:有限元 2:机器人 3:公差(产品工艺专项验收)
|
||||
*/
|
||||
private Integer pushType;
|
||||
|
||||
}
|
||||
|
||||
@@ -6,6 +6,7 @@ import com.github.pagehelper.PageInfo;
|
||||
import com.sdm.common.common.ResultCode;
|
||||
import com.sdm.common.common.SdmResponse;
|
||||
import com.sdm.common.common.ThreadLocalContext;
|
||||
import com.sdm.common.constants.LyricParamConstants;
|
||||
import com.sdm.common.entity.enums.AttachFileTypeEnum;
|
||||
import com.sdm.common.entity.enums.DirTypeEnum;
|
||||
import com.sdm.common.entity.enums.FilePermissionEnum;
|
||||
@@ -1615,14 +1616,22 @@ public class LyricInternalServiceImpl implements ILyricInternalService {
|
||||
jobNumber = cidUserRespSdmResponse.getData().getUsername();
|
||||
}
|
||||
HkUploadFileReq uploadFileReq = new HkUploadFileReq();
|
||||
uploadFileReq.setFilePower("2456236750149124114");
|
||||
// 推送类型 1:有限元 2:机器人 3:公差(产品工艺专项验收)
|
||||
Integer pushType = req.getPushType();
|
||||
if (pushType == 1) {
|
||||
uploadFileReq.setComponentInstId(LyricParamConstants.FINITE_ELEMENT_COMPONENT_INST_ID);
|
||||
}else if (pushType == 2) {
|
||||
uploadFileReq.setComponentInstId(LyricParamConstants.ROBOT_COMPONENT_INST_ID);
|
||||
}else {
|
||||
uploadFileReq.setComponentInstId(LyricParamConstants.TOLERANCE_COMPONENT_INST_ID);
|
||||
}
|
||||
uploadFileReq.setWaterMarkFlag(false);
|
||||
uploadFileReq.setWaterMarkContent("spdm");
|
||||
uploadFileReq.setSysId(1691399963692630016L);
|
||||
uploadFileReq.setFormId(1847115435993071616L);
|
||||
uploadFileReq.setComponentInstId(8000004142460000204L);
|
||||
uploadFileReq.setTableName("oa_three_d_review");
|
||||
uploadFileReq.setColumnName("simulation_table");
|
||||
uploadFileReq.setWaterMarkContent(LyricParamConstants.SYSTEM_CODE);
|
||||
uploadFileReq.setFilePower(LyricParamConstants.FILE_POWER);
|
||||
uploadFileReq.setSysId(LyricParamConstants.SYSTEM_ID);
|
||||
uploadFileReq.setFormId(LyricParamConstants.FORM_ID);
|
||||
uploadFileReq.setTableName(LyricParamConstants.TABLE_NAME);
|
||||
uploadFileReq.setColumnName(LyricParamConstants.COLUMN_NAME);
|
||||
uploadFileReq.setXmh(req.getProjectCode());
|
||||
uploadFileReq.setGwh(req.getWorkspaceCode());
|
||||
uploadFileReq.setFiles(Collections.singletonList(zipFilePath));
|
||||
|
||||
Reference in New Issue
Block a user