Open diegomvh opened 3 weeks ago
WIP
const transform = recs.transform<{ directory: string, total: number, count: number, average: number }>(({ e, t }) => e()
.filter(({ e, t }) => e().lt(t.fecha, new Date()))
.groupBy(() => [t.directory],
f => f.sum(t.size, 'total')
.countdistinct(t.contentType, 'count')
.average(t.size, 'average')
));
transform.query(q => {
q.orderBy(({ e, t }) => e().descending(t.total));
})
console.log(recs.toString());
console.log(transform.toString());
transform.fetchCollection().subscribe((col) => {
console.log(col);
});
Can you tell me how can I migrate the following code:
It seems the new
apply()
method version only accepts function or string.EDIT: Should I use
restore()
instead ofapply()
? Would be nice to have some kind ofChangelog
with the new release to see at least any breaking changes.Originally posted by @hakimio in https://github.com/diegomvh/angular-odata/issues/86#issuecomment-2126617551