Downloads Documentation Community Contribute Demo






Show Sidebar
Login | Register

root/openmrs-modules/epihandy/metadata/moduleApplicationContext.xml

Revision 2476, 3.1 kB (checked in by dkayiwa, 1 year ago)

clean of some bugs

Line 
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd">
3
4 <!-- Beans to add to the current Application context definition -->
5  
6 <beans>
7        
8     <bean id="epihandyUrlMapping" class="org.springframework.web.servlet.handler.SimpleUrlHandlerMapping">
9         <property name="mappings">
10             <props>
11                     <prop key="module/@MODULE_ID@/uploadData.form">uploadDataForm</prop>
12                     <prop key="module/@MODULE_ID@/downloadPatients.form">downloadPatientsForm</prop>
13                     <prop key="module/@MODULE_ID@/initDatabase.list">initDatabaseList</prop>
14             </props>
15         </property>
16     </bean>
17
18         <bean id="epihandySessionFactory" class="org.openmrs.module.epihandy.db.hibernate.EpihandyHibernateSessionFactoryBean">
19         </bean>
20
21         <bean parent="serviceContext">
22                 <property name="moduleService">
23                         <list>
24                                 <value>org.openmrs.module.epihandy.EpihandyService</value> <!-- service interface name -->
25                                  <bean class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean">
26                                         <property name="transactionManager"><ref bean="transactionManager"/></property>
27                                         <property name="target">
28                                                 <bean class="org.openmrs.module.epihandy.impl.EpihandyServiceImpl">
29                                                         <property name="epihandyDAO">
30                                                             <bean class="@MODULE_PACKAGE@.db.hibernate.HibernateEpihandyDAO">
31                                                                 <property name="sessionFactory"><ref bean="sessionFactory"/></property>
32                                                                 <property name="epihandySessionFactory"><ref bean="epihandySessionFactory"/></property>
33                                                             </bean>
34                                                         </property>
35                                                 </bean>
36                                         </property>
37                                         <property name="preInterceptors">
38                                                 <list>
39                                                         <ref bean="authorizationInterceptor"/>
40                                                 </list>
41                                         </property>
42                                         <property name="transactionAttributeSource">
43                                                 <bean class="org.springframework.transaction.annotation.AnnotationTransactionAttributeSource"/>
44                                         </property>
45                                 </bean>
46                         </list>
47                 </property>
48         </bean>
49        
50        
51         <!-- Controllers -->
52        
53         <bean id="uploadDataForm" class="org.openmrs.module.epihandy.web.controller.DataUploadFormController">
54                 <property name="commandName"><value>formData</value></property>
55                 <property name="formView"><value>/module/@MODULE_ID@/uploadDataForm</value></property>
56                 <property name="successView"><value>/openmrs/module/@MODULE_ID@/uploadData.form</value></property>
57         </bean>
58
59         <bean id="downloadPatientsForm" class="org.openmrs.module.epihandy.web.controller.PatientDownloadFormController">
60                 <property name="commandName"><value>patients</value></property>
61                 <property name="formView"><value>/module/@MODULE_ID@/downloadPatientsForm</value></property>
62                 <property name="successView"><value>/module/@MODULE_ID@/downloadPatientsForm</value></property>
63         </bean>
64        
65         <bean id="initDatabaseList" class="org.openmrs.module.epihandy.web.controller.InitDatabaseListController">
66                 <property name="commandName"><value>initDatabaseList</value></property>
67                 <property name="formView"><value>/module/epihandy/initDatabaseList</value></property>
68                 <property name="successView"><value>initDatabaseList.list</value></property>
69         </bean>
70        
71         <!-- /Controllers -->
72
73 </beans>
Note: See TracBrowser for help on using the browser.