320 lines
15 KiB
XML
320 lines
15 KiB
XML
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
|
<TenwaReport>
|
|
<datasources>
|
|
<datasource>
|
|
<id>2c9023815726a036015726a496b00001</id>
|
|
<dataSourceName>eleasing_mysql</dataSourceName>
|
|
<dataSourceType>SPRING</dataSourceType>
|
|
<jndi>dataSourceJDBC</jndi>
|
|
<url></url>
|
|
<username></username>
|
|
<driverName></driverName>
|
|
<password></password>
|
|
<dialect>com.tenwa.report.query.dialect.MysqlDialect</dialect>
|
|
<dialectName>Mysql</dialectName>
|
|
</datasource>
|
|
</datasources>
|
|
<reports>
|
|
<report>
|
|
<id>2c9c81b97520309601754a8707d10042</id>
|
|
<name>经销商月度资金统计表</name>
|
|
<enname>supplier_fund_month_report</enname>
|
|
<isActived>true</isActived>
|
|
<position>32</position>
|
|
<reportType>REPORT</reportType>
|
|
<parentReport>2c9c81b7685efbbc016931c675a50006</parentReport>
|
|
<children/>
|
|
<layouts>
|
|
<layout>2c9c81b975e496a90176650d873b0068</layout>
|
|
</layouts>
|
|
</report>
|
|
</reports>
|
|
<tables>
|
|
<table>
|
|
<id>2c9c81b97520309601754a87a5960043</id>
|
|
<name>经销商月度资金统计表</name>
|
|
<enname>supplier_fund_month_report</enname>
|
|
<reportDataSource>2c9023815726a036015726a496b00001</reportDataSource>
|
|
<queryType>COMPLEXSQL</queryType>
|
|
<sql>select t1.orgname ,
|
|
t1.svrentover ,
|
|
t1.clrentover,
|
|
t4.cc ,
|
|
t4.srent ,
|
|
t2.soverrent ,
|
|
t3.rents ,
|
|
t3.cover ,
|
|
concat(round(t1.clrentover/t1.svrentover*100,2),'%') rate
|
|
from (SELECT sum(csc.`vrentover`) svrentover,
|
|
sum(case when csc.contract_number in (
|
|
select distinct rrp.`contract_number`
|
|
from report_rent_plan rrp
|
|
LEFT JOIN lb_contract_info bci on rrp.contract_number = bci.CONTRACT_NUMBER
|
|
where bci.BUSINESSTYPE = '1' and rrp.`batch_status` = "未完成"
|
|
and rrp.`over_days` >= 0 ) then csc.`vrentover` else 0 end
|
|
) clrentover,
|
|
di.DISTRIBUTOR_NAME orgname
|
|
FROM `contract_statis_car` csc
|
|
LEFT JOIN LB_CONTRACT_INFO lci ON csc.contract_number = lci.contract_number
|
|
LEFT JOIN distributor_info di ON di.distributor_no = lci.distributor_id
|
|
GROUP BY di.DISTRIBUTOR_NAME) t1
|
|
left join
|
|
(select left(rrp.plan_date, 7),
|
|
rrp.distributor_name,
|
|
COUNT(case when rrp.COLLECT_STATUS in ('提前结清') then null ELSE 1 END) cc,
|
|
SUM(case when rrp.COLLECT_STATUS in ('提前结清') then 0 ELSE rrp.`rent` END) srent,
|
|
sum(case when rrp.batch_status = '未完成' then rrp.RENT ELSE 0 END) soverrent
|
|
from report_rent_plan rrp
|
|
left join code_library cl on cl.codeno = 'charge_way' and cl.itemno = rrp.collect_msg
|
|
LEFT JOIN lb_contract_info bci on rrp.contract_number = bci.CONTRACT_NUMBER
|
|
where bci.BUSINESSTYPE = '1'
|
|
/~startdate:and str_to_date(replace(left(rrp.PLAN_DATE, 10), '/', '-'), '%Y-%m-%d') >= str_to_date('{startdate}', '%Y/%m/%d')~/
|
|
/~enddate:and str_to_date(replace(left(rrp.PLAN_DATE, 10), '/', '-'), '%Y-%m-%d') <= str_to_date('{enddate}', '%Y/%m/%d')~/
|
|
group by rrp.distributor_name) t2 on t1.orgname = t2.distributor_name
|
|
left join
|
|
(select sum(rrp.`rent`) rents,
|
|
COUNT(DISTINCT (rrp.`contract_number`)) cover,
|
|
rrp.`distributor_name`
|
|
from report_rent_plan rrp
|
|
left join code_library cl on cl.codeno = 'charge_way' and cl.itemno = rrp.collect_msg
|
|
LEFT JOIN lb_contract_info bci on rrp.contract_number = bci.CONTRACT_NUMBER
|
|
where bci.BUSINESSTYPE = '1'
|
|
and rrp.`batch_status` = "未完成"
|
|
/~enddate:and str_to_date(replace(left(rrp.PLAN_DATE, 10), '/', '-'), '%Y-%m-%d') <= str_to_date('{enddate}', '%Y/%m/%d')~/
|
|
group by rrp.`distributor_name`
|
|
HAVING MAX(rrp.`over_days`) >= 0) t3 on t1.orgname = t3.distributor_name
|
|
left join
|
|
(select left(rrp.plan_date, 7),
|
|
rrp.distributor_name,
|
|
COUNT(case when rrp.COLLECT_STATUS in ('提前结清') then null ELSE 1 END) cc,
|
|
SUM(case when rrp.COLLECT_STATUS in ('提前结清') then 0 ELSE rrp.`rent` END) srent,
|
|
sum(case when rrp.batch_status = '未完成' then rrp.RENT ELSE 0 END) soverrent
|
|
from report_rent_plan rrp
|
|
left join code_library cl on cl.codeno = 'charge_way' and cl.itemno = rrp.collect_msg
|
|
LEFT JOIN lb_contract_info bci on rrp.contract_number = bci.CONTRACT_NUMBER
|
|
where bci.BUSINESSTYPE = '1'
|
|
/~enddate:and rrp.PLAN_DATE like CONCAT('%',left('{enddate}', 7),'%')~/
|
|
group by rrp.distributor_name) t4 on t1.orgname = t4.distributor_name</sql>
|
|
<sqlParamValue>startdate|enddate|enddate|enddate</sqlParamValue>
|
|
<columns>
|
|
<column>
|
|
<id>2c9c81b975e496a90176650d873d006b</id>
|
|
<name>orgname</name>
|
|
<columnDataType>STRING</columnDataType>
|
|
<formater></formater>
|
|
<label>渠道</label>
|
|
<enLabel>orgname</enLabel>
|
|
<width>100</width>
|
|
<position>9</position>
|
|
<isVisible>true</isVisible>
|
|
<color></color>
|
|
<isCountTotal>false</isCountTotal>
|
|
<isCountSubTotal>false</isCountSubTotal>
|
|
<isGroupby>false</isGroupby>
|
|
<isMerge>false</isMerge>
|
|
<action></action>
|
|
<actionParamters></actionParamters>
|
|
<actionCondition></actionCondition>
|
|
</column>
|
|
<column>
|
|
<id>2c9c81b975e496a90176650d873d006f</id>
|
|
<name>svrentover</name>
|
|
<columnDataType>NUMBER</columnDataType>
|
|
<formater>#,##0.00</formater>
|
|
<label>剩余租金</label>
|
|
<enLabel>svrentover</enLabel>
|
|
<width>100</width>
|
|
<position>10</position>
|
|
<isVisible>true</isVisible>
|
|
<color></color>
|
|
<isCountTotal>false</isCountTotal>
|
|
<isCountSubTotal>false</isCountSubTotal>
|
|
<isGroupby>false</isGroupby>
|
|
<isMerge>false</isMerge>
|
|
<action></action>
|
|
<actionParamters></actionParamters>
|
|
<actionCondition></actionCondition>
|
|
</column>
|
|
<column>
|
|
<id>2c9c81b975e496a90176650d873c0069</id>
|
|
<name>cc</name>
|
|
<columnDataType>NUMBER</columnDataType>
|
|
<formater></formater>
|
|
<label>当月应收单数</label>
|
|
<enLabel>cc</enLabel>
|
|
<width>100</width>
|
|
<position>11</position>
|
|
<isVisible>true</isVisible>
|
|
<color></color>
|
|
<isCountTotal>false</isCountTotal>
|
|
<isCountSubTotal>false</isCountSubTotal>
|
|
<isGroupby>false</isGroupby>
|
|
<isMerge>false</isMerge>
|
|
<action></action>
|
|
<actionParamters></actionParamters>
|
|
<actionCondition></actionCondition>
|
|
</column>
|
|
<column>
|
|
<id>2c9c81b975e496a90176650d873d0070</id>
|
|
<name>srent</name>
|
|
<columnDataType>NUMBER</columnDataType>
|
|
<formater>#,##0.00</formater>
|
|
<label>当月当期应收金额</label>
|
|
<enLabel>srent</enLabel>
|
|
<width>100</width>
|
|
<position>12</position>
|
|
<isVisible>true</isVisible>
|
|
<color></color>
|
|
<isCountTotal>false</isCountTotal>
|
|
<isCountSubTotal>false</isCountSubTotal>
|
|
<isGroupby>false</isGroupby>
|
|
<isMerge>false</isMerge>
|
|
<action></action>
|
|
<actionParamters></actionParamters>
|
|
<actionCondition></actionCondition>
|
|
</column>
|
|
<column>
|
|
<id>2c9c81b975e496a90176650d873d0071</id>
|
|
<name>soverrent</name>
|
|
<columnDataType>NUMBER</columnDataType>
|
|
<formater>#,##0.00</formater>
|
|
<label>当月逾期金额</label>
|
|
<enLabel>soverrent</enLabel>
|
|
<width>100</width>
|
|
<position>13</position>
|
|
<isVisible>true</isVisible>
|
|
<color></color>
|
|
<isCountTotal>false</isCountTotal>
|
|
<isCountSubTotal>false</isCountSubTotal>
|
|
<isGroupby>false</isGroupby>
|
|
<isMerge>false</isMerge>
|
|
<action></action>
|
|
<actionParamters></actionParamters>
|
|
<actionCondition></actionCondition>
|
|
</column>
|
|
<column>
|
|
<id>2c9c81b975e496a90176650d873d006c</id>
|
|
<name>cover</name>
|
|
<columnDataType>NUMBER</columnDataType>
|
|
<formater></formater>
|
|
<label>存量逾期合同数</label>
|
|
<enLabel>cover</enLabel>
|
|
<width>100</width>
|
|
<position>14</position>
|
|
<isVisible>true</isVisible>
|
|
<color></color>
|
|
<isCountTotal>false</isCountTotal>
|
|
<isCountSubTotal>false</isCountSubTotal>
|
|
<isGroupby>false</isGroupby>
|
|
<isMerge>false</isMerge>
|
|
<action></action>
|
|
<actionParamters></actionParamters>
|
|
<actionCondition></actionCondition>
|
|
</column>
|
|
<column>
|
|
<id>2c9c81b975e496a90176650d873d006d</id>
|
|
<name>rents</name>
|
|
<columnDataType>NUMBER</columnDataType>
|
|
<formater>#,##0.00</formater>
|
|
<label>存量逾期租金</label>
|
|
<enLabel>rents</enLabel>
|
|
<width>100</width>
|
|
<position>15</position>
|
|
<isVisible>true</isVisible>
|
|
<color></color>
|
|
<isCountTotal>false</isCountTotal>
|
|
<isCountSubTotal>false</isCountSubTotal>
|
|
<isGroupby>false</isGroupby>
|
|
<isMerge>false</isMerge>
|
|
<action></action>
|
|
<actionParamters></actionParamters>
|
|
<actionCondition></actionCondition>
|
|
</column>
|
|
<column>
|
|
<id>2c9c81b975e496a90176650d873d006e</id>
|
|
<name>clrentover</name>
|
|
<columnDataType>NUMBER</columnDataType>
|
|
<formater>#,##0.00</formater>
|
|
<label>存量逾期合同租金余额</label>
|
|
<enLabel>clrentover</enLabel>
|
|
<width>100</width>
|
|
<position>16</position>
|
|
<isVisible>true</isVisible>
|
|
<color></color>
|
|
<isCountTotal>false</isCountTotal>
|
|
<isCountSubTotal>false</isCountSubTotal>
|
|
<isGroupby>false</isGroupby>
|
|
<isMerge>false</isMerge>
|
|
<action></action>
|
|
<actionParamters></actionParamters>
|
|
<actionCondition></actionCondition>
|
|
</column>
|
|
<column>
|
|
<id>2c9c81b975e496a90176650d873d006a</id>
|
|
<name>rate</name>
|
|
<columnDataType>NUMBER</columnDataType>
|
|
<formater></formater>
|
|
<label>大口径逾期率</label>
|
|
<enLabel>rate</enLabel>
|
|
<width>100</width>
|
|
<position>17</position>
|
|
<isVisible>true</isVisible>
|
|
<color></color>
|
|
<isCountTotal>false</isCountTotal>
|
|
<isCountSubTotal>false</isCountSubTotal>
|
|
<isGroupby>false</isGroupby>
|
|
<isMerge>false</isMerge>
|
|
<action></action>
|
|
<actionParamters></actionParamters>
|
|
<actionCondition></actionCondition>
|
|
</column>
|
|
</columns>
|
|
<controls/>
|
|
<searchs/>
|
|
<searchExpress></searchExpress>
|
|
<filters>
|
|
<filter>
|
|
<id>2c9c81b975e496a90176650d873d0072</id>
|
|
<name>startdate</name>
|
|
<enname>startdate</enname>
|
|
<label>开始日期</label>
|
|
<filterType>FILTER</filterType>
|
|
<dbType>DATE</dbType>
|
|
<htmlType>DATE</htmlType>
|
|
<position>0</position>
|
|
</filter>
|
|
<filter>
|
|
<id>2c9c81b975e496a90176650d873d0073</id>
|
|
<name>enddate</name>
|
|
<enname>enddate</enname>
|
|
<label>结束日期</label>
|
|
<filterType>FILTER</filterType>
|
|
<dbType>DATE</dbType>
|
|
<htmlType>DATE</htmlType>
|
|
<position>1</position>
|
|
</filter>
|
|
</filters>
|
|
<filterExpress></filterExpress>
|
|
<pageSize>20</pageSize>
|
|
<showRowNumber>false</showRowNumber>
|
|
<showTotalTitle>false</showTotalTitle>
|
|
<isScale>false</isScale>
|
|
<isCache>false</isCache>
|
|
<isExcel>false</isExcel>
|
|
</table>
|
|
</tables>
|
|
<charts/>
|
|
<pages/>
|
|
<layouts>
|
|
<layout>
|
|
<id>2c9c81b975e496a90176650d873b0068</id>
|
|
<divHeight>0</divHeight>
|
|
<divWidth>0</divWidth>
|
|
<position>0</position>
|
|
<contentId>TABLE#2c9c81b97520309601754a87a5960043</contentId>
|
|
<report>2c9c81b97520309601754a8707d10042</report>
|
|
<contentType>TABLE</contentType>
|
|
</layout>
|
|
</layouts>
|
|
</TenwaReport>
|