Commit 59f49ed5 authored by sherlock's avatar sherlock

RZSJ -> RZSQ

parent 2bbf19ad
......@@ -14,6 +14,8 @@ import pwc.taxtech.atms.dto.vatdto.InputInvoiceDataSourceDto;
import pwc.taxtech.atms.vat.entity.InputInvoice;
import java.math.BigDecimal;
import java.text.ParsePosition;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.Collections;
......@@ -127,8 +129,8 @@ public class JXFP extends FunctionBase implements FreeRefFunction {
Date finalEndDate1 = endDate;
Date finalStartDate = startDate;
inputInvoices = inputInvoices.stream()
.filter(a -> DateUtils.strToDate(a.getRZSJ()).after(finalStartDate)
&& DateUtils.strToDate(a.getRZSJ()).before(finalEndDate1))
.filter(a -> strToDate(a.getRZSQ()).after(finalStartDate)
&& strToDate(a.getRZSQ()).before(finalEndDate1))
.collect(Collectors.toList());
}
}
......@@ -188,4 +190,12 @@ public class JXFP extends FunctionBase implements FreeRefFunction {
formulaContext.getProjectId());
return NumberEval.ZERO;
}
private static Date strToDate(String strDate) {
SimpleDateFormat formatter = new SimpleDateFormat("yyyyMM");
ParsePosition pos = new ParsePosition(0);
Date strtodate = formatter.parse(strDate, pos);
return strtodate;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment