User:Clément Combier: Difference between revisions

    From UNITApedia
    (Replaced content with "LCC (talk) 14:27, 28 May 2024 (UTC)")
    Tags: Replaced Manual revert
    No edit summary
    Line 1: Line 1:
    == Strapi Events Raw JSON ==
    <!-- 1) Fetch the data with #get_web_data -->
    {{#get_web_data:
      |url    = https://unitapedia.univ-unita.eu/strapi/api/events?populate=events,SupplementaryInfo
      |format  = json
      |debug  = 1
    }}
    <!-- 2) Display the raw JSON output -->
    == Raw JSON Output ==
    {{#external_data_debug}}
    == Strapi Events Display ==
    <!-- 1) Fetch the data with #get_web_data -->
    {{#get_web_data:
      |url    = https://unitapedia.univ-unita.eu/strapi/api/events?populate=events,SupplementaryInfo
      |format  = json
      |data    =
        EventID      = data.1.id,
        CreatedAt    = data.1.attributes.createdAt,
        UpdatedAt    = data.1.attributes.updatedAt,
        PublishedAt  = data.1.attributes.publishedAt,
        EventType    = data.1.attributes.events.1.Type,
        Participants  = data.1.attributes.events.1.Participants,
        Certificate  = data.1.attributes.events.1.Certificate,
        Category      = data.1.attributes.events.1.Category,
        EventDate    = data.1.attributes.events.1.Date,
        Publication  = data.1.attributes.SupplementaryInfo.1.Publication,
        Seminars      = data.1.attributes.SupplementaryInfo.1.Seminars,
        Workshops    = data.1.attributes.SupplementaryInfo.1.Workshops
      |debug  = 1
    }}
    <!-- 2) Display the data -->
    {{#if:{{#external_value:EventID}} |
      === Event Details ===
      * **Event ID:** {{#external_value:EventID}}
      * **Created At:** {{#external_value:CreatedAt}}
      * **Updated At:** {{#external_value:UpdatedAt}}
      * **Published At:** {{#external_value:PublishedAt}}
      * **Type:** {{#external_value:EventType}}
      * **Participants:** {{#external_value:Participants}}
      * **Certificate:** {{#external_value:Certificate}}
      * **Category:** {{#external_value:Category}}
      * **Date:** {{#external_value:EventDate}}
      * **Publication:** {{#external_value:Publication}}
      * **Seminars:** {{#external_value:Seminars}}
      * **Workshops:** {{#external_value:Workshops}}
    |
      * **Error:** Unable to retrieve event data. Check the debug output below.
    }}
    == Debug Output ==
    {{#external_data_debug}}
    [[User:Clément Combier|LCC]] ([[User talk:Clément Combier|talk]]) 14:27, 28 May 2024 (UTC)
    [[User:Clément Combier|LCC]] ([[User talk:Clément Combier|talk]]) 14:27, 28 May 2024 (UTC)

    Revision as of 08:11, 28 January 2025

    Strapi Events Raw JSON

    Raw JSON Output

    {{#external_data_debug}}

    Strapi Events Display

    Event Details

     * **Event ID:** Error: no local variable "EventID" has been set.
     * **Created At:** Error: no local variable "CreatedAt" has been set.
     * **Updated At:** Error: no local variable "UpdatedAt" has been set.
     * **Published At:** Error: no local variable "PublishedAt" has been set.
    
     * **Type:** Error: no local variable "EventType" has been set.
     * **Participants:** Error: no local variable "Participants" has been set.
     * **Certificate:** Error: no local variable "Certificate" has been set.
     * **Category:** Error: no local variable "Category" has been set.
     * **Date:** Error: no local variable "EventDate" has been set.
    
     * **Publication:** Error: no local variable "Publication" has been set.
     * **Seminars:** Error: no local variable "Seminars" has been set.
     * **Workshops:** Error: no local variable "Workshops" has been set.
    

    Debug Output

    {{#external_data_debug}}


    LCC (talk) 14:27, 28 May 2024 (UTC)