How to put the object {00: {. }, 01: {. . }, 03: {. . }, 04: {. . }, 05: {. . }} is assigned to the array, and the loop is {. No, no, no. } .

if I assign it directly to the array, [] = {}, when sorting, it jumps to 10, and 10 jumps to the first place

.

clipboard.png


clipboard.png

Feb.27,2021

you want to take the key value, the cyclic key as the serial number, don't you? Object you can use for..in, to store the key value in a new array, and the new array value is the key, loop array. But note that if the key is directly 00, not'00', the loop will lose the previous 0, and this can be dealt with


let arr=[];
for(index in hour_report){
    arr[parseInt(index)]=hour_report[index]
}

then use arr to v-for

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e91482-1344.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e91482-1344.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?