diff --git a/src/core/xsl/entity.xsl b/src/core/xsl/entity.xsl index 533b09abd71f7bebeb7602906a053d10bf85b907..4d14262a1f6b7e923567b8ebc358c15a77c958e2 100644 --- a/src/core/xsl/entity.xsl +++ b/src/core/xsl/entity.xsl @@ -52,7 +52,7 @@ <xsl:template match="@id" mode="backreference-link"> <a class="caosdb-backref-link btn caosdb-id-button" title="Find all entities which reference this one."> <xsl:attribute name="href"> - <xsl:value-of select="concat($entitypath, '?P=0L10&query=FIND+Entity+which+references+', current())"/> + <xsl:value-of select="concat($entitypath, '?P=0L10&query=FIND+Entity+which+references+%22', current(), '%22')"/> </xsl:attribute> <span class="bg-dark badge d-none d-sm-inline"> <i class="bi-link"></i> References diff --git a/test/core/js/modules/entity.xsl.js b/test/core/js/modules/entity.xsl.js index feb543620ddfdb77b8457bb5c9125799ffeaba74..7604d38c2e898e3dd3d9c5f0d207d3169d0752bc 100644 --- a/test/core/js/modules/entity.xsl.js +++ b/test/core/js/modules/entity.xsl.js @@ -108,7 +108,7 @@ QUnit.test("back references", function(assert) { var link = xslt(xml, xsl).firstChild; assert.equal(link.tagName, "A", "is a link"); - assert.equal(link.getAttribute("href"), "/entitypath/?P=0L10&query=FIND+Entity+which+references+265", "query correct."); + assert.equal(link.getAttribute("href"), "/entitypath/?P=0L10&query=FIND+Entity+which+references+%22265%22", "query correct."); }); QUnit.test("Entities have a caosdb-annotation-section", function(assert) {