|
|
@@ -3,6 +3,7 @@ package com.usoftchina.saas.money.service.impl;
|
|
|
import com.github.pagehelper.PageHelper;
|
|
|
import com.github.pagehelper.PageInfo;
|
|
|
import com.usoftchina.saas.base.service.CommonBaseServiceImpl;
|
|
|
+import com.usoftchina.saas.commons.api.CommonService;
|
|
|
import com.usoftchina.saas.commons.api.MaxnumberService;
|
|
|
import com.usoftchina.saas.commons.api.MessageLogService;
|
|
|
import com.usoftchina.saas.commons.dto.BatchDealBaseDTO;
|
|
|
@@ -46,6 +47,9 @@ public class PaybalanceServiceImpl extends CommonBaseServiceImpl<PaybalanceMappe
|
|
|
private StatsinfoMapper statsinfoMapper;
|
|
|
@Autowired
|
|
|
private MessageLogService messageLogService;
|
|
|
+ @Autowired
|
|
|
+ private CommonService commonService;
|
|
|
+
|
|
|
|
|
|
public DocBaseDTO insert(Pay pay) {
|
|
|
Paybalance paybalance = pay.getMain();
|
|
|
@@ -173,8 +177,6 @@ public class PaybalanceServiceImpl extends CommonBaseServiceImpl<PaybalanceMappe
|
|
|
public DocBaseDTO audit(Pay pay) {
|
|
|
Long companyId = BaseContextHolder.getCompanyId();
|
|
|
Paybalance paybalance = pay.getMain();
|
|
|
- paybalance.setPb_status(Status.AUDITED.getDisplay());
|
|
|
- paybalance.setPb_statuscode(Status.AUDITED.name());
|
|
|
paybalance.setCompanyId(companyId);
|
|
|
Subledger subledger = this.changSubledgerUntil(paybalance);
|
|
|
if (subledger.getSl_code() == null){
|
|
|
@@ -262,6 +264,9 @@ public class PaybalanceServiceImpl extends CommonBaseServiceImpl<PaybalanceMappe
|
|
|
statsinfoMapper.update(statsinfo);
|
|
|
}
|
|
|
DocBaseDTO baseDTO = getBaseDTOById(id);
|
|
|
+ commonService.commonAudit(BillCodeSeq.PAYBALANCE.getCaller(),
|
|
|
+ "pb_id='+baseDTO.getId()","pb_status","pb_statuscode",
|
|
|
+ "pb_auditdate","pb_auditman");
|
|
|
//日志记录
|
|
|
messageLogService.save(baseDTO);
|
|
|
return baseDTO;
|
|
|
@@ -349,7 +354,6 @@ public class PaybalanceServiceImpl extends CommonBaseServiceImpl<PaybalanceMappe
|
|
|
messageLogService.save(baseDTO);
|
|
|
}
|
|
|
|
|
|
-
|
|
|
public void delete(int id){
|
|
|
paybalanceMapper.deleteByPrimaryKey(id);
|
|
|
paybalancedetailMapper.deleteByPrimaryKey(id);
|