<configure
    xmlns="http://namespaces.zope.org/zope"
    xmlns:five="http://namespaces.zope.org/five"
    xmlns:genericsetup="http://namespaces.zope.org/genericsetup"
    xmlns:browser="http://namespaces.zope.org/browser"
    xmlns:i18n="http://namespaces.zope.org/i18n"
    xmlns:pp="http://namespaces.zopyx.com/pp"
    xmlns:plone="http://namespaces.plone.org/plone"
    >

    <browser:page
        name="xmldirector-bookalope-settings"
        for="Products.CMFPlone.interfaces.IPloneSiteRoot"
        class=".controlpanel.BookalopeSettingsControlPanel"
        permission="cmf.ManagePortal"
    />

    <browser:page
        name="xmldirector-bookalope"
        for="xmldirector.plonecore.connector.IConnector"
        class=".view.Bookalope"
        template="bookalope.pt"
        permission="cmf.ModifyPortalContent"
    />

    <browser:page
        name="bookalope-upload-source"
        for="xmldirector.plonecore.connector.IConnector"
        class=".view.Bookalope"
        attribute="upload_source"
        permission="cmf.ModifyPortalContent"
    />

    <browser:page
        name="bookalope-upload-cover"
        for="xmldirector.plonecore.connector.IConnector"
        class=".view.Bookalope"
        attribute="upload_cover"
        permission="cmf.ModifyPortalContent"
    />

    <browser:page
        name="bookalope-cleanup"
        for="xmldirector.plonecore.connector.IConnector"
        class=".view.Bookalope"
        attribute="cleanup_generated_files"
        permission="cmf.ModifyPortalContent"
    />
    
    <browser:page
        name="bookalope-cleanup-sources"
        for="xmldirector.plonecore.connector.IConnector"
        class=".view.Bookalope"
        attribute="cleanup_source_files"
        permission="cmf.ModifyPortalContent"
    />

    <browser:page
        name="bookalope-cleanup-covers"
        for="xmldirector.plonecore.connector.IConnector"
        class=".view.Bookalope"
        attribute="cleanup_cover_files"
        permission="cmf.ModifyPortalContent"
    />
    
    <browser:page
        name="bookalope-convert"
        for="xmldirector.plonecore.connector.IConnector"
        class=".view.Bookalope"
        attribute="convert"
        permission="cmf.ModifyPortalContent"
    />

    <plone:service
      method="POST"
        permission="cmf.ModifyPortalContent"
        for="xmldirector.plonecore.connector.IConnector"
        factory=".restapi.api_convert_bookalope"
        name="xmldirector-convert-bookalope"
    />

</configure>
