Commit 07091dfc authored by wangzb's avatar wangzb

feature-wzb :bug修复

parent 02d4e005
package com.yifu.cloud.plus.v1.yifu.order.vo;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import org.springframework.web.multipart.MultipartFile;
import java.io.Serializable;
@Data
public class OrderAttVo implements Serializable {
private static final long serialVersionUID = 6620652346415180825L;
/**
* 订单编号
*/
@Schema(description = "订单编号")
private String orderNo;
/**
* 订标识
*/
@Schema(description = "唯一标识")
private String file1;
/**
* 附件
*/
@Schema(description = "附件")
private MultipartFile[] file;
}
......@@ -3,6 +3,7 @@ package com.yifu.cloud.plus.v1.yifu.order.controller;
import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
import com.yifu.cloud.plus.v1.yifu.order.service.TOrderService;
import com.yifu.cloud.plus.v1.yifu.order.vo.OrderAddVO;
import com.yifu.cloud.plus.v1.yifu.order.vo.OrderAttVo;
import com.yifu.cloud.plus.v1.yifu.order.vo.OrderReplyAddVO;
import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.tags.Tag;
......@@ -47,6 +48,21 @@ public class EkpOrderController {
return tOrderService.receiveOrder(vo);
}
/**
* 接收处理ekp
*
* @author licancan
* @param vo
* @return {@link R}
* @throws IOException
*/
@Schema(description = "接收处理ekp附件")
@PostMapping(value = "/receiveOrderNew")
public R receiveOrder(OrderAttVo vo) throws IOException {
return tOrderService.receiveOrderNew(vo);
}
/**
* 接收处理ekp订单回复
*
......
......@@ -99,6 +99,18 @@ public interface TOrderService extends IService<TOrder> {
*/
R receiveOrder(OrderAddVO vo) throws IOException;
/**
* 接收处理ekp附件
*
* @author licancan
* @param vo
* @return {@link R}
* @throws IOException
*/
R receiveOrderNew(OrderAttVo vo) throws IOException;
/**
* 接收处理ekp订单回复
*
......
......@@ -573,8 +573,72 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
}
}
if (save && ArrayUtils.isNotEmpty(vo.getWageFile())){
for (MultipartFile multipartFile : vo.getWageFile()) {
return R.ok(OrderConstants.OPERATE_SUCCESS);
}
/**
* 接收处理ekp订单回复
*
* @author licancan
* @param vo
* @return {@link R}
* @throws IOException
*/
@Override
public R receiveOrderReply(OrderReplyAddVO vo) throws IOException{
if (Common.isEmpty(vo.getOrderNo())){
return R.failed(OrderConstants.ORDER_NO_IS_EMPTY);
}
TOrder one = this.getOne(Wrappers.<TOrder>query().lambda()
.eq(TOrder::getOrderNo, vo.getOrderNo())
.eq(TOrder::getDeleteFlag,CommonConstants.ZERO_INT)
.last(CommonConstants.LAST_ONE_SQL)
);
if (!Optional.ofNullable(one).isPresent()){
return R.failed(OrderConstants.ORDER_NO_NOT_EXIST);
}else {
if (CommonConstants.TWO_INT == one.getOrderStatus()){
return R.failed(OrderConstants.ORDER_STATUS_IS_TWO);
}
}
if (Common.isEmpty(vo.getCreateName())){
return R.failed(OrderConstants.REPLY_NAME_IS_EMPTY);
}
if (Common.isEmpty(vo.getCreateTime())){
return R.failed(OrderConstants.REPLY_TIME_IS_EMPTY);
}
if (Common.isEmpty(vo.getReplyContent()) && ArrayUtils.isEmpty(vo.getFile())){
return R.failed(OrderConstants.REPLY_CONTENT_AND_ENCLOSURE_IS_EMPTY);
}
// 校验回复内容2048字以内
if (!Common.isEmpty(vo.getReplyContent()) && !ValidityUtil.validate2048(vo.getReplyContent())){
return R.failed(OrderConstants.REPLY_CONTENT_MORE_THAN_2048);
}
if (ArrayUtils.isNotEmpty(vo.getFile())){
if (vo.getFile().length > CommonConstants.TWENTY_INT){
return R.failed(OrderConstants.ENCLOSURE_SIZE_ERROR);
}
for (MultipartFile multipartFile : vo.getFile()) {
if(!Common.checkInsuranceFile(multipartFile.getOriginalFilename())){
return R.failed(OrderConstants.ENCLOSURE_TYPE_IS_ERROR);
}
if (multipartFile.getSize() > (CommonConstants.FIFTY_INT*CommonConstants.BYTE*CommonConstants.BYTE)){
return R.failed(OrderConstants.ENCLOSURE_SIZE_ERROR);
}
}
}
TOrderReply reply = new TOrderReply();
BeanUtils.copyProperties(vo,reply);
reply.setReplyContent(Common.isEmpty(vo.getReplyContent())?null:vo.getReplyContent());
reply.setDeleteFlag(CommonConstants.ZERO_INT);
boolean save = tOrderReplyService.save(reply);
if (save && ArrayUtils.isNotEmpty(vo.getFile())){
for (MultipartFile multipartFile : vo.getFile()) {
String fileName = System.currentTimeMillis() + "_" + multipartFile.getOriginalFilename();
//filePath不传默认存储空间的根目录
//支持的附件格式
......@@ -583,15 +647,15 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
if (flag) {
log.info("文件:" + fileName + "上传至存储空间" + ossUtil.getBucketName() + "成功!");
TOrderEnclosure orderEnclosure = new TOrderEnclosure();
orderEnclosure.setOrderNo(order.getOrderNo());
orderEnclosure.setOrderNo(reply.getId());
orderEnclosure.setEnclosureName(multipartFile.getOriginalFilename());
orderEnclosure.setEnclosureFlag(CommonConstants.TWO_INTEGER);
orderEnclosure.setEnclosureFlag(CommonConstants.ONE_INT);
orderEnclosure.setEnclosureAddress(key);
orderEnclosure.setDeleteFlag(CommonConstants.ZERO_INT);
try {
tOrderEnclosureService.save(orderEnclosure);
} catch (Exception e) {
log.error("订单接收OSS文件上传接口异常:" + e.getMessage());
log.error("订单回复接收OSS文件上传接口异常:" + e.getMessage());
ossUtil.deleteObject(null, key);
return R.failed("failed:" + e.getMessage());
}
......@@ -600,9 +664,45 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
}
}
}
return R.ok(OrderConstants.OPERATE_SUCCESS);
}
if (save && ArrayUtils.isNotEmpty(vo.getSalaryFile())){
for (MultipartFile multipartFile : vo.getWageFile()) {
/**
* 接收处理ekp订单回复
*
* @author licancan
* @param vo
* @return {@link R}
* @throws IOException
*/
@Override
public R receiveOrderNew(OrderAttVo vo) throws IOException{
if (Common.isEmpty(vo.getOrderNo())){
return R.failed(OrderConstants.ORDER_NO_IS_EMPTY);
}
TOrder one = this.getOne(Wrappers.<TOrder>query().lambda()
.eq(TOrder::getOrderNo, vo.getOrderNo())
.eq(TOrder::getDeleteFlag,CommonConstants.ZERO_INT)
.last(CommonConstants.LAST_ONE_SQL)
);
if (ArrayUtils.isNotEmpty(vo.getFile())){
if (vo.getFile().length > CommonConstants.TWENTY_INT){
return R.failed(OrderConstants.ENCLOSURE_SIZE_ERROR);
}
for (MultipartFile multipartFile : vo.getFile()) {
if(!Common.checkInsuranceFile(multipartFile.getOriginalFilename())){
return R.failed(OrderConstants.ENCLOSURE_TYPE_IS_ERROR);
}
if (multipartFile.getSize() > (CommonConstants.FIFTY_INT*CommonConstants.BYTE*CommonConstants.BYTE)){
return R.failed(OrderConstants.ENCLOSURE_SIZE_ERROR);
}
}
}
if (vo.getFile1().equals("fileOne")) {
if (ArrayUtils.isNotEmpty(vo.getFile())) {
for (MultipartFile multipartFile : vo.getFile()) {
String fileName = System.currentTimeMillis() + "_" + multipartFile.getOriginalFilename();
//filePath不传默认存储空间的根目录
//支持的附件格式
......@@ -611,9 +711,9 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
if (flag) {
log.info("文件:" + fileName + "上传至存储空间" + ossUtil.getBucketName() + "成功!");
TOrderEnclosure orderEnclosure = new TOrderEnclosure();
orderEnclosure.setOrderNo(order.getOrderNo());
orderEnclosure.setOrderNo(vo.getOrderNo());
orderEnclosure.setEnclosureName(multipartFile.getOriginalFilename());
orderEnclosure.setEnclosureFlag(CommonConstants.THREE_INTEGER);
orderEnclosure.setEnclosureFlag(CommonConstants.TWO_INTEGER);
orderEnclosure.setEnclosureAddress(key);
orderEnclosure.setDeleteFlag(CommonConstants.ZERO_INT);
try {
......@@ -628,9 +728,10 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
}
}
}
if (save && ArrayUtils.isNotEmpty(vo.getSocialFile())){
for (MultipartFile multipartFile : vo.getSocialFile()) {
}
if (vo.getFile1().equals("fileTwo")) {
if (ArrayUtils.isNotEmpty(vo.getFile())) {
for (MultipartFile multipartFile : vo.getFile()) {
String fileName = System.currentTimeMillis() + "_" + multipartFile.getOriginalFilename();
//filePath不传默认存储空间的根目录
//支持的附件格式
......@@ -639,9 +740,9 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
if (flag) {
log.info("文件:" + fileName + "上传至存储空间" + ossUtil.getBucketName() + "成功!");
TOrderEnclosure orderEnclosure = new TOrderEnclosure();
orderEnclosure.setOrderNo(order.getOrderNo());
orderEnclosure.setOrderNo(vo.getOrderNo());
orderEnclosure.setEnclosureName(multipartFile.getOriginalFilename());
orderEnclosure.setEnclosureFlag(CommonConstants.FOUR_INTEGER);
orderEnclosure.setEnclosureFlag(CommonConstants.THREE_INTEGER);
orderEnclosure.setEnclosureAddress(key);
orderEnclosure.setDeleteFlag(CommonConstants.ZERO_INT);
try {
......@@ -656,8 +757,10 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
}
}
}
if (save && ArrayUtils.isNotEmpty(vo.getFundFile())){
for (MultipartFile multipartFile : vo.getFundFile()) {
}
if (vo.getFile1().equals("fileThree")) {
if (ArrayUtils.isNotEmpty(vo.getFile())) {
for (MultipartFile multipartFile : vo.getFile()) {
String fileName = System.currentTimeMillis() + "_" + multipartFile.getOriginalFilename();
//filePath不传默认存储空间的根目录
//支持的附件格式
......@@ -666,9 +769,9 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
if (flag) {
log.info("文件:" + fileName + "上传至存储空间" + ossUtil.getBucketName() + "成功!");
TOrderEnclosure orderEnclosure = new TOrderEnclosure();
orderEnclosure.setOrderNo(order.getOrderNo());
orderEnclosure.setOrderNo(vo.getOrderNo());
orderEnclosure.setEnclosureName(multipartFile.getOriginalFilename());
orderEnclosure.setEnclosureFlag(CommonConstants.FIVE_INTEGER);
orderEnclosure.setEnclosureFlag(CommonConstants.FOUR_INTEGER);
orderEnclosure.setEnclosureAddress(key);
orderEnclosure.setDeleteFlag(CommonConstants.ZERO_INT);
try {
......@@ -683,8 +786,10 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
}
}
}
if (save && ArrayUtils.isNotEmpty(vo.getInsuranceFile())){
for (MultipartFile multipartFile : vo.getInsuranceFile()) {
}
if (vo.getFile1().equals("fileFour")) {
if (ArrayUtils.isNotEmpty(vo.getFile())) {
for (MultipartFile multipartFile : vo.getFile()) {
String fileName = System.currentTimeMillis() + "_" + multipartFile.getOriginalFilename();
//filePath不传默认存储空间的根目录
//支持的附件格式
......@@ -693,9 +798,9 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
if (flag) {
log.info("文件:" + fileName + "上传至存储空间" + ossUtil.getBucketName() + "成功!");
TOrderEnclosure orderEnclosure = new TOrderEnclosure();
orderEnclosure.setOrderNo(order.getOrderNo());
orderEnclosure.setOrderNo(vo.getOrderNo());
orderEnclosure.setEnclosureName(multipartFile.getOriginalFilename());
orderEnclosure.setEnclosureFlag(CommonConstants.SIX_INTEGER);
orderEnclosure.setEnclosureFlag(CommonConstants.FIVE_INTEGER);
orderEnclosure.setEnclosureAddress(key);
orderEnclosure.setDeleteFlag(CommonConstants.ZERO_INT);
try {
......@@ -710,8 +815,10 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
}
}
}
if (save && ArrayUtils.isNotEmpty(vo.getWithHoldingFile())){
for (MultipartFile multipartFile : vo.getWithHoldingFile()) {
}
if (vo.getFile1().equals("fileFive")) {
if (ArrayUtils.isNotEmpty(vo.getFile())) {
for (MultipartFile multipartFile : vo.getFile()) {
String fileName = System.currentTimeMillis() + "_" + multipartFile.getOriginalFilename();
//filePath不传默认存储空间的根目录
//支持的附件格式
......@@ -720,9 +827,9 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
if (flag) {
log.info("文件:" + fileName + "上传至存储空间" + ossUtil.getBucketName() + "成功!");
TOrderEnclosure orderEnclosure = new TOrderEnclosure();
orderEnclosure.setOrderNo(order.getOrderNo());
orderEnclosure.setOrderNo(vo.getOrderNo());
orderEnclosure.setEnclosureName(multipartFile.getOriginalFilename());
orderEnclosure.setEnclosureFlag(CommonConstants.SEVEN_INTEGER);
orderEnclosure.setEnclosureFlag(CommonConstants.SIX_INTEGER);
orderEnclosure.setEnclosureAddress(key);
orderEnclosure.setDeleteFlag(CommonConstants.ZERO_INT);
try {
......@@ -737,8 +844,9 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
}
}
}
if (save && ArrayUtils.isNotEmpty(vo.getCollectionFile())){
for (MultipartFile multipartFile : vo.getCollectionFile()) {
} if (vo.getFile1().equals("fileSix")) {
if (ArrayUtils.isNotEmpty(vo.getFile())) {
for (MultipartFile multipartFile : vo.getFile()) {
String fileName = System.currentTimeMillis() + "_" + multipartFile.getOriginalFilename();
//filePath不传默认存储空间的根目录
//支持的附件格式
......@@ -747,9 +855,9 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
if (flag) {
log.info("文件:" + fileName + "上传至存储空间" + ossUtil.getBucketName() + "成功!");
TOrderEnclosure orderEnclosure = new TOrderEnclosure();
orderEnclosure.setOrderNo(order.getOrderNo());
orderEnclosure.setOrderNo(vo.getOrderNo());
orderEnclosure.setEnclosureName(multipartFile.getOriginalFilename());
orderEnclosure.setEnclosureFlag(CommonConstants.EIGHT_INTEGER);
orderEnclosure.setEnclosureFlag(CommonConstants.SEVEN_INTEGER);
orderEnclosure.setEnclosureAddress(key);
orderEnclosure.setDeleteFlag(CommonConstants.ZERO_INT);
try {
......@@ -764,8 +872,10 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
}
}
}
if (save && ArrayUtils.isNotEmpty(vo.getNoTaxFile())){
for (MultipartFile multipartFile : vo.getNoTaxFile()) {
}
if (vo.getFile1().equals("fileSeven")) {
if (ArrayUtils.isNotEmpty(vo.getFile())) {
for (MultipartFile multipartFile : vo.getFile()) {
String fileName = System.currentTimeMillis() + "_" + multipartFile.getOriginalFilename();
//filePath不传默认存储空间的根目录
//支持的附件格式
......@@ -774,9 +884,9 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
if (flag) {
log.info("文件:" + fileName + "上传至存储空间" + ossUtil.getBucketName() + "成功!");
TOrderEnclosure orderEnclosure = new TOrderEnclosure();
orderEnclosure.setOrderNo(order.getOrderNo());
orderEnclosure.setOrderNo(vo.getOrderNo());
orderEnclosure.setEnclosureName(multipartFile.getOriginalFilename());
orderEnclosure.setEnclosureFlag(CommonConstants.NINE_INTEGER);
orderEnclosure.setEnclosureFlag(CommonConstants.EIGHT_INTEGER);
orderEnclosure.setEnclosureAddress(key);
orderEnclosure.setDeleteFlag(CommonConstants.ZERO_INT);
try {
......@@ -791,8 +901,10 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
}
}
}
if (save && ArrayUtils.isNotEmpty(vo.getOtherFile())){
for (MultipartFile multipartFile : vo.getOtherFile()) {
}
if (vo.getFile1().equals("fileEigth")) {
if (ArrayUtils.isNotEmpty(vo.getFile())) {
for (MultipartFile multipartFile : vo.getFile()) {
String fileName = System.currentTimeMillis() + "_" + multipartFile.getOriginalFilename();
//filePath不传默认存储空间的根目录
//支持的附件格式
......@@ -801,9 +913,9 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
if (flag) {
log.info("文件:" + fileName + "上传至存储空间" + ossUtil.getBucketName() + "成功!");
TOrderEnclosure orderEnclosure = new TOrderEnclosure();
orderEnclosure.setOrderNo(order.getOrderNo());
orderEnclosure.setOrderNo(vo.getOrderNo());
orderEnclosure.setEnclosureName(multipartFile.getOriginalFilename());
orderEnclosure.setEnclosureFlag(CommonConstants.TEN_INTEGER);
orderEnclosure.setEnclosureFlag(CommonConstants.NINE_INTEGER);
orderEnclosure.setEnclosureAddress(key);
orderEnclosure.setDeleteFlag(CommonConstants.ZERO_INT);
try {
......@@ -818,8 +930,10 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
}
}
}
if (save && ArrayUtils.isNotEmpty(vo.getSalaryHandoverFile())){
for (MultipartFile multipartFile : vo.getOtherFile()) {
}
if (vo.getFile1().equals("fileNine")) {
if (ArrayUtils.isNotEmpty(vo.getFile())) {
for (MultipartFile multipartFile : vo.getFile()) {
String fileName = System.currentTimeMillis() + "_" + multipartFile.getOriginalFilename();
//filePath不传默认存储空间的根目录
//支持的附件格式
......@@ -828,9 +942,9 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
if (flag) {
log.info("文件:" + fileName + "上传至存储空间" + ossUtil.getBucketName() + "成功!");
TOrderEnclosure orderEnclosure = new TOrderEnclosure();
orderEnclosure.setOrderNo(order.getOrderNo());
orderEnclosure.setOrderNo(vo.getOrderNo());
orderEnclosure.setEnclosureName(multipartFile.getOriginalFilename());
orderEnclosure.setEnclosureFlag(CommonConstants.ELEVEN_INTEGER);
orderEnclosure.setEnclosureFlag(CommonConstants.TEN_INTEGER);
orderEnclosure.setEnclosureAddress(key);
orderEnclosure.setDeleteFlag(CommonConstants.ZERO_INT);
try {
......@@ -845,70 +959,9 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
}
}
}
return R.ok(OrderConstants.OPERATE_SUCCESS);
}
/**
* 接收处理ekp订单回复
*
* @author licancan
* @param vo
* @return {@link R}
* @throws IOException
*/
@Override
public R receiveOrderReply(OrderReplyAddVO vo) throws IOException{
if (Common.isEmpty(vo.getOrderNo())){
return R.failed(OrderConstants.ORDER_NO_IS_EMPTY);
}
TOrder one = this.getOne(Wrappers.<TOrder>query().lambda()
.eq(TOrder::getOrderNo, vo.getOrderNo())
.eq(TOrder::getDeleteFlag,CommonConstants.ZERO_INT)
.last(CommonConstants.LAST_ONE_SQL)
);
if (!Optional.ofNullable(one).isPresent()){
return R.failed(OrderConstants.ORDER_NO_NOT_EXIST);
}else {
if (CommonConstants.TWO_INT == one.getOrderStatus()){
return R.failed(OrderConstants.ORDER_STATUS_IS_TWO);
}
}
if (Common.isEmpty(vo.getCreateName())){
return R.failed(OrderConstants.REPLY_NAME_IS_EMPTY);
}
if (Common.isEmpty(vo.getCreateTime())){
return R.failed(OrderConstants.REPLY_TIME_IS_EMPTY);
}
if (Common.isEmpty(vo.getReplyContent()) && ArrayUtils.isEmpty(vo.getFile())){
return R.failed(OrderConstants.REPLY_CONTENT_AND_ENCLOSURE_IS_EMPTY);
}
// 校验回复内容2048字以内
if (!Common.isEmpty(vo.getReplyContent()) && !ValidityUtil.validate2048(vo.getReplyContent())){
return R.failed(OrderConstants.REPLY_CONTENT_MORE_THAN_2048);
}
if (ArrayUtils.isNotEmpty(vo.getFile())){
if (vo.getFile().length > CommonConstants.TWENTY_INT){
return R.failed(OrderConstants.ENCLOSURE_SIZE_ERROR);
}
for (MultipartFile multipartFile : vo.getFile()) {
if(!Common.checkInsuranceFile(multipartFile.getOriginalFilename())){
return R.failed(OrderConstants.ENCLOSURE_TYPE_IS_ERROR);
}
if (multipartFile.getSize() > (CommonConstants.FIFTY_INT*CommonConstants.BYTE*CommonConstants.BYTE)){
return R.failed(OrderConstants.ENCLOSURE_SIZE_ERROR);
}
}
}
TOrderReply reply = new TOrderReply();
BeanUtils.copyProperties(vo,reply);
reply.setReplyContent(Common.isEmpty(vo.getReplyContent())?null:vo.getReplyContent());
reply.setDeleteFlag(CommonConstants.ZERO_INT);
boolean save = tOrderReplyService.save(reply);
if (save && ArrayUtils.isNotEmpty(vo.getFile())){
if (vo.getFile1().equals("fileTen")) {
if (ArrayUtils.isNotEmpty(vo.getFile())) {
for (MultipartFile multipartFile : vo.getFile()) {
String fileName = System.currentTimeMillis() + "_" + multipartFile.getOriginalFilename();
//filePath不传默认存储空间的根目录
......@@ -918,15 +971,15 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
if (flag) {
log.info("文件:" + fileName + "上传至存储空间" + ossUtil.getBucketName() + "成功!");
TOrderEnclosure orderEnclosure = new TOrderEnclosure();
orderEnclosure.setOrderNo(reply.getId());
orderEnclosure.setOrderNo(vo.getOrderNo());
orderEnclosure.setEnclosureName(multipartFile.getOriginalFilename());
orderEnclosure.setEnclosureFlag(CommonConstants.ONE_INT);
orderEnclosure.setEnclosureFlag(CommonConstants.THREE_INT);
orderEnclosure.setEnclosureAddress(key);
orderEnclosure.setDeleteFlag(CommonConstants.ZERO_INT);
try {
tOrderEnclosureService.save(orderEnclosure);
} catch (Exception e) {
log.error("订单回复接收OSS文件上传接口异常:" + e.getMessage());
log.error("订单接收OSS文件上传接口异常:" + e.getMessage());
ossUtil.deleteObject(null, key);
return R.failed("failed:" + e.getMessage());
}
......@@ -935,9 +988,11 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
}
}
}
return R.ok(OrderConstants.OPERATE_SUCCESS);
}
return R.ok(OrderConstants.OPERATE_SUCCESS);
}
public R invalidOrder(String id) {
TOrder one = baseMapper.selectById(id);
if (Common.isNotNull(one) && CommonConstants.ZERO_INT != one.getOrderStatus()) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment