1 | <?xml version="1.0" encoding="UTF-8"?> |
---|
2 | |
---|
3 | <!-- |
---|
4 | IBIS-PH View System's "indicator profile" module related Spring properties. |
---|
5 | These properties are all specific to the "indicator" type requests and |
---|
6 | include indicator profile specific resources, controllers, and views. |
---|
7 | --> |
---|
8 | |
---|
9 | <beans default-lazy-init="false" default-autowire="no" |
---|
10 | xmlns="http://www.springframework.org/schema/beans" |
---|
11 | xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
---|
12 | xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd" |
---|
13 | > |
---|
14 | |
---|
15 | <!-- M O D E L S / C O N T R O L L E R R E S O R U C E S --> |
---|
16 | <bean id="indicatorProfilePath" class="org.ibisph.model.StringHolder"> |
---|
17 | <constructor-arg value="indicator/profile/"/> |
---|
18 | </bean> |
---|
19 | |
---|
20 | <bean id="indicatorPreviewXMLBasePath" class="org.ibisph.model.StringHolder"> |
---|
21 | <description> |
---|
22 | Full base XML file path used by the preview controllers to get the |
---|
23 | admin app created IP and IPV XML files. This path is either an |
---|
24 | admin app request URL, content URL, or explicit file path. This |
---|
25 | value is used by the controller code via a FileDAO get call which |
---|
26 | uses a URL. |
---|
27 | </description> |
---|
28 | <constructor-arg value="#{commonPublishedXMLBasePath.string}#{indicatorProfilePath.string}preview/"/> |
---|
29 | </bean> |
---|
30 | <bean id="indicatorPreviewXMLBasePathURL" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean"> |
---|
31 | <property name="targetObject" ref="commonContextAndPathService"/> |
---|
32 | <property name="targetMethod" value="getPathURL"/> |
---|
33 | <property name="arguments"><list><value>#{indicatorPreviewXMLBasePath.string}</value></list></property> |
---|
34 | </bean> |
---|
35 | |
---|
36 | |
---|
37 | <!-- M O D E L M A P S --> |
---|
38 | <bean id="indicatorSelectedRelationNameModelMap" class="org.ibisph.indicatorprofile.modelmap.RelationNameFromHTTPRequest"> |
---|
39 | <property name="modelMapKey" value="RelationName"/> |
---|
40 | </bean> |
---|
41 | |
---|
42 | <bean id="indicatorPublishedIndicatorsXMLModelMap" class="org.ibisph.modelmap.ModelFromFilePathAndNameService"> |
---|
43 | <description> |
---|
44 | Published indicators with the primary XML model map key. This model |
---|
45 | map is used for IP Indexes. Named XML to differentiate the parameter |
---|
46 | version of this model map (below). Inconsistently named but XML |
---|
47 | indicates that it is the main XML model map. |
---|
48 | </description> |
---|
49 | <property name="modelMapKey" value="#{commonXMLModelMapKey.string}"/> |
---|
50 | <property name="getModelService" ref="commonPublishedW3CModelService"/> |
---|
51 | <property name="filePathAndName" value="indicator/published_indicators.xml"/> |
---|
52 | </bean> |
---|
53 | <bean id="indicatorPublishedIndicatorsModelMap" |
---|
54 | parent="indicatorPublishedIndicatorsXMLModelMap" |
---|
55 | > |
---|
56 | <description> |
---|
57 | Published indicators as w3c XML used as a 2ndary/transformation |
---|
58 | parameter XML model map. Passed as a parameter to the XML/XSLT |
---|
59 | transformer. Used for Community and Topic pages. This is named |
---|
60 | without "Param" so that it's consistent with the other published |
---|
61 | XML file model maps that are passed as a w3c document parameter. |
---|
62 | </description> |
---|
63 | <property name="modelMapKey" value="PublishedIndicators"/> |
---|
64 | </bean> |
---|
65 | |
---|
66 | |
---|
67 | <bean id="indicatorProfileFilePathModelMapProperties" abstract="true"> |
---|
68 | <description> |
---|
69 | Indicator base path primary XML model map properties used for most |
---|
70 | indicator and IP modelmap based requests. This model map uses the |
---|
71 | published XML file path URL service to provide the base published |
---|
72 | XML base path URL with rest of the filePath and actual IP filename |
---|
73 | being set via the request's last segment/filename. |
---|
74 | </description> |
---|
75 | <property name="modelMapKey" value="#{commonXMLModelMapKey.string}"/> |
---|
76 | <property name="getModelService" ref="commonPublishedFilePathModelService"/> |
---|
77 | </bean> |
---|
78 | <bean id="indicatorProfileFilePathAndNameModelMap" |
---|
79 | class="org.ibisph.web.modelmap.ModelFromHTTPRequestPathLastSegment" |
---|
80 | parent="indicatorProfileFilePathModelMapProperties" |
---|
81 | > |
---|
82 | <description> |
---|
83 | Main IP path with filename URL model map used for all IP requests |
---|
84 | where the actual IP XML file name is the last segment in the request |
---|
85 | path. This model map uses the published XML file path URL service |
---|
86 | to provide the base published XML base path + the filePath to provide |
---|
87 | the next sub path segments + the request's last segment which is the |
---|
88 | actual IP filename. |
---|
89 | </description> |
---|
90 | <property name="filePath" value="#{indicatorProfilePath.string}"/> |
---|
91 | </bean> |
---|
92 | |
---|
93 | <bean id="indicatorProfileBasePathModelMap" |
---|
94 | class="org.ibisph.modelmap.ModelFromFilePathAndNameService" |
---|
95 | > |
---|
96 | <description> |
---|
97 | IP filepath URL that is passed as an XSLT param so that XSLT code |
---|
98 | can to loop/access a bunch of IP XMLs. Used for community IPs |
---|
99 | report and possibly other community pages like the Quick Facts |
---|
100 | demographic table etc. |
---|
101 | </description> |
---|
102 | <property name="modelMapKey" value="IndicatorProfilePath"/> |
---|
103 | <property name="filePathAndName" value="#{indicatorProfilePath.string}"/> |
---|
104 | <property name="getModelService" ref="commonPublishedFilePathModelService"/> |
---|
105 | </bean> |
---|
106 | |
---|
107 | <bean id="indicatorIndicatorSetsModelMap" class="org.ibisph.modelmap.ModelFromFilePathAndNameService"> |
---|
108 | <description> |
---|
109 | The indicator sets IPs XML has 3 uses: 1) the IP sets index page |
---|
110 | 2) the community controller that sets session values with on being |
---|
111 | an IP set name (so need dom4j access), and 3) the community IPs page |
---|
112 | XSLT to show and change to an alternative IP set. |
---|
113 | </description> |
---|
114 | <property name="modelMapKey" value="IndicatorSets"/> |
---|
115 | <property name="getModelService" ref="commonPublishedDocumentDAOService"/> |
---|
116 | <property name="filePathAndName" value="indicator/indicator_sets.xml"/> |
---|
117 | </bean> |
---|
118 | |
---|
119 | <bean id="indicatorPreviewFilePathAndNameURLModelMap" class="org.ibisph.web.modelmap.ModelFromHTTPRequestPathLastSegment"> |
---|
120 | <description> |
---|
121 | The main XML model map for IP and IPV Preview requests. |
---|
122 | </description> |
---|
123 | <property name="modelMapKey" value="#{commonXMLModelMapKey.string}"/> |
---|
124 | <property name="getModelService"> |
---|
125 | <bean class="org.ibisph.model.URLPathGetModelService"> |
---|
126 | <property name="basePath" ref="indicatorPreviewXMLBasePathURL"/> |
---|
127 | </bean> |
---|
128 | </property> |
---|
129 | </bean> |
---|
130 | |
---|
131 | |
---|
132 | |
---|
133 | <!-- C O N T R O L L E R S --> |
---|
134 | <bean id="indicatorAlphabeticalIndexController" parent="commonModelMapListController"> |
---|
135 | <property name="modelMapList"> |
---|
136 | <list> |
---|
137 | <ref bean="indicatorPublishedIndicatorsXMLModelMap"/> |
---|
138 | </list> |
---|
139 | </property> |
---|
140 | <property name="view" ref="indicatorAlphabeticalIndexView"/> |
---|
141 | </bean> |
---|
142 | <bean id="indicatorDemographicIndexController" parent="indicatorAlphabeticalIndexController"> |
---|
143 | <property name="view" ref="indicatorDemographicIndexView"/> |
---|
144 | </bean> |
---|
145 | <bean id="indicatorDataSourceIndexController" parent="commonModelMapListController"> |
---|
146 | <property name="modelMapList"> |
---|
147 | <list> |
---|
148 | <ref bean="indicatorPublishedIndicatorsXMLModelMap"/> |
---|
149 | <ref bean="commonDataSourcesModelMap"/> |
---|
150 | </list> |
---|
151 | </property> |
---|
152 | <property name="view" ref="indicatorDataSourceIndexView"/> |
---|
153 | </bean> |
---|
154 | <bean id="indicatorOrgUnitIndexController" parent="commonModelMapListController"> |
---|
155 | <property name="modelMapList"> |
---|
156 | <list> |
---|
157 | <ref bean="indicatorPublishedIndicatorsXMLModelMap"/> |
---|
158 | <ref bean="commonOrgUnitsModelMap"/> |
---|
159 | </list> |
---|
160 | </property> |
---|
161 | <property name="view" ref="indicatorOrgUnitIndexView"/> |
---|
162 | </bean> |
---|
163 | |
---|
164 | <bean id="indicatorTableIndexController" parent="commonModelMapListController"> |
---|
165 | <property name="modelMapList"> |
---|
166 | <list> |
---|
167 | <ref bean="indicatorPublishedIndicatorsXMLModelMap"/> |
---|
168 | <ref bean="commonDataSourcesModelMap"/> |
---|
169 | <ref bean="commonOrgUnitsModelMap"/> |
---|
170 | </list> |
---|
171 | </property> |
---|
172 | <property name="view" ref="indicatorTableIndexView"/> |
---|
173 | </bean> |
---|
174 | |
---|
175 | <bean id="indicatorIndicatorSetIndexController" parent="commonModelMapListController"> |
---|
176 | <property name="modelMapList"> |
---|
177 | <list> |
---|
178 | <ref bean="indicatorPublishedIndicatorsXMLModelMap"/> |
---|
179 | <ref bean="indicatorIndicatorSetsModelMap"/> |
---|
180 | </list> |
---|
181 | </property> |
---|
182 | <property name="view" ref="indicatorIndicatorSetIndexView"/> |
---|
183 | </bean> |
---|
184 | |
---|
185 | |
---|
186 | <!-- |
---|
187 | MODIFIED DATE NOTE: For IP's that are on a remote machine/accessed via |
---|
188 | URL, the modelmap is a file path not a document so the XML date can't be |
---|
189 | accessed. For IPVs the IPV XML is loaded in later model map processing |
---|
190 | because it needs to determine the view XSLT to be used. As such the XML |
---|
191 | date is returned for view XMLs - even if the file is on a remote server. |
---|
192 | If this is a problem in the future then similar code can be applied to |
---|
193 | open the IP XML and put into the map. |
---|
194 | --> |
---|
195 | <bean id="indicatorProfileControllerProperties" abstract="true" parent="commonModelMapListController"> |
---|
196 | <property name="modelMapList"> |
---|
197 | <list> |
---|
198 | <ref bean="commonAncillaryValuesModelMap"/> |
---|
199 | <ref bean="commonDataSourcesModelMap"/> |
---|
200 | <ref bean="commonDimensionsModelMap"/> |
---|
201 | <ref bean="commonMeasuresModelMap"/> |
---|
202 | <ref bean="commonOrgUnitsModelMap"/> |
---|
203 | <ref bean="commonValueAttributesModelMap"/> |
---|
204 | <ref bean="commonValueTypesModelMap"/> |
---|
205 | <ref bean="indicatorProfileFilePathAndNameModelMap"/> |
---|
206 | </list> |
---|
207 | </property> |
---|
208 | </bean> |
---|
209 | <bean id="indicatorImportantFactsController" parent="indicatorProfileControllerProperties"> |
---|
210 | <property name="view" ref="indicatorImportantFactsView"/> |
---|
211 | </bean> |
---|
212 | <bean id="indicatorServicesController" parent="indicatorProfileControllerProperties"> |
---|
213 | <property name="view" ref="indicatorServicesView"/> |
---|
214 | </bean> |
---|
215 | <bean id="indicatorResourcesController" parent="indicatorProfileControllerProperties"> |
---|
216 | <property name="view" ref="indicatorResourcesView"/> |
---|
217 | </bean> |
---|
218 | |
---|
219 | <bean id="indicatorSummaryViewController" parent="indicatorProfileControllerProperties"> |
---|
220 | <property name="view" ref="indicatorSummaryView"/> |
---|
221 | </bean> |
---|
222 | |
---|
223 | <bean id="indicatorCompleteViewController" parent="indicatorProfileControllerProperties"> |
---|
224 | <property name="view" ref="indicatorCompleteView"/> |
---|
225 | </bean> |
---|
226 | |
---|
227 | <bean id="indicatorViewController" parent="commonModelMapListController"> |
---|
228 | <description> |
---|
229 | v3 controller that loads the view XML to get the view's xslt view |
---|
230 | name can which is then set into the XSLT model map (mechanism for |
---|
231 | different view XSLT templates to be specified and applied). |
---|
232 | </description> |
---|
233 | <property name="modelMapList"> |
---|
234 | <list> |
---|
235 | <ref bean="commonAncillaryValuesModelMap"/> |
---|
236 | <ref bean="commonDataSourcesModelMap"/> |
---|
237 | <ref bean="commonDimensionsModelMap"/> |
---|
238 | <ref bean="commonMeasuresModelMap"/> |
---|
239 | <ref bean="commonOrgUnitsModelMap"/> |
---|
240 | <ref bean="commonValueAttributesModelMap"/> |
---|
241 | <ref bean="commonValueTypesModelMap"/> |
---|
242 | <ref bean="indicatorProfileFilePathAndNameModelMap"/> |
---|
243 | <bean class="org.ibisph.indicatorprofile.modelmap.IndicatorViewViewTemplate"> |
---|
244 | <description> |
---|
245 | Uses the complete path and filename url model to open |
---|
246 | the IPV XML doc. The IPV XML's VIEW_NAME element is then |
---|
247 | read to determine the view XSLT template to load and be |
---|
248 | used for the view request. The IPV XML doc is then put |
---|
249 | into the model map so the transform doesn't have to |
---|
250 | parse the XML twice. The XSLT model map is set to the |
---|
251 | just determined XSLT path via the XSLT get model service. |
---|
252 | </description> |
---|
253 | <property name="documentDAOService" ref="commonPublishedDocumentDAOService"/> |
---|
254 | <property name="defaultViewXSLTFilePathAndName" value="html/indicator/profile/view/ViewPage.xslt"/> |
---|
255 | <property name="XSLTURLGetModelService" ref="commonXSLTFilePathModelService"/> |
---|
256 | </bean> |
---|
257 | </list> |
---|
258 | </property> |
---|
259 | <property name="view" ref="commonXSLTTransformationView"/> |
---|
260 | </bean> |
---|
261 | |
---|
262 | <bean id="indicatorRelatedIndicatorsController" parent="commonModelMapListController"> |
---|
263 | <property name="modelMapList"> |
---|
264 | <list> |
---|
265 | <ref bean="indicatorSelectedRelationNameModelMap"/> |
---|
266 | <ref bean="indicatorProfileFilePathAndNameModelMap"/> |
---|
267 | <ref bean="commonOrgUnitsModelMap"/> |
---|
268 | </list> |
---|
269 | </property> |
---|
270 | <property name="view" ref="indicatorRelatedIndicatorsView"/> |
---|
271 | </bean> |
---|
272 | |
---|
273 | |
---|
274 | <bean id="indicatorPreviewController" parent="commonModelMapListController"> |
---|
275 | <description> |
---|
276 | The main IP Preview request is very similar to the non preview version |
---|
277 | other than the preview XML path is used for the primary XML model. |
---|
278 | </description> |
---|
279 | <property name="modelMapList"> |
---|
280 | <list> |
---|
281 | <ref bean="commonAncillaryValuesModelMap"/> |
---|
282 | <ref bean="commonDataSourcesModelMap"/> |
---|
283 | <ref bean="commonDimensionsModelMap"/> |
---|
284 | <ref bean="commonMeasuresModelMap"/> |
---|
285 | <ref bean="commonOrgUnitsModelMap"/> |
---|
286 | <ref bean="commonValueAttributesModelMap"/> |
---|
287 | <ref bean="commonValueTypesModelMap"/> |
---|
288 | <ref bean="indicatorPreviewFilePathAndNameURLModelMap"/> |
---|
289 | </list> |
---|
290 | </property> |
---|
291 | <property name="additionalHTTPResponseHeaders" ref="commonNoCacheHTTPResponseHeaders"/> |
---|
292 | <property name="view" ref="indicatorCompleteView"/> |
---|
293 | </bean> |
---|
294 | |
---|
295 | <bean id="indicatorViewPreviewController" parent="commonModelMapListController"> |
---|
296 | <description> |
---|
297 | The IPV Preview request is likewise similar to the non preview version |
---|
298 | other than the preview XML path is used for the primary XML model. |
---|
299 | </description> |
---|
300 | <property name="modelMapList"> |
---|
301 | <list> |
---|
302 | <ref bean="commonAncillaryValuesModelMap"/> |
---|
303 | <ref bean="commonDataSourcesModelMap"/> |
---|
304 | <ref bean="commonDimensionsModelMap"/> |
---|
305 | <ref bean="commonMeasuresModelMap"/> |
---|
306 | <ref bean="commonOrgUnitsModelMap"/> |
---|
307 | <ref bean="commonValueAttributesModelMap"/> |
---|
308 | <ref bean="commonValueTypesModelMap"/> |
---|
309 | <ref bean="indicatorPreviewFilePathAndNameURLModelMap"/> |
---|
310 | <bean class="org.ibisph.indicatorprofile.modelmap.IndicatorViewViewTemplate"> |
---|
311 | <property name="documentDAOService" ref="commonPublishedDocumentDAOService"/> |
---|
312 | <property name="XSLTURLGetModelService" ref="commonXSLTFilePathModelService"/> |
---|
313 | </bean> |
---|
314 | </list> |
---|
315 | </property> |
---|
316 | <property name="additionalHTTPResponseHeaders" ref="commonNoCacheHTTPResponseHeaders"/> |
---|
317 | <property name="view" ref="commonXSLTTransformationView"/> |
---|
318 | </bean> |
---|
319 | |
---|
320 | |
---|
321 | <bean id="indicatorContentBlocksController" parent="indicatorProfileControllerProperties"> |
---|
322 | <property name="view" ref="indicatorContentBlocksView"/> |
---|
323 | </bean> |
---|
324 | <bean id="indicatorContentJavaScriptController" parent="indicatorProfileControllerProperties"> |
---|
325 | <property name="view" ref="indicatorContentJavaScriptView"/> |
---|
326 | </bean> |
---|
327 | |
---|
328 | |
---|
329 | <!-- V I E W S --> |
---|
330 | <bean id="indicatorAlphabeticalIndexView" parent="commonXSLTTransformationView"> |
---|
331 | <property name="XSLTPathAndFilename" value="html/indicator/index/alphabetical/AlphabeticalPage.xslt"/> |
---|
332 | </bean> |
---|
333 | <bean id="indicatorDataSourceIndexView" parent="commonXSLTTransformationView"> |
---|
334 | <property name="XSLTPathAndFilename" value="html/indicator/index/data_source/DataSourcePage.xslt"/> |
---|
335 | </bean> |
---|
336 | <bean id="indicatorOrgUnitIndexView" parent="commonXSLTTransformationView"> |
---|
337 | <property name="XSLTPathAndFilename" value="html/indicator/index/org_unit/OrgUnitPage.xslt"/> |
---|
338 | </bean> |
---|
339 | <bean id="indicatorDemographicIndexView" parent="commonXSLTTransformationView"> |
---|
340 | <property name="XSLTPathAndFilename" value="html/indicator/index/demographic/DemographicPage.xslt"/> |
---|
341 | </bean> |
---|
342 | <bean id="indicatorIndicatorSetIndexView" parent="commonXSLTTransformationView"> |
---|
343 | <property name="XSLTPathAndFilename" value="html/indicator/index/indicator_set/IndicatorSetPage.xslt"/> |
---|
344 | </bean> |
---|
345 | <bean id="indicatorTableIndexView" parent="commonXSLTTransformationView"> |
---|
346 | <property name="XSLTPathAndFilename" value="html/indicator/index/table/TablePage.xslt"/> |
---|
347 | </bean> |
---|
348 | |
---|
349 | <bean id="indicatorSummaryView" parent="commonXSLTTransformationView"> |
---|
350 | <property name="XSLTPathAndFilename" value="html/indicator/profile/summary/SummaryPage.xslt"/> |
---|
351 | </bean> |
---|
352 | <bean id="indicatorCompleteView" parent="commonXSLTTransformationView"> |
---|
353 | <property name="XSLTPathAndFilename" value="html/indicator/profile/complete_profile/CompleteProfilePage.xslt"/> |
---|
354 | </bean> |
---|
355 | |
---|
356 | <bean id="indicatorImportantFactsView" parent="commonXSLTTransformationView"> |
---|
357 | <property name="XSLTPathAndFilename" value="html/indicator/profile/important_facts/ImportantFactsPage.xslt"/> |
---|
358 | </bean> |
---|
359 | <bean id="indicatorServicesView" parent="commonXSLTTransformationView"> |
---|
360 | <property name="XSLTPathAndFilename" value="html/indicator/profile/available_services/AvailableServicesPage.xslt"/> |
---|
361 | </bean> |
---|
362 | <bean id="indicatorResourcesView" parent="commonXSLTTransformationView"> |
---|
363 | <property name="XSLTPathAndFilename" value="html/indicator/profile/more_resources/MoreResourcesPage.xslt"/> |
---|
364 | </bean> |
---|
365 | <bean id="indicatorRelatedIndicatorsView" parent="commonXSLTTransformationView"> |
---|
366 | <property name="XSLTPathAndFilename" value="html/indicator/profile/related_indicators/RelatedIndicatorsPage.xslt"/> |
---|
367 | </bean> |
---|
368 | |
---|
369 | <bean id="indicatorContentBlocksView" parent="commonXSLTTransformationView"> |
---|
370 | <property name="XSLTPathAndFilename" value="html/indicator/profile/ContentBlocks.xslt"/> |
---|
371 | </bean> |
---|
372 | <bean id="indicatorContentJavaScriptView" parent="commonXSLTTransformationView"> |
---|
373 | <property name="XSLTPathAndFilename" value="json/IndicatorContentJavaScript.xslt"/> |
---|
374 | </bean> |
---|
375 | |
---|
376 | </beans> |
---|
377 | |
---|
378 | |
---|
379 | |
---|