fixing tests
This commit is contained in:
parent
c37cff7712
commit
d29dffe7e4
|
@ -1,7 +0,0 @@
|
|||
{
|
||||
"name": "newscreen",
|
||||
"props": {
|
||||
"_component": "@budibase/standard-component/div",
|
||||
"className": "something else"
|
||||
}
|
||||
}
|
|
@ -15,7 +15,7 @@ const {
|
|||
authenticatedRoutes
|
||||
} = require("./routes");
|
||||
|
||||
const builderPath = resolve(__dirname, "../../builder")
|
||||
const builderPath = resolve(__dirname, "../builder")
|
||||
|
||||
module.exports = (config, app) => {
|
||||
const router = new Router()
|
||||
|
|
|
@ -3,12 +3,24 @@ const StatusCodes = require("../../utilities/statusCodes")
|
|||
const {
|
||||
listScreens,
|
||||
saveScreen,
|
||||
buildPage
|
||||
buildPage,
|
||||
renameScreen,
|
||||
deleteScreen
|
||||
} = require("../../utilities/builder")
|
||||
|
||||
|
||||
const router = Router()
|
||||
|
||||
router.post("/_builder/api/:appname/pages/:pageName", async ctx => {
|
||||
await buildPage(
|
||||
ctx.config,
|
||||
ctx.params.appname,
|
||||
ctx.params.pageName,
|
||||
ctx.request.body
|
||||
)
|
||||
ctx.response.status = StatusCodes.OK
|
||||
})
|
||||
|
||||
router.get("/_builder/api/:appname/pages/:pagename/screens", async ctx => {
|
||||
ctx.body = await listScreens(
|
||||
ctx.config,
|
||||
|
@ -58,14 +70,4 @@ router
|
|||
ctx.response.status = StatusCodes.OK
|
||||
})
|
||||
|
||||
router.post("/_builder/api/:appname/pages/:pageName", async ctx => {
|
||||
await buildPage(
|
||||
ctx.config,
|
||||
ctx.params.appname,
|
||||
ctx.params.pageName,
|
||||
ctx.request.body
|
||||
)
|
||||
ctx.response.status = StatusCodes.OK
|
||||
})
|
||||
|
||||
module.exports = router
|
Loading…
Reference in New Issue