mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-19 09:45:37 -04:00
Add RevisionsService
Signed-off-by: David Mehren <git@herrmehren.de>
This commit is contained in:
parent
783d2cf5e4
commit
5ce8a532a8
3 changed files with 45 additions and 0 deletions
24
src/revisions/revisions.service.ts
Normal file
24
src/revisions/revisions.service.ts
Normal file
|
@ -0,0 +1,24 @@
|
|||
import { Injectable } from '@nestjs/common';
|
||||
import { RevisionMetadataDto } from './revision-metadata.dto';
|
||||
import { RevisionDto } from './revision.dto';
|
||||
|
||||
@Injectable()
|
||||
export class RevisionsService {
|
||||
getNoteRevisionMetadatas(noteIdOrAlias: string): RevisionMetadataDto[] {
|
||||
return [
|
||||
{
|
||||
id: 'some-uuid',
|
||||
updatedAt: new Date(),
|
||||
length: 42,
|
||||
},
|
||||
];
|
||||
}
|
||||
|
||||
getNoteRevision(noteIdOrAlias: string, revisionId: string): RevisionDto {
|
||||
return {
|
||||
id: revisionId,
|
||||
content: 'Foobar',
|
||||
patch: 'barfoo',
|
||||
};
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue