let list= [
? {
? ? id: "LK1123541",
? ? time: "08:22:32",
? },
? {
? ? id: "LK1123542",
? ? type: "路况",
? ? time: "07:00:02",
? },
? {
? ? id: "LK1123543",
? ? type: "路况",
? ? time: "07:00:04",
? },
? {
? ? id: "LK1123544",
? ? type: "路况",
? ? time: "07:00:05",
? }
];
initTime() {
this.list.sort((a, b) => {
return b.time< a.time? -1 : 1
})
console.log(this.list,"daoxu ");
}