SemanticMediaWiki / SemanticResultFormats

Provides additional visualizations (result formats) for Semantic MediaWiki
https://www.semantic-mediawiki.org/wiki/Extension:Semantic_Result_Formats
Other
45 stars 75 forks source link

[eventcalendar] fails when properties have a preferred label #764

Closed krabina closed 1 year ago

krabina commented 1 year ago

Setup

Issue

A working eventcalendar fails to display correctly (only shows the header) as soon as a property is present in the printout that has a preferred property label set. If you remove the "has preferred property label" statement, the exact same query is working again.

Steps to reproduce

  1. Create a working example for an eventcalendar
  2. Add some printout property
  3. add has preferred property label statement to a property used in the query

Expected result: ... eventcalendar should show and display the property in the defined label

Observed result: ... eventcalender only showsl the header, without and days or weeks in the month or week view, only displays something when you switch to "day"

Following message in the browser console:

Uncaught TypeError: list[property] is undefined
    getTypeId extensions/SemanticResultFormats/resources/ext.srf.api.results.js?ba572:138
    normalize extensions/SemanticResultFormats/resources/ext.srf.api.query.js?d13fd:169
    each jQuery
    normalize extensions/SemanticResultFormats/resources/ext.srf.api.query.js?d13fd:163
    type extensions/SemanticResultFormats/resources/ext.srf.api.query.js?d13fd:188
    init extensions/SemanticResultFormats/formats/calendar/resources/ext.srf.formats.eventcalendar.js?d3a86:787
    <anonymous> extensions/SemanticResultFormats/formats/calendar/resources/ext.srf.formats.eventcalendar.js?d3a86:1102
    jQuery 4
        fire
        fireWith
        tuple[0]
        using
    enqueue load.php?debug=true&lang=de&modules=startup&only=scripts&raw=1&skin=chameleon:1284
    using jQuery
    <anonymous> extensions/SemanticResultFormats/formats/calendar/resources/ext.srf.formats.eventcalendar.js?d3a86:1101
    jQuery 2
        each
        each
    <anonymous> extensions/SemanticResultFormats/formats/calendar/resources/ext.srf.formats.eventcalendar.js?d3a86:1047
    jQuery 2
        mightThrow
        process
ext.srf.api.results.js:138:6
    getTypeId extensions/SemanticResultFormats/resources/ext.srf.api.results.js?ba572:138
    normalize extensions/SemanticResultFormats/resources/ext.srf.api.query.js?d13fd:169
    each jQuery
    normalize extensions/SemanticResultFormats/resources/ext.srf.api.query.js?d13fd:163
    type extensions/SemanticResultFormats/resources/ext.srf.api.query.js?d13fd:188
    init extensions/SemanticResultFormats/formats/calendar/resources/ext.srf.formats.eventcalendar.js?d3a86:787
    <anonymous> extensions/SemanticResultFormats/formats/calendar/resources/ext.srf.formats.eventcalendar.js?d3a86:1102
    jQuery 4
        fire
        fireWith
        tuple[0]
        using
    enqueue load.php?debug=true&lang=de&modules=startup&only=scripts&raw=1&skin=chameleon:1284
    using jQuery
    <anonymous> extensions/SemanticResultFormats/formats/calendar/resources/ext.srf.formats.eventcalendar.js?d3a86:1101
    jQuery 2
        each
        each
    <anonymous> extensions/SemanticResultFormats/formats/calendar/resources/ext.srf.formats.eventcalendar.js?d3a86:1047
    jQuery 2
        mightThrow
        process
krabina commented 1 year ago

https://sandbox.semantic-mediawiki.net/wiki/Issue/SRF/764