<?xml version="1.0" encoding="ISO-8859-1"?>
<!-- ~ /* ~ * Copyright (C) 2003-2016 eXo Platform SAS. ~ * ~ * This program 
	is free software; you can redistribute it and/or ~ * modify it under the 
	terms of the GNU Affero General Public License ~ * as published by the Free 
	Software Foundation; either version 3 ~ * of the License, or (at your option) 
	any later version. ~ * ~ * This program is distributed in the hope that it 
	will be useful, ~ * but WITHOUT ANY WARRANTY; without even the implied warranty 
	of ~ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ~ * GNU 
	General Public License for more details. ~ * ~ * You should have received 
	a copy of the GNU General Public License ~ * along with this program; if 
	not, see<http://www.gnu.org/licenses/>. ~ */ -->
<configuration xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xsi:schemaLocation="http://www.exoplatform.org/xml/ns/kernel_1_2.xsd http://www.exoplatform.org/xml/ns/kernel_1_2.xsd"
               xmlns="http://www.exoplatform.org/xml/ns/kernel_1_2.xsd">
  <component>
    <type>org.exoplatform.commons.persistence.impl.EntityManagerService</type>
  </component>
  <component>
    <type>org.exoplatform.cs.service.EnvironmentService</type>
  </component>
  <component>
    <type>org.exoplatform.cs.service.CSSpaceService</type>
  </component>
  <component>
    <type>org.exoplatform.cs.service.TicketService</type>
  </component>
  <component>
    <type>org.exoplatform.cs.service.StatsService</type>
  </component>
  <component>
    <type>org.exoplatform.cs.dao.EnvironmentDAO</type>
  </component>
  <component>
    <type>org.exoplatform.cs.dao.SpaceDAO</type>
  </component>
  <component>
    <type>org.exoplatform.cs.dao.TypeDAO</type>
  </component>
  <component>
    <type>org.exoplatform.cs.dao.TopicDAO</type>
  </component>
  <component>
    <type>org.exoplatform.cs.dao.LogDAO</type>
  </component>
  <component>
    <type>org.exoplatform.platform.common.space.SpaceCustomizationService</type>
  </component>
  <component>
    <key>org.exoplatform.cs.injector.CSInjector</key>
    <type>org.exoplatform.cs.injector.CSInjector</type>
  </component>

  <!--
	<component>
		<type>org.exoplatform.cs.service.migration.SpaceNavAsyncMigrationService</type>
	</component>

	<component>
		<type>org.exoplatform.cs.service.migration.SpaceNavigationMigration</type>
	</component>-->

  <component>
    <type>org.exoplatform.cs.service.CSHandlerStarter</type>
    <component-plugins>
      <component-plugin>
        <name>CS Application Configuration</name>
        <set-method>setSpaceApplicationConfigPlugin</set-method>
        <type>org.exoplatform.social.core.space.SpaceApplicationConfigPlugin</type>
        <init-params>
          <object-param>
            <name>spaceHomeApplication</name>
            <description>Space Home Application</description>
            <object
                type="org.exoplatform.social.core.space.SpaceApplicationConfigPlugin$SpaceApplication">
              <field name="portletApp">
                <string>social-portlet</string>
              </field>
              <field name="portletName">
                <string>SpaceActivityStreamPortlet</string>
              </field>
              <field name="appTitle">
                <string>Home</string>
              </field>
            </object>
          </object-param>
          <object-param>
            <name>spaceApplicationListConfig</name>
            <description>space application list configuration</description>
            <object
                type="org.exoplatform.social.core.space.SpaceApplicationConfigPlugin">
              <field name="spaceApplicationList">
                <collection type="java.util.ArrayList">
                </collection>
              </field>
            </object>
          </object-param>
        </init-params>
      </component-plugin>
    </component-plugins>
  </component>
  <component>
    <key>org.exoplatform.cs.service.tickets.TicketStatusFlowService</key>
    <type>org.exoplatform.cs.service.tickets.TicketStatusFlowService</type>
  </component>
  <component>
    <key>org.exoplatform.cs.service.TicketUpdatesService</key>
    <type>org.exoplatform.cs.service.TicketUpdatesService</type>
  </component>
  <!-- Data Initialization -->
  <external-component-plugins>
    <target-component>org.exoplatform.commons.api.persistence.DataInitializer</target-component>
    <component-plugin>
      <name>CSAddonChangeLogsPlugin</name>
      <set-method>addChangeLogsPlugin</set-method>
      <type>org.exoplatform.commons.persistence.impl.ChangeLogsPlugin</type>
      <init-params>
        <values-param>
          <name>changelogs</name>
          <description>Change logs of customer space</description>
          <value>db/changelog/customer-space.db.changelog-1.0.0.xml</value>
        </values-param>
      </init-params>
    </component-plugin>
  </external-component-plugins>
  <!-- Social integration -->
  <external-component-plugins>
    <target-component>org.exoplatform.social.core.space.spi.SpaceService</target-component>
    <component-plugin>
      <name>DeleteSpaceListener</name>
      <set-method>addSpaceListener</set-method>
      <type>org.exoplatform.cs.service.listener.DeleteSpaceListener</type>
    </component-plugin>
    <component-plugin>
      <name>CSForumDataInitialize</name>
      <set-method>addSpaceListener</set-method>
      <type>org.exoplatform.cs.service.listener.CSForumDataInitializer</type>
      <init-params>
        <value-param>
          <name>portletName</name>
          <value>ForumPortlet</value>
        </value-param>
      </init-params>
    </component-plugin>
    <component-plugin>
      <name>CSForumDataInitialize</name>
      <set-method>addSpaceListener</set-method>
      <type>org.exoplatform.cs.service.listener.XMLDeploymentPlugin</type>
      <description>XML Deployment Plugin</description>
      <init-params>
        <value-param>
          <name>override</name>
          <description>indicates if this plugin will override data over legacy data, default value:false</description>
          <value>false</value>
        </value-param>
        <object-param>
          <name>Artifacts Data</name>
          <description>Deployment Descriptor</description>
          <object type="org.exoplatform.services.deployment.DeploymentDescriptor">
            <field name="target">
              <object
                  type="org.exoplatform.services.deployment.DeploymentDescriptor$Target">
                <field name="workspace">
                  <string>collaboration</string>
                </field>
                <field name="nodePath">
                  <string>/Data</string>
                </field>
              </object>
            </field>
            <field name="sourcePath">
              <string>war:/conf/customer-space/social/content/artifacts.xml</string>
            </field>
            <field name="cleanupPublication">
              <boolean>true</boolean>
            </field>
          </object>
        </object-param>
        <object-param>
          <name>Welcome Message Data</name>
          <description>Deployment Descriptor</description>
          <object type="org.exoplatform.services.deployment.DeploymentDescriptor">
            <field name="target">
              <object
                  type="org.exoplatform.services.deployment.DeploymentDescriptor$Target">
                <field name="workspace">
                  <string>collaboration</string>
                </field>
                <field name="nodePath">
                  <string>/Data</string>
                </field>
              </object>
            </field>
            <field name="sourcePath">
              <string>war:/conf/customer-space/social/content/welcome.xml</string>
            </field>
            <field name="cleanupPublication">
              <boolean>true</boolean>
            </field>
          </object>
        </object-param>
      </init-params>
    </component-plugin>
  </external-component-plugins>
  <!-- Deploy template for Content List Viewer Portlet -->
  <external-component-plugins>
    <target-component>org.exoplatform.services.cms.views.ApplicationTemplateManagerService</target-component>
    <component-plugin>
      <name>clv.templates.plugin</name>
      <set-method>addPlugin</set-method>
      <type>org.exoplatform.services.cms.views.PortletTemplatePlugin</type>
      <description>This plugin is used to import views templates for Content List Viewer</description>
      <init-params>
        <value-param>
          <name>portletName</name>
          <value>content-list-viewer</value>
        </value-param>
        <value-param>
          <name>portlet.template.path</name>
          <value>war:/conf/customer-space/wcm/artifacts/</value>
        </value-param>
        <object-param>
          <name>empty.paginator</name>
          <description>Empty paginator groovy template</description>
          <object type="org.exoplatform.services.cms.views.PortletTemplatePlugin$PortletTemplateConfig">
            <field name="templateName">
              <string>EmptyPaginator.gtmpl</string>
            </field>
            <field name="category">
              <string>paginators</string>
            </field>
          </object>
        </object-param>
      </init-params>
    </component-plugin>
  </external-component-plugins>
  <external-component-plugins>
    <target-component>org.exoplatform.social.core.space.spi.SpaceService</target-component>
    <component-plugin>
      <name>CSWikiInitializerPlugin</name>
      <set-method>registerSpaceListenerPlugin</set-method>
      <type>org.exoplatform.cs.listener.CSWikiInitializeListener</type>
    </component-plugin>
  </external-component-plugins>
  <external-component-plugins>
    <target-component>org.exoplatform.cs.service.tickets.TicketStatusFlowService</target-component>
    <component-plugin>
      <name>AddFlow</name>
      <set-method>addFlow</set-method>
      <type>org.exoplatform.cs.service.tickets.FlowPlugin</type>
      <init-params>
        <object-param>
          <name>flow</name>
          <object type="org.exoplatform.cs.service.tickets.FlowConfig">
            <field name="flow">
              <object type="org.exoplatform.cs.service.tickets.Flow">
                <field name="name">
                  <string>INCIDENT</string>
                </field>
                <field name="defaultState">
                  <string>open</string>
                </field>
                <field name="states">
                  <collection type="java.util.ArrayList">
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>open</string>
                        </field>
                        <field name="role">
                          <string>any</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>considered</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>closed</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>considered</string>
                        </field>
                        <field name="role">
                          <string>support</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>reproduced</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>notreproduced</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>resolved_wfv</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>suspended_wfi</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>closed</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>suspended_wfi</string>
                        </field>
                        <field name="role">
                          <string>support</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>open</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>reproduced</string>
                        </field>
                        <field name="role">
                          <string>support</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>inprogress</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>resolved_wfv</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>suspended_wfi</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>notreproduced</string>
                        </field>
                        <field name="role">
                          <string>support</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>considered</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>inprogress</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>resolved_wfv</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>suspended_wfi</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>inprogress</string>
                        </field>
                        <field name="role">
                          <string>support</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>resolved_maintenance</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>resolved_wfv</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>suspended_wfi</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>resolved_wfv</string>
                        </field>
                        <field name="role">
                          <string>support</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>resolved_validated</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>resolution_refused</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>resolved_maintenance</string>
                        </field>
                        <field name="role">
                          <string>support</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>resolved_validated</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>resolution_refused</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>resolved_validated</string>
                        </field>
                        <field name="role">
                          <string>customer</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>closed</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>closed</string>
                        </field>
                        <field name="role">
                          <string>any</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>reopen</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>reopen</string>
                        </field>
                        <field name="role">
                          <string>any</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>considered</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>resolved_wfv</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>suspended_wfi</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>closed</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>resolution_refused</string>
                        </field>
                        <field name="role">
                          <string>customer</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>suspended_wfi</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>considered</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>resolved_wfv</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string> </string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                  </collection>
                </field>
              </object>
            </field>
          </object>
        </object-param>
      </init-params>
    </component-plugin>
    <component-plugin>
      <name>AddFlow</name>
      <set-method>addFlow</set-method>
      <type>org.exoplatform.cs.service.tickets.FlowPlugin</type>
      <init-params>
        <object-param>
          <name>flow</name>
          <object type="org.exoplatform.cs.service.tickets.FlowConfig">
            <field name="flow">
              <object type="org.exoplatform.cs.service.tickets.Flow">
                <field name="name">
                  <string>INFORMATION</string>
                </field>
                <field name="defaultState">
                  <string>open</string>
                </field>
                <field name="states">
                  <collection type="java.util.ArrayList">
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>open</string>
                        </field>
                        <field name="role">
                          <string>any</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>considered</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>resolved_wfv</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>closed</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>considered</string>
                        </field>
                        <field name="role">
                          <string>support</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>inprogress</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>suspended_wfi</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>suspended_wfi</string>
                        </field>
                        <field name="role">
                          <string>support</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>inprogress</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>inprogress</string>
                        </field>
                        <field name="role">
                          <string>support</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>resolved_wfv</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>resolved_wfv</string>
                        </field>
                        <field name="role">
                          <string>support</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>resolved_validated</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>resolution_refused</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>resolved_validated</string>
                        </field>
                        <field name="role">
                          <string>customer</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>closed</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>resolution_refused</string>
                        </field>
                        <field name="role">
                          <string>customer</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>considered</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>resolved_wfv</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>closed</string>
                        </field>
                        <field name="role">
                          <string>support</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>reopen</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>reopen</string>
                        </field>
                        <field name="role">
                          <string>any</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>considered</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>resolved_wfv</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>closed</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string> </string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                  </collection>
                </field>
              </object>
            </field>
          </object>
        </object-param>
      </init-params>
    </component-plugin>
    <component-plugin>
      <name>AddFlow</name>
      <set-method>addFlow</set-method>
      <type>org.exoplatform.cs.service.tickets.FlowPlugin</type>
      <init-params>
        <object-param>
          <name>flow</name>
          <object type="org.exoplatform.cs.service.tickets.FlowConfig">
            <field name="flow">
              <object type="org.exoplatform.cs.service.tickets.Flow">
                <field name="name">
                  <string>SIMPLE</string>
                </field>
                <field name="defaultState">
                  <string>new</string>
                </field>
                <field name="states">
                  <collection type="java.util.ArrayList">
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>new</string>
                        </field>
                        <field name="role">
                          <string>any</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                            <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                            <field name="state">
                              <string>open</string>
                            </field>
                              <field name="reason">
                                <collection type="java.util.ArrayList">
                                  <value>
                                    <string>assigned</string>
                                  </value>
                                </collection>
                            </field>
                            </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>open</string>
                        </field>
                        <field name="role">
                          <string>any</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>inprogress</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string>work_started</string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>suspended</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string>need_info</string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>resolved</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string>submit_solution</string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                              <value>
                                  <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                      <field name="state">
                                          <string>closed</string>
                                      </field>
                                      <field name="reason">
                                        <collection type="java.util.ArrayList">
                                          <value>
                                            <string>unqualified</string>
                                          </value>
                                        </collection>
                                      </field>
                                  </object>
                              </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>suspended</string>
                        </field>
                        <field name="role">
                          <string>any</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>closed</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string>abandon</string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
                            <value>
                              <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                <field name="state">
                                  <string>inprogress</string>
                                </field>
                                <field name="reason">
                                  <collection type="java.util.ArrayList">
                                    <value>
                                      <string>resume_work</string>
                                    </value>
                                  </collection>
                                </field>
                              </object>
                            </value>
		                     <value>
                               <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                 <field name="state">
                                   <string>resolved</string>
                                 </field>
                                 <field name="reason">
                                   <collection type="java.util.ArrayList">
                                     <value>
                                       <string>submit_solution</string>
                                     </value>
                                   </collection>
                                 </field>
                               </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>inprogress</string>
                        </field>
                        <field name="role">
                          <string>any</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                            <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                 <field name="state">
                                     <string>suspended</string>
                                  </field>
                                   <field name="reason">
                                     <collection type="java.util.ArrayList">
                                       <value>
                                         <string>pause</string>
                                       </value>
                                     </collection>
                                    </field>
                              </object>
                            </value>
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>resolved</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string>submit_solution</string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
	                <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>resolved</string>
                        </field>
                        <field name="role">
                          <string>any</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>open</string>
                                    </field>

                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                        <string>reopen</string>
                                        </value>
                                        <value>
                                        <string>resolution_refused</string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                            <value>
                                <object type="org.exoplatform.cs.service.tickets.FlowStateSuccessor">
                                    <field name="state">
                                        <string>closed</string>
                                    </field>
                                    <field name="reason">
                                      <collection type="java.util.ArrayList">
                                        <value>
                                          <string>resolution_accepted</string>
                                        </value>
                                        <value>
                                          <string>auto_close</string>
                                        </value>
                                      </collection>
                                    </field>
                                </object>
                            </value>
                          </collection>
                        </field>
                      </object>
                    </value>
                    <value>
                      <object type="org.exoplatform.cs.service.tickets.FlowState">
                        <field name="state">
                          <string>closed</string>
                        </field>
                        <field name="role">
                          <string>any</string>
                        </field>
                        <field name="successors">
                          <collection type="java.util.ArrayList">

                          </collection>
                        </field>
                      </object>
                    </value>
                  </collection>
                </field>
              </object>
            </field>
          </object>
        </object-param>
      </init-params>
    </component-plugin>
  </external-component-plugins>
  <external-component-plugins>
    <target-component>org.exoplatform.services.listener.ListenerService</target-component>
    <component-plugin>
      <name>exo.addons.cs.ticket.updated</name>
      <set-method>addListener</set-method>
      <type>org.exoplatform.cs.service.listener.TicketUpdatedLogListener</type>
    </component-plugin>
  </external-component-plugins>
  <external-component-plugins>
    <target-component>org.exoplatform.services.listener.ListenerService</target-component>
    <component-plugin>
      <name>exo.addons.cs.ticket.created</name>
      <set-method>addListener</set-method>
      <type>org.exoplatform.cs.service.listener.TicketCreatedLogListener</type>
    </component-plugin>
  </external-component-plugins>
  <external-component-plugins>
    <target-component>org.exoplatform.forum.service.ForumService</target-component>
    <component-plugin>
      <name>ForumEventListener</name>
      <set-method>addListenerPlugin</set-method>
      <type>org.exoplatform.cs.listener.ForumListener</type>
      <init-params>
        <value-param>
          <name>support.group.name</name>
          <value>${exo.addon.cs.support.group.name:support-team}</value>
        </value-param>
        <value-param>
          <name>all.employee.group.name</name>
          <value>${exo.addon.cs.all.employee.group.name:/spaces/exo_employees}</value>
        </value-param>
      </init-params>
    </component-plugin>
  </external-component-plugins>
 <!-- Job for fixing Title for forum topics -->
 <!--
  <external-component-plugins>
    <target-component>org.exoplatform.services.scheduler.JobSchedulerService</target-component>
    <component-plugin>
      <name>FixCreationDateAndTitlesForTopics</name>
      <set-method>addPeriodJob</set-method>
      <type>org.exoplatform.services.scheduler.PeriodJob</type>
      <description>add a FixCreationDateAndTitlesForTopics job to the JobSchedulerService</description>
      <init-params>
        <properties-param>
          <name>job.info</name>
          <description>save the Forums Weekly Statistic data periodically</description>
          <property name="jobName" value="periodically"/>
          <property name="groupName" value="Customer-space"/>
          <property name="job" value="org.exoplatform.cs.job.UpdateTopicEntityJob"/>
          <property name="repeatCount" value="0"/>
          <property name="period" value="${exo.cs.job.update.topic.entity.period:600000}"/>
          <property name="startTime" value="+0"/>
          <property name="endTime" value=""/>
        </properties-param>
      </init-params>
    </component-plugin>
  </external-component-plugins>
  -->

  <!-- Job to collect daily stats -->


<!--

  <external-component-plugins>
    <target-component>org.exoplatform.services.scheduler.JobSchedulerService</target-component>
    <component-plugin>
      <name>AddCronJob</name>
      <set-method>addCronJob</set-method>
      <type>org.exoplatform.services.scheduler.CronJob</type>
      <description>Collect daily Statistic</description>
      <init-params>
        <properties-param>
          <name>cronjob.info</name>
          <description>Configuration for Stats Collector Job </description>
          <property name="jobName" value="StatsCollectorJob"/>
          <property name="groupName" value="group"/>
          <property name="job" value="org.exoplatform.cs.job.StatsCollectorJob"/>
          <property name="expression" value="0 0 23 * * ?"/>
          &lt;!&ndash;<property name="expression" value="0 */2 * ? * *"/>&ndash;&gt;
        </properties-param>
      </init-params>
    </component-plugin>
  </external-component-plugins>

-->

  <external-component-plugins>
    <target-component>org.exoplatform.services.scheduler.JobSchedulerService</target-component>
    <component-plugin>
      <name>AddCronJob</name>
      <set-method>addCronJob</set-method>
      <type>org.exoplatform.services.scheduler.CronJob</type>
      <description></description>
      <init-params>
        <properties-param>
          <name>cronjob.info</name>
          <description>Configuration for Reminder Notification Job </description>
          <property name="jobName" value="ReminderNotificationJob"/>
          <property name="groupName" value="group"/>
          <property name="job" value="org.exoplatform.cs.job.ReminderNotificationJob"/>
          <property name="expression" value="0 0 6 * * ?"/>
          <!--<property name="expression" value="0 */5 * ? * *"/>-->
        </properties-param>
      </init-params>
    </component-plugin>
  </external-component-plugins>

  <external-component-plugins>
    <target-component>org.exoplatform.services.scheduler.JobSchedulerService</target-component>
    <component-plugin>
      <name>AddCronJob</name>
      <set-method>addCronJob</set-method>
      <type>org.exoplatform.services.scheduler.CronJob</type>
      <description></description>
      <init-params>
        <properties-param>
          <name>cronjob.info</name>
          <description>Configuration for Auto Assign Job </description>
          <property name="jobName" value="AutoAssignJob"/>
          <property name="groupName" value="group"/>
          <property name="job" value="org.exoplatform.cs.job.AutoAssignJob"/>
          <property name="expression" value="0 */15 * ? * *"/>
        </properties-param>
      </init-params>
    </component-plugin>
  </external-component-plugins>


  <external-component-plugins>
  <target-component>org.exoplatform.web.WebAppController</target-component>
  <component-plugin>
    <name>CustomerTicketsHandler</name>
    <set-method>register</set-method>
    <type>org.exoplatform.cs.portal.handler.CustomerSpaceHandler</type>
  </component-plugin>
  </external-component-plugins>
  <external-component-plugins>
    <target-component>org.exoplatform.services.organization.OrganizationService</target-component>
    <component-plugin>
      <name>cs.update.membership</name>
      <set-method>addListenerPlugin</set-method>
      <type>org.exoplatform.cs.listener.CSMemebrshipListener</type>
      <description>this listener add/remove a user from all customer spaces when he is added/removed from support team group</description>
    </component-plugin>
  </external-component-plugins>

  <import>jar:/conf/portal/cs-notification-plugin.xml</import>
  <import>jar:/conf/portal/subscription-configuration.xml</import>
</configuration>
