md
This commit is contained in:
parent
ffb5607a2d
commit
05bb3819c2
@ -645,14 +645,14 @@ public class EmisCommonController extends EmisBaseController
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/autoDoProfitTrigger")
|
||||
public AjaxResult autoDoProfitTrigger(){
|
||||
public AjaxResult autoDoProfitTrigger(EmisWaybill emisWaybill){
|
||||
String lockKey="autoDoProfitTrigger";
|
||||
log.info("autoDoProfitTrigger start");
|
||||
|
||||
// 加锁查询
|
||||
redissonService.lock(lockKey,300);
|
||||
try{
|
||||
emisCommissionProfitService.autoDoProfit();
|
||||
emisCommissionProfitService.autoDoProfit(emisWaybill);
|
||||
}catch(Exception ex){
|
||||
ex.printStackTrace();
|
||||
log.error("autoDoProfitTrigger exception:"+ex.getMessage());
|
||||
|
||||
@ -11,8 +11,9 @@ package com.xdadan.erp.emis.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.xdadan.erp.emis.domain.EmisCommissionProfit;
|
||||
import com.xdadan.erp.emis.domain.EmisWaybill;
|
||||
|
||||
/**
|
||||
/**
|
||||
* @ClassName EmisCommissionProfitService
|
||||
* @Description 员工提成表
|
||||
* @author linfso
|
||||
@ -31,7 +32,7 @@ public interface IEmisCommissionProfitService
|
||||
/**
|
||||
* 自动计算提成
|
||||
*/
|
||||
public void autoDoProfit();
|
||||
public void autoDoProfit(EmisWaybill emisWaybill);
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@ -74,12 +74,11 @@ public class EmisCommissionProfitServiceImpl extends EmisBaseService implements
|
||||
*/
|
||||
@Async
|
||||
@Override
|
||||
public void autoDoProfit() {
|
||||
public void autoDoProfit(EmisWaybill emisWaybill) {
|
||||
|
||||
Map<String,Map<String,String> > profitMap = new HashMap<>();
|
||||
// 获取需要出账的运单列表
|
||||
EmisWaybill qEmisWaybill = new EmisWaybill();
|
||||
List<EmisWaybill> list = emisWaybillMapper.selectWaitDoProfitList(qEmisWaybill);
|
||||
List<EmisWaybill> list = emisWaybillMapper.selectWaitDoProfitList(emisWaybill);
|
||||
|
||||
// 多线程并发处理
|
||||
if(!CollectionUtil.isEmpty(list)){
|
||||
|
||||
Loading…
Reference in New Issue
Block a user