|
@@ -3,19 +3,27 @@ package com.goafanti.order.controller;
|
|
|
import com.goafanti.common.bo.Result;
|
|
import com.goafanti.common.bo.Result;
|
|
|
import com.goafanti.common.constant.ErrorConstants;
|
|
import com.goafanti.common.constant.ErrorConstants;
|
|
|
import com.goafanti.common.controller.CertifyApiController;
|
|
import com.goafanti.common.controller.CertifyApiController;
|
|
|
|
|
+import com.goafanti.common.utils.excel.NewExcelUtil;
|
|
|
import com.goafanti.order.bo.InputOrderListBo;
|
|
import com.goafanti.order.bo.InputOrderListBo;
|
|
|
|
|
+import com.goafanti.order.bo.OutOrderLegalAffairsListBo;
|
|
|
import com.goafanti.order.service.LegalAffairsService;
|
|
import com.goafanti.order.service.LegalAffairsService;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
|
+import org.springframework.beans.factory.annotation.Value;
|
|
|
import org.springframework.web.bind.annotation.RequestMapping;
|
|
import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
import org.springframework.web.bind.annotation.RequestMethod;
|
|
import org.springframework.web.bind.annotation.RequestMethod;
|
|
|
import org.springframework.web.bind.annotation.RestController;
|
|
import org.springframework.web.bind.annotation.RestController;
|
|
|
|
|
|
|
|
|
|
+import java.util.List;
|
|
|
|
|
+
|
|
|
@RestController
|
|
@RestController
|
|
|
@RequestMapping(value = "/api/admin/lagalAffairs")
|
|
@RequestMapping(value = "/api/admin/lagalAffairs")
|
|
|
public class LegalAffairsApiController extends CertifyApiController {
|
|
public class LegalAffairsApiController extends CertifyApiController {
|
|
|
@Autowired
|
|
@Autowired
|
|
|
private LegalAffairsService legalAffairsService;
|
|
private LegalAffairsService legalAffairsService;
|
|
|
|
|
|
|
|
|
|
+ @Value(value = "${upload.path}")
|
|
|
|
|
+ private String uploadPath = null;
|
|
|
|
|
+
|
|
|
/**
|
|
/**
|
|
|
* 订单催款转交法务
|
|
* 订单催款转交法务
|
|
|
* @param orderNo
|
|
* @param orderNo
|
|
@@ -46,7 +54,28 @@ public class LegalAffairsApiController extends CertifyApiController {
|
|
|
@RequestMapping(value = "/orderList",method = RequestMethod.GET)
|
|
@RequestMapping(value = "/orderList",method = RequestMethod.GET)
|
|
|
public Result orderList(InputOrderListBo in){
|
|
public Result orderList(InputOrderListBo in){
|
|
|
Result res =new Result();
|
|
Result res =new Result();
|
|
|
- res.data(legalAffairsService.orderList(in));
|
|
|
|
|
|
|
+ res.data(legalAffairsService.orderListPage(in));
|
|
|
return res;
|
|
return res;
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
|
|
+ /**
|
|
|
|
|
+ * 订单催款列表(法务)
|
|
|
|
|
+ * @param in
|
|
|
|
|
+ * @return
|
|
|
|
|
+ */
|
|
|
|
|
+ @RequestMapping(value = "/orderList/Exprot",method = RequestMethod.GET)
|
|
|
|
|
+ public Result orderListExprot(InputOrderListBo in){
|
|
|
|
|
+ List<OutOrderLegalAffairsListBo> list = legalAffairsService.getLegalAffairsOrder(in);
|
|
|
|
|
+ NewExcelUtil newExcelUtil=new NewExcelUtil<>(OutOrderLegalAffairsListBo.class);
|
|
|
|
|
+ StringBuffer sb=new StringBuffer("搜索条件=》");
|
|
|
|
|
+ if (in.getUserName()!=null)sb=sb.append("客户名称:").append(in.getUserName()).append(",");
|
|
|
|
|
+ if (in.getLegalAffairs()!=null)sb=sb.append("转交法务:").append(in.getLegalAffairs()==0?"未转交":"已转交").append(",");
|
|
|
|
|
+ if (in.getContractNo()!=null)sb=sb.append("合同编号:").append(in.getContractNo()).append(",");
|
|
|
|
|
+ if (in.getDepName()!=null)sb=sb.append("订单部门:").append(in.getDepName()).append(",");
|
|
|
|
|
+ if (in.getStartTime()!=null&&in.getEndTime()!=null){
|
|
|
|
|
+ sb=sb.append("催款启动时间:").append(in.getStartTime()).append("~").append(in.getEndTime()).append(",");
|
|
|
|
|
+
|
|
|
|
|
+ }
|
|
|
|
|
+ return newExcelUtil.exportExcel(list,"订单催款列表",uploadPath,sb.substring(0,sb.length()-1));
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|