mirror of
https://github.com/crocofied/CoreControl.git
synced 2025-12-29 16:14:43 +00:00
types.ts fix
This commit is contained in:
@@ -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,
|
||||
|
||||
@@ -7,6 +7,7 @@ export interface Site {
|
||||
|
||||
export interface Network {
|
||||
id: string;
|
||||
siteId: string;
|
||||
name: string;
|
||||
ipv4Subnet?: string;
|
||||
ipv6Subnet?: string;
|
||||
|
||||
Reference in New Issue
Block a user