Questions tagged [force-recorddata]
The force-recorddata tag has no usage guidance.
49
questions
0
votes
1
answer
129
views
Record is updated successfully with "force:recordData" but in response getting Error status code as 'INSUFFICIENT_ACCESS'
In my Lightning component, I am using Force:recordData to update the record It is getting updated but throwing error.
Any help would be greatly appreciated.
Test.cmp code
<force:recordData aura:id=&...
0
votes
1
answer
21
views
force:recordData gives unsupported entity error for a newly created Business Platform Object BoatReview
I want to use force:recordData component for BoatReview's addReview functionality. But I am getting this error "This entity is not currently supported by force:recordData." What else I need ...
0
votes
2
answers
2k
views
Get record data from recordId within Aura with no Apex controller
I have a Quick Action button on the Highlight Panel of Case page that launches a Lightning Aura Comp (QA: Detail page button with URL). Through pageReference, I was able to access the parent CaseId. ...
1
vote
1
answer
179
views
force:recordData redirect to created record on Salesforce mobile app
I created an overwrite for the "new"-button on a custom object via a Lightning Component.
On the desktop everything works fine but the Salesforce mobile app causes some issues.
The component ...
0
votes
0
answers
176
views
Force:record is returning null results
I'm overriding an edit button on a custom object named schedule, which has a lookup relationship with the lead object. But when I try to lead fields through force:recorddata is returning null values.
...
1
vote
0
answers
63
views
panelOnDestroyCallback does not work in Mobile
I have a Aura component with form for creating a standard Task object using force:recordData.
And I want to use panelOnDestroyCallback in order to navigate to Lead object in mobile version.
However I ...
0
votes
1
answer
259
views
Make a custom related record component dynamic
I created a custom Related Record component for a specific sObject, but I'd like to make it dynamic so I can use the same component for two more sObjects.
Here's the code:
<aura:component ...
0
votes
1
answer
2k
views
Showing related object fields in a custom aura component
First time with Aura components, having a hard time understanding them.
I'm trying to write a simple component that shows some related object fields. I know there's a standard one provided by ...
0
votes
1
answer
912
views
force:recordData returning null results
I'm working on a lightning component and I'm trying to retrieve lead record details through
force:recorddata but actually it's returning null results.
My component:
<aura:component implements="...
0
votes
1
answer
340
views
Can't Pass aura:attribute to force:recordData recordID Field
I'm probably missing something crazy simple, hopefully someone here can clear this up for me. I have a simple component as follows:
<aura:component implements="flexipage:...
0
votes
1
answer
562
views
Refreshing record in force:recordData doesn't work
I'm trying to solve a problem with old data being saved. This component is on a detail page:
Open record
Amend one field and save
Use component to trigger a different field to update using force:...
0
votes
1
answer
131
views
LDS: targetFields in force:recordData not re-evaluating
So I have a very simple component that has force:recordData. Since it is not a synchronous operation, initially simpleRecord attribute shows null in init handler.
In updateRec method, I can see the ...
1
vote
1
answer
259
views
Where is targetError attribute handled
This is rather a generic question but I cannot find anything in documentation or communities:
Where is the targetError attribute variable (in below example error) set/handled for a recordDataset
<...
0
votes
1
answer
730
views
On page load of the Aura Component i'm not able to get logged-in/current User ProfileID using force:recordData
On page load of the Aura Component i'm not able to get logged-in/current user Profile ID or Profile Name using the LDS force:recordData
Here is the code from the component and JavaScript controller
...
1
vote
1
answer
716
views
force:recordData providing stale data
I have a hidden lightning component on a Lightning page that checks some data of the record and updates the record if needed. The record is a SBQQ__Quote__c record.
It mostly works, however, ...
0
votes
1
answer
257
views
How to add conditional fields in force:recordData
I am getting an error while loading my aura components due to some of the lookup fields does not have any value. In our data model we have a lookup to an Account from Account. It's setup as a customer ...
2
votes
1
answer
1k
views
How to retrieve translated picklist value with force:recordData in lightning
I have a requirement where I need to show some record's fields within a component in account's detail page. Because of some UI requirement we are showing some fields via ligtning:recordViewForm and ...
4
votes
1
answer
1k
views
Lightning Data Service - Dynamic Fields
I am creating a dynamic navigation (button) component to be used throughout the org. I am trying to provide system admins the ability to specify the data (field/fields) to be retrieved by the force:...
2
votes
1
answer
507
views
How to retrieve sObject picklist field value instead of API name using force:recordData
To get picklist's field value from sObject using SOQL I can use toLabel(FIELD_NAME). Is it possible to do the same with force:recordData component?
1
vote
1
answer
1k
views
Is it possible to use Lightning Data Services \ <force:recordData without sharing rules \ field level security?
It is possible to declare a Apex controller class as
public without sharing class noSharing { }
Is it possible to use Lightning Data Services
<force:recordData
Without sharing \ field level ...
2
votes
0
answers
312
views
Picklists values and lookups for force:recordData
Is there any option to render some input with picklist values in order to use it with force:recordData?
I know that lightning:recordEditForm with lightning:inputField can do this (see here: Can I ...
2
votes
1
answer
2k
views
Lightning: Fields on Record loaded via force:recordData appear to be read-only / unwriteable
Scenario: I am loading an existing record using force:recordData, but since this component isn't on a record page, it cannot/does not implement force:hasRecordId. Instead, I created an attribute ...
3
votes
1
answer
2k
views
Lightning Component: Custom Fields Not Being Stored when saving force:recordData
I've been following the Salesforce documentation on using the force:recordData component to instantiate a new instance of a Case object (targetRecord) using component.getNewRecord, then pushing data ...
2
votes
1
answer
2k
views
Deleting record associated with a lightning:datatable row - Use LDS or APEX Controller?
What is the recommended method of deleting a record associated with a row in a lightning:datatable? All the examples I see show to make a call to an Apex controller to do the delete (maybe I should ...
4
votes
1
answer
2k
views
lightning:recordViewForm and force:recordData refresh issues
I'm having TestObject as parent object and New Custom Object having M-D relationship to it. TestObject having Min and Max Rollup summary fields which will rollup number field in child object.
I was ...
2
votes
1
answer
466
views
How to deal with users without permission while using Lightning Data Services?
To be more specific, I have the following scenario that just happened:
I developed a component on a sandbox (development environment). This component uses force:recordData to retrieve some field data ...
1
vote
2
answers
5k
views
When does force:recordData execute?
I am using force:recordData to pull data for a Campaign on load of the component. The component is triggered by a quick action.
I understand that force:recordData is an asynchronous process. ...
-1
votes
1
answer
4k
views
force:recordData not updating targetFields on reloadRecord
Working on the lightning component framework specialist superbadge, stage 6, and getting the following error:
The BoatDetails component must use force:recordData to load the appropriate list of ...
1
vote
1
answer
1k
views
Cannot load custom object records from Lightning Data Service due to Users Permissions
I'm struggling to load my custom object record using LDS and i got a object privilegies error :
You don't have access to this record. Ask your administrator for help or to request access.
I've ...
2
votes
1
answer
2k
views
Cannot load data using force:recordData from my component
I'm struggling to get fetch data from my component using Lightning Data Service.
My component is linked to a custom action to create a new record for a custom object.
Below is the error i get when the ...
1
vote
1
answer
838
views
Using <force:recordData> in a community does not show/edit all records
I have a community and I am developing a lightning component page to display a custom object record Grant__c in this community.
The custom object Grant__c is in Private sharing mode so only owners ...
8
votes
1
answer
3k
views
Show form with page layouts && intercept save ... Lightning:recordForm / force:recordData
Somewhat flummoxed with this lightning component.
The use case is simple: Intercept the save event on a record edit, grab the new field values and do 'stuff' before saving the record.
Example
User ...
2
votes
1
answer
2k
views
Lightning record edit form issues with Person Account
I was rendering the person contact details using lightning record edit form. Updating the person contact details using force:recordData lightning data service.
If i'm updating the person contact ...
2
votes
1
answer
1k
views
<force:recordData> not getting called
I'm facing trouble with <force:recordData>.
I have a list of custom objects displayed in the form of table over <Aura:iteration>
Out of that list, when a button is clicked, a certain ...
1
vote
1
answer
420
views
I'm unable to get private attribute from a component to use in force:recordData
<aura:component implements="force:appHostable,flexipage:availableForAllPageTypes,force:hasRecordId" access="global" >
<aura:attribute name="boatReview" type="BoatReview__c" access="global"...
1
vote
2
answers
2k
views
Lightning Data Service - empty error message
Today I'm struggling with something I really do not understand. I'm trying to make simple lightning component for creating new record of custom sObject.
Problem appears on the save method. Result ...
2
votes
1
answer
2k
views
Error calling apex controller from Lightning component
This is my first subject since I'm very new to Salesforce.
My problem is that I'm trying to create simple Lightning component which could clone record with custom logic. This component suppose to be ...
0
votes
1
answer
257
views
entity is not currently supported by force:recordData
I have two lightning components on a product detail object page within my community. These two components have the standard force:recordData stuff in them:
<aura:attribute name="record" type="...
0
votes
1
answer
323
views
Retrieve Community Contact fields in force:recordData
Is there a way to retrieve Community user's contact fields in force:recordData? This is my first lightning coming, and I'm not finding proper information on this.
I'm trying to display the logged in ...
2
votes
1
answer
3k
views
force:recordData for Update OR Create
I can't seem to allow force:recordData to update records. I am able to make it create new records without any problem.
I think the problem is in the attribute of the component? Or perhaps I am not ...
4
votes
1
answer
3k
views
force:recordData on user object
I am just trying to get the user details on the page using LDS.
<force:recordData aura:id="userRecord"
recordId="{!v.userrecordId}"
targetRecord="{!v....
0
votes
2
answers
2k
views
force:recordData issue with the lookup value
I am using the force:recordData and trying to get the field values from the recordData in JS.
Component:
<aura:attribute name="recordId" type="String" />
<aura:attribute name="record" ...
2
votes
1
answer
3k
views
force:recordData Individual Fields Access
I cannot seem to get the fields from force:recordData available to my component. I'm fairly confident I have the syntax wrong, but I can't find the proper way to reference the data.
This code in the ...
11
votes
2
answers
19k
views
get the value from force:RecordData on Init handler
Is there a way we can get the value from force:RecordData on init ? I am getting the onclick event of a button.
<aura:handler name="init" value="{!this}" action="{!c.doInit}"/>
<aura:...
0
votes
2
answers
2k
views
Trailhead challenge passed but unable to use the edit component
From the Manipulate Records with force:recordData module https://trailhead.salesforce.com/modules/lightning_data_service/units/lightning_data_service_manipulate_records, I passed the challenge using ...
5
votes
2
answers
8k
views
Attributes and Field clarification from Lightning data service trailhead module
Below lightning component is from Lightning data service module in trailhead
Questions 1: Why there are two object attributes used - record , simpleRecord, when one attribute can serve the purpose. ...
1
vote
1
answer
702
views
Can we save list of OpportunityLineItems using lightning data service <force:recordData?
I am trying to create multiple opportunity products and quotelineitems for respective opportunities and quote.
I have already inserted the opportuity and quote using lightning data service.
But I ...
0
votes
2
answers
5k
views
In <force:recordData> not able to set it's recordId Attribute from client-side controller
Whenever I click on the <lightning:button> inside <aura:iteration>, I need to delete that particular record using <force:recordData> but When I click on <lightning:button>, ...
10
votes
1
answer
10k
views
Can force:recordData query related parent fields?
Anyone found a way to select parent fields with force:recordData?
It would be great to have something like this:
<force:recordData recordId="{!v.recordId}" targetRecord="{!v.child}"
...