I have an object that I need to sort, I'm interested in defining the order of about 4 at least the others could be ordered as they are, saying that this object does not always come in the same order is therefore my query.
{
gratificacionZona:7500 //Quinto
leyNoDocente:"28000"
sueldoBase:50000 //Primero
sueldoGeneral:0 //Segundo
sueldoPIE:0 //Tercero
sueldoSEP:0 //Cuarto
}
Sometimes this object can bring more parameters, but I'm only interested in the order of these marked.
this code enters the items to the fix that I need.
_.forEach(liquidacion.imponible, function(value,key){
aa.table.body.push([{ text: key , border: [true, false, false, false] }, { text: value , border: [false, false, true, false] }]);
})