- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
export function compareTwoObjectExceptTime (obj1, obj2) {
const obj1Copy = { ...obj1 }
const obj2Copy = { ...obj2 }
delete obj1Copy.ScheduledStartOn
delete obj1Copy.ScheduledFinishOn
delete obj1Copy.FinishedStartOn
delete obj1Copy.FinishedFinishOn
delete obj1Copy.ScheduledDuration
delete obj1Copy.FinishedDuration
delete obj1Copy.tasks
delete obj2Copy.ScheduledStartOn
delete obj2Copy.ScheduledFinishOn
delete obj2Copy.FinishedStartOn
delete obj2Copy.FinishedFinishOn
delete obj2Copy.ScheduledDuration
delete obj2Copy.FinishedDuration
delete obj2Copy.tasks
return JSON.stringify(obj1Copy) === JSON.stringify(obj2Copy)
}
Support 30.01.2023 20:39 # 0
p.s. Ты хотел удивить нас, запостив говнокод на js?