Calling an interface using card as button pattern

Hi There,

I’m trying to use card as buttons pattern to call an interface.

Interface is having gridfield used inside a!headerContentLayout() to display task lists.

However, I’m not sure how can I call call this interface using card as buttons pattern. Is that a right way of calling ?

Please do let me know if you need any more details.

  Discussion posts and replies are publicly visible

Parents Reply
  • 0
    Certified Lead Developer
    in reply to beenav6123

    Check this 

    a!localVariables(
      local!showNewInterface,
      {
        
        a!cardChoiceField(
          label: "Card Choices",
          data: {
            a!map(id: 1, icon: "smile-o", primaryText: "Good", secondaryText: "I enjoyed my experience!", showTask:true()),
            a!map(id: 2, icon: "meh-o", primaryText: "Neutral", secondaryText: "My experience was okay.", showTask:false()),
            
          },
          cardTemplate: a!cardTemplateTile(
            id: fv!data.id,
            primaryText: fv!data.primaryText,
            secondaryText: fv!data.secondaryText,
            icon: fv!data.icon
          ),
          value: local!showNewInterface,
          saveInto: a!save(
            local!showNewInterface,
            save!value
          ),
          maxSelections: 1,
          validations: {}
        ),
        choose(
          local!showNewInterface,
          a!cardLayout(
            contents: a!richTextDisplayField(
              label: "I am happy Card"
            ),
    
          ),
          a!cardLayout(
            contents: a!richTextDisplayField(
              label: "I am neutral Card"
            )
          )
        )
      }
    )

Children