|
|
|
@ -93,7 +93,7 @@ |
|
|
|
|
|
|
|
|
|
SELECT count(t.id) AS monthCount, |
|
|
|
|
sum(t.tax_amount) AS monthTaxAmount |
|
|
|
|
FROM ${dxhyTertiary}.t_dx_invoice_reimburse t |
|
|
|
|
FROM t_dx_invoice_reimburse t |
|
|
|
|
WHERE t.gf_tax_no = #{gfTaxNo} |
|
|
|
|
|
|
|
|
|
AND t.is_deduction = '0' |
|
|
|
@ -104,8 +104,8 @@ |
|
|
|
|
AND ( |
|
|
|
|
(t.is_domestic = '0' AND t.invoice_type IN ('92', '89', '88', '87')) |
|
|
|
|
OR (t.invoice_type = '90' AND |
|
|
|
|
exists(select area_name from ${dxhyAdmin}.sys_city where locate(area_name, t.departure_city)) |
|
|
|
|
AND exists(select area_name from ${dxhyAdmin}.sys_city where locate(area_name, t.reaching_city))) |
|
|
|
|
exists(select area_name from sys_city where locate(area_name, t.departure_city)) |
|
|
|
|
AND exists(select area_name from sys_city where locate(area_name, t.reaching_city))) |
|
|
|
|
OR ( |
|
|
|
|
t.invoice_type = '10' |
|
|
|
|
AND t.invoice_date > '2019-04-01 00:00:00' |
|
|
|
@ -119,7 +119,7 @@ |
|
|
|
|
databaseId="mysql"> |
|
|
|
|
SELECT count(t.id) AS yearCount, |
|
|
|
|
sum(t.tax_amount) AS yearTaxAmount |
|
|
|
|
FROM ${dxhyTertiary}.t_dx_invoice_reimburse t |
|
|
|
|
FROM t_dx_invoice_reimburse t |
|
|
|
|
WHERE t.gf_tax_no = #{gfTaxNo} |
|
|
|
|
AND YEAR(t.create_date) = #{year} |
|
|
|
|
|
|
|
|
@ -127,8 +127,8 @@ |
|
|
|
|
AND ( |
|
|
|
|
(t.is_domestic = '0' AND t.invoice_type IN ('92', '89', '88', '87')) |
|
|
|
|
OR (t.invoice_type = '90' AND |
|
|
|
|
exists(select area_name from ${dxhyAdmin}.sys_city where locate(area_name, t.departure_city)) |
|
|
|
|
AND exists(select area_name from ${dxhyAdmin}.sys_city where locate(area_name, t.reaching_city))) |
|
|
|
|
exists(select area_name from sys_city where locate(area_name, t.departure_city)) |
|
|
|
|
AND exists(select area_name from sys_city where locate(area_name, t.reaching_city))) |
|
|
|
|
OR (t.invoice_type = '10' AND t.invoice_date > '2019-04-01 00:00:00' AND t.tag LIKE '%运输服务%') |
|
|
|
|
) |
|
|
|
|
</select> |
|
|
|
@ -258,7 +258,7 @@ |
|
|
|
|
SELECT count(t.id) count, |
|
|
|
|
sum(t.tax_amount) taxAmountsum, |
|
|
|
|
sum(t.tax_amount) authenticationTaxAmountsum |
|
|
|
|
FROM ${dxhyTertiary}.t_dx_invoice_reimburse t |
|
|
|
|
FROM t_dx_invoice_reimburse t |
|
|
|
|
WHERE t.gf_tax_no = #{gfTaxNo} |
|
|
|
|
|
|
|
|
|
AND date_format(t.create_date, '%Y-%m-%d') >= date_format(#{monthStart}, '%Y-%m-%d') |
|
|
|
@ -267,8 +267,8 @@ |
|
|
|
|
|
|
|
|
|
AND t.invoice_type = '90' |
|
|
|
|
AND t.is_deduction = '0' |
|
|
|
|
AND exists(select area_name from ${dxhyAdmin}.sys_city where locate(area_name, t.departure_city)) |
|
|
|
|
AND exists(select area_name from ${dxhyAdmin}.sys_city where locate(area_name, t.reaching_city)) |
|
|
|
|
AND exists(select area_name from sys_city where locate(area_name, t.departure_city)) |
|
|
|
|
AND exists(select area_name from sys_city where locate(area_name, t.reaching_city)) |
|
|
|
|
|
|
|
|
|
</select> |
|
|
|
|
<select id="slelectPassengerTicketaHighwayVo" |
|
|
|
@ -410,15 +410,15 @@ |
|
|
|
|
|
|
|
|
|
SELECT count(t.id) AS monthCount, |
|
|
|
|
sum(t.tax_amount) AS monthTaxAmount |
|
|
|
|
FROM ${dxhyTertiary}.t_dx_invoice_reimburse t |
|
|
|
|
FROM t_dx_invoice_reimburse t |
|
|
|
|
WHERE t.gf_tax_no = #{ gfTaxNo } |
|
|
|
|
AND t.is_deduction = '0' |
|
|
|
|
AND t.create_date >= to_date(#{ monthStart }, 'yyyy-mm-dd') |
|
|
|
|
AND t.create_date < to_date(#{ monthEnd }, 'yyyy-mm-dd') |
|
|
|
|
AND ( |
|
|
|
|
(t.is_domestic = '0' AND t.invoice_type IN ('92', '89', '88', '87')) |
|
|
|
|
OR (t.invoice_type = '90' AND t.departure_city in (select area_name from ${dxhyAdmin}.sys_city) |
|
|
|
|
AND t.reaching_city in (select area_name from ${dxhyAdmin}.sys_city)) |
|
|
|
|
OR (t.invoice_type = '90' AND t.departure_city in (select area_name from sys_city) |
|
|
|
|
AND t.reaching_city in (select area_name from sys_city)) |
|
|
|
|
OR ( |
|
|
|
|
t.invoice_type = '10' |
|
|
|
|
AND t.invoice_date > '2019-04-01 00:00:00' |
|
|
|
@ -432,15 +432,15 @@ |
|
|
|
|
databaseId="oracle"> |
|
|
|
|
SELECT count(t.id) AS yearCount, |
|
|
|
|
sum(t.tax_amount) AS yearTaxAmount |
|
|
|
|
FROM ${dxhyTertiary}.t_dx_invoice_reimburse t, |
|
|
|
|
${dxhyAdmin}.sys_city c |
|
|
|
|
FROM t_dx_invoice_reimburse t, |
|
|
|
|
sys_city c |
|
|
|
|
WHERE t.gf_tax_no = #{ gfTaxNo } |
|
|
|
|
AND to_char(t.invoice_date, 'yyyy') = #{ year } |
|
|
|
|
AND t.is_deduction = '0' |
|
|
|
|
AND ( |
|
|
|
|
(t.is_domestic = '0' AND t.invoice_type IN ('92', '89', '88', '87')) |
|
|
|
|
OR (t.invoice_type = '90' AND t.departure_city in (select area_name from ${dxhyAdmin}.sys_city) |
|
|
|
|
AND t.reaching_city in (select area_name from ${dxhyAdmin}.sys_city)) |
|
|
|
|
OR (t.invoice_type = '90' AND t.departure_city in (select area_name from sys_city) |
|
|
|
|
AND t.reaching_city in (select area_name from sys_city)) |
|
|
|
|
OR (t.invoice_type = '10' AND t.invoice_date > '2019-04-01 00:00:00' AND t.tag LIKE '%运输服务%')) |
|
|
|
|
</select> |
|
|
|
|
<select id="selectReimOtherInvoiceMonthCar" |
|
|
|
@ -538,14 +538,14 @@ |
|
|
|
|
SELECT count(t.id) AS count, |
|
|
|
|
sum(t.tax_amount) AS taxAmountsum, |
|
|
|
|
sum(t.tax_amount) AS authenticationTaxAmountsum |
|
|
|
|
FROM ${dxhyTertiary}.t_dx_invoice_reimburse t |
|
|
|
|
FROM t_dx_invoice_reimburse t |
|
|
|
|
WHERE t.gf_tax_no = #{gfTaxNo} |
|
|
|
|
and t.create_date >= to_date(#{monthStart}, 'yyyy-mm-dd') |
|
|
|
|
and t.create_date < to_date(#{monthEnd}, 'yyyy-mm-dd') |
|
|
|
|
and t.invoice_type = '90' |
|
|
|
|
and t.is_deduction = '0' |
|
|
|
|
AND t.departure_city in (select area_name from ${dxhyAdmin}.sys_city) |
|
|
|
|
AND t.reaching_city in (select area_name from ${dxhyAdmin}.sys_city) |
|
|
|
|
AND t.departure_city in (select area_name from sys_city) |
|
|
|
|
AND t.reaching_city in (select area_name from sys_city) |
|
|
|
|
|
|
|
|
|
</select> |
|
|
|
|
<select id="slelectPassengerTicketaHighwayVo" |
|
|
|
|