diff --git a/.env b/.env index 89dca287..69836969 100644 --- a/.env +++ b/.env @@ -11,6 +11,7 @@ NEXTCLOUD_URL=https://espace.slm-lab.net NEXTCLOUD_CLIENT_ID=espace.slm-lab.net NEXTCLOUD_CLIENT_SECRET=YHLVMGpu0nGRaP7gMDpSjRr1ia6HiSr1 +# Agenda/Calendar database (Prisma) DATABASE_URL="postgresql://postgres:postgres@localhost:5432/calendar_db?schema=public" # Sidebar iframes @@ -46,5 +47,12 @@ ROCKET_CHAT_TOKEN=w91TYgkH-Z67Oz72usYdkW5TZLLRwnre7qyAhp7aHJB ROCKET_CHAT_USER_ID=Tpuww59PJKsrGNQJB LEANTIME_TOKEN=lt_lsdShQdoYHaPUWuL07XZR1Rf3GeySsIs_UDlll3VJPk5EwAuILpMC4BwzJ9MZFRrb LEANTIME_API_URL=https://agilite.slm-lab.net +<<<<<<< HEAD -NEWSDB_URL=postgresql://alma:Sict33711###@cube.governance-labs.com/rivacube \ No newline at end of file +NEWSDB_URL=postgresql://alma:Sict33711###@cube.governance-labs.com/rivacube +======= +DB_USER=alma +DB_PASSWORD=Sict33711### +DB_NAME=rivacube +DB_HOST=cube.governance-labs.com +>>>>>>> 1abc8e9fe8b5d9382da1c53238741114288da34c diff --git a/app/api/news/route.ts b/app/api/news/route.ts index f4f4ef5c..b3e70fb0 100644 --- a/app/api/news/route.ts +++ b/app/api/news/route.ts @@ -1,25 +1,25 @@ import { NextResponse } from 'next/server'; -import { prisma } from '@/lib/prisma'; +import { Pool } from 'pg'; + +const pool = new Pool({ + connectionString: process.env.NEWSDB_URL, +}); export async function GET() { try { - const news = await prisma.news.findMany({ - orderBy: { - date: 'desc' - }, - take: 5, - select: { - id: true, - title: true, - date: true, - source: true, - description: true, - category: true, - url: true - } - }); - - return NextResponse.json(news); + const client = await pool.connect(); + try { + const result = await client.query( + `SELECT id, title, date, source, description, category, url + FROM news + ORDER BY date DESC + LIMIT 5` + ); + + return NextResponse.json(result.rows); + } finally { + client.release(); + } } catch (error) { console.error('Error fetching news:', error); return NextResponse.json( diff --git a/lib/prisma-news.ts b/lib/prisma-news.ts new file mode 100644 index 00000000..26b690ba --- /dev/null +++ b/lib/prisma-news.ts @@ -0,0 +1,13 @@ +import { PrismaClient } from '@prisma/client/news' + +const globalForPrisma = globalThis as unknown as { + prismaNews: PrismaClient | undefined; +} + +export const prismaNews = + globalForPrisma.prismaNews || + new PrismaClient({ + log: ['query'], + }) + +if (process.env.NODE_ENV !== 'production') globalForPrisma.prismaNews = prismaNews \ No newline at end of file diff --git a/node_modules/.prisma/client/edge.js b/node_modules/.prisma/client/edge.js index cc42ee09..accf1cf2 100644 --- a/node_modules/.prisma/client/edge.js +++ b/node_modules/.prisma/client/edge.js @@ -89,27 +89,20 @@ exports.Prisma.TransactionIsolationLevel = makeStrictEnum({ Serializable: 'Serializable' }); -exports.Prisma.CalendarScalarFieldEnum = { - id: 'id', - name: 'name', - color: 'color', - description: 'description', - userId: 'userId', - createdAt: 'createdAt', - updatedAt: 'updatedAt' -}; - -exports.Prisma.EventScalarFieldEnum = { +exports.Prisma.NewsScalarFieldEnum = { id: 'id', title: 'title', + url: 'url', + date: 'date', + source: 'source', + content: 'content', + sentiment_score: 'sentiment_score', + sentiment: 'sentiment', + symbols: 'symbols', + symbol: 'symbol', + processed_at: 'processed_at', description: 'description', - start: 'start', - end: 'end', - location: 'location', - isAllDay: 'isAllDay', - calendarId: 'calendarId', - createdAt: 'createdAt', - updatedAt: 'updatedAt' + category: 'category' }; exports.Prisma.SortOrder = { @@ -129,8 +122,7 @@ exports.Prisma.NullsOrder = { exports.Prisma.ModelName = { - Calendar: 'Calendar', - Event: 'Event' + News: 'News' }; /** * Create the Client @@ -143,7 +135,7 @@ const config = { "value": "prisma-client-js" }, "output": { - "value": "/Users/alma/Downloads/neah/front/node_modules/@prisma/client", + "value": "/Users/alma/Downloads/neahfront6/node_modules/@prisma/client", "fromEnvVar": null }, "config": { @@ -154,13 +146,18 @@ const config = { "fromEnvVar": null, "value": "darwin-arm64", "native": true + }, + { + "fromEnvVar": null, + "value": "linux-arm64-openssl-3.0.x" } ], "previewFeatures": [], - "sourceFilePath": "/Users/alma/Downloads/neah/front/prisma/schema.prisma" + "sourceFilePath": "/Users/alma/Downloads/neahfront6/prisma/news.schema.prisma" }, "relativeEnvPaths": { - "rootEnvPath": null + "rootEnvPath": null, + "schemaEnvPath": "../../../.env" }, "relativePath": "../../../prisma", "clientVersion": "6.4.1", @@ -169,28 +166,30 @@ const config = { "db" ], "activeProvider": "postgresql", - "postinstall": true, + "postinstall": false, "inlineDatasources": { "db": { "url": { - "fromEnvVar": null, - "value": "postgresql://enkun:183d9ad665c9257703c2e0703f111d240266a56b33e10df04fb8c565e55e0b94@172.16.32.141:5432/enkun?schema=public" + "fromEnvVar": "NEWSDB_URL", + "value": null } } }, - "inlineSchema": "generator client {\n provider = \"prisma-client-js\"\n}\n\ndatasource db {\n provider = \"postgresql\"\n //TODO: Modifier l'url\n url = \"postgresql://enkun:183d9ad665c9257703c2e0703f111d240266a56b33e10df04fb8c565e55e0b94@172.16.32.141:5432/enkun?schema=public\"\n}\n\nmodel Calendar {\n id String @id @default(cuid())\n name String\n color String @default(\"#0082c9\")\n description String?\n userId String\n createdAt DateTime @default(now())\n updatedAt DateTime @updatedAt\n events Event[]\n\n @@index([userId])\n}\n\nmodel Event {\n id String @id @default(cuid())\n title String\n description String?\n start DateTime\n end DateTime\n location String?\n isAllDay Boolean @default(false)\n calendar Calendar @relation(fields: [calendarId], references: [id], onDelete: Cascade)\n calendarId String\n createdAt DateTime @default(now())\n updatedAt DateTime @updatedAt\n\n @@index([calendarId])\n @@index([start, end])\n}\n", - "inlineSchemaHash": "d54fe55cddcb5a229a08e0b8c234fdd2db832218b95783858f4595ac032de6be", + "inlineSchema": "// This is your Prisma schema file for the news database\ngenerator client {\n provider = \"prisma-client-js\"\n binaryTargets = [\"native\", \"linux-arm64-openssl-3.0.x\"]\n}\n\ndatasource db {\n provider = \"postgresql\"\n url = env(\"NEWSDB_URL\")\n}\n\nmodel News {\n id Int @id @default(autoincrement())\n title String\n url String @unique\n date DateTime\n source String\n content String?\n sentiment_score Float?\n sentiment String?\n symbols String[]\n symbol String?\n processed_at DateTime @default(now())\n description String?\n category String? @db.VarChar(50)\n\n @@index([category])\n @@index([date])\n @@index([symbol])\n}\n", + "inlineSchemaHash": "ab8ea0a0b44e836388cadcdd96e01142dc99421f5ecdef6cc8db0283fcfaa7b5", "copyEngine": true } config.dirname = '/' -config.runtimeDataModel = JSON.parse("{\"models\":{\"Calendar\":{\"dbName\":null,\"schema\":null,\"fields\":[{\"name\":\"id\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":true,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"String\",\"nativeType\":null,\"default\":{\"name\":\"cuid\",\"args\":[1]},\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"name\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"color\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"String\",\"nativeType\":null,\"default\":\"#0082c9\",\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"description\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"userId\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"createdAt\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"DateTime\",\"nativeType\":null,\"default\":{\"name\":\"now\",\"args\":[]},\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"updatedAt\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"DateTime\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":true},{\"name\":\"events\",\"kind\":\"object\",\"isList\":true,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"Event\",\"nativeType\":null,\"relationName\":\"CalendarToEvent\",\"relationFromFields\":[],\"relationToFields\":[],\"isGenerated\":false,\"isUpdatedAt\":false}],\"primaryKey\":null,\"uniqueFields\":[],\"uniqueIndexes\":[],\"isGenerated\":false},\"Event\":{\"dbName\":null,\"schema\":null,\"fields\":[{\"name\":\"id\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":true,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"String\",\"nativeType\":null,\"default\":{\"name\":\"cuid\",\"args\":[1]},\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"title\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"description\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"start\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"DateTime\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"end\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"DateTime\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"location\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"isAllDay\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"Boolean\",\"nativeType\":null,\"default\":false,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"calendar\",\"kind\":\"object\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"Calendar\",\"nativeType\":null,\"relationName\":\"CalendarToEvent\",\"relationFromFields\":[\"calendarId\"],\"relationToFields\":[\"id\"],\"relationOnDelete\":\"Cascade\",\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"calendarId\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":true,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"createdAt\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"DateTime\",\"nativeType\":null,\"default\":{\"name\":\"now\",\"args\":[]},\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"updatedAt\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"DateTime\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":true}],\"primaryKey\":null,\"uniqueFields\":[],\"uniqueIndexes\":[],\"isGenerated\":false}},\"enums\":{},\"types\":{}}") +config.runtimeDataModel = JSON.parse("{\"models\":{\"News\":{\"dbName\":null,\"schema\":null,\"fields\":[{\"name\":\"id\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":true,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"Int\",\"nativeType\":null,\"default\":{\"name\":\"autoincrement\",\"args\":[]},\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"title\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"url\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":true,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"date\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"DateTime\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"source\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"content\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"sentiment_score\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"Float\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"sentiment\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"symbols\",\"kind\":\"scalar\",\"isList\":true,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"symbol\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"processed_at\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"DateTime\",\"nativeType\":null,\"default\":{\"name\":\"now\",\"args\":[]},\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"description\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"category\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":[\"VarChar\",[\"50\"]],\"isGenerated\":false,\"isUpdatedAt\":false}],\"primaryKey\":null,\"uniqueFields\":[],\"uniqueIndexes\":[],\"isGenerated\":false}},\"enums\":{},\"types\":{}}") defineDmmfProperty(exports.Prisma, config.runtimeDataModel) config.engineWasm = undefined config.compilerWasm = undefined config.injectableEdgeEnv = () => ({ - parsed: {} + parsed: { + NEWSDB_URL: typeof globalThis !== 'undefined' && globalThis['NEWSDB_URL'] || typeof process !== 'undefined' && process.env && process.env.NEWSDB_URL || undefined + } }) if (typeof globalThis !== 'undefined' && globalThis['DEBUG'] || typeof process !== 'undefined' && process.env && process.env.DEBUG || undefined) { diff --git a/node_modules/.prisma/client/index-browser.js b/node_modules/.prisma/client/index-browser.js index cbb8f5e6..52d7b987 100644 --- a/node_modules/.prisma/client/index-browser.js +++ b/node_modules/.prisma/client/index-browser.js @@ -117,27 +117,20 @@ exports.Prisma.TransactionIsolationLevel = makeStrictEnum({ Serializable: 'Serializable' }); -exports.Prisma.CalendarScalarFieldEnum = { - id: 'id', - name: 'name', - color: 'color', - description: 'description', - userId: 'userId', - createdAt: 'createdAt', - updatedAt: 'updatedAt' -}; - -exports.Prisma.EventScalarFieldEnum = { +exports.Prisma.NewsScalarFieldEnum = { id: 'id', title: 'title', + url: 'url', + date: 'date', + source: 'source', + content: 'content', + sentiment_score: 'sentiment_score', + sentiment: 'sentiment', + symbols: 'symbols', + symbol: 'symbol', + processed_at: 'processed_at', description: 'description', - start: 'start', - end: 'end', - location: 'location', - isAllDay: 'isAllDay', - calendarId: 'calendarId', - createdAt: 'createdAt', - updatedAt: 'updatedAt' + category: 'category' }; exports.Prisma.SortOrder = { @@ -157,8 +150,7 @@ exports.Prisma.NullsOrder = { exports.Prisma.ModelName = { - Calendar: 'Calendar', - Event: 'Event' + News: 'News' }; /** diff --git a/node_modules/.prisma/client/index.d.ts b/node_modules/.prisma/client/index.d.ts index 46e63bff..1b0aa748 100644 --- a/node_modules/.prisma/client/index.d.ts +++ b/node_modules/.prisma/client/index.d.ts @@ -14,15 +14,10 @@ export type PrismaPromise = $Public.PrismaPromise /** - * Model Calendar + * Model News * */ -export type Calendar = $Result.DefaultSelection -/** - * Model Event - * - */ -export type Event = $Result.DefaultSelection +export type News = $Result.DefaultSelection /** * ## Prisma Client ʲˢ @@ -31,8 +26,8 @@ export type Event = $Result.DefaultSelection * @example * ``` * const prisma = new PrismaClient() - * // Fetch zero or more Calendars - * const calendars = await prisma.calendar.findMany() + * // Fetch zero or more News + * const news = await prisma.news.findMany() * ``` * * @@ -52,8 +47,8 @@ export class PrismaClient< * @example * ``` * const prisma = new PrismaClient() - * // Fetch zero or more Calendars - * const calendars = await prisma.calendar.findMany() + * // Fetch zero or more News + * const news = await prisma.news.findMany() * ``` * * @@ -150,24 +145,14 @@ export class PrismaClient< }>, ClientOptions> /** - * `prisma.calendar`: Exposes CRUD operations for the **Calendar** model. + * `prisma.news`: Exposes CRUD operations for the **News** model. * Example usage: * ```ts - * // Fetch zero or more Calendars - * const calendars = await prisma.calendar.findMany() + * // Fetch zero or more News + * const news = await prisma.news.findMany() * ``` */ - get calendar(): Prisma.CalendarDelegate; - - /** - * `prisma.event`: Exposes CRUD operations for the **Event** model. - * Example usage: - * ```ts - * // Fetch zero or more Events - * const events = await prisma.event.findMany() - * ``` - */ - get event(): Prisma.EventDelegate; + get news(): Prisma.NewsDelegate; } export namespace Prisma { @@ -608,8 +593,7 @@ export namespace Prisma { export const ModelName: { - Calendar: 'Calendar', - Event: 'Event' + News: 'News' }; export type ModelName = (typeof ModelName)[keyof typeof ModelName] @@ -625,155 +609,81 @@ export namespace Prisma { export type TypeMap = { meta: { - modelProps: "calendar" | "event" + modelProps: "news" txIsolationLevel: Prisma.TransactionIsolationLevel } model: { - Calendar: { - payload: Prisma.$CalendarPayload - fields: Prisma.CalendarFieldRefs + News: { + payload: Prisma.$NewsPayload + fields: Prisma.NewsFieldRefs operations: { findUnique: { - args: Prisma.CalendarFindUniqueArgs - result: $Utils.PayloadToResult | null + args: Prisma.NewsFindUniqueArgs + result: $Utils.PayloadToResult | null } findUniqueOrThrow: { - args: Prisma.CalendarFindUniqueOrThrowArgs - result: $Utils.PayloadToResult + args: Prisma.NewsFindUniqueOrThrowArgs + result: $Utils.PayloadToResult } findFirst: { - args: Prisma.CalendarFindFirstArgs - result: $Utils.PayloadToResult | null + args: Prisma.NewsFindFirstArgs + result: $Utils.PayloadToResult | null } findFirstOrThrow: { - args: Prisma.CalendarFindFirstOrThrowArgs - result: $Utils.PayloadToResult + args: Prisma.NewsFindFirstOrThrowArgs + result: $Utils.PayloadToResult } findMany: { - args: Prisma.CalendarFindManyArgs - result: $Utils.PayloadToResult[] + args: Prisma.NewsFindManyArgs + result: $Utils.PayloadToResult[] } create: { - args: Prisma.CalendarCreateArgs - result: $Utils.PayloadToResult + args: Prisma.NewsCreateArgs + result: $Utils.PayloadToResult } createMany: { - args: Prisma.CalendarCreateManyArgs + args: Prisma.NewsCreateManyArgs result: BatchPayload } createManyAndReturn: { - args: Prisma.CalendarCreateManyAndReturnArgs - result: $Utils.PayloadToResult[] + args: Prisma.NewsCreateManyAndReturnArgs + result: $Utils.PayloadToResult[] } delete: { - args: Prisma.CalendarDeleteArgs - result: $Utils.PayloadToResult + args: Prisma.NewsDeleteArgs + result: $Utils.PayloadToResult } update: { - args: Prisma.CalendarUpdateArgs - result: $Utils.PayloadToResult + args: Prisma.NewsUpdateArgs + result: $Utils.PayloadToResult } deleteMany: { - args: Prisma.CalendarDeleteManyArgs + args: Prisma.NewsDeleteManyArgs result: BatchPayload } updateMany: { - args: Prisma.CalendarUpdateManyArgs + args: Prisma.NewsUpdateManyArgs result: BatchPayload } updateManyAndReturn: { - args: Prisma.CalendarUpdateManyAndReturnArgs - result: $Utils.PayloadToResult[] + args: Prisma.NewsUpdateManyAndReturnArgs + result: $Utils.PayloadToResult[] } upsert: { - args: Prisma.CalendarUpsertArgs - result: $Utils.PayloadToResult + args: Prisma.NewsUpsertArgs + result: $Utils.PayloadToResult } aggregate: { - args: Prisma.CalendarAggregateArgs - result: $Utils.Optional + args: Prisma.NewsAggregateArgs + result: $Utils.Optional } groupBy: { - args: Prisma.CalendarGroupByArgs - result: $Utils.Optional[] + args: Prisma.NewsGroupByArgs + result: $Utils.Optional[] } count: { - args: Prisma.CalendarCountArgs - result: $Utils.Optional | number - } - } - } - Event: { - payload: Prisma.$EventPayload - fields: Prisma.EventFieldRefs - operations: { - findUnique: { - args: Prisma.EventFindUniqueArgs - result: $Utils.PayloadToResult | null - } - findUniqueOrThrow: { - args: Prisma.EventFindUniqueOrThrowArgs - result: $Utils.PayloadToResult - } - findFirst: { - args: Prisma.EventFindFirstArgs - result: $Utils.PayloadToResult | null - } - findFirstOrThrow: { - args: Prisma.EventFindFirstOrThrowArgs - result: $Utils.PayloadToResult - } - findMany: { - args: Prisma.EventFindManyArgs - result: $Utils.PayloadToResult[] - } - create: { - args: Prisma.EventCreateArgs - result: $Utils.PayloadToResult - } - createMany: { - args: Prisma.EventCreateManyArgs - result: BatchPayload - } - createManyAndReturn: { - args: Prisma.EventCreateManyAndReturnArgs - result: $Utils.PayloadToResult[] - } - delete: { - args: Prisma.EventDeleteArgs - result: $Utils.PayloadToResult - } - update: { - args: Prisma.EventUpdateArgs - result: $Utils.PayloadToResult - } - deleteMany: { - args: Prisma.EventDeleteManyArgs - result: BatchPayload - } - updateMany: { - args: Prisma.EventUpdateManyArgs - result: BatchPayload - } - updateManyAndReturn: { - args: Prisma.EventUpdateManyAndReturnArgs - result: $Utils.PayloadToResult[] - } - upsert: { - args: Prisma.EventUpsertArgs - result: $Utils.PayloadToResult - } - aggregate: { - args: Prisma.EventAggregateArgs - result: $Utils.Optional - } - groupBy: { - args: Prisma.EventGroupByArgs - result: $Utils.Optional[] - } - count: { - args: Prisma.EventCountArgs - result: $Utils.Optional | number + args: Prisma.NewsCountArgs + result: $Utils.Optional | number } } } @@ -861,8 +771,7 @@ export namespace Prisma { omit?: Prisma.GlobalOmitConfig } export type GlobalOmitConfig = { - calendar?: CalendarOmit - event?: EventOmit + news?: NewsOmit } /* Types for Logging */ @@ -952,1542 +861,472 @@ export namespace Prisma { */ - /** - * Count Type CalendarCountOutputType - */ - - export type CalendarCountOutputType = { - events: number - } - - export type CalendarCountOutputTypeSelect = { - events?: boolean | CalendarCountOutputTypeCountEventsArgs - } - - // Custom InputTypes - /** - * CalendarCountOutputType without action - */ - export type CalendarCountOutputTypeDefaultArgs = { - /** - * Select specific fields to fetch from the CalendarCountOutputType - */ - select?: CalendarCountOutputTypeSelect | null - } - - /** - * CalendarCountOutputType without action - */ - export type CalendarCountOutputTypeCountEventsArgs = { - where?: EventWhereInput - } - /** * Models */ /** - * Model Calendar + * Model News */ - export type AggregateCalendar = { - _count: CalendarCountAggregateOutputType | null - _min: CalendarMinAggregateOutputType | null - _max: CalendarMaxAggregateOutputType | null + export type AggregateNews = { + _count: NewsCountAggregateOutputType | null + _avg: NewsAvgAggregateOutputType | null + _sum: NewsSumAggregateOutputType | null + _min: NewsMinAggregateOutputType | null + _max: NewsMaxAggregateOutputType | null } - export type CalendarMinAggregateOutputType = { - id: string | null - name: string | null - color: string | null - description: string | null - userId: string | null - createdAt: Date | null - updatedAt: Date | null + export type NewsAvgAggregateOutputType = { + id: number | null + sentiment_score: number | null } - export type CalendarMaxAggregateOutputType = { - id: string | null - name: string | null - color: string | null - description: string | null - userId: string | null - createdAt: Date | null - updatedAt: Date | null + export type NewsSumAggregateOutputType = { + id: number | null + sentiment_score: number | null } - export type CalendarCountAggregateOutputType = { - id: number - name: number - color: number - description: number - userId: number - createdAt: number - updatedAt: number - _all: number - } - - - export type CalendarMinAggregateInputType = { - id?: true - name?: true - color?: true - description?: true - userId?: true - createdAt?: true - updatedAt?: true - } - - export type CalendarMaxAggregateInputType = { - id?: true - name?: true - color?: true - description?: true - userId?: true - createdAt?: true - updatedAt?: true - } - - export type CalendarCountAggregateInputType = { - id?: true - name?: true - color?: true - description?: true - userId?: true - createdAt?: true - updatedAt?: true - _all?: true - } - - export type CalendarAggregateArgs = { - /** - * Filter which Calendar to aggregate. - */ - where?: CalendarWhereInput - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} - * - * Determine the order of Calendars to fetch. - */ - orderBy?: CalendarOrderByWithRelationInput | CalendarOrderByWithRelationInput[] - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} - * - * Sets the start position - */ - cursor?: CalendarWhereUniqueInput - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} - * - * Take `±n` Calendars from the position of the cursor. - */ - take?: number - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} - * - * Skip the first `n` Calendars. - */ - skip?: number - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} - * - * Count returned Calendars - **/ - _count?: true | CalendarCountAggregateInputType - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} - * - * Select which fields to find the minimum value - **/ - _min?: CalendarMinAggregateInputType - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} - * - * Select which fields to find the maximum value - **/ - _max?: CalendarMaxAggregateInputType - } - - export type GetCalendarAggregateType = { - [P in keyof T & keyof AggregateCalendar]: P extends '_count' | 'count' - ? T[P] extends true - ? number - : GetScalarType - : GetScalarType - } - - - - - export type CalendarGroupByArgs = { - where?: CalendarWhereInput - orderBy?: CalendarOrderByWithAggregationInput | CalendarOrderByWithAggregationInput[] - by: CalendarScalarFieldEnum[] | CalendarScalarFieldEnum - having?: CalendarScalarWhereWithAggregatesInput - take?: number - skip?: number - _count?: CalendarCountAggregateInputType | true - _min?: CalendarMinAggregateInputType - _max?: CalendarMaxAggregateInputType - } - - export type CalendarGroupByOutputType = { - id: string - name: string - color: string - description: string | null - userId: string - createdAt: Date - updatedAt: Date - _count: CalendarCountAggregateOutputType | null - _min: CalendarMinAggregateOutputType | null - _max: CalendarMaxAggregateOutputType | null - } - - type GetCalendarGroupByPayload = Prisma.PrismaPromise< - Array< - PickEnumerable & - { - [P in ((keyof T) & (keyof CalendarGroupByOutputType))]: P extends '_count' - ? T[P] extends boolean - ? number - : GetScalarType - : GetScalarType - } - > - > - - - export type CalendarSelect = $Extensions.GetSelect<{ - id?: boolean - name?: boolean - color?: boolean - description?: boolean - userId?: boolean - createdAt?: boolean - updatedAt?: boolean - events?: boolean | Calendar$eventsArgs - _count?: boolean | CalendarCountOutputTypeDefaultArgs - }, ExtArgs["result"]["calendar"]> - - export type CalendarSelectCreateManyAndReturn = $Extensions.GetSelect<{ - id?: boolean - name?: boolean - color?: boolean - description?: boolean - userId?: boolean - createdAt?: boolean - updatedAt?: boolean - }, ExtArgs["result"]["calendar"]> - - export type CalendarSelectUpdateManyAndReturn = $Extensions.GetSelect<{ - id?: boolean - name?: boolean - color?: boolean - description?: boolean - userId?: boolean - createdAt?: boolean - updatedAt?: boolean - }, ExtArgs["result"]["calendar"]> - - export type CalendarSelectScalar = { - id?: boolean - name?: boolean - color?: boolean - description?: boolean - userId?: boolean - createdAt?: boolean - updatedAt?: boolean - } - - export type CalendarOmit = $Extensions.GetOmit<"id" | "name" | "color" | "description" | "userId" | "createdAt" | "updatedAt", ExtArgs["result"]["calendar"]> - export type CalendarInclude = { - events?: boolean | Calendar$eventsArgs - _count?: boolean | CalendarCountOutputTypeDefaultArgs - } - export type CalendarIncludeCreateManyAndReturn = {} - export type CalendarIncludeUpdateManyAndReturn = {} - - export type $CalendarPayload = { - name: "Calendar" - objects: { - events: Prisma.$EventPayload[] - } - scalars: $Extensions.GetPayloadResult<{ - id: string - name: string - color: string - description: string | null - userId: string - createdAt: Date - updatedAt: Date - }, ExtArgs["result"]["calendar"]> - composites: {} - } - - type CalendarGetPayload = $Result.GetResult - - type CalendarCountArgs = - Omit & { - select?: CalendarCountAggregateInputType | true - } - - export interface CalendarDelegate { - [K: symbol]: { types: Prisma.TypeMap['model']['Calendar'], meta: { name: 'Calendar' } } - /** - * Find zero or one Calendar that matches the filter. - * @param {CalendarFindUniqueArgs} args - Arguments to find a Calendar - * @example - * // Get one Calendar - * const calendar = await prisma.calendar.findUnique({ - * where: { - * // ... provide filter here - * } - * }) - */ - findUnique(args: SelectSubset>): Prisma__CalendarClient<$Result.GetResult, T, "findUnique", ClientOptions> | null, null, ExtArgs, ClientOptions> - - /** - * Find one Calendar that matches the filter or throw an error with `error.code='P2025'` - * if no matches were found. - * @param {CalendarFindUniqueOrThrowArgs} args - Arguments to find a Calendar - * @example - * // Get one Calendar - * const calendar = await prisma.calendar.findUniqueOrThrow({ - * where: { - * // ... provide filter here - * } - * }) - */ - findUniqueOrThrow(args: SelectSubset>): Prisma__CalendarClient<$Result.GetResult, T, "findUniqueOrThrow", ClientOptions>, never, ExtArgs, ClientOptions> - - /** - * Find the first Calendar that matches the filter. - * Note, that providing `undefined` is treated as the value not being there. - * Read more here: https://pris.ly/d/null-undefined - * @param {CalendarFindFirstArgs} args - Arguments to find a Calendar - * @example - * // Get one Calendar - * const calendar = await prisma.calendar.findFirst({ - * where: { - * // ... provide filter here - * } - * }) - */ - findFirst(args?: SelectSubset>): Prisma__CalendarClient<$Result.GetResult, T, "findFirst", ClientOptions> | null, null, ExtArgs, ClientOptions> - - /** - * Find the first Calendar that matches the filter or - * throw `PrismaKnownClientError` with `P2025` code if no matches were found. - * Note, that providing `undefined` is treated as the value not being there. - * Read more here: https://pris.ly/d/null-undefined - * @param {CalendarFindFirstOrThrowArgs} args - Arguments to find a Calendar - * @example - * // Get one Calendar - * const calendar = await prisma.calendar.findFirstOrThrow({ - * where: { - * // ... provide filter here - * } - * }) - */ - findFirstOrThrow(args?: SelectSubset>): Prisma__CalendarClient<$Result.GetResult, T, "findFirstOrThrow", ClientOptions>, never, ExtArgs, ClientOptions> - - /** - * Find zero or more Calendars that matches the filter. - * Note, that providing `undefined` is treated as the value not being there. - * Read more here: https://pris.ly/d/null-undefined - * @param {CalendarFindManyArgs} args - Arguments to filter and select certain fields only. - * @example - * // Get all Calendars - * const calendars = await prisma.calendar.findMany() - * - * // Get first 10 Calendars - * const calendars = await prisma.calendar.findMany({ take: 10 }) - * - * // Only select the `id` - * const calendarWithIdOnly = await prisma.calendar.findMany({ select: { id: true } }) - * - */ - findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany", ClientOptions>> - - /** - * Create a Calendar. - * @param {CalendarCreateArgs} args - Arguments to create a Calendar. - * @example - * // Create one Calendar - * const Calendar = await prisma.calendar.create({ - * data: { - * // ... data to create a Calendar - * } - * }) - * - */ - create(args: SelectSubset>): Prisma__CalendarClient<$Result.GetResult, T, "create", ClientOptions>, never, ExtArgs, ClientOptions> - - /** - * Create many Calendars. - * @param {CalendarCreateManyArgs} args - Arguments to create many Calendars. - * @example - * // Create many Calendars - * const calendar = await prisma.calendar.createMany({ - * data: [ - * // ... provide data here - * ] - * }) - * - */ - createMany(args?: SelectSubset>): Prisma.PrismaPromise - - /** - * Create many Calendars and returns the data saved in the database. - * @param {CalendarCreateManyAndReturnArgs} args - Arguments to create many Calendars. - * @example - * // Create many Calendars - * const calendar = await prisma.calendar.createManyAndReturn({ - * data: [ - * // ... provide data here - * ] - * }) - * - * // Create many Calendars and only return the `id` - * const calendarWithIdOnly = await prisma.calendar.createManyAndReturn({ - * select: { id: true }, - * data: [ - * // ... provide data here - * ] - * }) - * Note, that providing `undefined` is treated as the value not being there. - * Read more here: https://pris.ly/d/null-undefined - * - */ - createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn", ClientOptions>> - - /** - * Delete a Calendar. - * @param {CalendarDeleteArgs} args - Arguments to delete one Calendar. - * @example - * // Delete one Calendar - * const Calendar = await prisma.calendar.delete({ - * where: { - * // ... filter to delete one Calendar - * } - * }) - * - */ - delete(args: SelectSubset>): Prisma__CalendarClient<$Result.GetResult, T, "delete", ClientOptions>, never, ExtArgs, ClientOptions> - - /** - * Update one Calendar. - * @param {CalendarUpdateArgs} args - Arguments to update one Calendar. - * @example - * // Update one Calendar - * const calendar = await prisma.calendar.update({ - * where: { - * // ... provide filter here - * }, - * data: { - * // ... provide data here - * } - * }) - * - */ - update(args: SelectSubset>): Prisma__CalendarClient<$Result.GetResult, T, "update", ClientOptions>, never, ExtArgs, ClientOptions> - - /** - * Delete zero or more Calendars. - * @param {CalendarDeleteManyArgs} args - Arguments to filter Calendars to delete. - * @example - * // Delete a few Calendars - * const { count } = await prisma.calendar.deleteMany({ - * where: { - * // ... provide filter here - * } - * }) - * - */ - deleteMany(args?: SelectSubset>): Prisma.PrismaPromise - - /** - * Update zero or more Calendars. - * Note, that providing `undefined` is treated as the value not being there. - * Read more here: https://pris.ly/d/null-undefined - * @param {CalendarUpdateManyArgs} args - Arguments to update one or more rows. - * @example - * // Update many Calendars - * const calendar = await prisma.calendar.updateMany({ - * where: { - * // ... provide filter here - * }, - * data: { - * // ... provide data here - * } - * }) - * - */ - updateMany(args: SelectSubset>): Prisma.PrismaPromise - - /** - * Update zero or more Calendars and returns the data updated in the database. - * @param {CalendarUpdateManyAndReturnArgs} args - Arguments to update many Calendars. - * @example - * // Update many Calendars - * const calendar = await prisma.calendar.updateManyAndReturn({ - * where: { - * // ... provide filter here - * }, - * data: [ - * // ... provide data here - * ] - * }) - * - * // Update zero or more Calendars and only return the `id` - * const calendarWithIdOnly = await prisma.calendar.updateManyAndReturn({ - * select: { id: true }, - * where: { - * // ... provide filter here - * }, - * data: [ - * // ... provide data here - * ] - * }) - * Note, that providing `undefined` is treated as the value not being there. - * Read more here: https://pris.ly/d/null-undefined - * - */ - updateManyAndReturn(args: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "updateManyAndReturn", ClientOptions>> - - /** - * Create or update one Calendar. - * @param {CalendarUpsertArgs} args - Arguments to update or create a Calendar. - * @example - * // Update or create a Calendar - * const calendar = await prisma.calendar.upsert({ - * create: { - * // ... data to create a Calendar - * }, - * update: { - * // ... in case it already exists, update - * }, - * where: { - * // ... the filter for the Calendar we want to update - * } - * }) - */ - upsert(args: SelectSubset>): Prisma__CalendarClient<$Result.GetResult, T, "upsert", ClientOptions>, never, ExtArgs, ClientOptions> - - - /** - * Count the number of Calendars. - * Note, that providing `undefined` is treated as the value not being there. - * Read more here: https://pris.ly/d/null-undefined - * @param {CalendarCountArgs} args - Arguments to filter Calendars to count. - * @example - * // Count the number of Calendars - * const count = await prisma.calendar.count({ - * where: { - * // ... the filter for the Calendars we want to count - * } - * }) - **/ - count( - args?: Subset, - ): Prisma.PrismaPromise< - T extends $Utils.Record<'select', any> - ? T['select'] extends true - ? number - : GetScalarType - : number - > - - /** - * Allows you to perform aggregations operations on a Calendar. - * Note, that providing `undefined` is treated as the value not being there. - * Read more here: https://pris.ly/d/null-undefined - * @param {CalendarAggregateArgs} args - Select which aggregations you would like to apply and on what fields. - * @example - * // Ordered by age ascending - * // Where email contains prisma.io - * // Limited to the 10 users - * const aggregations = await prisma.user.aggregate({ - * _avg: { - * age: true, - * }, - * where: { - * email: { - * contains: "prisma.io", - * }, - * }, - * orderBy: { - * age: "asc", - * }, - * take: 10, - * }) - **/ - aggregate(args: Subset): Prisma.PrismaPromise> - - /** - * Group by Calendar. - * Note, that providing `undefined` is treated as the value not being there. - * Read more here: https://pris.ly/d/null-undefined - * @param {CalendarGroupByArgs} args - Group by arguments. - * @example - * // Group by city, order by createdAt, get count - * const result = await prisma.user.groupBy({ - * by: ['city', 'createdAt'], - * orderBy: { - * createdAt: true - * }, - * _count: { - * _all: true - * }, - * }) - * - **/ - groupBy< - T extends CalendarGroupByArgs, - HasSelectOrTake extends Or< - Extends<'skip', Keys>, - Extends<'take', Keys> - >, - OrderByArg extends True extends HasSelectOrTake - ? { orderBy: CalendarGroupByArgs['orderBy'] } - : { orderBy?: CalendarGroupByArgs['orderBy'] }, - OrderFields extends ExcludeUnderscoreKeys>>, - ByFields extends MaybeTupleToUnion, - ByValid extends Has, - HavingFields extends GetHavingFields, - HavingValid extends Has, - ByEmpty extends T['by'] extends never[] ? True : False, - InputErrors extends ByEmpty extends True - ? `Error: "by" must not be empty.` - : HavingValid extends False - ? { - [P in HavingFields]: P extends ByFields - ? never - : P extends string - ? `Error: Field "${P}" used in "having" needs to be provided in "by".` - : [ - Error, - 'Field ', - P, - ` in "having" needs to be provided in "by"`, - ] - }[HavingFields] - : 'take' extends Keys - ? 'orderBy' extends Keys - ? ByValid extends True - ? {} - : { - [P in OrderFields]: P extends ByFields - ? never - : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` - }[OrderFields] - : 'Error: If you provide "take", you also need to provide "orderBy"' - : 'skip' extends Keys - ? 'orderBy' extends Keys - ? ByValid extends True - ? {} - : { - [P in OrderFields]: P extends ByFields - ? never - : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` - }[OrderFields] - : 'Error: If you provide "skip", you also need to provide "orderBy"' - : ByValid extends True - ? {} - : { - [P in OrderFields]: P extends ByFields - ? never - : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` - }[OrderFields] - >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetCalendarGroupByPayload : Prisma.PrismaPromise - /** - * Fields of the Calendar model - */ - readonly fields: CalendarFieldRefs; - } - - /** - * The delegate class that acts as a "Promise-like" for Calendar. - * Why is this prefixed with `Prisma__`? - * Because we want to prevent naming conflicts as mentioned in - * https://github.com/prisma/prisma-client-js/issues/707 - */ - export interface Prisma__CalendarClient extends Prisma.PrismaPromise { - readonly [Symbol.toStringTag]: "PrismaPromise" - events = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany", ClientOptions> | Null> - /** - * Attaches callbacks for the resolution and/or rejection of the Promise. - * @param onfulfilled The callback to execute when the Promise is resolved. - * @param onrejected The callback to execute when the Promise is rejected. - * @returns A Promise for the completion of which ever callback is executed. - */ - then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise - /** - * Attaches a callback for only the rejection of the Promise. - * @param onrejected The callback to execute when the Promise is rejected. - * @returns A Promise for the completion of the callback. - */ - catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise - /** - * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The - * resolved value cannot be modified from the callback. - * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). - * @returns A Promise for the completion of the callback. - */ - finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise - } - - - - - /** - * Fields of the Calendar model - */ - interface CalendarFieldRefs { - readonly id: FieldRef<"Calendar", 'String'> - readonly name: FieldRef<"Calendar", 'String'> - readonly color: FieldRef<"Calendar", 'String'> - readonly description: FieldRef<"Calendar", 'String'> - readonly userId: FieldRef<"Calendar", 'String'> - readonly createdAt: FieldRef<"Calendar", 'DateTime'> - readonly updatedAt: FieldRef<"Calendar", 'DateTime'> - } - - - // Custom InputTypes - /** - * Calendar findUnique - */ - export type CalendarFindUniqueArgs = { - /** - * Select specific fields to fetch from the Calendar - */ - select?: CalendarSelect | null - /** - * Omit specific fields from the Calendar - */ - omit?: CalendarOmit | null - /** - * Choose, which related nodes to fetch as well - */ - include?: CalendarInclude | null - /** - * Filter, which Calendar to fetch. - */ - where: CalendarWhereUniqueInput - } - - /** - * Calendar findUniqueOrThrow - */ - export type CalendarFindUniqueOrThrowArgs = { - /** - * Select specific fields to fetch from the Calendar - */ - select?: CalendarSelect | null - /** - * Omit specific fields from the Calendar - */ - omit?: CalendarOmit | null - /** - * Choose, which related nodes to fetch as well - */ - include?: CalendarInclude | null - /** - * Filter, which Calendar to fetch. - */ - where: CalendarWhereUniqueInput - } - - /** - * Calendar findFirst - */ - export type CalendarFindFirstArgs = { - /** - * Select specific fields to fetch from the Calendar - */ - select?: CalendarSelect | null - /** - * Omit specific fields from the Calendar - */ - omit?: CalendarOmit | null - /** - * Choose, which related nodes to fetch as well - */ - include?: CalendarInclude | null - /** - * Filter, which Calendar to fetch. - */ - where?: CalendarWhereInput - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} - * - * Determine the order of Calendars to fetch. - */ - orderBy?: CalendarOrderByWithRelationInput | CalendarOrderByWithRelationInput[] - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} - * - * Sets the position for searching for Calendars. - */ - cursor?: CalendarWhereUniqueInput - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} - * - * Take `±n` Calendars from the position of the cursor. - */ - take?: number - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} - * - * Skip the first `n` Calendars. - */ - skip?: number - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} - * - * Filter by unique combinations of Calendars. - */ - distinct?: CalendarScalarFieldEnum | CalendarScalarFieldEnum[] - } - - /** - * Calendar findFirstOrThrow - */ - export type CalendarFindFirstOrThrowArgs = { - /** - * Select specific fields to fetch from the Calendar - */ - select?: CalendarSelect | null - /** - * Omit specific fields from the Calendar - */ - omit?: CalendarOmit | null - /** - * Choose, which related nodes to fetch as well - */ - include?: CalendarInclude | null - /** - * Filter, which Calendar to fetch. - */ - where?: CalendarWhereInput - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} - * - * Determine the order of Calendars to fetch. - */ - orderBy?: CalendarOrderByWithRelationInput | CalendarOrderByWithRelationInput[] - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} - * - * Sets the position for searching for Calendars. - */ - cursor?: CalendarWhereUniqueInput - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} - * - * Take `±n` Calendars from the position of the cursor. - */ - take?: number - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} - * - * Skip the first `n` Calendars. - */ - skip?: number - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} - * - * Filter by unique combinations of Calendars. - */ - distinct?: CalendarScalarFieldEnum | CalendarScalarFieldEnum[] - } - - /** - * Calendar findMany - */ - export type CalendarFindManyArgs = { - /** - * Select specific fields to fetch from the Calendar - */ - select?: CalendarSelect | null - /** - * Omit specific fields from the Calendar - */ - omit?: CalendarOmit | null - /** - * Choose, which related nodes to fetch as well - */ - include?: CalendarInclude | null - /** - * Filter, which Calendars to fetch. - */ - where?: CalendarWhereInput - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} - * - * Determine the order of Calendars to fetch. - */ - orderBy?: CalendarOrderByWithRelationInput | CalendarOrderByWithRelationInput[] - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} - * - * Sets the position for listing Calendars. - */ - cursor?: CalendarWhereUniqueInput - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} - * - * Take `±n` Calendars from the position of the cursor. - */ - take?: number - /** - * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} - * - * Skip the first `n` Calendars. - */ - skip?: number - distinct?: CalendarScalarFieldEnum | CalendarScalarFieldEnum[] - } - - /** - * Calendar create - */ - export type CalendarCreateArgs = { - /** - * Select specific fields to fetch from the Calendar - */ - select?: CalendarSelect | null - /** - * Omit specific fields from the Calendar - */ - omit?: CalendarOmit | null - /** - * Choose, which related nodes to fetch as well - */ - include?: CalendarInclude | null - /** - * The data needed to create a Calendar. - */ - data: XOR - } - - /** - * Calendar createMany - */ - export type CalendarCreateManyArgs = { - /** - * The data used to create many Calendars. - */ - data: CalendarCreateManyInput | CalendarCreateManyInput[] - skipDuplicates?: boolean - } - - /** - * Calendar createManyAndReturn - */ - export type CalendarCreateManyAndReturnArgs = { - /** - * Select specific fields to fetch from the Calendar - */ - select?: CalendarSelectCreateManyAndReturn | null - /** - * Omit specific fields from the Calendar - */ - omit?: CalendarOmit | null - /** - * The data used to create many Calendars. - */ - data: CalendarCreateManyInput | CalendarCreateManyInput[] - skipDuplicates?: boolean - } - - /** - * Calendar update - */ - export type CalendarUpdateArgs = { - /** - * Select specific fields to fetch from the Calendar - */ - select?: CalendarSelect | null - /** - * Omit specific fields from the Calendar - */ - omit?: CalendarOmit | null - /** - * Choose, which related nodes to fetch as well - */ - include?: CalendarInclude | null - /** - * The data needed to update a Calendar. - */ - data: XOR - /** - * Choose, which Calendar to update. - */ - where: CalendarWhereUniqueInput - } - - /** - * Calendar updateMany - */ - export type CalendarUpdateManyArgs = { - /** - * The data used to update Calendars. - */ - data: XOR - /** - * Filter which Calendars to update - */ - where?: CalendarWhereInput - /** - * Limit how many Calendars to update. - */ - limit?: number - } - - /** - * Calendar updateManyAndReturn - */ - export type CalendarUpdateManyAndReturnArgs = { - /** - * Select specific fields to fetch from the Calendar - */ - select?: CalendarSelectUpdateManyAndReturn | null - /** - * Omit specific fields from the Calendar - */ - omit?: CalendarOmit | null - /** - * The data used to update Calendars. - */ - data: XOR - /** - * Filter which Calendars to update - */ - where?: CalendarWhereInput - /** - * Limit how many Calendars to update. - */ - limit?: number - } - - /** - * Calendar upsert - */ - export type CalendarUpsertArgs = { - /** - * Select specific fields to fetch from the Calendar - */ - select?: CalendarSelect | null - /** - * Omit specific fields from the Calendar - */ - omit?: CalendarOmit | null - /** - * Choose, which related nodes to fetch as well - */ - include?: CalendarInclude | null - /** - * The filter to search for the Calendar to update in case it exists. - */ - where: CalendarWhereUniqueInput - /** - * In case the Calendar found by the `where` argument doesn't exist, create a new Calendar with this data. - */ - create: XOR - /** - * In case the Calendar was found with the provided `where` argument, update it with this data. - */ - update: XOR - } - - /** - * Calendar delete - */ - export type CalendarDeleteArgs = { - /** - * Select specific fields to fetch from the Calendar - */ - select?: CalendarSelect | null - /** - * Omit specific fields from the Calendar - */ - omit?: CalendarOmit | null - /** - * Choose, which related nodes to fetch as well - */ - include?: CalendarInclude | null - /** - * Filter which Calendar to delete. - */ - where: CalendarWhereUniqueInput - } - - /** - * Calendar deleteMany - */ - export type CalendarDeleteManyArgs = { - /** - * Filter which Calendars to delete - */ - where?: CalendarWhereInput - /** - * Limit how many Calendars to delete. - */ - limit?: number - } - - /** - * Calendar.events - */ - export type Calendar$eventsArgs = { - /** - * Select specific fields to fetch from the Event - */ - select?: EventSelect | null - /** - * Omit specific fields from the Event - */ - omit?: EventOmit | null - /** - * Choose, which related nodes to fetch as well - */ - include?: EventInclude | null - where?: EventWhereInput - orderBy?: EventOrderByWithRelationInput | EventOrderByWithRelationInput[] - cursor?: EventWhereUniqueInput - take?: number - skip?: number - distinct?: EventScalarFieldEnum | EventScalarFieldEnum[] - } - - /** - * Calendar without action - */ - export type CalendarDefaultArgs = { - /** - * Select specific fields to fetch from the Calendar - */ - select?: CalendarSelect | null - /** - * Omit specific fields from the Calendar - */ - omit?: CalendarOmit | null - /** - * Choose, which related nodes to fetch as well - */ - include?: CalendarInclude | null - } - - - /** - * Model Event - */ - - export type AggregateEvent = { - _count: EventCountAggregateOutputType | null - _min: EventMinAggregateOutputType | null - _max: EventMaxAggregateOutputType | null - } - - export type EventMinAggregateOutputType = { - id: string | null + export type NewsMinAggregateOutputType = { + id: number | null title: string | null + url: string | null + date: Date | null + source: string | null + content: string | null + sentiment_score: number | null + sentiment: string | null + symbol: string | null + processed_at: Date | null description: string | null - start: Date | null - end: Date | null - location: string | null - isAllDay: boolean | null - calendarId: string | null - createdAt: Date | null - updatedAt: Date | null + category: string | null } - export type EventMaxAggregateOutputType = { - id: string | null + export type NewsMaxAggregateOutputType = { + id: number | null title: string | null + url: string | null + date: Date | null + source: string | null + content: string | null + sentiment_score: number | null + sentiment: string | null + symbol: string | null + processed_at: Date | null description: string | null - start: Date | null - end: Date | null - location: string | null - isAllDay: boolean | null - calendarId: string | null - createdAt: Date | null - updatedAt: Date | null + category: string | null } - export type EventCountAggregateOutputType = { + export type NewsCountAggregateOutputType = { id: number title: number + url: number + date: number + source: number + content: number + sentiment_score: number + sentiment: number + symbols: number + symbol: number + processed_at: number description: number - start: number - end: number - location: number - isAllDay: number - calendarId: number - createdAt: number - updatedAt: number + category: number _all: number } - export type EventMinAggregateInputType = { + export type NewsAvgAggregateInputType = { id?: true - title?: true - description?: true - start?: true - end?: true - location?: true - isAllDay?: true - calendarId?: true - createdAt?: true - updatedAt?: true + sentiment_score?: true } - export type EventMaxAggregateInputType = { + export type NewsSumAggregateInputType = { id?: true - title?: true - description?: true - start?: true - end?: true - location?: true - isAllDay?: true - calendarId?: true - createdAt?: true - updatedAt?: true + sentiment_score?: true } - export type EventCountAggregateInputType = { + export type NewsMinAggregateInputType = { id?: true title?: true + url?: true + date?: true + source?: true + content?: true + sentiment_score?: true + sentiment?: true + symbol?: true + processed_at?: true description?: true - start?: true - end?: true - location?: true - isAllDay?: true - calendarId?: true - createdAt?: true - updatedAt?: true + category?: true + } + + export type NewsMaxAggregateInputType = { + id?: true + title?: true + url?: true + date?: true + source?: true + content?: true + sentiment_score?: true + sentiment?: true + symbol?: true + processed_at?: true + description?: true + category?: true + } + + export type NewsCountAggregateInputType = { + id?: true + title?: true + url?: true + date?: true + source?: true + content?: true + sentiment_score?: true + sentiment?: true + symbols?: true + symbol?: true + processed_at?: true + description?: true + category?: true _all?: true } - export type EventAggregateArgs = { + export type NewsAggregateArgs = { /** - * Filter which Event to aggregate. + * Filter which News to aggregate. */ - where?: EventWhereInput + where?: NewsWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * - * Determine the order of Events to fetch. + * Determine the order of News to fetch. */ - orderBy?: EventOrderByWithRelationInput | EventOrderByWithRelationInput[] + orderBy?: NewsOrderByWithRelationInput | NewsOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ - cursor?: EventWhereUniqueInput + cursor?: NewsWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * - * Take `±n` Events from the position of the cursor. + * Take `±n` News from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * - * Skip the first `n` Events. + * Skip the first `n` News. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * - * Count returned Events + * Count returned News **/ - _count?: true | EventCountAggregateInputType + _count?: true | NewsCountAggregateInputType + /** + * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} + * + * Select which fields to average + **/ + _avg?: NewsAvgAggregateInputType + /** + * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} + * + * Select which fields to sum + **/ + _sum?: NewsSumAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ - _min?: EventMinAggregateInputType + _min?: NewsMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ - _max?: EventMaxAggregateInputType + _max?: NewsMaxAggregateInputType } - export type GetEventAggregateType = { - [P in keyof T & keyof AggregateEvent]: P extends '_count' | 'count' + export type GetNewsAggregateType = { + [P in keyof T & keyof AggregateNews]: P extends '_count' | 'count' ? T[P] extends true ? number - : GetScalarType - : GetScalarType + : GetScalarType + : GetScalarType } - export type EventGroupByArgs = { - where?: EventWhereInput - orderBy?: EventOrderByWithAggregationInput | EventOrderByWithAggregationInput[] - by: EventScalarFieldEnum[] | EventScalarFieldEnum - having?: EventScalarWhereWithAggregatesInput + export type NewsGroupByArgs = { + where?: NewsWhereInput + orderBy?: NewsOrderByWithAggregationInput | NewsOrderByWithAggregationInput[] + by: NewsScalarFieldEnum[] | NewsScalarFieldEnum + having?: NewsScalarWhereWithAggregatesInput take?: number skip?: number - _count?: EventCountAggregateInputType | true - _min?: EventMinAggregateInputType - _max?: EventMaxAggregateInputType + _count?: NewsCountAggregateInputType | true + _avg?: NewsAvgAggregateInputType + _sum?: NewsSumAggregateInputType + _min?: NewsMinAggregateInputType + _max?: NewsMaxAggregateInputType } - export type EventGroupByOutputType = { - id: string + export type NewsGroupByOutputType = { + id: number title: string + url: string + date: Date + source: string + content: string | null + sentiment_score: number | null + sentiment: string | null + symbols: string[] + symbol: string | null + processed_at: Date description: string | null - start: Date - end: Date - location: string | null - isAllDay: boolean - calendarId: string - createdAt: Date - updatedAt: Date - _count: EventCountAggregateOutputType | null - _min: EventMinAggregateOutputType | null - _max: EventMaxAggregateOutputType | null + category: string | null + _count: NewsCountAggregateOutputType | null + _avg: NewsAvgAggregateOutputType | null + _sum: NewsSumAggregateOutputType | null + _min: NewsMinAggregateOutputType | null + _max: NewsMaxAggregateOutputType | null } - type GetEventGroupByPayload = Prisma.PrismaPromise< + type GetNewsGroupByPayload = Prisma.PrismaPromise< Array< - PickEnumerable & + PickEnumerable & { - [P in ((keyof T) & (keyof EventGroupByOutputType))]: P extends '_count' + [P in ((keyof T) & (keyof NewsGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number - : GetScalarType - : GetScalarType + : GetScalarType + : GetScalarType } > > - export type EventSelect = $Extensions.GetSelect<{ + export type NewsSelect = $Extensions.GetSelect<{ id?: boolean title?: boolean + url?: boolean + date?: boolean + source?: boolean + content?: boolean + sentiment_score?: boolean + sentiment?: boolean + symbols?: boolean + symbol?: boolean + processed_at?: boolean description?: boolean - start?: boolean - end?: boolean - location?: boolean - isAllDay?: boolean - calendarId?: boolean - createdAt?: boolean - updatedAt?: boolean - calendar?: boolean | CalendarDefaultArgs - }, ExtArgs["result"]["event"]> + category?: boolean + }, ExtArgs["result"]["news"]> - export type EventSelectCreateManyAndReturn = $Extensions.GetSelect<{ + export type NewsSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean title?: boolean + url?: boolean + date?: boolean + source?: boolean + content?: boolean + sentiment_score?: boolean + sentiment?: boolean + symbols?: boolean + symbol?: boolean + processed_at?: boolean description?: boolean - start?: boolean - end?: boolean - location?: boolean - isAllDay?: boolean - calendarId?: boolean - createdAt?: boolean - updatedAt?: boolean - calendar?: boolean | CalendarDefaultArgs - }, ExtArgs["result"]["event"]> + category?: boolean + }, ExtArgs["result"]["news"]> - export type EventSelectUpdateManyAndReturn = $Extensions.GetSelect<{ + export type NewsSelectUpdateManyAndReturn = $Extensions.GetSelect<{ id?: boolean title?: boolean + url?: boolean + date?: boolean + source?: boolean + content?: boolean + sentiment_score?: boolean + sentiment?: boolean + symbols?: boolean + symbol?: boolean + processed_at?: boolean description?: boolean - start?: boolean - end?: boolean - location?: boolean - isAllDay?: boolean - calendarId?: boolean - createdAt?: boolean - updatedAt?: boolean - calendar?: boolean | CalendarDefaultArgs - }, ExtArgs["result"]["event"]> + category?: boolean + }, ExtArgs["result"]["news"]> - export type EventSelectScalar = { + export type NewsSelectScalar = { id?: boolean title?: boolean + url?: boolean + date?: boolean + source?: boolean + content?: boolean + sentiment_score?: boolean + sentiment?: boolean + symbols?: boolean + symbol?: boolean + processed_at?: boolean description?: boolean - start?: boolean - end?: boolean - location?: boolean - isAllDay?: boolean - calendarId?: boolean - createdAt?: boolean - updatedAt?: boolean + category?: boolean } - export type EventOmit = $Extensions.GetOmit<"id" | "title" | "description" | "start" | "end" | "location" | "isAllDay" | "calendarId" | "createdAt" | "updatedAt", ExtArgs["result"]["event"]> - export type EventInclude = { - calendar?: boolean | CalendarDefaultArgs - } - export type EventIncludeCreateManyAndReturn = { - calendar?: boolean | CalendarDefaultArgs - } - export type EventIncludeUpdateManyAndReturn = { - calendar?: boolean | CalendarDefaultArgs - } + export type NewsOmit = $Extensions.GetOmit<"id" | "title" | "url" | "date" | "source" | "content" | "sentiment_score" | "sentiment" | "symbols" | "symbol" | "processed_at" | "description" | "category", ExtArgs["result"]["news"]> - export type $EventPayload = { - name: "Event" - objects: { - calendar: Prisma.$CalendarPayload - } + export type $NewsPayload = { + name: "News" + objects: {} scalars: $Extensions.GetPayloadResult<{ - id: string + id: number title: string + url: string + date: Date + source: string + content: string | null + sentiment_score: number | null + sentiment: string | null + symbols: string[] + symbol: string | null + processed_at: Date description: string | null - start: Date - end: Date - location: string | null - isAllDay: boolean - calendarId: string - createdAt: Date - updatedAt: Date - }, ExtArgs["result"]["event"]> + category: string | null + }, ExtArgs["result"]["news"]> composites: {} } - type EventGetPayload = $Result.GetResult + type NewsGetPayload = $Result.GetResult - type EventCountArgs = - Omit & { - select?: EventCountAggregateInputType | true + type NewsCountArgs = + Omit & { + select?: NewsCountAggregateInputType | true } - export interface EventDelegate { - [K: symbol]: { types: Prisma.TypeMap['model']['Event'], meta: { name: 'Event' } } + export interface NewsDelegate { + [K: symbol]: { types: Prisma.TypeMap['model']['News'], meta: { name: 'News' } } /** - * Find zero or one Event that matches the filter. - * @param {EventFindUniqueArgs} args - Arguments to find a Event + * Find zero or one News that matches the filter. + * @param {NewsFindUniqueArgs} args - Arguments to find a News * @example - * // Get one Event - * const event = await prisma.event.findUnique({ + * // Get one News + * const news = await prisma.news.findUnique({ * where: { * // ... provide filter here * } * }) */ - findUnique(args: SelectSubset>): Prisma__EventClient<$Result.GetResult, T, "findUnique", ClientOptions> | null, null, ExtArgs, ClientOptions> + findUnique(args: SelectSubset>): Prisma__NewsClient<$Result.GetResult, T, "findUnique", ClientOptions> | null, null, ExtArgs, ClientOptions> /** - * Find one Event that matches the filter or throw an error with `error.code='P2025'` + * Find one News that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. - * @param {EventFindUniqueOrThrowArgs} args - Arguments to find a Event + * @param {NewsFindUniqueOrThrowArgs} args - Arguments to find a News * @example - * // Get one Event - * const event = await prisma.event.findUniqueOrThrow({ + * // Get one News + * const news = await prisma.news.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ - findUniqueOrThrow(args: SelectSubset>): Prisma__EventClient<$Result.GetResult, T, "findUniqueOrThrow", ClientOptions>, never, ExtArgs, ClientOptions> + findUniqueOrThrow(args: SelectSubset>): Prisma__NewsClient<$Result.GetResult, T, "findUniqueOrThrow", ClientOptions>, never, ExtArgs, ClientOptions> /** - * Find the first Event that matches the filter. + * Find the first News that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined - * @param {EventFindFirstArgs} args - Arguments to find a Event + * @param {NewsFindFirstArgs} args - Arguments to find a News * @example - * // Get one Event - * const event = await prisma.event.findFirst({ + * // Get one News + * const news = await prisma.news.findFirst({ * where: { * // ... provide filter here * } * }) */ - findFirst(args?: SelectSubset>): Prisma__EventClient<$Result.GetResult, T, "findFirst", ClientOptions> | null, null, ExtArgs, ClientOptions> + findFirst(args?: SelectSubset>): Prisma__NewsClient<$Result.GetResult, T, "findFirst", ClientOptions> | null, null, ExtArgs, ClientOptions> /** - * Find the first Event that matches the filter or + * Find the first News that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined - * @param {EventFindFirstOrThrowArgs} args - Arguments to find a Event + * @param {NewsFindFirstOrThrowArgs} args - Arguments to find a News * @example - * // Get one Event - * const event = await prisma.event.findFirstOrThrow({ + * // Get one News + * const news = await prisma.news.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ - findFirstOrThrow(args?: SelectSubset>): Prisma__EventClient<$Result.GetResult, T, "findFirstOrThrow", ClientOptions>, never, ExtArgs, ClientOptions> + findFirstOrThrow(args?: SelectSubset>): Prisma__NewsClient<$Result.GetResult, T, "findFirstOrThrow", ClientOptions>, never, ExtArgs, ClientOptions> /** - * Find zero or more Events that matches the filter. + * Find zero or more News that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined - * @param {EventFindManyArgs} args - Arguments to filter and select certain fields only. + * @param {NewsFindManyArgs} args - Arguments to filter and select certain fields only. * @example - * // Get all Events - * const events = await prisma.event.findMany() + * // Get all News + * const news = await prisma.news.findMany() * - * // Get first 10 Events - * const events = await prisma.event.findMany({ take: 10 }) + * // Get first 10 News + * const news = await prisma.news.findMany({ take: 10 }) * * // Only select the `id` - * const eventWithIdOnly = await prisma.event.findMany({ select: { id: true } }) + * const newsWithIdOnly = await prisma.news.findMany({ select: { id: true } }) * */ - findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany", ClientOptions>> + findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany", ClientOptions>> /** - * Create a Event. - * @param {EventCreateArgs} args - Arguments to create a Event. + * Create a News. + * @param {NewsCreateArgs} args - Arguments to create a News. * @example - * // Create one Event - * const Event = await prisma.event.create({ + * // Create one News + * const News = await prisma.news.create({ * data: { - * // ... data to create a Event + * // ... data to create a News * } * }) * */ - create(args: SelectSubset>): Prisma__EventClient<$Result.GetResult, T, "create", ClientOptions>, never, ExtArgs, ClientOptions> + create(args: SelectSubset>): Prisma__NewsClient<$Result.GetResult, T, "create", ClientOptions>, never, ExtArgs, ClientOptions> /** - * Create many Events. - * @param {EventCreateManyArgs} args - Arguments to create many Events. + * Create many News. + * @param {NewsCreateManyArgs} args - Arguments to create many News. * @example - * // Create many Events - * const event = await prisma.event.createMany({ + * // Create many News + * const news = await prisma.news.createMany({ * data: [ * // ... provide data here * ] * }) * */ - createMany(args?: SelectSubset>): Prisma.PrismaPromise + createMany(args?: SelectSubset>): Prisma.PrismaPromise /** - * Create many Events and returns the data saved in the database. - * @param {EventCreateManyAndReturnArgs} args - Arguments to create many Events. + * Create many News and returns the data saved in the database. + * @param {NewsCreateManyAndReturnArgs} args - Arguments to create many News. * @example - * // Create many Events - * const event = await prisma.event.createManyAndReturn({ + * // Create many News + * const news = await prisma.news.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * - * // Create many Events and only return the `id` - * const eventWithIdOnly = await prisma.event.createManyAndReturn({ + * // Create many News and only return the `id` + * const newsWithIdOnly = await prisma.news.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here @@ -2497,28 +1336,28 @@ export namespace Prisma { * Read more here: https://pris.ly/d/null-undefined * */ - createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn", ClientOptions>> + createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn", ClientOptions>> /** - * Delete a Event. - * @param {EventDeleteArgs} args - Arguments to delete one Event. + * Delete a News. + * @param {NewsDeleteArgs} args - Arguments to delete one News. * @example - * // Delete one Event - * const Event = await prisma.event.delete({ + * // Delete one News + * const News = await prisma.news.delete({ * where: { - * // ... filter to delete one Event + * // ... filter to delete one News * } * }) * */ - delete(args: SelectSubset>): Prisma__EventClient<$Result.GetResult, T, "delete", ClientOptions>, never, ExtArgs, ClientOptions> + delete(args: SelectSubset>): Prisma__NewsClient<$Result.GetResult, T, "delete", ClientOptions>, never, ExtArgs, ClientOptions> /** - * Update one Event. - * @param {EventUpdateArgs} args - Arguments to update one Event. + * Update one News. + * @param {NewsUpdateArgs} args - Arguments to update one News. * @example - * // Update one Event - * const event = await prisma.event.update({ + * // Update one News + * const news = await prisma.news.update({ * where: { * // ... provide filter here * }, @@ -2528,30 +1367,30 @@ export namespace Prisma { * }) * */ - update(args: SelectSubset>): Prisma__EventClient<$Result.GetResult, T, "update", ClientOptions>, never, ExtArgs, ClientOptions> + update(args: SelectSubset>): Prisma__NewsClient<$Result.GetResult, T, "update", ClientOptions>, never, ExtArgs, ClientOptions> /** - * Delete zero or more Events. - * @param {EventDeleteManyArgs} args - Arguments to filter Events to delete. + * Delete zero or more News. + * @param {NewsDeleteManyArgs} args - Arguments to filter News to delete. * @example - * // Delete a few Events - * const { count } = await prisma.event.deleteMany({ + * // Delete a few News + * const { count } = await prisma.news.deleteMany({ * where: { * // ... provide filter here * } * }) * */ - deleteMany(args?: SelectSubset>): Prisma.PrismaPromise + deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** - * Update zero or more Events. + * Update zero or more News. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined - * @param {EventUpdateManyArgs} args - Arguments to update one or more rows. + * @param {NewsUpdateManyArgs} args - Arguments to update one or more rows. * @example - * // Update many Events - * const event = await prisma.event.updateMany({ + * // Update many News + * const news = await prisma.news.updateMany({ * where: { * // ... provide filter here * }, @@ -2561,14 +1400,14 @@ export namespace Prisma { * }) * */ - updateMany(args: SelectSubset>): Prisma.PrismaPromise + updateMany(args: SelectSubset>): Prisma.PrismaPromise /** - * Update zero or more Events and returns the data updated in the database. - * @param {EventUpdateManyAndReturnArgs} args - Arguments to update many Events. + * Update zero or more News and returns the data updated in the database. + * @param {NewsUpdateManyAndReturnArgs} args - Arguments to update many News. * @example - * // Update many Events - * const event = await prisma.event.updateManyAndReturn({ + * // Update many News + * const news = await prisma.news.updateManyAndReturn({ * where: { * // ... provide filter here * }, @@ -2577,8 +1416,8 @@ export namespace Prisma { * ] * }) * - * // Update zero or more Events and only return the `id` - * const eventWithIdOnly = await prisma.event.updateManyAndReturn({ + * // Update zero or more News and only return the `id` + * const newsWithIdOnly = await prisma.news.updateManyAndReturn({ * select: { id: true }, * where: { * // ... provide filter here @@ -2591,56 +1430,56 @@ export namespace Prisma { * Read more here: https://pris.ly/d/null-undefined * */ - updateManyAndReturn(args: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "updateManyAndReturn", ClientOptions>> + updateManyAndReturn(args: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "updateManyAndReturn", ClientOptions>> /** - * Create or update one Event. - * @param {EventUpsertArgs} args - Arguments to update or create a Event. + * Create or update one News. + * @param {NewsUpsertArgs} args - Arguments to update or create a News. * @example - * // Update or create a Event - * const event = await prisma.event.upsert({ + * // Update or create a News + * const news = await prisma.news.upsert({ * create: { - * // ... data to create a Event + * // ... data to create a News * }, * update: { * // ... in case it already exists, update * }, * where: { - * // ... the filter for the Event we want to update + * // ... the filter for the News we want to update * } * }) */ - upsert(args: SelectSubset>): Prisma__EventClient<$Result.GetResult, T, "upsert", ClientOptions>, never, ExtArgs, ClientOptions> + upsert(args: SelectSubset>): Prisma__NewsClient<$Result.GetResult, T, "upsert", ClientOptions>, never, ExtArgs, ClientOptions> /** - * Count the number of Events. + * Count the number of News. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined - * @param {EventCountArgs} args - Arguments to filter Events to count. + * @param {NewsCountArgs} args - Arguments to filter News to count. * @example - * // Count the number of Events - * const count = await prisma.event.count({ + * // Count the number of News + * const count = await prisma.news.count({ * where: { - * // ... the filter for the Events we want to count + * // ... the filter for the News we want to count * } * }) **/ - count( - args?: Subset, + count( + args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number - : GetScalarType + : GetScalarType : number > /** - * Allows you to perform aggregations operations on a Event. + * Allows you to perform aggregations operations on a News. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined - * @param {EventAggregateArgs} args - Select which aggregations you would like to apply and on what fields. + * @param {NewsAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io @@ -2660,13 +1499,13 @@ export namespace Prisma { * take: 10, * }) **/ - aggregate(args: Subset): Prisma.PrismaPromise> + aggregate(args: Subset): Prisma.PrismaPromise> /** - * Group by Event. + * Group by News. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined - * @param {EventGroupByArgs} args - Group by arguments. + * @param {NewsGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ @@ -2681,14 +1520,14 @@ export namespace Prisma { * **/ groupBy< - T extends EventGroupByArgs, + T extends NewsGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake - ? { orderBy: EventGroupByArgs['orderBy'] } - : { orderBy?: EventGroupByArgs['orderBy'] }, + ? { orderBy: NewsGroupByArgs['orderBy'] } + : { orderBy?: NewsGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, @@ -2737,22 +1576,21 @@ export namespace Prisma { ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] - >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetEventGroupByPayload : Prisma.PrismaPromise + >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetNewsGroupByPayload : Prisma.PrismaPromise /** - * Fields of the Event model + * Fields of the News model */ - readonly fields: EventFieldRefs; + readonly fields: NewsFieldRefs; } /** - * The delegate class that acts as a "Promise-like" for Event. + * The delegate class that acts as a "Promise-like" for News. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ - export interface Prisma__EventClient extends Prisma.PrismaPromise { + export interface Prisma__NewsClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" - calendar = {}>(args?: Subset>): Prisma__CalendarClient<$Result.GetResult, T, "findUniqueOrThrow", ClientOptions> | Null, Null, ExtArgs, ClientOptions> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. @@ -2779,430 +1617,385 @@ export namespace Prisma { /** - * Fields of the Event model + * Fields of the News model */ - interface EventFieldRefs { - readonly id: FieldRef<"Event", 'String'> - readonly title: FieldRef<"Event", 'String'> - readonly description: FieldRef<"Event", 'String'> - readonly start: FieldRef<"Event", 'DateTime'> - readonly end: FieldRef<"Event", 'DateTime'> - readonly location: FieldRef<"Event", 'String'> - readonly isAllDay: FieldRef<"Event", 'Boolean'> - readonly calendarId: FieldRef<"Event", 'String'> - readonly createdAt: FieldRef<"Event", 'DateTime'> - readonly updatedAt: FieldRef<"Event", 'DateTime'> + interface NewsFieldRefs { + readonly id: FieldRef<"News", 'Int'> + readonly title: FieldRef<"News", 'String'> + readonly url: FieldRef<"News", 'String'> + readonly date: FieldRef<"News", 'DateTime'> + readonly source: FieldRef<"News", 'String'> + readonly content: FieldRef<"News", 'String'> + readonly sentiment_score: FieldRef<"News", 'Float'> + readonly sentiment: FieldRef<"News", 'String'> + readonly symbols: FieldRef<"News", 'String[]'> + readonly symbol: FieldRef<"News", 'String'> + readonly processed_at: FieldRef<"News", 'DateTime'> + readonly description: FieldRef<"News", 'String'> + readonly category: FieldRef<"News", 'String'> } // Custom InputTypes /** - * Event findUnique + * News findUnique */ - export type EventFindUniqueArgs = { + export type NewsFindUniqueArgs = { /** - * Select specific fields to fetch from the Event + * Select specific fields to fetch from the News */ - select?: EventSelect | null + select?: NewsSelect | null /** - * Omit specific fields from the Event + * Omit specific fields from the News */ - omit?: EventOmit | null + omit?: NewsOmit | null /** - * Choose, which related nodes to fetch as well + * Filter, which News to fetch. */ - include?: EventInclude | null - /** - * Filter, which Event to fetch. - */ - where: EventWhereUniqueInput + where: NewsWhereUniqueInput } /** - * Event findUniqueOrThrow + * News findUniqueOrThrow */ - export type EventFindUniqueOrThrowArgs = { + export type NewsFindUniqueOrThrowArgs = { /** - * Select specific fields to fetch from the Event + * Select specific fields to fetch from the News */ - select?: EventSelect | null + select?: NewsSelect | null /** - * Omit specific fields from the Event + * Omit specific fields from the News */ - omit?: EventOmit | null + omit?: NewsOmit | null /** - * Choose, which related nodes to fetch as well + * Filter, which News to fetch. */ - include?: EventInclude | null - /** - * Filter, which Event to fetch. - */ - where: EventWhereUniqueInput + where: NewsWhereUniqueInput } /** - * Event findFirst + * News findFirst */ - export type EventFindFirstArgs = { + export type NewsFindFirstArgs = { /** - * Select specific fields to fetch from the Event + * Select specific fields to fetch from the News */ - select?: EventSelect | null + select?: NewsSelect | null /** - * Omit specific fields from the Event + * Omit specific fields from the News */ - omit?: EventOmit | null + omit?: NewsOmit | null /** - * Choose, which related nodes to fetch as well + * Filter, which News to fetch. */ - include?: EventInclude | null - /** - * Filter, which Event to fetch. - */ - where?: EventWhereInput + where?: NewsWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * - * Determine the order of Events to fetch. + * Determine the order of News to fetch. */ - orderBy?: EventOrderByWithRelationInput | EventOrderByWithRelationInput[] + orderBy?: NewsOrderByWithRelationInput | NewsOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * - * Sets the position for searching for Events. + * Sets the position for searching for News. */ - cursor?: EventWhereUniqueInput + cursor?: NewsWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * - * Take `±n` Events from the position of the cursor. + * Take `±n` News from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * - * Skip the first `n` Events. + * Skip the first `n` News. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * - * Filter by unique combinations of Events. + * Filter by unique combinations of News. */ - distinct?: EventScalarFieldEnum | EventScalarFieldEnum[] + distinct?: NewsScalarFieldEnum | NewsScalarFieldEnum[] } /** - * Event findFirstOrThrow + * News findFirstOrThrow */ - export type EventFindFirstOrThrowArgs = { + export type NewsFindFirstOrThrowArgs = { /** - * Select specific fields to fetch from the Event + * Select specific fields to fetch from the News */ - select?: EventSelect | null + select?: NewsSelect | null /** - * Omit specific fields from the Event + * Omit specific fields from the News */ - omit?: EventOmit | null + omit?: NewsOmit | null /** - * Choose, which related nodes to fetch as well + * Filter, which News to fetch. */ - include?: EventInclude | null - /** - * Filter, which Event to fetch. - */ - where?: EventWhereInput + where?: NewsWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * - * Determine the order of Events to fetch. + * Determine the order of News to fetch. */ - orderBy?: EventOrderByWithRelationInput | EventOrderByWithRelationInput[] + orderBy?: NewsOrderByWithRelationInput | NewsOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * - * Sets the position for searching for Events. + * Sets the position for searching for News. */ - cursor?: EventWhereUniqueInput + cursor?: NewsWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * - * Take `±n` Events from the position of the cursor. + * Take `±n` News from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * - * Skip the first `n` Events. + * Skip the first `n` News. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * - * Filter by unique combinations of Events. + * Filter by unique combinations of News. */ - distinct?: EventScalarFieldEnum | EventScalarFieldEnum[] + distinct?: NewsScalarFieldEnum | NewsScalarFieldEnum[] } /** - * Event findMany + * News findMany */ - export type EventFindManyArgs = { + export type NewsFindManyArgs = { /** - * Select specific fields to fetch from the Event + * Select specific fields to fetch from the News */ - select?: EventSelect | null + select?: NewsSelect | null /** - * Omit specific fields from the Event + * Omit specific fields from the News */ - omit?: EventOmit | null + omit?: NewsOmit | null /** - * Choose, which related nodes to fetch as well + * Filter, which News to fetch. */ - include?: EventInclude | null - /** - * Filter, which Events to fetch. - */ - where?: EventWhereInput + where?: NewsWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * - * Determine the order of Events to fetch. + * Determine the order of News to fetch. */ - orderBy?: EventOrderByWithRelationInput | EventOrderByWithRelationInput[] + orderBy?: NewsOrderByWithRelationInput | NewsOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * - * Sets the position for listing Events. + * Sets the position for listing News. */ - cursor?: EventWhereUniqueInput + cursor?: NewsWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * - * Take `±n` Events from the position of the cursor. + * Take `±n` News from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * - * Skip the first `n` Events. + * Skip the first `n` News. */ skip?: number - distinct?: EventScalarFieldEnum | EventScalarFieldEnum[] + distinct?: NewsScalarFieldEnum | NewsScalarFieldEnum[] } /** - * Event create + * News create */ - export type EventCreateArgs = { + export type NewsCreateArgs = { /** - * Select specific fields to fetch from the Event + * Select specific fields to fetch from the News */ - select?: EventSelect | null + select?: NewsSelect | null /** - * Omit specific fields from the Event + * Omit specific fields from the News */ - omit?: EventOmit | null + omit?: NewsOmit | null /** - * Choose, which related nodes to fetch as well + * The data needed to create a News. */ - include?: EventInclude | null - /** - * The data needed to create a Event. - */ - data: XOR + data: XOR } /** - * Event createMany + * News createMany */ - export type EventCreateManyArgs = { + export type NewsCreateManyArgs = { /** - * The data used to create many Events. + * The data used to create many News. */ - data: EventCreateManyInput | EventCreateManyInput[] + data: NewsCreateManyInput | NewsCreateManyInput[] skipDuplicates?: boolean } /** - * Event createManyAndReturn + * News createManyAndReturn */ - export type EventCreateManyAndReturnArgs = { + export type NewsCreateManyAndReturnArgs = { /** - * Select specific fields to fetch from the Event + * Select specific fields to fetch from the News */ - select?: EventSelectCreateManyAndReturn | null + select?: NewsSelectCreateManyAndReturn | null /** - * Omit specific fields from the Event + * Omit specific fields from the News */ - omit?: EventOmit | null + omit?: NewsOmit | null /** - * The data used to create many Events. + * The data used to create many News. */ - data: EventCreateManyInput | EventCreateManyInput[] + data: NewsCreateManyInput | NewsCreateManyInput[] skipDuplicates?: boolean - /** - * Choose, which related nodes to fetch as well - */ - include?: EventIncludeCreateManyAndReturn | null } /** - * Event update + * News update */ - export type EventUpdateArgs = { + export type NewsUpdateArgs = { /** - * Select specific fields to fetch from the Event + * Select specific fields to fetch from the News */ - select?: EventSelect | null + select?: NewsSelect | null /** - * Omit specific fields from the Event + * Omit specific fields from the News */ - omit?: EventOmit | null + omit?: NewsOmit | null /** - * Choose, which related nodes to fetch as well + * The data needed to update a News. */ - include?: EventInclude | null + data: XOR /** - * The data needed to update a Event. + * Choose, which News to update. */ - data: XOR - /** - * Choose, which Event to update. - */ - where: EventWhereUniqueInput + where: NewsWhereUniqueInput } /** - * Event updateMany + * News updateMany */ - export type EventUpdateManyArgs = { + export type NewsUpdateManyArgs = { /** - * The data used to update Events. + * The data used to update News. */ - data: XOR + data: XOR /** - * Filter which Events to update + * Filter which News to update */ - where?: EventWhereInput + where?: NewsWhereInput /** - * Limit how many Events to update. + * Limit how many News to update. */ limit?: number } /** - * Event updateManyAndReturn + * News updateManyAndReturn */ - export type EventUpdateManyAndReturnArgs = { + export type NewsUpdateManyAndReturnArgs = { /** - * Select specific fields to fetch from the Event + * Select specific fields to fetch from the News */ - select?: EventSelectUpdateManyAndReturn | null + select?: NewsSelectUpdateManyAndReturn | null /** - * Omit specific fields from the Event + * Omit specific fields from the News */ - omit?: EventOmit | null + omit?: NewsOmit | null /** - * The data used to update Events. + * The data used to update News. */ - data: XOR + data: XOR /** - * Filter which Events to update + * Filter which News to update */ - where?: EventWhereInput + where?: NewsWhereInput /** - * Limit how many Events to update. - */ - limit?: number - /** - * Choose, which related nodes to fetch as well - */ - include?: EventIncludeUpdateManyAndReturn | null - } - - /** - * Event upsert - */ - export type EventUpsertArgs = { - /** - * Select specific fields to fetch from the Event - */ - select?: EventSelect | null - /** - * Omit specific fields from the Event - */ - omit?: EventOmit | null - /** - * Choose, which related nodes to fetch as well - */ - include?: EventInclude | null - /** - * The filter to search for the Event to update in case it exists. - */ - where: EventWhereUniqueInput - /** - * In case the Event found by the `where` argument doesn't exist, create a new Event with this data. - */ - create: XOR - /** - * In case the Event was found with the provided `where` argument, update it with this data. - */ - update: XOR - } - - /** - * Event delete - */ - export type EventDeleteArgs = { - /** - * Select specific fields to fetch from the Event - */ - select?: EventSelect | null - /** - * Omit specific fields from the Event - */ - omit?: EventOmit | null - /** - * Choose, which related nodes to fetch as well - */ - include?: EventInclude | null - /** - * Filter which Event to delete. - */ - where: EventWhereUniqueInput - } - - /** - * Event deleteMany - */ - export type EventDeleteManyArgs = { - /** - * Filter which Events to delete - */ - where?: EventWhereInput - /** - * Limit how many Events to delete. + * Limit how many News to update. */ limit?: number } /** - * Event without action + * News upsert */ - export type EventDefaultArgs = { + export type NewsUpsertArgs = { /** - * Select specific fields to fetch from the Event + * Select specific fields to fetch from the News */ - select?: EventSelect | null + select?: NewsSelect | null /** - * Omit specific fields from the Event + * Omit specific fields from the News */ - omit?: EventOmit | null + omit?: NewsOmit | null /** - * Choose, which related nodes to fetch as well + * The filter to search for the News to update in case it exists. */ - include?: EventInclude | null + where: NewsWhereUniqueInput + /** + * In case the News found by the `where` argument doesn't exist, create a new News with this data. + */ + create: XOR + /** + * In case the News was found with the provided `where` argument, update it with this data. + */ + update: XOR + } + + /** + * News delete + */ + export type NewsDeleteArgs = { + /** + * Select specific fields to fetch from the News + */ + select?: NewsSelect | null + /** + * Omit specific fields from the News + */ + omit?: NewsOmit | null + /** + * Filter which News to delete. + */ + where: NewsWhereUniqueInput + } + + /** + * News deleteMany + */ + export type NewsDeleteManyArgs = { + /** + * Filter which News to delete + */ + where?: NewsWhereInput + /** + * Limit how many News to delete. + */ + limit?: number + } + + /** + * News without action + */ + export type NewsDefaultArgs = { + /** + * Select specific fields to fetch from the News + */ + select?: NewsSelect | null + /** + * Omit specific fields from the News + */ + omit?: NewsOmit | null } @@ -3220,33 +2013,23 @@ export namespace Prisma { export type TransactionIsolationLevel = (typeof TransactionIsolationLevel)[keyof typeof TransactionIsolationLevel] - export const CalendarScalarFieldEnum: { - id: 'id', - name: 'name', - color: 'color', - description: 'description', - userId: 'userId', - createdAt: 'createdAt', - updatedAt: 'updatedAt' - }; - - export type CalendarScalarFieldEnum = (typeof CalendarScalarFieldEnum)[keyof typeof CalendarScalarFieldEnum] - - - export const EventScalarFieldEnum: { + export const NewsScalarFieldEnum: { id: 'id', title: 'title', + url: 'url', + date: 'date', + source: 'source', + content: 'content', + sentiment_score: 'sentiment_score', + sentiment: 'sentiment', + symbols: 'symbols', + symbol: 'symbol', + processed_at: 'processed_at', description: 'description', - start: 'start', - end: 'end', - location: 'location', - isAllDay: 'isAllDay', - calendarId: 'calendarId', - createdAt: 'createdAt', - updatedAt: 'updatedAt' + category: 'category' }; - export type EventScalarFieldEnum = (typeof EventScalarFieldEnum)[keyof typeof EventScalarFieldEnum] + export type NewsScalarFieldEnum = (typeof NewsScalarFieldEnum)[keyof typeof NewsScalarFieldEnum] export const SortOrder: { @@ -3278,6 +2061,20 @@ export namespace Prisma { */ + /** + * Reference to a field of type 'Int' + */ + export type IntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int'> + + + + /** + * Reference to a field of type 'Int[]' + */ + export type ListIntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int[]'> + + + /** * Reference to a field of type 'String' */ @@ -3307,336 +2104,234 @@ export namespace Prisma { /** - * Reference to a field of type 'Boolean' + * Reference to a field of type 'Float' */ - export type BooleanFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Boolean'> + export type FloatFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Float'> /** - * Reference to a field of type 'Int' + * Reference to a field of type 'Float[]' */ - export type IntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int'> - - - - /** - * Reference to a field of type 'Int[]' - */ - export type ListIntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int[]'> + export type ListFloatFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Float[]'> /** * Deep Input Types */ - export type CalendarWhereInput = { - AND?: CalendarWhereInput | CalendarWhereInput[] - OR?: CalendarWhereInput[] - NOT?: CalendarWhereInput | CalendarWhereInput[] - id?: StringFilter<"Calendar"> | string - name?: StringFilter<"Calendar"> | string - color?: StringFilter<"Calendar"> | string - description?: StringNullableFilter<"Calendar"> | string | null - userId?: StringFilter<"Calendar"> | string - createdAt?: DateTimeFilter<"Calendar"> | Date | string - updatedAt?: DateTimeFilter<"Calendar"> | Date | string - events?: EventListRelationFilter + export type NewsWhereInput = { + AND?: NewsWhereInput | NewsWhereInput[] + OR?: NewsWhereInput[] + NOT?: NewsWhereInput | NewsWhereInput[] + id?: IntFilter<"News"> | number + title?: StringFilter<"News"> | string + url?: StringFilter<"News"> | string + date?: DateTimeFilter<"News"> | Date | string + source?: StringFilter<"News"> | string + content?: StringNullableFilter<"News"> | string | null + sentiment_score?: FloatNullableFilter<"News"> | number | null + sentiment?: StringNullableFilter<"News"> | string | null + symbols?: StringNullableListFilter<"News"> + symbol?: StringNullableFilter<"News"> | string | null + processed_at?: DateTimeFilter<"News"> | Date | string + description?: StringNullableFilter<"News"> | string | null + category?: StringNullableFilter<"News"> | string | null } - export type CalendarOrderByWithRelationInput = { - id?: SortOrder - name?: SortOrder - color?: SortOrder - description?: SortOrderInput | SortOrder - userId?: SortOrder - createdAt?: SortOrder - updatedAt?: SortOrder - events?: EventOrderByRelationAggregateInput - } - - export type CalendarWhereUniqueInput = Prisma.AtLeast<{ - id?: string - AND?: CalendarWhereInput | CalendarWhereInput[] - OR?: CalendarWhereInput[] - NOT?: CalendarWhereInput | CalendarWhereInput[] - name?: StringFilter<"Calendar"> | string - color?: StringFilter<"Calendar"> | string - description?: StringNullableFilter<"Calendar"> | string | null - userId?: StringFilter<"Calendar"> | string - createdAt?: DateTimeFilter<"Calendar"> | Date | string - updatedAt?: DateTimeFilter<"Calendar"> | Date | string - events?: EventListRelationFilter - }, "id"> - - export type CalendarOrderByWithAggregationInput = { - id?: SortOrder - name?: SortOrder - color?: SortOrder - description?: SortOrderInput | SortOrder - userId?: SortOrder - createdAt?: SortOrder - updatedAt?: SortOrder - _count?: CalendarCountOrderByAggregateInput - _max?: CalendarMaxOrderByAggregateInput - _min?: CalendarMinOrderByAggregateInput - } - - export type CalendarScalarWhereWithAggregatesInput = { - AND?: CalendarScalarWhereWithAggregatesInput | CalendarScalarWhereWithAggregatesInput[] - OR?: CalendarScalarWhereWithAggregatesInput[] - NOT?: CalendarScalarWhereWithAggregatesInput | CalendarScalarWhereWithAggregatesInput[] - id?: StringWithAggregatesFilter<"Calendar"> | string - name?: StringWithAggregatesFilter<"Calendar"> | string - color?: StringWithAggregatesFilter<"Calendar"> | string - description?: StringNullableWithAggregatesFilter<"Calendar"> | string | null - userId?: StringWithAggregatesFilter<"Calendar"> | string - createdAt?: DateTimeWithAggregatesFilter<"Calendar"> | Date | string - updatedAt?: DateTimeWithAggregatesFilter<"Calendar"> | Date | string - } - - export type EventWhereInput = { - AND?: EventWhereInput | EventWhereInput[] - OR?: EventWhereInput[] - NOT?: EventWhereInput | EventWhereInput[] - id?: StringFilter<"Event"> | string - title?: StringFilter<"Event"> | string - description?: StringNullableFilter<"Event"> | string | null - start?: DateTimeFilter<"Event"> | Date | string - end?: DateTimeFilter<"Event"> | Date | string - location?: StringNullableFilter<"Event"> | string | null - isAllDay?: BoolFilter<"Event"> | boolean - calendarId?: StringFilter<"Event"> | string - createdAt?: DateTimeFilter<"Event"> | Date | string - updatedAt?: DateTimeFilter<"Event"> | Date | string - calendar?: XOR - } - - export type EventOrderByWithRelationInput = { + export type NewsOrderByWithRelationInput = { id?: SortOrder title?: SortOrder + url?: SortOrder + date?: SortOrder + source?: SortOrder + content?: SortOrderInput | SortOrder + sentiment_score?: SortOrderInput | SortOrder + sentiment?: SortOrderInput | SortOrder + symbols?: SortOrder + symbol?: SortOrderInput | SortOrder + processed_at?: SortOrder description?: SortOrderInput | SortOrder - start?: SortOrder - end?: SortOrder - location?: SortOrderInput | SortOrder - isAllDay?: SortOrder - calendarId?: SortOrder - createdAt?: SortOrder - updatedAt?: SortOrder - calendar?: CalendarOrderByWithRelationInput + category?: SortOrderInput | SortOrder } - export type EventWhereUniqueInput = Prisma.AtLeast<{ - id?: string - AND?: EventWhereInput | EventWhereInput[] - OR?: EventWhereInput[] - NOT?: EventWhereInput | EventWhereInput[] - title?: StringFilter<"Event"> | string - description?: StringNullableFilter<"Event"> | string | null - start?: DateTimeFilter<"Event"> | Date | string - end?: DateTimeFilter<"Event"> | Date | string - location?: StringNullableFilter<"Event"> | string | null - isAllDay?: BoolFilter<"Event"> | boolean - calendarId?: StringFilter<"Event"> | string - createdAt?: DateTimeFilter<"Event"> | Date | string - updatedAt?: DateTimeFilter<"Event"> | Date | string - calendar?: XOR - }, "id"> + export type NewsWhereUniqueInput = Prisma.AtLeast<{ + id?: number + url?: string + AND?: NewsWhereInput | NewsWhereInput[] + OR?: NewsWhereInput[] + NOT?: NewsWhereInput | NewsWhereInput[] + title?: StringFilter<"News"> | string + date?: DateTimeFilter<"News"> | Date | string + source?: StringFilter<"News"> | string + content?: StringNullableFilter<"News"> | string | null + sentiment_score?: FloatNullableFilter<"News"> | number | null + sentiment?: StringNullableFilter<"News"> | string | null + symbols?: StringNullableListFilter<"News"> + symbol?: StringNullableFilter<"News"> | string | null + processed_at?: DateTimeFilter<"News"> | Date | string + description?: StringNullableFilter<"News"> | string | null + category?: StringNullableFilter<"News"> | string | null + }, "id" | "url"> - export type EventOrderByWithAggregationInput = { + export type NewsOrderByWithAggregationInput = { id?: SortOrder title?: SortOrder + url?: SortOrder + date?: SortOrder + source?: SortOrder + content?: SortOrderInput | SortOrder + sentiment_score?: SortOrderInput | SortOrder + sentiment?: SortOrderInput | SortOrder + symbols?: SortOrder + symbol?: SortOrderInput | SortOrder + processed_at?: SortOrder description?: SortOrderInput | SortOrder - start?: SortOrder - end?: SortOrder - location?: SortOrderInput | SortOrder - isAllDay?: SortOrder - calendarId?: SortOrder - createdAt?: SortOrder - updatedAt?: SortOrder - _count?: EventCountOrderByAggregateInput - _max?: EventMaxOrderByAggregateInput - _min?: EventMinOrderByAggregateInput + category?: SortOrderInput | SortOrder + _count?: NewsCountOrderByAggregateInput + _avg?: NewsAvgOrderByAggregateInput + _max?: NewsMaxOrderByAggregateInput + _min?: NewsMinOrderByAggregateInput + _sum?: NewsSumOrderByAggregateInput } - export type EventScalarWhereWithAggregatesInput = { - AND?: EventScalarWhereWithAggregatesInput | EventScalarWhereWithAggregatesInput[] - OR?: EventScalarWhereWithAggregatesInput[] - NOT?: EventScalarWhereWithAggregatesInput | EventScalarWhereWithAggregatesInput[] - id?: StringWithAggregatesFilter<"Event"> | string - title?: StringWithAggregatesFilter<"Event"> | string - description?: StringNullableWithAggregatesFilter<"Event"> | string | null - start?: DateTimeWithAggregatesFilter<"Event"> | Date | string - end?: DateTimeWithAggregatesFilter<"Event"> | Date | string - location?: StringNullableWithAggregatesFilter<"Event"> | string | null - isAllDay?: BoolWithAggregatesFilter<"Event"> | boolean - calendarId?: StringWithAggregatesFilter<"Event"> | string - createdAt?: DateTimeWithAggregatesFilter<"Event"> | Date | string - updatedAt?: DateTimeWithAggregatesFilter<"Event"> | Date | string + export type NewsScalarWhereWithAggregatesInput = { + AND?: NewsScalarWhereWithAggregatesInput | NewsScalarWhereWithAggregatesInput[] + OR?: NewsScalarWhereWithAggregatesInput[] + NOT?: NewsScalarWhereWithAggregatesInput | NewsScalarWhereWithAggregatesInput[] + id?: IntWithAggregatesFilter<"News"> | number + title?: StringWithAggregatesFilter<"News"> | string + url?: StringWithAggregatesFilter<"News"> | string + date?: DateTimeWithAggregatesFilter<"News"> | Date | string + source?: StringWithAggregatesFilter<"News"> | string + content?: StringNullableWithAggregatesFilter<"News"> | string | null + sentiment_score?: FloatNullableWithAggregatesFilter<"News"> | number | null + sentiment?: StringNullableWithAggregatesFilter<"News"> | string | null + symbols?: StringNullableListFilter<"News"> + symbol?: StringNullableWithAggregatesFilter<"News"> | string | null + processed_at?: DateTimeWithAggregatesFilter<"News"> | Date | string + description?: StringNullableWithAggregatesFilter<"News"> | string | null + category?: StringNullableWithAggregatesFilter<"News"> | string | null } - export type CalendarCreateInput = { - id?: string - name: string - color?: string - description?: string | null - userId: string - createdAt?: Date | string - updatedAt?: Date | string - events?: EventCreateNestedManyWithoutCalendarInput - } - - export type CalendarUncheckedCreateInput = { - id?: string - name: string - color?: string - description?: string | null - userId: string - createdAt?: Date | string - updatedAt?: Date | string - events?: EventUncheckedCreateNestedManyWithoutCalendarInput - } - - export type CalendarUpdateInput = { - id?: StringFieldUpdateOperationsInput | string - name?: StringFieldUpdateOperationsInput | string - color?: StringFieldUpdateOperationsInput | string - description?: NullableStringFieldUpdateOperationsInput | string | null - userId?: StringFieldUpdateOperationsInput | string - createdAt?: DateTimeFieldUpdateOperationsInput | Date | string - updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string - events?: EventUpdateManyWithoutCalendarNestedInput - } - - export type CalendarUncheckedUpdateInput = { - id?: StringFieldUpdateOperationsInput | string - name?: StringFieldUpdateOperationsInput | string - color?: StringFieldUpdateOperationsInput | string - description?: NullableStringFieldUpdateOperationsInput | string | null - userId?: StringFieldUpdateOperationsInput | string - createdAt?: DateTimeFieldUpdateOperationsInput | Date | string - updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string - events?: EventUncheckedUpdateManyWithoutCalendarNestedInput - } - - export type CalendarCreateManyInput = { - id?: string - name: string - color?: string - description?: string | null - userId: string - createdAt?: Date | string - updatedAt?: Date | string - } - - export type CalendarUpdateManyMutationInput = { - id?: StringFieldUpdateOperationsInput | string - name?: StringFieldUpdateOperationsInput | string - color?: StringFieldUpdateOperationsInput | string - description?: NullableStringFieldUpdateOperationsInput | string | null - userId?: StringFieldUpdateOperationsInput | string - createdAt?: DateTimeFieldUpdateOperationsInput | Date | string - updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string - } - - export type CalendarUncheckedUpdateManyInput = { - id?: StringFieldUpdateOperationsInput | string - name?: StringFieldUpdateOperationsInput | string - color?: StringFieldUpdateOperationsInput | string - description?: NullableStringFieldUpdateOperationsInput | string | null - userId?: StringFieldUpdateOperationsInput | string - createdAt?: DateTimeFieldUpdateOperationsInput | Date | string - updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string - } - - export type EventCreateInput = { - id?: string + export type NewsCreateInput = { title: string + url: string + date: Date | string + source: string + content?: string | null + sentiment_score?: number | null + sentiment?: string | null + symbols?: NewsCreatesymbolsInput | string[] + symbol?: string | null + processed_at?: Date | string description?: string | null - start: Date | string - end: Date | string - location?: string | null - isAllDay?: boolean - createdAt?: Date | string - updatedAt?: Date | string - calendar: CalendarCreateNestedOneWithoutEventsInput + category?: string | null } - export type EventUncheckedCreateInput = { - id?: string + export type NewsUncheckedCreateInput = { + id?: number title: string + url: string + date: Date | string + source: string + content?: string | null + sentiment_score?: number | null + sentiment?: string | null + symbols?: NewsCreatesymbolsInput | string[] + symbol?: string | null + processed_at?: Date | string description?: string | null - start: Date | string - end: Date | string - location?: string | null - isAllDay?: boolean - calendarId: string - createdAt?: Date | string - updatedAt?: Date | string + category?: string | null } - export type EventUpdateInput = { - id?: StringFieldUpdateOperationsInput | string + export type NewsUpdateInput = { title?: StringFieldUpdateOperationsInput | string + url?: StringFieldUpdateOperationsInput | string + date?: DateTimeFieldUpdateOperationsInput | Date | string + source?: StringFieldUpdateOperationsInput | string + content?: NullableStringFieldUpdateOperationsInput | string | null + sentiment_score?: NullableFloatFieldUpdateOperationsInput | number | null + sentiment?: NullableStringFieldUpdateOperationsInput | string | null + symbols?: NewsUpdatesymbolsInput | string[] + symbol?: NullableStringFieldUpdateOperationsInput | string | null + processed_at?: DateTimeFieldUpdateOperationsInput | Date | string description?: NullableStringFieldUpdateOperationsInput | string | null - start?: DateTimeFieldUpdateOperationsInput | Date | string - end?: DateTimeFieldUpdateOperationsInput | Date | string - location?: NullableStringFieldUpdateOperationsInput | string | null - isAllDay?: BoolFieldUpdateOperationsInput | boolean - createdAt?: DateTimeFieldUpdateOperationsInput | Date | string - updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string - calendar?: CalendarUpdateOneRequiredWithoutEventsNestedInput + category?: NullableStringFieldUpdateOperationsInput | string | null } - export type EventUncheckedUpdateInput = { - id?: StringFieldUpdateOperationsInput | string + export type NewsUncheckedUpdateInput = { + id?: IntFieldUpdateOperationsInput | number title?: StringFieldUpdateOperationsInput | string + url?: StringFieldUpdateOperationsInput | string + date?: DateTimeFieldUpdateOperationsInput | Date | string + source?: StringFieldUpdateOperationsInput | string + content?: NullableStringFieldUpdateOperationsInput | string | null + sentiment_score?: NullableFloatFieldUpdateOperationsInput | number | null + sentiment?: NullableStringFieldUpdateOperationsInput | string | null + symbols?: NewsUpdatesymbolsInput | string[] + symbol?: NullableStringFieldUpdateOperationsInput | string | null + processed_at?: DateTimeFieldUpdateOperationsInput | Date | string description?: NullableStringFieldUpdateOperationsInput | string | null - start?: DateTimeFieldUpdateOperationsInput | Date | string - end?: DateTimeFieldUpdateOperationsInput | Date | string - location?: NullableStringFieldUpdateOperationsInput | string | null - isAllDay?: BoolFieldUpdateOperationsInput | boolean - calendarId?: StringFieldUpdateOperationsInput | string - createdAt?: DateTimeFieldUpdateOperationsInput | Date | string - updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string + category?: NullableStringFieldUpdateOperationsInput | string | null } - export type EventCreateManyInput = { - id?: string + export type NewsCreateManyInput = { + id?: number title: string + url: string + date: Date | string + source: string + content?: string | null + sentiment_score?: number | null + sentiment?: string | null + symbols?: NewsCreatesymbolsInput | string[] + symbol?: string | null + processed_at?: Date | string description?: string | null - start: Date | string - end: Date | string - location?: string | null - isAllDay?: boolean - calendarId: string - createdAt?: Date | string - updatedAt?: Date | string + category?: string | null } - export type EventUpdateManyMutationInput = { - id?: StringFieldUpdateOperationsInput | string + export type NewsUpdateManyMutationInput = { title?: StringFieldUpdateOperationsInput | string + url?: StringFieldUpdateOperationsInput | string + date?: DateTimeFieldUpdateOperationsInput | Date | string + source?: StringFieldUpdateOperationsInput | string + content?: NullableStringFieldUpdateOperationsInput | string | null + sentiment_score?: NullableFloatFieldUpdateOperationsInput | number | null + sentiment?: NullableStringFieldUpdateOperationsInput | string | null + symbols?: NewsUpdatesymbolsInput | string[] + symbol?: NullableStringFieldUpdateOperationsInput | string | null + processed_at?: DateTimeFieldUpdateOperationsInput | Date | string description?: NullableStringFieldUpdateOperationsInput | string | null - start?: DateTimeFieldUpdateOperationsInput | Date | string - end?: DateTimeFieldUpdateOperationsInput | Date | string - location?: NullableStringFieldUpdateOperationsInput | string | null - isAllDay?: BoolFieldUpdateOperationsInput | boolean - createdAt?: DateTimeFieldUpdateOperationsInput | Date | string - updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string + category?: NullableStringFieldUpdateOperationsInput | string | null } - export type EventUncheckedUpdateManyInput = { - id?: StringFieldUpdateOperationsInput | string + export type NewsUncheckedUpdateManyInput = { + id?: IntFieldUpdateOperationsInput | number title?: StringFieldUpdateOperationsInput | string + url?: StringFieldUpdateOperationsInput | string + date?: DateTimeFieldUpdateOperationsInput | Date | string + source?: StringFieldUpdateOperationsInput | string + content?: NullableStringFieldUpdateOperationsInput | string | null + sentiment_score?: NullableFloatFieldUpdateOperationsInput | number | null + sentiment?: NullableStringFieldUpdateOperationsInput | string | null + symbols?: NewsUpdatesymbolsInput | string[] + symbol?: NullableStringFieldUpdateOperationsInput | string | null + processed_at?: DateTimeFieldUpdateOperationsInput | Date | string description?: NullableStringFieldUpdateOperationsInput | string | null - start?: DateTimeFieldUpdateOperationsInput | Date | string - end?: DateTimeFieldUpdateOperationsInput | Date | string - location?: NullableStringFieldUpdateOperationsInput | string | null - isAllDay?: BoolFieldUpdateOperationsInput | boolean - calendarId?: StringFieldUpdateOperationsInput | string - createdAt?: DateTimeFieldUpdateOperationsInput | Date | string - updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string + category?: NullableStringFieldUpdateOperationsInput | string | null + } + + export type IntFilter<$PrismaModel = never> = { + equals?: number | IntFieldRefInput<$PrismaModel> + in?: number[] | ListIntFieldRefInput<$PrismaModel> + notIn?: number[] | ListIntFieldRefInput<$PrismaModel> + lt?: number | IntFieldRefInput<$PrismaModel> + lte?: number | IntFieldRefInput<$PrismaModel> + gt?: number | IntFieldRefInput<$PrismaModel> + gte?: number | IntFieldRefInput<$PrismaModel> + not?: NestedIntFilter<$PrismaModel> | number } export type StringFilter<$PrismaModel = never> = { @@ -3654,6 +2349,17 @@ export namespace Prisma { not?: NestedStringFilter<$PrismaModel> | string } + export type DateTimeFilter<$PrismaModel = never> = { + equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> + in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> + notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> + lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> + lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> + gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> + gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> + not?: NestedDateTimeFilter<$PrismaModel> | Date | string + } + export type StringNullableFilter<$PrismaModel = never> = { equals?: string | StringFieldRefInput<$PrismaModel> | null in?: string[] | ListStringFieldRefInput<$PrismaModel> | null @@ -3669,21 +2375,23 @@ export namespace Prisma { not?: NestedStringNullableFilter<$PrismaModel> | string | null } - export type DateTimeFilter<$PrismaModel = never> = { - equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> - in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> - notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> - lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> - lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> - gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> - gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> - not?: NestedDateTimeFilter<$PrismaModel> | Date | string + export type FloatNullableFilter<$PrismaModel = never> = { + equals?: number | FloatFieldRefInput<$PrismaModel> | null + in?: number[] | ListFloatFieldRefInput<$PrismaModel> | null + notIn?: number[] | ListFloatFieldRefInput<$PrismaModel> | null + lt?: number | FloatFieldRefInput<$PrismaModel> + lte?: number | FloatFieldRefInput<$PrismaModel> + gt?: number | FloatFieldRefInput<$PrismaModel> + gte?: number | FloatFieldRefInput<$PrismaModel> + not?: NestedFloatNullableFilter<$PrismaModel> | number | null } - export type EventListRelationFilter = { - every?: EventWhereInput - some?: EventWhereInput - none?: EventWhereInput + export type StringNullableListFilter<$PrismaModel = never> = { + equals?: string[] | ListStringFieldRefInput<$PrismaModel> | null + has?: string | StringFieldRefInput<$PrismaModel> | null + hasEvery?: string[] | ListStringFieldRefInput<$PrismaModel> + hasSome?: string[] | ListStringFieldRefInput<$PrismaModel> + isEmpty?: boolean } export type SortOrderInput = { @@ -3691,38 +2399,76 @@ export namespace Prisma { nulls?: NullsOrder } - export type EventOrderByRelationAggregateInput = { - _count?: SortOrder + export type NewsCountOrderByAggregateInput = { + id?: SortOrder + title?: SortOrder + url?: SortOrder + date?: SortOrder + source?: SortOrder + content?: SortOrder + sentiment_score?: SortOrder + sentiment?: SortOrder + symbols?: SortOrder + symbol?: SortOrder + processed_at?: SortOrder + description?: SortOrder + category?: SortOrder } - export type CalendarCountOrderByAggregateInput = { + export type NewsAvgOrderByAggregateInput = { id?: SortOrder - name?: SortOrder - color?: SortOrder - description?: SortOrder - userId?: SortOrder - createdAt?: SortOrder - updatedAt?: SortOrder + sentiment_score?: SortOrder } - export type CalendarMaxOrderByAggregateInput = { + export type NewsMaxOrderByAggregateInput = { id?: SortOrder - name?: SortOrder - color?: SortOrder + title?: SortOrder + url?: SortOrder + date?: SortOrder + source?: SortOrder + content?: SortOrder + sentiment_score?: SortOrder + sentiment?: SortOrder + symbol?: SortOrder + processed_at?: SortOrder description?: SortOrder - userId?: SortOrder - createdAt?: SortOrder - updatedAt?: SortOrder + category?: SortOrder } - export type CalendarMinOrderByAggregateInput = { + export type NewsMinOrderByAggregateInput = { id?: SortOrder - name?: SortOrder - color?: SortOrder + title?: SortOrder + url?: SortOrder + date?: SortOrder + source?: SortOrder + content?: SortOrder + sentiment_score?: SortOrder + sentiment?: SortOrder + symbol?: SortOrder + processed_at?: SortOrder description?: SortOrder - userId?: SortOrder - createdAt?: SortOrder - updatedAt?: SortOrder + category?: SortOrder + } + + export type NewsSumOrderByAggregateInput = { + id?: SortOrder + sentiment_score?: SortOrder + } + + export type IntWithAggregatesFilter<$PrismaModel = never> = { + equals?: number | IntFieldRefInput<$PrismaModel> + in?: number[] | ListIntFieldRefInput<$PrismaModel> + notIn?: number[] | ListIntFieldRefInput<$PrismaModel> + lt?: number | IntFieldRefInput<$PrismaModel> + lte?: number | IntFieldRefInput<$PrismaModel> + gt?: number | IntFieldRefInput<$PrismaModel> + gte?: number | IntFieldRefInput<$PrismaModel> + not?: NestedIntWithAggregatesFilter<$PrismaModel> | number + _count?: NestedIntFilter<$PrismaModel> + _avg?: NestedFloatFilter<$PrismaModel> + _sum?: NestedIntFilter<$PrismaModel> + _min?: NestedIntFilter<$PrismaModel> + _max?: NestedIntFilter<$PrismaModel> } export type StringWithAggregatesFilter<$PrismaModel = never> = { @@ -3743,6 +2489,20 @@ export namespace Prisma { _max?: NestedStringFilter<$PrismaModel> } + export type DateTimeWithAggregatesFilter<$PrismaModel = never> = { + equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> + in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> + notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> + lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> + lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> + gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> + gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> + not?: NestedDateTimeWithAggregatesFilter<$PrismaModel> | Date | string + _count?: NestedIntFilter<$PrismaModel> + _min?: NestedDateTimeFilter<$PrismaModel> + _max?: NestedDateTimeFilter<$PrismaModel> + } + export type StringNullableWithAggregatesFilter<$PrismaModel = never> = { equals?: string | StringFieldRefInput<$PrismaModel> | null in?: string[] | ListStringFieldRefInput<$PrismaModel> | null @@ -3761,147 +2521,68 @@ export namespace Prisma { _max?: NestedStringNullableFilter<$PrismaModel> } - export type DateTimeWithAggregatesFilter<$PrismaModel = never> = { - equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> - in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> - notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> - lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> - lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> - gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> - gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> - not?: NestedDateTimeWithAggregatesFilter<$PrismaModel> | Date | string - _count?: NestedIntFilter<$PrismaModel> - _min?: NestedDateTimeFilter<$PrismaModel> - _max?: NestedDateTimeFilter<$PrismaModel> + export type FloatNullableWithAggregatesFilter<$PrismaModel = never> = { + equals?: number | FloatFieldRefInput<$PrismaModel> | null + in?: number[] | ListFloatFieldRefInput<$PrismaModel> | null + notIn?: number[] | ListFloatFieldRefInput<$PrismaModel> | null + lt?: number | FloatFieldRefInput<$PrismaModel> + lte?: number | FloatFieldRefInput<$PrismaModel> + gt?: number | FloatFieldRefInput<$PrismaModel> + gte?: number | FloatFieldRefInput<$PrismaModel> + not?: NestedFloatNullableWithAggregatesFilter<$PrismaModel> | number | null + _count?: NestedIntNullableFilter<$PrismaModel> + _avg?: NestedFloatNullableFilter<$PrismaModel> + _sum?: NestedFloatNullableFilter<$PrismaModel> + _min?: NestedFloatNullableFilter<$PrismaModel> + _max?: NestedFloatNullableFilter<$PrismaModel> } - export type BoolFilter<$PrismaModel = never> = { - equals?: boolean | BooleanFieldRefInput<$PrismaModel> - not?: NestedBoolFilter<$PrismaModel> | boolean - } - - export type CalendarScalarRelationFilter = { - is?: CalendarWhereInput - isNot?: CalendarWhereInput - } - - export type EventCountOrderByAggregateInput = { - id?: SortOrder - title?: SortOrder - description?: SortOrder - start?: SortOrder - end?: SortOrder - location?: SortOrder - isAllDay?: SortOrder - calendarId?: SortOrder - createdAt?: SortOrder - updatedAt?: SortOrder - } - - export type EventMaxOrderByAggregateInput = { - id?: SortOrder - title?: SortOrder - description?: SortOrder - start?: SortOrder - end?: SortOrder - location?: SortOrder - isAllDay?: SortOrder - calendarId?: SortOrder - createdAt?: SortOrder - updatedAt?: SortOrder - } - - export type EventMinOrderByAggregateInput = { - id?: SortOrder - title?: SortOrder - description?: SortOrder - start?: SortOrder - end?: SortOrder - location?: SortOrder - isAllDay?: SortOrder - calendarId?: SortOrder - createdAt?: SortOrder - updatedAt?: SortOrder - } - - export type BoolWithAggregatesFilter<$PrismaModel = never> = { - equals?: boolean | BooleanFieldRefInput<$PrismaModel> - not?: NestedBoolWithAggregatesFilter<$PrismaModel> | boolean - _count?: NestedIntFilter<$PrismaModel> - _min?: NestedBoolFilter<$PrismaModel> - _max?: NestedBoolFilter<$PrismaModel> - } - - export type EventCreateNestedManyWithoutCalendarInput = { - create?: XOR | EventCreateWithoutCalendarInput[] | EventUncheckedCreateWithoutCalendarInput[] - connectOrCreate?: EventCreateOrConnectWithoutCalendarInput | EventCreateOrConnectWithoutCalendarInput[] - createMany?: EventCreateManyCalendarInputEnvelope - connect?: EventWhereUniqueInput | EventWhereUniqueInput[] - } - - export type EventUncheckedCreateNestedManyWithoutCalendarInput = { - create?: XOR | EventCreateWithoutCalendarInput[] | EventUncheckedCreateWithoutCalendarInput[] - connectOrCreate?: EventCreateOrConnectWithoutCalendarInput | EventCreateOrConnectWithoutCalendarInput[] - createMany?: EventCreateManyCalendarInputEnvelope - connect?: EventWhereUniqueInput | EventWhereUniqueInput[] + export type NewsCreatesymbolsInput = { + set: string[] } export type StringFieldUpdateOperationsInput = { set?: string } - export type NullableStringFieldUpdateOperationsInput = { - set?: string | null - } - export type DateTimeFieldUpdateOperationsInput = { set?: Date | string } - export type EventUpdateManyWithoutCalendarNestedInput = { - create?: XOR | EventCreateWithoutCalendarInput[] | EventUncheckedCreateWithoutCalendarInput[] - connectOrCreate?: EventCreateOrConnectWithoutCalendarInput | EventCreateOrConnectWithoutCalendarInput[] - upsert?: EventUpsertWithWhereUniqueWithoutCalendarInput | EventUpsertWithWhereUniqueWithoutCalendarInput[] - createMany?: EventCreateManyCalendarInputEnvelope - set?: EventWhereUniqueInput | EventWhereUniqueInput[] - disconnect?: EventWhereUniqueInput | EventWhereUniqueInput[] - delete?: EventWhereUniqueInput | EventWhereUniqueInput[] - connect?: EventWhereUniqueInput | EventWhereUniqueInput[] - update?: EventUpdateWithWhereUniqueWithoutCalendarInput | EventUpdateWithWhereUniqueWithoutCalendarInput[] - updateMany?: EventUpdateManyWithWhereWithoutCalendarInput | EventUpdateManyWithWhereWithoutCalendarInput[] - deleteMany?: EventScalarWhereInput | EventScalarWhereInput[] + export type NullableStringFieldUpdateOperationsInput = { + set?: string | null } - export type EventUncheckedUpdateManyWithoutCalendarNestedInput = { - create?: XOR | EventCreateWithoutCalendarInput[] | EventUncheckedCreateWithoutCalendarInput[] - connectOrCreate?: EventCreateOrConnectWithoutCalendarInput | EventCreateOrConnectWithoutCalendarInput[] - upsert?: EventUpsertWithWhereUniqueWithoutCalendarInput | EventUpsertWithWhereUniqueWithoutCalendarInput[] - createMany?: EventCreateManyCalendarInputEnvelope - set?: EventWhereUniqueInput | EventWhereUniqueInput[] - disconnect?: EventWhereUniqueInput | EventWhereUniqueInput[] - delete?: EventWhereUniqueInput | EventWhereUniqueInput[] - connect?: EventWhereUniqueInput | EventWhereUniqueInput[] - update?: EventUpdateWithWhereUniqueWithoutCalendarInput | EventUpdateWithWhereUniqueWithoutCalendarInput[] - updateMany?: EventUpdateManyWithWhereWithoutCalendarInput | EventUpdateManyWithWhereWithoutCalendarInput[] - deleteMany?: EventScalarWhereInput | EventScalarWhereInput[] + export type NullableFloatFieldUpdateOperationsInput = { + set?: number | null + increment?: number + decrement?: number + multiply?: number + divide?: number } - export type CalendarCreateNestedOneWithoutEventsInput = { - create?: XOR - connectOrCreate?: CalendarCreateOrConnectWithoutEventsInput - connect?: CalendarWhereUniqueInput + export type NewsUpdatesymbolsInput = { + set?: string[] + push?: string | string[] } - export type BoolFieldUpdateOperationsInput = { - set?: boolean + export type IntFieldUpdateOperationsInput = { + set?: number + increment?: number + decrement?: number + multiply?: number + divide?: number } - export type CalendarUpdateOneRequiredWithoutEventsNestedInput = { - create?: XOR - connectOrCreate?: CalendarCreateOrConnectWithoutEventsInput - upsert?: CalendarUpsertWithoutEventsInput - connect?: CalendarWhereUniqueInput - update?: XOR, CalendarUncheckedUpdateWithoutEventsInput> + export type NestedIntFilter<$PrismaModel = never> = { + equals?: number | IntFieldRefInput<$PrismaModel> + in?: number[] | ListIntFieldRefInput<$PrismaModel> + notIn?: number[] | ListIntFieldRefInput<$PrismaModel> + lt?: number | IntFieldRefInput<$PrismaModel> + lte?: number | IntFieldRefInput<$PrismaModel> + gt?: number | IntFieldRefInput<$PrismaModel> + gte?: number | IntFieldRefInput<$PrismaModel> + not?: NestedIntFilter<$PrismaModel> | number } export type NestedStringFilter<$PrismaModel = never> = { @@ -3918,6 +2599,17 @@ export namespace Prisma { not?: NestedStringFilter<$PrismaModel> | string } + export type NestedDateTimeFilter<$PrismaModel = never> = { + equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> + in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> + notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> + lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> + lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> + gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> + gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> + not?: NestedDateTimeFilter<$PrismaModel> | Date | string + } + export type NestedStringNullableFilter<$PrismaModel = never> = { equals?: string | StringFieldRefInput<$PrismaModel> | null in?: string[] | ListStringFieldRefInput<$PrismaModel> | null @@ -3932,15 +2624,42 @@ export namespace Prisma { not?: NestedStringNullableFilter<$PrismaModel> | string | null } - export type NestedDateTimeFilter<$PrismaModel = never> = { - equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> - in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> - notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> - lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> - lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> - gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> - gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> - not?: NestedDateTimeFilter<$PrismaModel> | Date | string + export type NestedFloatNullableFilter<$PrismaModel = never> = { + equals?: number | FloatFieldRefInput<$PrismaModel> | null + in?: number[] | ListFloatFieldRefInput<$PrismaModel> | null + notIn?: number[] | ListFloatFieldRefInput<$PrismaModel> | null + lt?: number | FloatFieldRefInput<$PrismaModel> + lte?: number | FloatFieldRefInput<$PrismaModel> + gt?: number | FloatFieldRefInput<$PrismaModel> + gte?: number | FloatFieldRefInput<$PrismaModel> + not?: NestedFloatNullableFilter<$PrismaModel> | number | null + } + + export type NestedIntWithAggregatesFilter<$PrismaModel = never> = { + equals?: number | IntFieldRefInput<$PrismaModel> + in?: number[] | ListIntFieldRefInput<$PrismaModel> + notIn?: number[] | ListIntFieldRefInput<$PrismaModel> + lt?: number | IntFieldRefInput<$PrismaModel> + lte?: number | IntFieldRefInput<$PrismaModel> + gt?: number | IntFieldRefInput<$PrismaModel> + gte?: number | IntFieldRefInput<$PrismaModel> + not?: NestedIntWithAggregatesFilter<$PrismaModel> | number + _count?: NestedIntFilter<$PrismaModel> + _avg?: NestedFloatFilter<$PrismaModel> + _sum?: NestedIntFilter<$PrismaModel> + _min?: NestedIntFilter<$PrismaModel> + _max?: NestedIntFilter<$PrismaModel> + } + + export type NestedFloatFilter<$PrismaModel = never> = { + equals?: number | FloatFieldRefInput<$PrismaModel> + in?: number[] | ListFloatFieldRefInput<$PrismaModel> + notIn?: number[] | ListFloatFieldRefInput<$PrismaModel> + lt?: number | FloatFieldRefInput<$PrismaModel> + lte?: number | FloatFieldRefInput<$PrismaModel> + gt?: number | FloatFieldRefInput<$PrismaModel> + gte?: number | FloatFieldRefInput<$PrismaModel> + not?: NestedFloatFilter<$PrismaModel> | number } export type NestedStringWithAggregatesFilter<$PrismaModel = never> = { @@ -3960,15 +2679,18 @@ export namespace Prisma { _max?: NestedStringFilter<$PrismaModel> } - export type NestedIntFilter<$PrismaModel = never> = { - equals?: number | IntFieldRefInput<$PrismaModel> - in?: number[] | ListIntFieldRefInput<$PrismaModel> - notIn?: number[] | ListIntFieldRefInput<$PrismaModel> - lt?: number | IntFieldRefInput<$PrismaModel> - lte?: number | IntFieldRefInput<$PrismaModel> - gt?: number | IntFieldRefInput<$PrismaModel> - gte?: number | IntFieldRefInput<$PrismaModel> - not?: NestedIntFilter<$PrismaModel> | number + export type NestedDateTimeWithAggregatesFilter<$PrismaModel = never> = { + equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> + in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> + notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> + lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> + lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> + gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> + gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> + not?: NestedDateTimeWithAggregatesFilter<$PrismaModel> | Date | string + _count?: NestedIntFilter<$PrismaModel> + _min?: NestedDateTimeFilter<$PrismaModel> + _max?: NestedDateTimeFilter<$PrismaModel> } export type NestedStringNullableWithAggregatesFilter<$PrismaModel = never> = { @@ -3999,201 +2721,20 @@ export namespace Prisma { not?: NestedIntNullableFilter<$PrismaModel> | number | null } - export type NestedDateTimeWithAggregatesFilter<$PrismaModel = never> = { - equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> - in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> - notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> - lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> - lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> - gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> - gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> - not?: NestedDateTimeWithAggregatesFilter<$PrismaModel> | Date | string - _count?: NestedIntFilter<$PrismaModel> - _min?: NestedDateTimeFilter<$PrismaModel> - _max?: NestedDateTimeFilter<$PrismaModel> - } - - export type NestedBoolFilter<$PrismaModel = never> = { - equals?: boolean | BooleanFieldRefInput<$PrismaModel> - not?: NestedBoolFilter<$PrismaModel> | boolean - } - - export type NestedBoolWithAggregatesFilter<$PrismaModel = never> = { - equals?: boolean | BooleanFieldRefInput<$PrismaModel> - not?: NestedBoolWithAggregatesFilter<$PrismaModel> | boolean - _count?: NestedIntFilter<$PrismaModel> - _min?: NestedBoolFilter<$PrismaModel> - _max?: NestedBoolFilter<$PrismaModel> - } - - export type EventCreateWithoutCalendarInput = { - id?: string - title: string - description?: string | null - start: Date | string - end: Date | string - location?: string | null - isAllDay?: boolean - createdAt?: Date | string - updatedAt?: Date | string - } - - export type EventUncheckedCreateWithoutCalendarInput = { - id?: string - title: string - description?: string | null - start: Date | string - end: Date | string - location?: string | null - isAllDay?: boolean - createdAt?: Date | string - updatedAt?: Date | string - } - - export type EventCreateOrConnectWithoutCalendarInput = { - where: EventWhereUniqueInput - create: XOR - } - - export type EventCreateManyCalendarInputEnvelope = { - data: EventCreateManyCalendarInput | EventCreateManyCalendarInput[] - skipDuplicates?: boolean - } - - export type EventUpsertWithWhereUniqueWithoutCalendarInput = { - where: EventWhereUniqueInput - update: XOR - create: XOR - } - - export type EventUpdateWithWhereUniqueWithoutCalendarInput = { - where: EventWhereUniqueInput - data: XOR - } - - export type EventUpdateManyWithWhereWithoutCalendarInput = { - where: EventScalarWhereInput - data: XOR - } - - export type EventScalarWhereInput = { - AND?: EventScalarWhereInput | EventScalarWhereInput[] - OR?: EventScalarWhereInput[] - NOT?: EventScalarWhereInput | EventScalarWhereInput[] - id?: StringFilter<"Event"> | string - title?: StringFilter<"Event"> | string - description?: StringNullableFilter<"Event"> | string | null - start?: DateTimeFilter<"Event"> | Date | string - end?: DateTimeFilter<"Event"> | Date | string - location?: StringNullableFilter<"Event"> | string | null - isAllDay?: BoolFilter<"Event"> | boolean - calendarId?: StringFilter<"Event"> | string - createdAt?: DateTimeFilter<"Event"> | Date | string - updatedAt?: DateTimeFilter<"Event"> | Date | string - } - - export type CalendarCreateWithoutEventsInput = { - id?: string - name: string - color?: string - description?: string | null - userId: string - createdAt?: Date | string - updatedAt?: Date | string - } - - export type CalendarUncheckedCreateWithoutEventsInput = { - id?: string - name: string - color?: string - description?: string | null - userId: string - createdAt?: Date | string - updatedAt?: Date | string - } - - export type CalendarCreateOrConnectWithoutEventsInput = { - where: CalendarWhereUniqueInput - create: XOR - } - - export type CalendarUpsertWithoutEventsInput = { - update: XOR - create: XOR - where?: CalendarWhereInput - } - - export type CalendarUpdateToOneWithWhereWithoutEventsInput = { - where?: CalendarWhereInput - data: XOR - } - - export type CalendarUpdateWithoutEventsInput = { - id?: StringFieldUpdateOperationsInput | string - name?: StringFieldUpdateOperationsInput | string - color?: StringFieldUpdateOperationsInput | string - description?: NullableStringFieldUpdateOperationsInput | string | null - userId?: StringFieldUpdateOperationsInput | string - createdAt?: DateTimeFieldUpdateOperationsInput | Date | string - updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string - } - - export type CalendarUncheckedUpdateWithoutEventsInput = { - id?: StringFieldUpdateOperationsInput | string - name?: StringFieldUpdateOperationsInput | string - color?: StringFieldUpdateOperationsInput | string - description?: NullableStringFieldUpdateOperationsInput | string | null - userId?: StringFieldUpdateOperationsInput | string - createdAt?: DateTimeFieldUpdateOperationsInput | Date | string - updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string - } - - export type EventCreateManyCalendarInput = { - id?: string - title: string - description?: string | null - start: Date | string - end: Date | string - location?: string | null - isAllDay?: boolean - createdAt?: Date | string - updatedAt?: Date | string - } - - export type EventUpdateWithoutCalendarInput = { - id?: StringFieldUpdateOperationsInput | string - title?: StringFieldUpdateOperationsInput | string - description?: NullableStringFieldUpdateOperationsInput | string | null - start?: DateTimeFieldUpdateOperationsInput | Date | string - end?: DateTimeFieldUpdateOperationsInput | Date | string - location?: NullableStringFieldUpdateOperationsInput | string | null - isAllDay?: BoolFieldUpdateOperationsInput | boolean - createdAt?: DateTimeFieldUpdateOperationsInput | Date | string - updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string - } - - export type EventUncheckedUpdateWithoutCalendarInput = { - id?: StringFieldUpdateOperationsInput | string - title?: StringFieldUpdateOperationsInput | string - description?: NullableStringFieldUpdateOperationsInput | string | null - start?: DateTimeFieldUpdateOperationsInput | Date | string - end?: DateTimeFieldUpdateOperationsInput | Date | string - location?: NullableStringFieldUpdateOperationsInput | string | null - isAllDay?: BoolFieldUpdateOperationsInput | boolean - createdAt?: DateTimeFieldUpdateOperationsInput | Date | string - updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string - } - - export type EventUncheckedUpdateManyWithoutCalendarInput = { - id?: StringFieldUpdateOperationsInput | string - title?: StringFieldUpdateOperationsInput | string - description?: NullableStringFieldUpdateOperationsInput | string | null - start?: DateTimeFieldUpdateOperationsInput | Date | string - end?: DateTimeFieldUpdateOperationsInput | Date | string - location?: NullableStringFieldUpdateOperationsInput | string | null - isAllDay?: BoolFieldUpdateOperationsInput | boolean - createdAt?: DateTimeFieldUpdateOperationsInput | Date | string - updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string + export type NestedFloatNullableWithAggregatesFilter<$PrismaModel = never> = { + equals?: number | FloatFieldRefInput<$PrismaModel> | null + in?: number[] | ListFloatFieldRefInput<$PrismaModel> | null + notIn?: number[] | ListFloatFieldRefInput<$PrismaModel> | null + lt?: number | FloatFieldRefInput<$PrismaModel> + lte?: number | FloatFieldRefInput<$PrismaModel> + gt?: number | FloatFieldRefInput<$PrismaModel> + gte?: number | FloatFieldRefInput<$PrismaModel> + not?: NestedFloatNullableWithAggregatesFilter<$PrismaModel> | number | null + _count?: NestedIntNullableFilter<$PrismaModel> + _avg?: NestedFloatNullableFilter<$PrismaModel> + _sum?: NestedFloatNullableFilter<$PrismaModel> + _min?: NestedFloatNullableFilter<$PrismaModel> + _max?: NestedFloatNullableFilter<$PrismaModel> } diff --git a/node_modules/.prisma/client/index.js b/node_modules/.prisma/client/index.js index 10f4b900..aca7c408 100644 --- a/node_modules/.prisma/client/index.js +++ b/node_modules/.prisma/client/index.js @@ -90,27 +90,20 @@ exports.Prisma.TransactionIsolationLevel = makeStrictEnum({ Serializable: 'Serializable' }); -exports.Prisma.CalendarScalarFieldEnum = { - id: 'id', - name: 'name', - color: 'color', - description: 'description', - userId: 'userId', - createdAt: 'createdAt', - updatedAt: 'updatedAt' -}; - -exports.Prisma.EventScalarFieldEnum = { +exports.Prisma.NewsScalarFieldEnum = { id: 'id', title: 'title', + url: 'url', + date: 'date', + source: 'source', + content: 'content', + sentiment_score: 'sentiment_score', + sentiment: 'sentiment', + symbols: 'symbols', + symbol: 'symbol', + processed_at: 'processed_at', description: 'description', - start: 'start', - end: 'end', - location: 'location', - isAllDay: 'isAllDay', - calendarId: 'calendarId', - createdAt: 'createdAt', - updatedAt: 'updatedAt' + category: 'category' }; exports.Prisma.SortOrder = { @@ -130,8 +123,7 @@ exports.Prisma.NullsOrder = { exports.Prisma.ModelName = { - Calendar: 'Calendar', - Event: 'Event' + News: 'News' }; /** * Create the Client @@ -144,7 +136,7 @@ const config = { "value": "prisma-client-js" }, "output": { - "value": "/Users/alma/Downloads/neah/front/node_modules/@prisma/client", + "value": "/Users/alma/Downloads/neahfront6/node_modules/@prisma/client", "fromEnvVar": null }, "config": { @@ -155,13 +147,18 @@ const config = { "fromEnvVar": null, "value": "darwin-arm64", "native": true + }, + { + "fromEnvVar": null, + "value": "linux-arm64-openssl-3.0.x" } ], "previewFeatures": [], - "sourceFilePath": "/Users/alma/Downloads/neah/front/prisma/schema.prisma" + "sourceFilePath": "/Users/alma/Downloads/neahfront6/prisma/news.schema.prisma" }, "relativeEnvPaths": { - "rootEnvPath": null + "rootEnvPath": null, + "schemaEnvPath": "../../../.env" }, "relativePath": "../../../prisma", "clientVersion": "6.4.1", @@ -170,17 +167,17 @@ const config = { "db" ], "activeProvider": "postgresql", - "postinstall": true, + "postinstall": false, "inlineDatasources": { "db": { "url": { - "fromEnvVar": null, - "value": "postgresql://enkun:183d9ad665c9257703c2e0703f111d240266a56b33e10df04fb8c565e55e0b94@172.16.32.141:5432/enkun?schema=public" + "fromEnvVar": "NEWSDB_URL", + "value": null } } }, - "inlineSchema": "generator client {\n provider = \"prisma-client-js\"\n}\n\ndatasource db {\n provider = \"postgresql\"\n //TODO: Modifier l'url\n url = \"postgresql://enkun:183d9ad665c9257703c2e0703f111d240266a56b33e10df04fb8c565e55e0b94@172.16.32.141:5432/enkun?schema=public\"\n}\n\nmodel Calendar {\n id String @id @default(cuid())\n name String\n color String @default(\"#0082c9\")\n description String?\n userId String\n createdAt DateTime @default(now())\n updatedAt DateTime @updatedAt\n events Event[]\n\n @@index([userId])\n}\n\nmodel Event {\n id String @id @default(cuid())\n title String\n description String?\n start DateTime\n end DateTime\n location String?\n isAllDay Boolean @default(false)\n calendar Calendar @relation(fields: [calendarId], references: [id], onDelete: Cascade)\n calendarId String\n createdAt DateTime @default(now())\n updatedAt DateTime @updatedAt\n\n @@index([calendarId])\n @@index([start, end])\n}\n", - "inlineSchemaHash": "d54fe55cddcb5a229a08e0b8c234fdd2db832218b95783858f4595ac032de6be", + "inlineSchema": "// This is your Prisma schema file for the news database\ngenerator client {\n provider = \"prisma-client-js\"\n binaryTargets = [\"native\", \"linux-arm64-openssl-3.0.x\"]\n}\n\ndatasource db {\n provider = \"postgresql\"\n url = env(\"NEWSDB_URL\")\n}\n\nmodel News {\n id Int @id @default(autoincrement())\n title String\n url String @unique\n date DateTime\n source String\n content String?\n sentiment_score Float?\n sentiment String?\n symbols String[]\n symbol String?\n processed_at DateTime @default(now())\n description String?\n category String? @db.VarChar(50)\n\n @@index([category])\n @@index([date])\n @@index([symbol])\n}\n", + "inlineSchemaHash": "ab8ea0a0b44e836388cadcdd96e01142dc99421f5ecdef6cc8db0283fcfaa7b5", "copyEngine": true } @@ -201,7 +198,7 @@ if (!fs.existsSync(path.join(__dirname, 'schema.prisma'))) { config.isBundled = true } -config.runtimeDataModel = JSON.parse("{\"models\":{\"Calendar\":{\"dbName\":null,\"schema\":null,\"fields\":[{\"name\":\"id\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":true,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"String\",\"nativeType\":null,\"default\":{\"name\":\"cuid\",\"args\":[1]},\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"name\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"color\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"String\",\"nativeType\":null,\"default\":\"#0082c9\",\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"description\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"userId\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"createdAt\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"DateTime\",\"nativeType\":null,\"default\":{\"name\":\"now\",\"args\":[]},\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"updatedAt\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"DateTime\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":true},{\"name\":\"events\",\"kind\":\"object\",\"isList\":true,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"Event\",\"nativeType\":null,\"relationName\":\"CalendarToEvent\",\"relationFromFields\":[],\"relationToFields\":[],\"isGenerated\":false,\"isUpdatedAt\":false}],\"primaryKey\":null,\"uniqueFields\":[],\"uniqueIndexes\":[],\"isGenerated\":false},\"Event\":{\"dbName\":null,\"schema\":null,\"fields\":[{\"name\":\"id\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":true,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"String\",\"nativeType\":null,\"default\":{\"name\":\"cuid\",\"args\":[1]},\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"title\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"description\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"start\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"DateTime\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"end\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"DateTime\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"location\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"isAllDay\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"Boolean\",\"nativeType\":null,\"default\":false,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"calendar\",\"kind\":\"object\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"Calendar\",\"nativeType\":null,\"relationName\":\"CalendarToEvent\",\"relationFromFields\":[\"calendarId\"],\"relationToFields\":[\"id\"],\"relationOnDelete\":\"Cascade\",\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"calendarId\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":true,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"createdAt\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"DateTime\",\"nativeType\":null,\"default\":{\"name\":\"now\",\"args\":[]},\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"updatedAt\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"DateTime\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":true}],\"primaryKey\":null,\"uniqueFields\":[],\"uniqueIndexes\":[],\"isGenerated\":false}},\"enums\":{},\"types\":{}}") +config.runtimeDataModel = JSON.parse("{\"models\":{\"News\":{\"dbName\":null,\"schema\":null,\"fields\":[{\"name\":\"id\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":true,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"Int\",\"nativeType\":null,\"default\":{\"name\":\"autoincrement\",\"args\":[]},\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"title\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"url\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":true,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"date\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"DateTime\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"source\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"content\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"sentiment_score\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"Float\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"sentiment\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"symbols\",\"kind\":\"scalar\",\"isList\":true,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"symbol\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"processed_at\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"DateTime\",\"nativeType\":null,\"default\":{\"name\":\"now\",\"args\":[]},\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"description\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":null,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"category\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":false,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"String\",\"nativeType\":[\"VarChar\",[\"50\"]],\"isGenerated\":false,\"isUpdatedAt\":false}],\"primaryKey\":null,\"uniqueFields\":[],\"uniqueIndexes\":[],\"isGenerated\":false}},\"enums\":{},\"types\":{}}") defineDmmfProperty(exports.Prisma, config.runtimeDataModel) config.engineWasm = undefined config.compilerWasm = undefined @@ -221,6 +218,10 @@ Object.assign(exports, Prisma) // file annotations for bundling tools to include these files path.join(__dirname, "libquery_engine-darwin-arm64.dylib.node"); path.join(process.cwd(), "node_modules/.prisma/client/libquery_engine-darwin-arm64.dylib.node") + +// file annotations for bundling tools to include these files +path.join(__dirname, "libquery_engine-linux-arm64-openssl-3.0.x.so.node"); +path.join(process.cwd(), "node_modules/.prisma/client/libquery_engine-linux-arm64-openssl-3.0.x.so.node") // file annotations for bundling tools to include these files path.join(__dirname, "schema.prisma"); path.join(process.cwd(), "node_modules/.prisma/client/schema.prisma") diff --git a/node_modules/.prisma/client/package.json b/node_modules/.prisma/client/package.json index 9ee200ba..d5bc2a3f 100644 --- a/node_modules/.prisma/client/package.json +++ b/node_modules/.prisma/client/package.json @@ -1,5 +1,5 @@ { - "name": "prisma-client-a39bf2eb34241f9f263bba0d47613aa7e5863c7141c09c9c46ea39fc56dce086", + "name": "prisma-client-eeb846ee0ec87fa2c130414bdb67895badd3ab3283962f9d99affb3454d642b0", "main": "index.js", "types": "index.d.ts", "browser": "index-browser.js", diff --git a/node_modules/.prisma/client/schema.prisma b/node_modules/.prisma/client/schema.prisma index ab077ece..51b3a083 100644 --- a/node_modules/.prisma/client/schema.prisma +++ b/node_modules/.prisma/client/schema.prisma @@ -1,39 +1,30 @@ +// This is your Prisma schema file for the news database generator client { - provider = "prisma-client-js" + provider = "prisma-client-js" + binaryTargets = ["native", "linux-arm64-openssl-3.0.x"] } datasource db { provider = "postgresql" - //TODO: Modifier l'url - url = "postgresql://enkun:183d9ad665c9257703c2e0703f111d240266a56b33e10df04fb8c565e55e0b94@172.16.32.141:5432/enkun?schema=public" + url = env("NEWSDB_URL") } -model Calendar { - id String @id @default(cuid()) - name String - color String @default("#0082c9") - description String? - userId String - createdAt DateTime @default(now()) - updatedAt DateTime @updatedAt - events Event[] +model News { + id Int @id @default(autoincrement()) + title String + url String @unique + date DateTime + source String + content String? + sentiment_score Float? + sentiment String? + symbols String[] + symbol String? + processed_at DateTime @default(now()) + description String? + category String? @db.VarChar(50) - @@index([userId]) -} - -model Event { - id String @id @default(cuid()) - title String - description String? - start DateTime - end DateTime - location String? - isAllDay Boolean @default(false) - calendar Calendar @relation(fields: [calendarId], references: [id], onDelete: Cascade) - calendarId String - createdAt DateTime @default(now()) - updatedAt DateTime @updatedAt - - @@index([calendarId]) - @@index([start, end]) + @@index([category]) + @@index([date]) + @@index([symbol]) } diff --git a/node_modules/.prisma/client/wasm.js b/node_modules/.prisma/client/wasm.js index cbb8f5e6..52d7b987 100644 --- a/node_modules/.prisma/client/wasm.js +++ b/node_modules/.prisma/client/wasm.js @@ -117,27 +117,20 @@ exports.Prisma.TransactionIsolationLevel = makeStrictEnum({ Serializable: 'Serializable' }); -exports.Prisma.CalendarScalarFieldEnum = { - id: 'id', - name: 'name', - color: 'color', - description: 'description', - userId: 'userId', - createdAt: 'createdAt', - updatedAt: 'updatedAt' -}; - -exports.Prisma.EventScalarFieldEnum = { +exports.Prisma.NewsScalarFieldEnum = { id: 'id', title: 'title', + url: 'url', + date: 'date', + source: 'source', + content: 'content', + sentiment_score: 'sentiment_score', + sentiment: 'sentiment', + symbols: 'symbols', + symbol: 'symbol', + processed_at: 'processed_at', description: 'description', - start: 'start', - end: 'end', - location: 'location', - isAllDay: 'isAllDay', - calendarId: 'calendarId', - createdAt: 'createdAt', - updatedAt: 'updatedAt' + category: 'category' }; exports.Prisma.SortOrder = { @@ -157,8 +150,7 @@ exports.Prisma.NullsOrder = { exports.Prisma.ModelName = { - Calendar: 'Calendar', - Event: 'Event' + News: 'News' }; /** diff --git a/prisma/news.schema.prisma b/prisma/news.schema.prisma new file mode 100644 index 00000000..14d69b28 --- /dev/null +++ b/prisma/news.schema.prisma @@ -0,0 +1,30 @@ +// This is your Prisma schema file for the news database +generator client { + provider = "prisma-client-js" + binaryTargets = ["native", "linux-arm64-openssl-3.0.x"] +} + +datasource db { + provider = "postgresql" + url = env("NEWSDB_URL") +} + +model News { + id Int @id @default(autoincrement()) + title String + url String @unique + date DateTime + source String + content String? + sentiment_score Float? + sentiment String? + symbols String[] + symbol String? + processed_at DateTime @default(now()) + description String? + category String? @db.VarChar(50) + + @@index([category]) + @@index([date]) + @@index([symbol]) +} \ No newline at end of file diff --git a/prisma/schema.prisma b/prisma/schema.prisma index 8af7fe4b..7c2e3447 100644 --- a/prisma/schema.prisma +++ b/prisma/schema.prisma @@ -11,11 +11,6 @@ datasource db { url = env("DATABASE_URL") } -datasource newsdb { - provider = "postgresql" - url = env("NEWSDB_URL") -} - model Calendar { id String @id @default(uuid()) name String @@ -45,24 +40,4 @@ model Event { @@index([calendarId]) @@index([userId]) -} - -model News { - id Int @id @default(autoincrement()) - title String - url String @unique - date DateTime - source String - content String? - sentiment_score Float? - sentiment String? - symbols String[] - symbol String? - processed_at DateTime @default(now()) - description String? - category String? @db.VarChar(50) - - @@index([category]) - @@index([date]) - @@index([symbol]) } \ No newline at end of file