• Vikas U Mishra
  • NEWBIE
  • 0 Points
  • Member since 2015

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 4
    Questions
  • 2
    Replies
We are setting error msg for picklist which default Error Handling
 
additionalCapabilitiesField.set("v.errors",[{message:"my error message"}])

same is not wokring for force:inputfield value which is showing picklist field.
 
<div class="slds-form-element">
            <label class="slds-form-element__label" 
                   for="additionalCapabilities">Additional Capabilities: </label>
            <div class="slds-form-element__control">
                <force:inputField aura:id="additionalCapabilities" value="{!v.newOpportunity.Secondary_Service_Offerings__c}" />
            </div>
        </div>

 
We are setting value force:inputField for Account Lookup field on Opportunity object for Lightning Component.

 
component.set("v.newOpportunity.AccountId", accountDetailsId);
                
                // we need this for the actual 'pill' in the lookup field
                var values = [{
                    type: 'Account',
                    id: accountDetailsId,
                    label: component.get('v.account.Name'),
                    icon : {
                        url:'/img/icon/t4v35/standard/account_120.png',
                        backgroundColor:'A094ED',
                        alt:'Account'
                    }
                }];
                
                component.find("accountName").get("v.body")[0].set("v.values", values);

Do we have any other workaround for this? 
Even after setting value, I am getting undefined for following code.
component.find("accountName").get("v.body")[0].get("v.values")


Component side code:

<div class="slds-form-element">
            <label class="slds-form-element__label"
                   for="accountName">Account Name: </label>
            <div class="slds-form-element__control">     
                <force:inputField aura:id="accountName" value="{!v.newOpportunity.AccountId}" required="true"/>
            </div>
        </div>
Do we have any way to add VisualForce page or Lightning Component into Lightning Dashboard.

We have line charts with 5 data series which has been build using VF page. NOw we are looking to include same into Lightning Dashboard.
We are getting issue with Standard Account field "BillingCountry" while writting Trigger.
We are getting not getting new value for BeforeUpdate Trigger.

Not sure what may be issue, we have created custom field for Country and same is working properly.

Pls, check following debug log showing old and new values same.
|USER_DEBUG|[106]|DEBUG|Old Country: United States
|STATEMENT_EXECUTE|[107]
|HEAP_ALLOCATE|[107]|Bytes:14
|HEAP_ALLOCATE|[107]|Bytes:27
|USER_DEBUG|[107]|DEBUG|New Country : United States
|STATEMENT_EXECUTE|[108]
|HEAP_ALLOCATE|[108]|Bytes:18
|HEAP_ALLOCATE|[108]|Bytes:20
|USER_DEBUG|[108]|DEBUG|Old Country Code: US
|STATEMENT_EXECUTE|[109]
|HEAP_ALLOCATE|[109]|Bytes:18
|HEAP_ALLOCATE|[109]|Bytes:20
|USER_DEBUG|[109]|DEBUG|New Country Code: US

 
Do we have any way to add VisualForce page or Lightning Component into Lightning Dashboard.

We have line charts with 5 data series which has been build using VF page. NOw we are looking to include same into Lightning Dashboard.
We are getting issue with Standard Account field "BillingCountry" while writting Trigger.
We are getting not getting new value for BeforeUpdate Trigger.

Not sure what may be issue, we have created custom field for Country and same is working properly.

Pls, check following debug log showing old and new values same.
|USER_DEBUG|[106]|DEBUG|Old Country: United States
|STATEMENT_EXECUTE|[107]
|HEAP_ALLOCATE|[107]|Bytes:14
|HEAP_ALLOCATE|[107]|Bytes:27
|USER_DEBUG|[107]|DEBUG|New Country : United States
|STATEMENT_EXECUTE|[108]
|HEAP_ALLOCATE|[108]|Bytes:18
|HEAP_ALLOCATE|[108]|Bytes:20
|USER_DEBUG|[108]|DEBUG|Old Country Code: US
|STATEMENT_EXECUTE|[109]
|HEAP_ALLOCATE|[109]|Bytes:18
|HEAP_ALLOCATE|[109]|Bytes:20
|USER_DEBUG|[109]|DEBUG|New Country Code: US