Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Aadarsh Dubey 17 posts 141 karma points
    Apr 11, 2024 @ 09:45
    Aadarsh Dubey
    0

    Carousel in Block Grid

    I have to create Carousels with help of Blockgrid so i have done the following process

    First i have created 1 element type named Carousel items in which i have property Title and Image

    enter image description here

    now i have created 1 data type with block list with carousel item block inside it

    enter image description here

    Now i have created i more element type named carousel in which i have 1 property field in which i am using this block list data type

    enter image description here

    now i am using this carousel as root in my block grid content

    enter image description here

    i am able to add multiple carousel items in it as shown in image

    enter image description here

    my data is coming in Carousel enter image description here

    but i am unable to show that image and title over here enter image description here

    this happens because i am wrinting the code to display title and image but my carousel is expecting code for carouselitems properties in which i have use data type of Block list of carousel properties

    so what will be the way to display that property

    Thanks and Regards Aadarsh

  • Huw Reddick 1932 posts 6722 karma points MVP 2x c-trib
    Apr 11, 2024 @ 10:23
    Huw Reddick
    1

    Hi Aadarsh,

    I think you probably need to create a custom template for your carousel to do this

  • Aadarsh Dubey 17 posts 141 karma points
    Apr 11, 2024 @ 10:28
    Aadarsh Dubey
    0

    I have already created my custom html for it also i am pointing it in my Advanced option in element type but unable to fetch the data

    this is my code

    enter image description here

    Please guide on this if any changes

  • Huw Reddick 1932 posts 6722 karma points MVP 2x c-trib
    Apr 11, 2024 @ 13:05
    Huw Reddick
    100

    At a guess, it doesn't know how to render carouselItems.

    Personally I wouldn't do it using an angular template, I would install the block preview package, you can then create a razor template to display your carousel items which is a lot simpler to deal with.

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies