md
This commit is contained in:
parent
79f83d2728
commit
0284adb180
@ -553,6 +553,34 @@ public class EmisCommonController extends EmisBaseController
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 单独查询状态
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/redoQueryInvoiceStatus")
|
||||
public AjaxResult redoQueryInvoiceStatus(String seqNo){
|
||||
String lockKey="redoQueryInvoiceStatus:"+seqNo;
|
||||
// 加锁查询
|
||||
redissonService.lock(lockKey,300);
|
||||
try{
|
||||
emisSettleInvoiceChRecordService.doQueryAndUpdateChOpenBillStatus(seqNo);
|
||||
}
|
||||
catch (Exception ex){
|
||||
redissonService.unlock(lockKey);
|
||||
|
||||
ex.printStackTrace();
|
||||
// 返回子定义异常
|
||||
if(ex instanceof EmisBizError){
|
||||
return AjaxResult.error(ex.getMessage(),((EmisBizError)ex).getErrorCode());
|
||||
}
|
||||
|
||||
return AjaxResult.error("确认异常,联系客服");
|
||||
}
|
||||
redissonService.unlock(lockKey);
|
||||
return AjaxResult.success("发送成功");
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 单独出账
|
||||
* @return
|
||||
|
||||
@ -80,4 +80,6 @@ public interface IEmisSettleInvoiceChRecordService
|
||||
public int sendHXToOpen(Long id) throws EmisBizError;
|
||||
|
||||
public void autoDoQueryOpenBillStatus();
|
||||
|
||||
public void doQueryAndUpdateChOpenBillStatus(String reqNo);
|
||||
}
|
||||
|
||||
@ -260,12 +260,13 @@ public class EmisSettleInvoiceChRecordServiceImpl implements IEmisSettleInvoiceC
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void autoDoQueryOpenBillStatus(){
|
||||
|
||||
List<EmisSettleInvoiceChRecord> listWaitQuery=emisSettleInvoiceChRecordMapper.selectWaitQueryStatusList();
|
||||
for (EmisSettleInvoiceChRecord itemRecord:listWaitQuery) {
|
||||
try {
|
||||
doQueryAndUpdateChOpenBillStatus(itemRecord);
|
||||
doQueryAndUpdateChOpenBillStatus(itemRecord.getReqNo());
|
||||
}catch (Exception ex){
|
||||
ex.printStackTrace();
|
||||
}
|
||||
@ -273,7 +274,11 @@ public class EmisSettleInvoiceChRecordServiceImpl implements IEmisSettleInvoiceC
|
||||
|
||||
}
|
||||
|
||||
private void doQueryAndUpdateChOpenBillStatus(EmisSettleInvoiceChRecord itemRecord){
|
||||
@Override
|
||||
public void doQueryAndUpdateChOpenBillStatus(String reqNo)
|
||||
{
|
||||
|
||||
EmisSettleInvoiceChRecord itemRecord=emisSettleInvoiceChRecordMapper.selectEmisSettleInvoiceChRecordByReqNo(reqNo);
|
||||
|
||||
EmisBaseInvoiceChInfo emisBaseInvoiceChInfo = emisBaseInvoiceChInfoMapper.selectEmisBaseInvoiceChInfoByTaxNo(itemRecord.getSalerCompanyTaxNo());
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user