<?xml version="1.0" encoding="UTF-8"?>
<changelog xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="./schema.xsd">

    <changeset id="WAR-511_add_profiles_and_vendor_access:1" author="menger" run-on-change="true">
        <cypherquery>
            <![CDATA[

            MATCH (identity:Identity {email: 'joe.shergold@kollectivenr.com'})
            MERGE (increment:IncrementId {nodeName: 'Profile'})
                ON CREATE SET increment.id = 2
                ON MATCH SET increment.id = increment.id + 1
            CREATE (profile:Profile {
                profileId: (increment.id - 1),
                profileType: 'MoneyhubProfile',
                profileName: identity.name,
                brand: identity.defaultBrand,
                fullCatalogAccess: true,
                roles: ['accounting'],
                uuid: apoc.create.uuid()
            })
            MERGE (identity)-[:HAS_PROFILE]->(profile)
            WITH profile
            MATCH (vendor:Vendor {id: '*'})
            MERGE (profile)-[:HAS_ACCESS_TO]->(vendor)

            ]]>
        </cypherquery>
    </changeset>

    <changeset id="WAR-511_add_profiles_and_vendor_access:2" author="menger" run-on-change="true">
        <cypherquery>
            <![CDATA[

            MATCH (identity:Identity {email: 'debbieanne.odonovan@kollectivenr.com'})-[:HAS_PROFILE]->(profile:Profile {profileType: 'MoneyhubProfile'}),
                (vendor:Vendor {id: '*'})
            MERGE (profile)-[:HAS_ACCESS_TO]->(vendor)

            ]]>
        </cypherquery>
    </changeset>

    <changeset id="WAR-511_add_profiles_and_vendor_access:3" author="menger" run-on-change="true">
        <cypherquery>
            <![CDATA[

            MATCH (identity:Identity {email: 'elizabete.kolbjer@awal.com'})-[:HAS_PROFILE]->(profile:Profile {profileType: 'MoneyhubProfile'}),
                (vendor:Vendor {id: '*'})
            MERGE (profile)-[:HAS_ACCESS_TO]->(vendor)

            ]]>
        </cypherquery>
    </changeset>

    <changeset id="WAR-511_add_profiles_and_vendor_access:4" author="menger" run-on-change="true">
        <cypherquery>
            <![CDATA[

            MATCH (identity:Identity {email: 'gemma.hall@awal.com'})-[:HAS_PROFILE]->(profile:Profile {profileType: 'MoneyhubProfile'}),
                (vendor:Vendor {id: '*'})
            MERGE (profile)-[:HAS_ACCESS_TO]->(vendor)

            ]]>
        </cypherquery>
    </changeset>

    <changeset id="WAR-511_add_profiles_and_vendor_access:5" author="menger" run-on-change="true">
        <cypherquery>
            <![CDATA[

            MATCH (identity:Identity {email: 'heide.avent@kollectivenr.com'})-[:HAS_PROFILE]->(profile:Profile {profileType: 'MoneyhubProfile'}),
                (vendor:Vendor {id: '*'})
            MERGE (profile)-[:HAS_ACCESS_TO]->(vendor)

            ]]>
        </cypherquery>
    </changeset>

    <changeset id="WAR-511_add_profiles_and_vendor_access:6" author="menger" run-on-change="true">
        <cypherquery>
            <![CDATA[

            MATCH (identity:Identity {email: 'henry.riggs@kollectivenr.com'})-[:HAS_PROFILE]->(profile:Profile {profileType: 'MoneyhubProfile'}),
                (vendor:Vendor {id: '*'})
            MERGE (profile)-[:HAS_ACCESS_TO]->(vendor)

            ]]>
        </cypherquery>
    </changeset>

    <changeset id="WAR-511_add_profiles_and_vendor_access:7" author="menger" run-on-change="true">
        <cypherquery>
            <![CDATA[

            MATCH (identity:Identity {email: 'jessica.farquharson@awal.com'})-[:HAS_PROFILE]->(profile:Profile {profileType: 'MoneyhubProfile'}),
                (vendor:Vendor {id: '*'})
            MERGE (profile)-[:HAS_ACCESS_TO]->(vendor)

            ]]>
        </cypherquery>
    </changeset>

    <changeset id="WAR-511_add_profiles_and_vendor_access:8" author="menger" run-on-change="true">
        <cypherquery>
            <![CDATA[

            MATCH (identity:Identity {email: 'lewis.white@kollectivenr.com'})-[:HAS_PROFILE]->(profile:Profile {profileType: 'MoneyhubProfile'}),
                (vendor:Vendor {id: '*'})
            MERGE (profile)-[:HAS_ACCESS_TO]->(vendor)

            ]]>
        </cypherquery>
    </changeset>

    <changeset id="WAR-511_add_profiles_and_vendor_access:9" author="menger" run-on-change="true">
        <cypherquery>
            <![CDATA[

            MATCH (identity:Identity {email: 'matthew.osborne@awal.com'})-[:HAS_PROFILE]->(profile:Profile {profileType: 'MoneyhubProfile'}),
                (vendor:Vendor {id: '*'})
            MERGE (profile)-[:HAS_ACCESS_TO]->(vendor)

            ]]>
        </cypherquery>
    </changeset>

    <changeset id="WAR-511_add_profiles_and_vendor_access:10" author="menger" run-on-change="true">
        <cypherquery>
            <![CDATA[

            MATCH (identity:Identity {email: 'natalie.parsons@kollectivenr.com'})-[:HAS_PROFILE]->(profile:Profile {profileType: 'MoneyhubProfile'}),
                (vendor:Vendor {id: '*'})
            MERGE (profile)-[:HAS_ACCESS_TO]->(vendor)

            ]]>
        </cypherquery>
    </changeset>

    <changeset id="WAR-511_add_profiles_and_vendor_access:11" author="menger" run-on-change="true">
        <cypherquery>
            <![CDATA[

            MATCH (identity:Identity {email: 'sam.thomas@awal.com'})-[:HAS_PROFILE]->(profile:Profile {profileType: 'MoneyhubProfile'}),
                (vendor:Vendor {id: '*'})
            MERGE (profile)-[:HAS_ACCESS_TO]->(vendor)

            ]]>
        </cypherquery>
    </changeset>

    <changeset id="WAR-511_add_profiles_and_vendor_access:12" author="menger" run-on-change="true">
        <cypherquery>
            <![CDATA[

            MATCH (identity:Identity {email: 'tom.doherty@kollectivenr.com'})-[:HAS_PROFILE]->(profile:Profile {profileType: 'MoneyhubProfile'}),
                (vendor:Vendor {id: '*'})
            MERGE (profile)-[:HAS_ACCESS_TO]->(vendor)

            ]]>
        </cypherquery>
    </changeset>

</changelog>
