2
 Followers
4
 Likes

Change Value of all Elements from List

Builtin & User functions
New

There could be an Action that would change the value of an attribute for all elements of a List, avoiding iterating/cycling (For Each) every single element of the List.

eg: Having a List with an attribute "IsActive". Setting all elements' Is Active from the List to False, would need a For Each.

Created on 4 May (5 days ago)
Comments (1)

Hello Pedro,

It looks like a nice ideia.

I´m not an expert in javascript, maybe create something like the "map" method.

Something like this:

const employees = [

    { name: 'Nuno', isActive: '' },

    { name: 'Pedro', isActive: '' }

]

const employeesNew = employees.map(function(row) {

   return { name: name, isActive: true }

})

views
37
Followers
2