Skip to content

Commit

Permalink
MIR-1352 Use mycreo text editor for editing xml documents
Browse files Browse the repository at this point in the history
  • Loading branch information
Possommi committed Sep 6, 2024
1 parent e643167 commit 489ef80
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 12 deletions.
4 changes: 2 additions & 2 deletions mir-module/src/main/resources/actionmappings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
<when condition="(group = admin) or (group = editor)" url="/servlets/MCRLockServlet?url=/editor/editor-admins.xed" />
</action>
<action action="update-xml">
<when condition="(group = admin)" url="/servlets/MCRLockServlet?url=/editor/editor-xml.xed" />
<when condition="(group = admin)" url="/modules/webtools/texteditor/objects/" />
</action>
</collection>
<collection name="lecture">
Expand All @@ -49,4 +49,4 @@
<when condition="true" url="/servlets/MCRLoginServlet?url=MCRActionMappingServlet/lecture/create-child" />
</action>
</collection>
</actionmappings>
</actionmappings>
15 changes: 5 additions & 10 deletions mir-module/src/main/resources/xsl/modsdetails-external.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -400,12 +400,6 @@
<xsl:variable name="adminEditURL">
<xsl:value-of select="actionmapping:getURLforID('update-admin',$id,true())" xmlns:actionmapping="xalan://org.mycore.wfc.actionmapping.MCRURLRetriever" />
</xsl:variable>
<xsl:variable name="editURL_allMods">
<xsl:call-template name="mods.getObjectEditURL">
<xsl:with-param name="id" select="$id" />
<xsl:with-param name="layout" select="'all'" />
</xsl:call-template>
</xsl:variable>
<xsl:variable name="copyURL">
<xsl:value-of select="actionmapping:getURLforID('create-copy',$id,true())" xmlns:actionmapping="xalan://org.mycore.wfc.actionmapping.MCRURLRetriever" />
</xsl:variable>
Expand All @@ -423,8 +417,7 @@
</xsl:when>
<xsl:otherwise>
<a class="btn btn-primary btn-sm w-100"
href="{$ServletsBaseURL}MCRBasketServlet{$HttpSession}?type={$basketType}&amp;action=add&amp;redirect={encoder:encode($RequestURL)}&amp;id={/mycoreobject/@ID}&amp;uri=mcrobject:{/mycoreobject/@ID}"
>
href="{$ServletsBaseURL}MCRBasketServlet{$HttpSession}?type={$basketType}&amp;action=add&amp;redirect={encoder:encode($RequestURL)}&amp;id={/mycoreobject/@ID}&amp;uri=mcrobject:{/mycoreobject/@ID}">
<i class="fas fa-plus">
<xsl:value-of select="' '" />
</i>
Expand Down Expand Up @@ -572,9 +565,11 @@
</xsl:choose>
</li>
</xsl:if>
<xsl:if test="string-length($editURL_allMods) &gt; 0">

<xsl:variable name="edit-all-mods-url" select="actionmapping:getURLforID('update-xml', $id, true())" xmlns:actionmapping="xalan://org.mycore.wfc.actionmapping.MCRURLRetriever"/>
<xsl:if test="string-length($edit-all-mods-url) &gt; 0">
<li>
<a href="{$editURL_allMods}" class="dropdown-item">
<a href="{$edit-all-mods-url}{$id}" class="dropdown-item">
<xsl:value-of select="i18n:translate('component.mods.object.editAllModsXML')" />
</a>
</li>
Expand Down

0 comments on commit 489ef80

Please sign in to comment.