added new fields to permit model, removed changes endpoints
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
import { FastifyInstance } from "fastify";
|
||||
import {
|
||||
deletePermitHandler,
|
||||
getPermitChangesHandler,
|
||||
getPermitHandler,
|
||||
listPermitsHandler,
|
||||
searchPermitHandler,
|
||||
@@ -121,21 +120,6 @@ export async function permitRoutes(fastify: FastifyInstance) {
|
||||
}
|
||||
);
|
||||
|
||||
fastify.get(
|
||||
"/:permitId/changes",
|
||||
{
|
||||
schema: {
|
||||
params: {
|
||||
type: "object",
|
||||
properties: { permitId: { type: "string" } },
|
||||
},
|
||||
},
|
||||
config: { requiredClaims: ["permit:read"] },
|
||||
preHandler: [fastify.authorize],
|
||||
},
|
||||
getPermitChangesHandler
|
||||
);
|
||||
|
||||
await noteRoutes(fastify);
|
||||
|
||||
fastify.addHook("onSend", hideFields("permits"));
|
||||
|
||||
Reference in New Issue
Block a user