Worked on the note endpoint and helpers, ready for response and testing
This commit is contained in:
@@ -9,3 +9,4 @@ export class API extends BaseAPI {
|
||||
API.errors = require('./APIErrors').APIErrors;
|
||||
API.user = require('./userResponses').UserAPI;
|
||||
API.permalink = require('./permaLinkResponse').PermaLinkAPI;
|
||||
API.note = require('./noteResponse').NoteAPI;
|
||||
|
||||
5
src/models/api/noteResponse.js
Normal file
5
src/models/api/noteResponse.js
Normal file
@@ -0,0 +1,5 @@
|
||||
import {API} from './API';
|
||||
|
||||
export class NoteAPI extends API {
|
||||
|
||||
}
|
||||
@@ -1,3 +1,11 @@
|
||||
import {Database} from '../database/database';
|
||||
|
||||
export class Groups {
|
||||
constructor() { }
|
||||
static async newGroup() {
|
||||
|
||||
}
|
||||
|
||||
static async doesGroupExist() {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,7 +3,11 @@ import {Database} from '../database/database';
|
||||
|
||||
export class Notes extends Groups {
|
||||
static async newNote(id, content, creatorid, order) {
|
||||
Database.note.newNote(id, content, creatorid, order, null);
|
||||
return await Database.note.newNote(id, content, creatorid, order, null);
|
||||
}
|
||||
|
||||
static async newGroupedNote(id, content, creatorid, order, parentgroup) {
|
||||
return await Database.note.newNote(id, content, creatorid, order, parentgroup);
|
||||
}
|
||||
|
||||
static async genID() {
|
||||
@@ -34,10 +38,6 @@ export class Notes extends Groups {
|
||||
|
||||
}
|
||||
|
||||
static async newGroupedNote(id, content, creatorid, order, parentgroup) {
|
||||
|
||||
}
|
||||
|
||||
static async reorderNote(id, newPosition) {
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user