Questions tagged [aura-iteration]

questions regarding the aura:iteration component. This coomponent iterates over a collection of items and renders the body of the tag for each item.

42 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
3
votes
1answer
1k views

How do I get the value of a row of HTML table in an aura iteration with onclick?

I am trying to make a functionality where my lightning component shows a table of records and I want to make it so if you click a records row, it autofills my form with that records information. Here ...
3
votes
0answers
692 views

Lightning “change” event doesn't fire in aura:Iteration

I am passing an Object to my component and iterate through it's child records. To handle changes I added the Lightning change handler. (I made data an array, so I can set a default for demo purposes, ...
1
vote
1answer
1k views

How to navigate to one component to another by passing parameters

I'm new to Salesforce. I have just started with lightning Aura components. I want to understand simple workflow of aura. Can anyone help me with the code for below requirement. Thanks in advance. ...
1
vote
0answers
60 views

aura:iteration label of current field

Is there a possibility to get the Label of current field using aura:iteration ? <aura:iteration items="{!v.objectName}" var="objectName"> <lightning:input value="{!objectName.field1}" ...
1
vote
1answer
878 views

Find value of div inside aura iteration on icon click!

I am trying to find the value of a div which is inside aura iteration on icon click which is also inside the same aura iteration. Here in this code below I am trying to find the value of the aura:id=...
1
vote
0answers
138 views

create account from a button inside aura iteration and set account id to the adjacent lookup column

I am new to lightning. I am inserting list of contacts in aura iteration with account lookup. I made custom component for searching account, which works fine. But i also need to give option to create ...
1
vote
0answers
1k views

Lightning button attribute “Disabled” in “aura:iteration tag”

I'm trying to enable a lightning:button if a lightning:inputField changes. This is the aura:component: <aura:component implements="flexipage:availableForRecordHome,force:hasRecordId,force:...
1
vote
1answer
168 views

Disable aura:Iteration field but keep name attribute visible

How could it be accomplished to display the field name above the input field if the field is disabled? As of now, if the field is disabled, so is the e.fieldName attribute. <aura:iteration items=...
1
vote
0answers
1k views

Getting Uncaught Action failed: aura:if$controller$handleTheTruth [Cannot read property '$getType$' of undefined] error on Component.set

In my code, I am getting a list of Object from apex controller, and populating the same into an aura attribute paginationList. On the below line, I am getting the error: component.set('v....
1
vote
0answers
82 views

Data binding variables were displayed Blank in Lightning component inside aura:iterator

I'm Displaying two types of lists in Lightning component. One is List of OpportunityTeamMember and other is List of case. But when I'm iterating over List of Opportunity team members I'm able to see ...
1
vote
1answer
2k views

Lightning Data Table and Aura Iteration

I am trying to render multiple data tables on a page (inside lightning accordians but thats irrelevent) using Aura iteration. i am specifically having trouble with the data attribute of the datatable. ...
0
votes
0answers
18 views

Aura:If results in label - field not value

When using aura:if, I can't get the value of the field to show. Unless I'm using lighting:outputfield the result is the field label. Is there something else I should do to ensure the value is produced ...
0
votes
1answer
30 views

Dynamically calculate values in Aura Iteration

I've aura iteration in my Aura Component where I have a start date and End date and I want to calculate the difference between Start and End date for each row in Aura iteration. What options I have ...
0
votes
0answers
16 views

How to use <lightning:inputField> inside an <aura:iteration>?

How to use lightning:inputField inside an aura:iteration and lightning:inputField with picklists values, field dependencies? lightning:inputField can used in aura:iteration,but lightning:inputField ...
0
votes
0answers
12 views

Identify Lightning RecordEditForm in Aura Iteration

I am using multiple Lightning Record Edit Forms in Aura Iteration and wish to uniquely identity the form when onerror is fired 1.Below is my Component. <aura:iteration items="{!v.episodeList}&...
0
votes
0answers
165 views

Iteration in LWC not working for 2nd element of input array

I am working in LWC requirements where I have a list of records using this list I need to create inputs text. Once I loop through the list in LWC 'HTML component' my input texts are coming as aspected ...
0
votes
1answer
434 views

LWC create input fields under LWC iteration

I am new to LWC. I have to create multiple input fields for different rows. Let say, I have selected 3 records from the previous page and for all those 3 records I need to create the input field and ...
0
votes
1answer
64 views

How to change the value of ui:outputText in second div onchange inputfiled in aura iteration in one div

I have below an aura component and a controller function, I want to change the value of ui:outputText on change order Price of lightning:input. Now getting the current input box value in the ...
0
votes
1answer
324 views

how to remove “Added non-passive event listener to a scroll-blocking <some> event.” warning?

I am using lightning record form inside aura iteration like this which is visible on hover <aura:Iteration items="{!v.Accountscurrent}" var="acc" indexVar="index"> <span class=" icon slds-...
0
votes
0answers
39 views

How to force click from Lightning Button

I would like to force the click of a lightning button that is inside an aura: iteration. I'm using the class variable, which in the code below looks like "data.idMedico". <table id="tabelaBusca" ...
0
votes
0answers
33 views

Date Format of DateTime in Select/Aura Iteration

Here is the code : <lightning:select aura:id="SelectRepport" name="PaymentType" label="repport Z" onchange="{!c.zRepportSelected}"> <option value="0">Chosse ...</option> <aura:...
0
votes
1answer
67 views

Dynamic expression in nested aura iteration in Salesforce Lightning

I've two objects: listContent: [{'Id':1,'Name':'SF'},{'Id':2,'Name':'DS'}] fields:['Id','Name'] Now I'm using nested aura iteration to display the listContent as shown below: <aura:iteration ...
0
votes
0answers
375 views

Nested Rows inside table with shared headers - Aura Iteration

I'm trying to create a table with nested rows based on nested array data set with following structure: [ 'key1' : [ 'subKey1' : 'subValue1', 'subKey2' : 'subValue2', ...
0
votes
1answer
410 views

Setting different checkboxes in aura:iteration - Dynamic binding does not work in Lightning

I need to be able to call different checkboxes in an aura:iteration: <aura:attribute name="orders" type="Order[]"/> <aura:handler name="init" value="{!this}" action="{!c.doInit}" /&...
0
votes
0answers
40 views

<aura if> not working as expected

Hello I made a following component which displays all permission set which i want but now I am stuck. Here I want to display my selected permission set on the table. Although the table is displayed on ...
0
votes
1answer
1k views

How do you get ID of lightning button inside of an iteration?

So I get the error "component.find.(...).get is not a function". Through research I found out that this is because iteration creates multiple instances of aura:id. I've tried to use event.getSource() ...
0
votes
1answer
975 views

Submit Record Edit Form for every object in Aura iteration

I have a Contact object form with a child form component for Buying Center objects. When I upsert the Contact, I need to submit a list of Buying Centers for this Contact. Parent Contact component has ...
0
votes
0answers
31 views

List item deletion in aura: iteration

I have a list in which every time I click the "Adicionar outro CID" button a new line with a field and a button "Remover" is added just below it: Original image: After clicking the button: If I ...
0
votes
1answer
289 views

How to edit a specific row/index in aura iteration by javascript?

Hi I am trying to edit a specific row in an iteration based on an onchange event. One of my columns in my iteration is a picklist. And depending on what is selected I want the rest of the columns in ...
0
votes
0answers
76 views

Dynamically change style for iterated list

Wanna add some color gradation(if its possible without js calling) for my iterated elements, but got some trouble with calling index value inside style param. Code look like this: <aura:iteration ...
0
votes
0answers
284 views

Verical tabs - unable to get selected tab dynamically

We have created vertical tabs using lightning:tabset but we could not able to put the icon on the lihgtning:tab . So we are converted lightning:tabs to vertical tabs. But we are not able to capture ...
0
votes
0answers
260 views

Sorting the items in the desired order in lightning component aura:iteration tag

I am displaying list of records using aura:iteration, now i want to put to arrow marks(up and down). if user clicks on any one record want to move that record in the selected direction either up or ...
0
votes
1answer
460 views

Using lightning component inside Aura:Iteration. It doesnt display anything not even any error

Im using lightning component inside Aura:Iteration. It doesnt display anything not even any error. PFB Code <aura:component > <aura:attribute name="item" type="Camping_Item__c" required="...
0
votes
2answers
693 views

Uncheck child component checkboxes from parent button

How can I reach this behavior? My component is structured like this: <aura:component> <button onclick="{!c.clearCheckbox}" /> <aura:iteration items="{v.items} var="i"> ...
0
votes
1answer
420 views

Passing iterated variable from Markup to JS Controller

I need a way to keep track of each iterated lightning:inputField so that any changes made to that specific field is reflected by a CSS style change. Markup <aura:iteration items="{!v....
0
votes
1answer
422 views

lightning component - passing a list of objects to a child component

I have a map attribute that holds the following map<string,list<SObject>> I want to iterate over the map and pass the list down to a child component but keep getting an error. This is ...
0
votes
0answers
262 views

Change event on UI:InputText in Aura:Iteration throws 'afterRender threw an error in 'ui:inputText' [(a || s).replace is not a function'

I am facing a very strange error when applying change event on UI:InputText that is inside Aura:Iteration. When I focus out of the Input it throws me below error. This page has an error. You might ...
0
votes
1answer
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 ...
0
votes
0answers
128 views

Aura:iteration and appending {!v. } with the var iterator

Is there a way, while iterating through a List of field names to retrieve the corresponding record field value? Ex: <aura:attribute name="layoutAPIFieldsList" type="List" /> <aura:...
0
votes
1answer
5k views

Multiple input inside aura:iteration table

I have an attribute that I am rendering to a table inside an aura:iteration with the following code: <aura:attribute name="licenceassocparties" type="String[]" default="false" access="PRIVATE"/>...
-1
votes
1answer
25 views

I want to iterate over my Account[]

so there is an Account[] which has Accounts and their related contacts. Can i get contacts details like this?: if not then how can i access contacts details, without adding one more aura iteration tag ...
-1
votes
1answer
139 views

<aura if is true> not working as expected

I wrote a following code for component but it is not giving result as i expected, Component code <aura:component > <aura:attribute name="parentOptions" type="List"/> <aura:...