• Kalidas Ponraj
  • 5 Points
  • Member since 2018

  • Chatter
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
  • 2
I'm stuck on step #2 of Einstein Analytics and Discovery Insights Specialist superbadge.  I'm getting this warning while checking the challenge:
Challenge #2 Not complete
The step "Churn Tenure' is in compact form, so the filter values need to be specifed as a minimum and maximum
The static step that feeds has the following the value:
"Tenure_Length": {
                "broadcastFacet": false,
                "label": "Tenure Length",
                "selectMode": "single",
                "type": "staticflex",
                "values": [
                        "display": "High Risk",
                        "value": "1 to 12 months",
                        "min": 1,
                        "max": 12

I'm using selection binding for min and max values.  The dashboard is correctly filtering:
User-added image
User-added image
Any ideas? 
I've tried a non-compact form step where I inject a saql fragment into the query, as well as where I inject min/max values using a range filter serialization...All these efforts end in the same challenge failure message.

Any help/suggesitions are welcome!
Hi Friends, 
I'm struggling with some of the tasks here in the super badge. Please, can you share me a source code? I will start from scratch again. I have created multiple trailhead playgrounds still messed up somehow. Here is my current error "Challenge Not yet complete... here's what's wrong: 
The BoatSearchForm component is missing a lightning
: select component. Double check the requirements and try again." even though I have above component in my code list. 
I will tell you what I did so far for this task.
1. Created mentioned custom objects in the new Trailhead Playground org with the relationships and all. 
2. Developed some of the code. Please check the below code.

<aura:component implements="force:appHostable,flexipage:availableForAllPageTypes" access="global" >
<lightning:card title="Find a Boat" class="slds-m-top_10px" >
     <c:BoatSearchForm />
<lightning:card title="Matching Boats" >
     <c:BoatSearchResults /> 
<aura:handler name="formsubmit"



<aura:component implements="force:appHostable,flexipage:availableForAllPageTypes" 
                access="global" controller="BoatSearchResults">
    <aura:handler name="init" action="{!c.doSearch}" value="{!this}"/>
    <aura:attribute name="boatTypeId" type="String" />
    <aura:attribute name="boats" type="Boat__c[]" />  
    <!--<aura:method name="search" description="Sample method with parameter">
        <aura:attribute name="boatTypeId" type="String"  />
    <!-- set up the aura:method for search -->
    <aura:method name="search" description="accepts boatTypeId
            and executes search that refreshes the boats attribute">
        <aura:attribute name="boatTypeId" type="Id"/>
    <!-- Display errors, if any -->
    <aura:if isTrue="{!not(empty(v.errorString))}">
        <div class="recordError">
            <ui:message title="Error" severity="error" closable="true">
    <aura:if isTrue="{!not(empty(v.boats))}">
        <lightning:layout multipleRows="true" horizontalAlign="center">
                <aura:iteration items="{!v.boats}" var="boatVar">
                    <lightning:layoutItem flexibility="grow"  class="slds-m-right_small" >   
                        <c:BoatTile boat="{!boatVar}"/>
         <aura:set attribute="else">
            <div class="slds-align_absolute-center">No boats found</div>

<aura:component implements="force:appHostable,flexipage:availableForAllPageTypes" controller="BoatSearchFormController" >
    <aura:handler name="formsubmit"
    <aura:attribute name="searchOptions" type='String[]' default='All'/>
    <aura:attribute name='searchOptionToIdMap' type='Map' default="{All:''}" />
    <aura:attribute name='showNewButton' type='Boolean' default='false'/>

    <lightning:layout horizontalAlign="center"   >

       <lightning:layoutItem class="slds-grid_vertical-align-center" >

           <lightning:select aura:id='typeSelect' name='selectItem' label='' onchange=''>
             <aura:iteration items='{!v.searchOptions}' var='option'>
                 <option value='{!option}' text='{!option}'></option>

       <lightning:layoutItem class="slds-grid_vertical-align-center" >
         <lightning:button label="Search" variant="brand" onclick='{!c.onFormSubmit}' />
         <aura:if isTrue='{!v.showNewButton}'>
            <lightning:button variant='neutral' label='New' onclick='{!c.createBoat}'/>




({    createBoat: function (component,event,helper) {
        var createRecordEvent = $A.get('e.force:createRecord');
        if (createRecordEvent) {
            var typeName = component.find('typeSelect').get('v.value');
            var typeMap = component.get('v.searchOptionToIdMap');
            var typeId = null;
            if (typeName && typeMap && typeMap[typeName]) {
                typeId = typeMap[typeName];
                'entityApiName': 'Boat__c',
                'defaultFieldValues': {
                    'BoatType__c': typeId
    onFormSubmit : function(component, event, helper){
        var boatTypeId = component.get("v.selectedType");
        console.log("Search button pressed " + boatTypeId);
        var formSubmit = component.getEvent("FormSubmit");
                            {"boatTypeId" : boatTypeId}

public with sharing class BoatSearchResults  {
     public static List <Boat__c> getBoats(String boatTypeId) {
      if(boatTypeId != '')  {
             return [SELECT id, BoatType__c, picture__c, name,contact__r.Name
                    FROM Boat__c
                    WHERE BoatType__c =:boatTypeId];
      } else {
          return [SELECT id, BoatType__c, picture__c, name,contact__r.Name
                    FROM Boat__c];

    onSearch : function(component) {
        var action = component.get("c.getBoats");
        action.setCallback(this, function(response){
        var status = response.getState();
            if(status === "SUCCESS"){
             if(! $A.util.isEmpty(response.getReturnValue())){
                } else {
                     component.set("v.recordError","No boats found");

<aura:event type="COMPONENT" description="Boat Event">
    <aura:attribute name="formData" type="Object"/>

    onFormSubmit : function(component, event, helper){
        console.log("event received by BoatSearchController.js");
        var formData = event.getParam("formData");
        var boatTypeId = formData.boatTypeId;
        var BSRcmp = component.find("BSRcmp");
        var auraMethodResult = BSRcmp.search(boatTypeId);
        console.log("auraMethodResult: " + auraMethodResult);
<aura:component implements="force:appHostable,flexipage:availableForAllPageTypes">
 <aura:attribute name="boat" type="Boat__c" />
    <aura:attribute name="selected" type="String" />
 <lightning:button class="tile">
        <div style="{!'background-image:url(\'' + v.boat.Picture__c + '\'); '}" class="innertile">
          <div class="lower-third">
           <h1 class="slds-truncate">{!v.boat.Contact__r.Name}</h1>
Any help much appreciated. I would love to hear some new tips and new techniques with this task. If you share some source code that would greately appreciated. 

Thank you