Layout API.
This commit is contained in:
parent
bb4d7e0b32
commit
82e4e190fc
|
@ -3,6 +3,7 @@ import { generateLayoutID, getScreenParams } from "../../db/utils"
|
|||
import { events, context } from "@budibase/backend-core"
|
||||
import {
|
||||
BBContext,
|
||||
DeleteLayoutResponse,
|
||||
Layout,
|
||||
SaveLayoutRequest,
|
||||
SaveLayoutResponse,
|
||||
|
@ -32,7 +33,7 @@ export async function save(
|
|||
ctx.status = 200
|
||||
}
|
||||
|
||||
export async function destroy(ctx: BBContext) {
|
||||
export async function destroy(ctx: UserCtx<void, DeleteLayoutResponse>) {
|
||||
const db = context.getAppDB()
|
||||
const layoutId = ctx.params.layoutId,
|
||||
layoutRev = ctx.params.layoutRev
|
||||
|
|
|
@ -3,3 +3,7 @@ import { Layout } from "../../documents"
|
|||
export interface SaveLayoutRequest extends Layout {}
|
||||
|
||||
export interface SaveLayoutResponse extends Layout {}
|
||||
|
||||
export interface DeleteLayoutResponse {
|
||||
message: string
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue