<beans default-lazy-init="false"
    xmlns="http://www.springframework.org/schema/beans" 	
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd">
	
	<!--  DI 3	Device Failure Report-->
	<bean id="DI3" class="gov.va.med.fw.report.ConfigurableReportBuilder">	
		<constructor-arg ref="DI3.dataService"/>
		<property name="reportNameResolver"> 
			<bean class="gov.va.med.ccht.service.report.StandardReportNameResolver">
			</bean>
		</property>				
		<property name="reportDataService" ref="DI3.dataService"/>
		<property name="reportTemplate" ref="DI3.reportTemplate"/>
	</bean>
	
	<bean
		id="DI3.dataService"
		class="gov.va.med.fw.report.jasperreport.data.JasperReportDataService">

		<property name="reportDataDAOs">
			<map>
				<entry key="DI3.Summary.national" value="DI3.Summary.national.dataDAO"/>
				<entry key="DI3.Summary.visn" value="DI3.Summary.visn.dataDAO"/>
				<entry key="DI3.Summary.facility" value="DI3.Summary.facility.dataDAO"/>
			</map>
		</property>   	
    	
		<property name="metaDataMap">
		    <map>
				<entry key="DI3.Summary.national">
					<map>
						<entry key="visn_name"><value type="java.lang.Integer">0</value></entry>
						<entry key="facility_name"><value type="java.lang.Integer">1</value></entry>
						<entry key="vendor_name"><value type="java.lang.Integer">2</value></entry>
						<entry key="model_name"><value type="java.lang.Integer">3</value></entry>					
						<entry key="totalDevices"><value type="java.lang.Integer">4</value></entry>
						<entry key="failedDevices"><value type="java.lang.Integer">5</value></entry>
						<entry key="failureRate"><value type="java.lang.Integer">6</value></entry>								
					</map>
				</entry>									
				<entry key="DI3.Summary.visn">
					<map>
						<entry key="visn_name"><value type="java.lang.Integer">0</value></entry>
						<entry key="facility_name"><value type="java.lang.Integer">1</value></entry>
						<entry key="vendor_name"><value type="java.lang.Integer">2</value></entry>
						<entry key="model_name"><value type="java.lang.Integer">3</value></entry>					
						<entry key="totalDevices"><value type="java.lang.Integer">4</value></entry>
						<entry key="failedDevices"><value type="java.lang.Integer">5</value></entry>
						<entry key="failureRate"><value type="java.lang.Integer">6</value></entry>								
					</map>
				</entry>									
				<entry key="DI3.Summary.facility">
					<map>
						<entry key="visn_name"><value type="java.lang.Integer">0</value></entry>
						<entry key="facility_name"><value type="java.lang.Integer">1</value></entry>
						<entry key="vendor_name"><value type="java.lang.Integer">2</value></entry>
						<entry key="model_name"><value type="java.lang.Integer">3</value></entry>					
						<entry key="totalDevices"><value type="java.lang.Integer">4</value></entry>
						<entry key="failedDevices"><value type="java.lang.Integer">5</value></entry>
						<entry key="failureRate"><value type="java.lang.Integer">6</value></entry>								
					</map>
				</entry>			
		    </map>
		</property>
	</bean>
	
	<bean id="DI3.ehCacheStrategy" class="gov.va.med.fw.cache.EHCacheStrategy">
	</bean>

	<bean id="DI3.reportTemplate" class="gov.va.med.fw.report.jasperreport.JasperReportTemplate">
		<property name="templateCache" ref="DI3.ehCacheStrategy"/>
		<property name="templates">
			<map>			
				<entry key="DI3.Summary.national" value="di3_summary_national.jasper"/>				
				<entry key="DI3.Summary.visn" value="di3_summary_visn.jasper"/>
				<entry key="DI3.Summary.facility" value="di3_summary_facility.jasper"/>	
			</map>
		</property>
	</bean>
	
	<bean id="DI3.Summary.xls" abstract="true">
		<property name="footNotes">
			<list>
				<value>Failure includes all purchased devices.</value>
				<value>A status of Repair constitutes a device failure.</value>
				<value>*The failure rate counts the initial failure of a device only.</value>
			</list>
		</property>
	</bean>
		
	<bean id="DI3.Summary.national.xls" class="gov.va.med.fw.report.excelreport.ExcelReport" parent="DI3.Summary.xls">
		<property name="reportTitle" value="National Device Failure Rate Report"/>
	</bean>
	
	<bean id="DI3.Summary.visn.xls" class="gov.va.med.fw.report.excelreport.ExcelReport" parent="DI3.Summary.xls">
		<property name="reportTitle" value="VISN Device Failure Rate Report"/>
	</bean>
			
	<bean id="DI3.Summary.facility.xls" class="gov.va.med.fw.report.excelreport.ExcelReport" parent="DI3.Summary.xls">
		<property name="reportTitle" value="Facility Device Failure Rate Report"/>
	</bean>
	
	<bean id="DI3.dataDAO.abstract" abstract="true"
		class="gov.va.med.ccht.persistent.hibernate.StandardReportDataDAOImpl">
		<property name="postProcessRequired" value="false"/>
		<property name="paginated" value="false"/>
		<property name="queryName" value="di3_summary_visn"/>
	</bean>
	<bean id="DI3.Summary.national.dataDAO" parent="DI3.dataDAO.abstract">
		<property name="queryName" value="di3_summary_national"/>
	</bean>	
	<bean id="DI3.Summary.visn.dataDAO" parent="DI3.dataDAO.abstract">
		<property name="queryName" value="di3_summary_visn"/>
	</bean>
	<bean id="DI3.Summary.facility.dataDAO" parent="DI3.dataDAO.abstract">
		<property name="queryName" value="di3_summary_facility"/>
	</bean>
</beans>

