|
@@ -385,7 +385,10 @@ public class CashierProcessService {
|
|
|
zyReceipt.setSexName(zyActpatient.getSexName());
|
|
|
zyReceipt.setZyTs(diff == 0 ? 1 : diff + 1);
|
|
|
ZyLedgerFile zyLedgerFile = list.get(0);
|
|
|
- if((NumberEnum.ONE.getCode().equals(fpVersion) && Convert.toInt(param.getTypeFlag(),0) == 3) || NumberEnum.ZERO.getCode().equals(fpVersion)){
|
|
|
+ if(NumberEnum.ONE.getCode().equals(fpVersion) && zyLedgerFile.getAccountDate() == null && Convert.toInt(param.getTypeFlag(),0) == 3){
|
|
|
+ throw new BizException(ExceptionEnum.LOGICAL_ERROR, "未结算处理,不能"+fpVersionStr+"发票");
|
|
|
+ }
|
|
|
+ if(NumberEnum.ZERO.getCode().equals(fpVersion)){
|
|
|
if (zyLedgerFile.getCashDate() == null) {
|
|
|
throw new BizException(ExceptionEnum.LOGICAL_ERROR, "未出纳处理,不能"+fpVersionStr+"发票");
|
|
|
}
|