Enhance styling
[gpl/argeo-suite.git] / org.argeo.suite.web / META-INF / spring / people.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <beans xmlns="http://www.springframework.org/schema/beans"
3         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:p="http://www.springframework.org/schema/p"
4         xmlns:util="http://www.springframework.org/schema/util"
5         xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
6          http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-2.5.xsd">
7
8         <!-- People UI -->
9         <bean id="people.mainPage" class="org.argeo.connect.people.web.pages.PeopleDynamicPages">
10                 <property name="dynamicPages" ref="people.dynamicPages" />
11                 <property name="peopleService" ref="peopleService" />
12                 <property name="resourcesService" ref="resourcesService" />
13                 <property name="iconPathes" ref="peopleEntityIcons" />
14         </bean>
15
16         <bean id="people.header" class="org.argeo.cms.util.SimpleCmsHeader">
17                 <property name="lead">
18                         <list>
19                                 <bean p:image="theme/argeo-classic/img/byArgeo.png" p:target="/people#"
20                                         p:custom="cms_header-logo" parent="menuLink" />
21                                 <bean p:label="All" p:target="people!/search/all" parent="menuLink" />
22                                 <bean p:label="Persons" p:target="people!/search/persons"
23                                         parent="menuLink" />
24                                 <bean p:label="Organisations" p:target="people!/search/orgs"
25                                         parent="menuLink" />
26                                 <bean p:label="Browse" p:target="browse#" parent="menuLink" />
27                         </list>
28                 </property>
29                 <property name="end" ref="headerEnd" />
30         </bean>
31
32         <util:map id="peopleEntityIcons">
33                 <entry key="people:person" value="theme/argeo-classic/icons/people/types/person.gif" />
34                 <entry key="people:org" value="theme/argeo-classic/icons/people/types/company.png" />
35         </util:map>
36
37         <!-- UI Providers -->
38         <!-- A map for the specific page given the node type of the passed context -->
39         <util:map id="people.dynamicPages">
40                 <entry>
41                         <key>
42                                 <util:constant static-field="org.argeo.connect.people.PeopleTypes.PEOPLE_PERSON" />
43                         </key>
44                         <bean class="org.argeo.connect.people.web.pages.PersonPage">
45                                 <property name="personHeaderPart" ref="personHeaderPart" />
46                                 <property name="contactsWithNotePart" ref="contactsWithNotePart" />
47                                 <property name="activitiesPart" ref="activitiesPart" />
48                         </bean>
49                 </entry>
50                 <entry>
51                         <key>
52                                 <util:constant static-field="org.argeo.connect.people.PeopleTypes.PEOPLE_ORG" />
53                         </key>
54                         <bean class="org.argeo.connect.people.web.pages.OrgPage">
55                                 <property name="orgHeaderPart" ref="orgHeaderPart" />
56                                 <property name="contactsWithNotePart" ref="contactsWithNotePart" />
57                                 <property name="activitiesPart" ref="activitiesPart" />
58                         </bean>
59                 </entry>
60                 <entry>
61                         <key>
62                                 <util:constant
63                                         static-field="org.argeo.connect.resources.ResourcesTypes.RESOURCES_TAG_INSTANCE" />
64                         </key>
65                         <bean class="org.argeo.connect.people.web.pages.TagLikeInstancePage">
66                                 <property name="peopleService" ref="peopleService" />
67                                 <property name="resourcesService" ref="resourcesService" />
68
69                                 <property name="iconPathes" ref="peopleEntityIcons" />
70                                 <property name="propertyName" value="connect:tags" />
71                         </bean>
72                 </entry>
73                 <entry>
74                         <key>
75                                 <util:constant
76                                         static-field="org.argeo.connect.people.PeopleTypes.PEOPLE_MAILING_LIST" />
77                         </key>
78                         <bean class="org.argeo.connect.people.web.pages.TagLikeInstancePage">
79                                 <property name="resourcesService" ref="resourcesService" />
80                                 <property name="peopleService" ref="peopleService" />
81                                 <property name="iconPathes" ref="peopleEntityIcons" />
82                                 <property name="propertyName" value="people:mailingLists" />
83                         </bean>
84                 </entry>
85         </util:map>
86
87         <!-- Various headers -->
88         <bean id="personHeaderPart" class="org.argeo.connect.people.web.parts.PersonHeaderPart">
89                 <property name="resourcesService" ref="resourcesService" />
90                 <property name="peopleService" ref="peopleService" />
91                 <property name="tagsPart" ref="tagsPart" />
92                 <property name="mailingListsPart" ref="mailingListsPart" />
93         </bean>
94
95         <bean id="orgHeaderPart" class="org.argeo.connect.people.web.parts.OrgHeaderPart">
96                 <property name="resourcesService" ref="resourcesService" />
97                 <property name="peopleService" ref="peopleService" />
98                 <property name="tagsPart" ref="tagsPart" />
99                 <property name="mailingListsPart" ref="mailingListsPart" />
100         </bean>
101
102         <!-- Contacts -->
103         <bean id="contactsWithNotePart" class="org.argeo.connect.people.web.parts.ContactsWithNotePart">
104                 <property name="singleContactPart" ref="singleContactPart" />
105         </bean>
106         <bean id="singleContactPart" class="org.argeo.connect.people.web.parts.SingleContactPart">
107                 <property name="resourcesService" ref="resourcesService" />
108                 <property name="contactButtonsPart" ref="contactButtonsPart" />
109         </bean>
110         <bean id="contactButtonsPart" class="org.argeo.connect.people.web.parts.ContactButtonsPart">
111         </bean>
112
113         <!-- Activities and workflows -->
114         <bean id="activitiesPart" class="org.argeo.connect.people.web.parts.ActivitiesPart">
115         </bean>
116
117         <!-- Tag like properties -->
118         <bean id="tagsPart" class="org.argeo.connect.people.web.parts.TagLikeValuesPart">
119                 <property name="propertyName">
120                         <util:constant static-field="org.argeo.connect.ConnectNames.CONNECT_TAGS" />
121                 </property>
122         </bean>
123         <bean id="mailingListsPart" class="org.argeo.connect.people.web.parts.TagLikeValuesPart">
124                 <property name="propertyName">
125                         <util:constant
126                                 static-field="org.argeo.connect.people.PeopleNames.PEOPLE_MAILING_LISTS" />
127                 </property>
128         </bean>
129 </beans>