arieay 查询sql增加税率字段 v2

release
yefei 2 years ago
parent c722d5132e
commit fb030aee69
  1. 12
      dxhy-base/src/main/java/com/dxhy/base/controller/BaseInvoiceController.java
  2. 7
      dxhy-base/src/main/resources/mapper/BaseFpZhMapper.xml
  3. 12
      dxhy-base/src/main/resources/mapper/BaseSggxcxMapper.xml

@ -227,9 +227,9 @@ public class BaseInvoiceController extends AbstractController {
} }
if (!StringUtils.isNotBlank(taxRate) && !"99".equals(taxRate)){ if (!StringUtils.isNotBlank(taxRate) && !"99".equals(taxRate)){
List<String> rates = new ArrayList<>(); // List<String> rates = new ArrayList<>();
rates = convertRates(taxRate,rates); // rates = convertRates(taxRate,rates);
pramsMap.put("taxRate",rates); pramsMap.put("taxRate",taxRate);
} }
if (!StringHelper.isBlank(invoiceType)) { if (!StringHelper.isBlank(invoiceType)) {
@ -576,9 +576,9 @@ public class BaseInvoiceController extends AbstractController {
} }
if (!StringUtils.isNotBlank(taxRate) && !"99".equals(taxRate)){ if (!StringUtils.isNotBlank(taxRate) && !"99".equals(taxRate)){
List<String> rates = new ArrayList<>(); // List<String> rates = new ArrayList<>();
rates = convertRates(taxRate,rates); // rates = convertRates(taxRate,rates);
pramsMap.put("taxRate",rates); pramsMap.put("taxRate",taxRate);
} }
List<String> gfshList = new ArrayList<>(); List<String> gfshList = new ArrayList<>();
if (!"99".equals(gfsh) && StringUtils.isNotBlank(gfsh)) { if (!"99".equals(gfsh) && StringUtils.isNotBlank(gfsh)) {

@ -241,7 +241,6 @@
#{taxRate} #{taxRate}
</foreach> </foreach>
</if> </if>
order by t.rzh_date desc,t.invoice_date desc
</select> </select>
<select id="selectByPramsMap" parameterType="java.util.Map" <select id="selectByPramsMap" parameterType="java.util.Map"
resultMap="BaseResultMap" databaseId="oracle"> resultMap="BaseResultMap" databaseId="oracle">
@ -504,6 +503,12 @@
<if test="eleInvoiceNo!=null and eleInvoiceNo!='' and eleInvoiceNo!='null'"> <if test="eleInvoiceNo!=null and eleInvoiceNo!='' and eleInvoiceNo!='null'">
and t.ele_invoice_no = #{eleInvoiceNo} and t.ele_invoice_no = #{eleInvoiceNo}
</if> </if>
<if test="taxRate!=null and taxRate!='' and taxRate != null and taxRate !='99'">
and t.tax_rate like %#{taxRate}%
</if>
<if test="taxRate==''">
and t.tax_rate #{taxRate}
</if>
</select> </select>
<select id="selectRzfpHj" parameterType="java.util.Map" <select id="selectRzfpHj" parameterType="java.util.Map"
resultMap="RzcxhjResultMap" databaseId="oracle"> resultMap="RzcxhjResultMap" databaseId="oracle">

@ -223,6 +223,12 @@
<if test="accountPeriod != null and accountPeriod != '' and accountPeriod != 'null' and accountPeriod != '99'"> <if test="accountPeriod != null and accountPeriod != '' and accountPeriod != 'null' and accountPeriod != '99'">
and t.account_period = #{accountPeriod} and t.account_period = #{accountPeriod}
</if> </if>
<if test="taxRate!=null and taxRate!='' and taxRate != null and taxRate !='99'">
and t.tax_rate like %#{taxRate}%
</if>
<if test="taxRate==''">
and t.tax_rate #{taxRate}
</if>
<!-- <if test="qsksrq != null and qsksrq != '' and qsksrq != 'null' and qsjsrq != null and qsjsrq != '' and qsjsrq != 'null'">--> <!-- <if test="qsksrq != null and qsksrq != '' and qsksrq != 'null' and qsjsrq != null and qsjsrq != '' and qsjsrq != 'null'">-->
<!-- order by t.qs_date desc,t.invoice_date desc--> <!-- order by t.qs_date desc,t.invoice_date desc-->
<!-- </if>--> <!-- </if>-->
@ -565,6 +571,12 @@
<if test="accountPeriod != null and accountPeriod != '' and accountPeriod != 'null' and accountPeriod != '99'"> <if test="accountPeriod != null and accountPeriod != '' and accountPeriod != 'null' and accountPeriod != '99'">
and t.account_period = #{accountPeriod} and t.account_period = #{accountPeriod}
</if> </if>
<if test="taxRate!=null and taxRate!='' and taxRate != null and taxRate !='99'">
and t.tax_rate like %#{taxRate}%
</if>
<if test="taxRate==''">
and t.tax_rate #{taxRate}
</if>
order by t.bzdh desc order by t.bzdh desc
</select> </select>

Loading…
Cancel
Save