types.ts fix

This commit is contained in:
headlesdev
2025-05-18 16:32:49 +02:00
parent 5dd17f9f1b
commit d4ad6e1656
3 changed files with 6 additions and 4 deletions

View File

@@ -2,7 +2,8 @@ import { NextRequest, NextResponse } from "next/server";
import prisma from "@/app/prisma";
interface Body {
siteId: number;
id: string;
siteId: string;
name: string;
ipv4Subnet?: string;
ipv6Subnet?: string;
@@ -15,7 +16,7 @@ export async function POST(request: NextRequest) {
try {
const network = await prisma.network.create({
data: {
siteId: body.siteId,
siteId: Number(body.siteId),
name: body.name,
ipv4Subnet: body.ipv4Subnet,
ipv6Subnet: body.ipv6Subnet,

View File

@@ -7,6 +7,7 @@ export interface Site {
export interface Network {
id: string;
siteId: string;
name: string;
ipv4Subnet?: string;
ipv6Subnet?: string;