Commit 53190c5d authored by jiaorz's avatar jiaorz

Merge branch 'master-invoice-modular' into dev

parents fc900d7e 057bd9d8
...@@ -49,7 +49,7 @@ public class OrderInvoiceBiz extends BaseBiz<OrderInvoiceMapper, OrderInvoice> { ...@@ -49,7 +49,7 @@ public class OrderInvoiceBiz extends BaseBiz<OrderInvoiceMapper, OrderInvoice> {
} }
String[] orderIdArray = orderInvoice.getOrderIds().split(","); String[] orderIdArray = orderInvoice.getOrderIds().split(",");
if (orderIdArray.length > 0) { if (orderIdArray.length > 0) {
for (int a = 0; a <= orderIdArray.length; a ++) { for (int a = 0; a <= orderIdArray.length - 1; a ++) {
String orderId = StringUtils.isBlank(orderIdArray[a])? "0" : orderIdArray[a]; String orderId = StringUtils.isBlank(orderIdArray[a])? "0" : orderIdArray[a];
BaseOrder baseOrder = baseOrderBiz.selectById(Integer.parseInt(orderId)); BaseOrder baseOrder = baseOrderBiz.selectById(Integer.parseInt(orderId));
if (baseOrder == null) { if (baseOrder == null) {
......
...@@ -2,24 +2,17 @@ package com.xxfc.platform.universal.controller; ...@@ -2,24 +2,17 @@ package com.xxfc.platform.universal.controller;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.github.wxiaoqi.security.auth.client.annotation.IgnoreUserToken; import com.github.wxiaoqi.security.auth.client.annotation.IgnoreUserToken;
import com.github.wxiaoqi.security.common.constant.RestCode;
import com.github.wxiaoqi.security.common.msg.ObjectRestResponse; import com.github.wxiaoqi.security.common.msg.ObjectRestResponse;
import com.github.wxiaoqi.security.common.util.process.ResultCode;
import com.github.wxiaoqi.security.common.util.result.JsonResultUtil; import com.github.wxiaoqi.security.common.util.result.JsonResultUtil;
import com.xxfc.platform.universal.constant.VideoConstant;
import com.xxfc.platform.universal.dto.ImgDTO; import com.xxfc.platform.universal.dto.ImgDTO;
import com.xxfc.platform.universal.dto.UploadImgDTO; import com.xxfc.platform.universal.dto.UploadImgDTO;
import com.xxfc.platform.universal.service.FileUploadService; import com.xxfc.platform.universal.service.FileUploadService;
import com.xxfc.platform.universal.service.UploadService; import com.xxfc.platform.universal.service.UploadService;
import com.xxfc.platform.universal.service.UploadZipService; import com.xxfc.platform.universal.service.UploadZipService;
import com.xxfc.platform.universal.utils.ImgBase64Util;
import com.xxfc.platform.universal.utils.PublicMsg; import com.xxfc.platform.universal.utils.PublicMsg;
import com.xxfc.platform.universal.vo.Ueditor; import com.xxfc.platform.universal.vo.Ueditor;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.apache.commons.fileupload.FileItem;
import org.apache.commons.fileupload.disk.DiskFileItemFactory;
import org.apache.commons.fileupload.servlet.ServletFileUpload;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity; import org.springframework.http.ResponseEntity;
...@@ -27,7 +20,6 @@ import org.springframework.web.bind.annotation.*; ...@@ -27,7 +20,6 @@ import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.MultipartFile;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
import java.io.File;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;
...@@ -172,6 +164,9 @@ public class UploadController{ ...@@ -172,6 +164,9 @@ public class UploadController{
@RequestMapping(value="/app/unauth/ueditor", method = RequestMethod.POST) @RequestMapping(value="/app/unauth/ueditor", method = RequestMethod.POST)
public Ueditor imgUpload(MultipartFile upfile) throws Exception { public Ueditor imgUpload(MultipartFile upfile) throws Exception {
Ueditor ueditor = new Ueditor(); Ueditor ueditor = new Ueditor();
if (upfile == null) {
return ueditor;
}
ueditor.setUrl(uploadService.uploadFile(upfile,"admin")); ueditor.setUrl(uploadService.uploadFile(upfile,"admin"));
ueditor.setOriginal(upfile.getOriginalFilename()); ueditor.setOriginal(upfile.getOriginalFilename());
ueditor.setState("SUCCESS"); ueditor.setState("SUCCESS");
......
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