Expanded groups scheme. Expanded addGroups mutation. Refactored addGroups mutation to update username and title of a group when used. Added an incrementGroups mutation that updates the new deletedLinks row in the scheme.
This commit is contained in:
@@ -105,10 +105,31 @@ export const resolvers = {
|
||||
},
|
||||
addGroup: async (
|
||||
_parent: unknown,
|
||||
data: { groupID: number; groupName: string }
|
||||
data: { groupID: number; groupName: string; groupUsername: string }
|
||||
// _ctx: unknown
|
||||
) => {
|
||||
const { groupID, groupName } = data;
|
||||
const { groupID, groupName, groupUsername } = data;
|
||||
|
||||
const existingGroup = await prisma.groups.findFirst({
|
||||
where: { telegramID: groupID }
|
||||
});
|
||||
|
||||
if (existingGroup !== null) {
|
||||
if (
|
||||
existingGroup.name !== groupName ||
|
||||
existingGroup.username !== groupUsername
|
||||
) {
|
||||
return await prisma.groups.update({
|
||||
where: {
|
||||
telegramID: existingGroup.telegramID
|
||||
},
|
||||
data: { name: groupName, username: groupUsername || "" }
|
||||
});
|
||||
}
|
||||
|
||||
return existingGroup;
|
||||
}
|
||||
|
||||
return await prisma.groups.create({
|
||||
data: {
|
||||
telegramID: groupID,
|
||||
@@ -116,6 +137,18 @@ export const resolvers = {
|
||||
}
|
||||
});
|
||||
},
|
||||
incrementGroup: async (
|
||||
_parent: unknown,
|
||||
data: { groupID: number; linksDeleted: number }
|
||||
// _ctx: unknown
|
||||
) => {
|
||||
const { groupID, linksDeleted } = data;
|
||||
|
||||
return await prisma.groups.update({
|
||||
where: { telegramID: groupID },
|
||||
data: { linksDeleted: { increment: linksDeleted } }
|
||||
});
|
||||
},
|
||||
increment: async (
|
||||
_parent: unknown,
|
||||
data: { link: boolean; command: boolean; trigger: boolean }
|
||||
|
||||
@@ -13,13 +13,16 @@ const typeDefs = /* GraphQL */ `
|
||||
type Mutation {
|
||||
init: String!
|
||||
cronJob: TotalStats!
|
||||
addGroup(groupID: Int, groupName: String): Groups!
|
||||
addGroup(groupID: BigInt, groupName: String, groupUsername: String): Groups!
|
||||
incrementGroup(groupID: BigInt, linksDeleted: Int): Groups!
|
||||
increment(link: Boolean, command: Boolean, trigger: Boolean): DailyStats!
|
||||
}
|
||||
|
||||
type Groups {
|
||||
telegramID: Int
|
||||
telegramID: BigInt
|
||||
name: String
|
||||
username: String
|
||||
linksDeleted: BigInt
|
||||
createdAt: Date
|
||||
updatedAt: Date
|
||||
}
|
||||
|
||||
@@ -14,15 +14,15 @@ import * as $Enums from "./enums"
|
||||
import type * as Prisma from "./internal/prismaNamespace"
|
||||
|
||||
|
||||
export type IntFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
in?: number[] | Prisma.ListIntFieldRefInput<$PrismaModel>
|
||||
notIn?: number[] | Prisma.ListIntFieldRefInput<$PrismaModel>
|
||||
lt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
lte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedIntFilter<$PrismaModel> | number
|
||||
export type BigIntFilter<$PrismaModel = never> = {
|
||||
equals?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
in?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
notIn?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
lt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
lte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBigIntFilter<$PrismaModel> | bigint | number
|
||||
}
|
||||
|
||||
export type StringFilter<$PrismaModel = never> = {
|
||||
@@ -51,20 +51,20 @@ export type DateTimeFilter<$PrismaModel = never> = {
|
||||
not?: Prisma.NestedDateTimeFilter<$PrismaModel> | Date | string
|
||||
}
|
||||
|
||||
export type IntWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
in?: number[] | Prisma.ListIntFieldRefInput<$PrismaModel>
|
||||
notIn?: number[] | Prisma.ListIntFieldRefInput<$PrismaModel>
|
||||
lt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
lte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedIntWithAggregatesFilter<$PrismaModel> | number
|
||||
export type BigIntWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
in?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
notIn?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
lt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
lte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBigIntWithAggregatesFilter<$PrismaModel> | bigint | number
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_avg?: Prisma.NestedFloatFilter<$PrismaModel>
|
||||
_sum?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_sum?: Prisma.NestedBigIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedBigIntFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedBigIntFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type StringWithAggregatesFilter<$PrismaModel = never> = {
|
||||
@@ -99,34 +99,7 @@ export type DateTimeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
_max?: Prisma.NestedDateTimeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type BigIntFilter<$PrismaModel = never> = {
|
||||
equals?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
in?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
notIn?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
lt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
lte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBigIntFilter<$PrismaModel> | bigint | number
|
||||
}
|
||||
|
||||
export type BigIntWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
in?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
notIn?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
lt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
lte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBigIntWithAggregatesFilter<$PrismaModel> | bigint | number
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_avg?: Prisma.NestedFloatFilter<$PrismaModel>
|
||||
_sum?: Prisma.NestedBigIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedBigIntFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedBigIntFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedIntFilter<$PrismaModel = never> = {
|
||||
export type IntFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
in?: number[] | Prisma.ListIntFieldRefInput<$PrismaModel>
|
||||
notIn?: number[] | Prisma.ListIntFieldRefInput<$PrismaModel>
|
||||
@@ -137,6 +110,33 @@ export type NestedIntFilter<$PrismaModel = never> = {
|
||||
not?: Prisma.NestedIntFilter<$PrismaModel> | number
|
||||
}
|
||||
|
||||
export type IntWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
in?: number[] | Prisma.ListIntFieldRefInput<$PrismaModel>
|
||||
notIn?: number[] | Prisma.ListIntFieldRefInput<$PrismaModel>
|
||||
lt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
lte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedIntWithAggregatesFilter<$PrismaModel> | number
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_avg?: Prisma.NestedFloatFilter<$PrismaModel>
|
||||
_sum?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedBigIntFilter<$PrismaModel = never> = {
|
||||
equals?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
in?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
notIn?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
lt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
lte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBigIntFilter<$PrismaModel> | bigint | number
|
||||
}
|
||||
|
||||
export type NestedStringFilter<$PrismaModel = never> = {
|
||||
equals?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
in?: string[] | Prisma.ListStringFieldRefInput<$PrismaModel>
|
||||
@@ -162,7 +162,23 @@ export type NestedDateTimeFilter<$PrismaModel = never> = {
|
||||
not?: Prisma.NestedDateTimeFilter<$PrismaModel> | Date | string
|
||||
}
|
||||
|
||||
export type NestedIntWithAggregatesFilter<$PrismaModel = never> = {
|
||||
export type NestedBigIntWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
in?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
notIn?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
lt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
lte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBigIntWithAggregatesFilter<$PrismaModel> | bigint | number
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_avg?: Prisma.NestedFloatFilter<$PrismaModel>
|
||||
_sum?: Prisma.NestedBigIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedBigIntFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedBigIntFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedIntFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
in?: number[] | Prisma.ListIntFieldRefInput<$PrismaModel>
|
||||
notIn?: number[] | Prisma.ListIntFieldRefInput<$PrismaModel>
|
||||
@@ -170,12 +186,7 @@ export type NestedIntWithAggregatesFilter<$PrismaModel = never> = {
|
||||
lte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedIntWithAggregatesFilter<$PrismaModel> | number
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_avg?: Prisma.NestedFloatFilter<$PrismaModel>
|
||||
_sum?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
not?: Prisma.NestedIntFilter<$PrismaModel> | number
|
||||
}
|
||||
|
||||
export type NestedFloatFilter<$PrismaModel = never> = {
|
||||
@@ -220,31 +231,20 @@ export type NestedDateTimeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
_max?: Prisma.NestedDateTimeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedBigIntFilter<$PrismaModel = never> = {
|
||||
equals?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
in?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
notIn?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
lt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
lte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBigIntFilter<$PrismaModel> | bigint | number
|
||||
}
|
||||
|
||||
export type NestedBigIntWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
in?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
notIn?: bigint[] | number[] | Prisma.ListBigIntFieldRefInput<$PrismaModel>
|
||||
lt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
lte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gt?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
gte?: bigint | number | Prisma.BigIntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBigIntWithAggregatesFilter<$PrismaModel> | bigint | number
|
||||
export type NestedIntWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
in?: number[] | Prisma.ListIntFieldRefInput<$PrismaModel>
|
||||
notIn?: number[] | Prisma.ListIntFieldRefInput<$PrismaModel>
|
||||
lt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
lte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedIntWithAggregatesFilter<$PrismaModel> | number
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_avg?: Prisma.NestedFloatFilter<$PrismaModel>
|
||||
_sum?: Prisma.NestedBigIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedBigIntFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedBigIntFilter<$PrismaModel>
|
||||
_sum?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -47,7 +47,6 @@ const config: runtime.GetPrismaClientConfig = {
|
||||
"db"
|
||||
],
|
||||
"activeProvider": "mongodb",
|
||||
"postinstall": true,
|
||||
"inlineDatasources": {
|
||||
"db": {
|
||||
"url": {
|
||||
@@ -56,8 +55,8 @@ const config: runtime.GetPrismaClientConfig = {
|
||||
}
|
||||
}
|
||||
},
|
||||
"inlineSchema": "// This is your Prisma schema file,\n// learn more about it in the docs: https://pris.ly/d/prisma-schema\n\n// Looking for ways to speed up your queries, or scale easily with your serverless or edge functions?\n// Try Prisma Accelerate: https://pris.ly/cli/accelerate-init\n\ngenerator client {\n provider = \"prisma-client\"\n output = \"generated\"\n}\n\ndatasource db {\n provider = \"mongodb\"\n url = env(\"DATABASE_URL\")\n}\n\nmodel Groups {\n telegramID Int @id @map(\"_id\") @db.Int\n name String\n createdAt DateTime @default(now())\n updatedAt DateTime @default(now()) @updatedAt\n}\n\nmodel TotalStats {\n createdAt DateTime @id @default(now()) @map(\"_id\")\n updatedAt DateTime @default(now()) @updatedAt\n linksDeleted BigInt @default(0) @db.Long\n commandResponses BigInt @default(0) @db.Long\n timesTriggered BigInt @default(0) @db.Long\n}\n\nmodel DailyStats {\n createdAt DateTime @id @default(now()) @map(\"_id\")\n updatedAt DateTime @default(now()) @updatedAt\n linksDeleted Int @default(0) @db.Int\n commandResponses Int @default(0) @db.Int\n timesTriggered Int @default(0) @db.Int\n}\n",
|
||||
"inlineSchemaHash": "0774d8717cbe04c1e3c6c3a2f861e5d37cdde6afa6ac939d315318e6dd21e64f",
|
||||
"inlineSchema": "// This is your Prisma schema file,\n// learn more about it in the docs: https://pris.ly/d/prisma-schema\n\n// Looking for ways to speed up your queries, or scale easily with your serverless or edge functions?\n// Try Prisma Accelerate: https://pris.ly/cli/accelerate-init\n\ngenerator client {\n provider = \"prisma-client\"\n output = \"generated\"\n}\n\ndatasource db {\n provider = \"mongodb\"\n url = env(\"DATABASE_URL\")\n}\n\nmodel Groups {\n telegramID BigInt @id @map(\"_id\") @db.Long\n name String\n username String @default(\"\")\n linksDeleted BigInt @default(0) @db.Long\n createdAt DateTime @default(now())\n updatedAt DateTime @default(now()) @updatedAt\n}\n\nmodel TotalStats {\n createdAt DateTime @id @default(now()) @map(\"_id\")\n updatedAt DateTime @default(now()) @updatedAt\n linksDeleted BigInt @default(0) @db.Long\n commandResponses BigInt @default(0) @db.Long\n timesTriggered BigInt @default(0) @db.Long\n}\n\nmodel DailyStats {\n createdAt DateTime @id @default(now()) @map(\"_id\")\n updatedAt DateTime @default(now()) @updatedAt\n linksDeleted Int @default(0) @db.Int\n commandResponses Int @default(0) @db.Int\n timesTriggered Int @default(0) @db.Int\n}\n",
|
||||
"inlineSchemaHash": "7ad3413e48bf8457ce655de4b457d4b5629952ca6a037b0fe084bc063b32d97d",
|
||||
"copyEngine": true,
|
||||
"runtimeDataModel": {
|
||||
"models": {},
|
||||
@@ -67,7 +66,7 @@ const config: runtime.GetPrismaClientConfig = {
|
||||
"dirname": ""
|
||||
}
|
||||
|
||||
config.runtimeDataModel = JSON.parse("{\"models\":{\"Groups\":{\"dbName\":null,\"schema\":null,\"fields\":[{\"name\":\"telegramID\",\"dbName\":\"_id\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":true,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"Int\",\"nativeType\":[\"Int\",[]],\"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\":\"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\":true,\"type\":\"DateTime\",\"nativeType\":null,\"default\":{\"name\":\"now\",\"args\":[]},\"isGenerated\":false,\"isUpdatedAt\":true}],\"primaryKey\":null,\"uniqueFields\":[],\"uniqueIndexes\":[],\"isGenerated\":false},\"TotalStats\":{\"dbName\":null,\"schema\":null,\"fields\":[{\"name\":\"createdAt\",\"dbName\":\"_id\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":true,\"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\":true,\"type\":\"DateTime\",\"nativeType\":null,\"default\":{\"name\":\"now\",\"args\":[]},\"isGenerated\":false,\"isUpdatedAt\":true},{\"name\":\"linksDeleted\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"BigInt\",\"nativeType\":[\"Long\",[]],\"default\":\"0\",\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"commandResponses\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"BigInt\",\"nativeType\":[\"Long\",[]],\"default\":\"0\",\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"timesTriggered\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"BigInt\",\"nativeType\":[\"Long\",[]],\"default\":\"0\",\"isGenerated\":false,\"isUpdatedAt\":false}],\"primaryKey\":null,\"uniqueFields\":[],\"uniqueIndexes\":[],\"isGenerated\":false},\"DailyStats\":{\"dbName\":null,\"schema\":null,\"fields\":[{\"name\":\"createdAt\",\"dbName\":\"_id\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":true,\"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\":true,\"type\":\"DateTime\",\"nativeType\":null,\"default\":{\"name\":\"now\",\"args\":[]},\"isGenerated\":false,\"isUpdatedAt\":true},{\"name\":\"linksDeleted\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"Int\",\"nativeType\":[\"Int\",[]],\"default\":0,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"commandResponses\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"Int\",\"nativeType\":[\"Int\",[]],\"default\":0,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"timesTriggered\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"Int\",\"nativeType\":[\"Int\",[]],\"default\":0,\"isGenerated\":false,\"isUpdatedAt\":false}],\"primaryKey\":null,\"uniqueFields\":[],\"uniqueIndexes\":[],\"isGenerated\":false}},\"enums\":{},\"types\":{}}")
|
||||
config.runtimeDataModel = JSON.parse("{\"models\":{\"Groups\":{\"dbName\":null,\"schema\":null,\"fields\":[{\"name\":\"telegramID\",\"dbName\":\"_id\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":true,\"isReadOnly\":false,\"hasDefaultValue\":false,\"type\":\"BigInt\",\"nativeType\":[\"Long\",[]],\"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\":\"username\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"String\",\"nativeType\":null,\"default\":\"\",\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"linksDeleted\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"BigInt\",\"nativeType\":[\"Long\",[]],\"default\":\"0\",\"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\":true,\"type\":\"DateTime\",\"nativeType\":null,\"default\":{\"name\":\"now\",\"args\":[]},\"isGenerated\":false,\"isUpdatedAt\":true}],\"primaryKey\":null,\"uniqueFields\":[],\"uniqueIndexes\":[],\"isGenerated\":false},\"TotalStats\":{\"dbName\":null,\"schema\":null,\"fields\":[{\"name\":\"createdAt\",\"dbName\":\"_id\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":true,\"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\":true,\"type\":\"DateTime\",\"nativeType\":null,\"default\":{\"name\":\"now\",\"args\":[]},\"isGenerated\":false,\"isUpdatedAt\":true},{\"name\":\"linksDeleted\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"BigInt\",\"nativeType\":[\"Long\",[]],\"default\":\"0\",\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"commandResponses\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"BigInt\",\"nativeType\":[\"Long\",[]],\"default\":\"0\",\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"timesTriggered\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"BigInt\",\"nativeType\":[\"Long\",[]],\"default\":\"0\",\"isGenerated\":false,\"isUpdatedAt\":false}],\"primaryKey\":null,\"uniqueFields\":[],\"uniqueIndexes\":[],\"isGenerated\":false},\"DailyStats\":{\"dbName\":null,\"schema\":null,\"fields\":[{\"name\":\"createdAt\",\"dbName\":\"_id\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":true,\"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\":true,\"type\":\"DateTime\",\"nativeType\":null,\"default\":{\"name\":\"now\",\"args\":[]},\"isGenerated\":false,\"isUpdatedAt\":true},{\"name\":\"linksDeleted\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"Int\",\"nativeType\":[\"Int\",[]],\"default\":0,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"commandResponses\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"Int\",\"nativeType\":[\"Int\",[]],\"default\":0,\"isGenerated\":false,\"isUpdatedAt\":false},{\"name\":\"timesTriggered\",\"kind\":\"scalar\",\"isList\":false,\"isRequired\":true,\"isUnique\":false,\"isId\":false,\"isReadOnly\":false,\"hasDefaultValue\":true,\"type\":\"Int\",\"nativeType\":[\"Int\",[]],\"default\":0,\"isGenerated\":false,\"isUpdatedAt\":false}],\"primaryKey\":null,\"uniqueFields\":[],\"uniqueIndexes\":[],\"isGenerated\":false}},\"enums\":{},\"types\":{}}")
|
||||
config.engineWasm = undefined
|
||||
config.compilerWasm = undefined
|
||||
|
||||
|
||||
@@ -654,6 +654,8 @@ export type TypeMap<ExtArgs extends runtime.Types.Extensions.InternalArgs = runt
|
||||
export const GroupsScalarFieldEnum = {
|
||||
telegramID: 'telegramID',
|
||||
name: 'name',
|
||||
username: 'username',
|
||||
linksDeleted: 'linksDeleted',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt'
|
||||
} as const
|
||||
@@ -706,16 +708,16 @@ export type QueryMode = (typeof QueryMode)[keyof typeof QueryMode]
|
||||
|
||||
|
||||
/**
|
||||
* Reference to a field of type 'Int'
|
||||
* Reference to a field of type 'BigInt'
|
||||
*/
|
||||
export type IntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int'>
|
||||
export type BigIntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'BigInt'>
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Reference to a field of type 'Int[]'
|
||||
* Reference to a field of type 'BigInt[]'
|
||||
*/
|
||||
export type ListIntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int[]'>
|
||||
export type ListBigIntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'BigInt[]'>
|
||||
|
||||
|
||||
|
||||
@@ -748,16 +750,16 @@ export type ListDateTimeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaM
|
||||
|
||||
|
||||
/**
|
||||
* Reference to a field of type 'BigInt'
|
||||
* Reference to a field of type 'Int'
|
||||
*/
|
||||
export type BigIntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'BigInt'>
|
||||
export type IntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int'>
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Reference to a field of type 'BigInt[]'
|
||||
* Reference to a field of type 'Int[]'
|
||||
*/
|
||||
export type ListBigIntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'BigInt[]'>
|
||||
export type ListIntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int[]'>
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -63,6 +63,8 @@ export type ModelName = (typeof ModelName)[keyof typeof ModelName]
|
||||
export const GroupsScalarFieldEnum = {
|
||||
telegramID: 'telegramID',
|
||||
name: 'name',
|
||||
username: 'username',
|
||||
linksDeleted: 'linksDeleted',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt'
|
||||
} as const
|
||||
|
||||
@@ -28,22 +28,28 @@ export type AggregateGroups = {
|
||||
|
||||
export type GroupsAvgAggregateOutputType = {
|
||||
telegramID: number | null
|
||||
linksDeleted: number | null
|
||||
}
|
||||
|
||||
export type GroupsSumAggregateOutputType = {
|
||||
telegramID: number | null
|
||||
telegramID: bigint | null
|
||||
linksDeleted: bigint | null
|
||||
}
|
||||
|
||||
export type GroupsMinAggregateOutputType = {
|
||||
telegramID: number | null
|
||||
telegramID: bigint | null
|
||||
name: string | null
|
||||
username: string | null
|
||||
linksDeleted: bigint | null
|
||||
createdAt: Date | null
|
||||
updatedAt: Date | null
|
||||
}
|
||||
|
||||
export type GroupsMaxAggregateOutputType = {
|
||||
telegramID: number | null
|
||||
telegramID: bigint | null
|
||||
name: string | null
|
||||
username: string | null
|
||||
linksDeleted: bigint | null
|
||||
createdAt: Date | null
|
||||
updatedAt: Date | null
|
||||
}
|
||||
@@ -51,6 +57,8 @@ export type GroupsMaxAggregateOutputType = {
|
||||
export type GroupsCountAggregateOutputType = {
|
||||
telegramID: number
|
||||
name: number
|
||||
username: number
|
||||
linksDeleted: number
|
||||
createdAt: number
|
||||
updatedAt: number
|
||||
_all: number
|
||||
@@ -59,15 +67,19 @@ export type GroupsCountAggregateOutputType = {
|
||||
|
||||
export type GroupsAvgAggregateInputType = {
|
||||
telegramID?: true
|
||||
linksDeleted?: true
|
||||
}
|
||||
|
||||
export type GroupsSumAggregateInputType = {
|
||||
telegramID?: true
|
||||
linksDeleted?: true
|
||||
}
|
||||
|
||||
export type GroupsMinAggregateInputType = {
|
||||
telegramID?: true
|
||||
name?: true
|
||||
username?: true
|
||||
linksDeleted?: true
|
||||
createdAt?: true
|
||||
updatedAt?: true
|
||||
}
|
||||
@@ -75,6 +87,8 @@ export type GroupsMinAggregateInputType = {
|
||||
export type GroupsMaxAggregateInputType = {
|
||||
telegramID?: true
|
||||
name?: true
|
||||
username?: true
|
||||
linksDeleted?: true
|
||||
createdAt?: true
|
||||
updatedAt?: true
|
||||
}
|
||||
@@ -82,6 +96,8 @@ export type GroupsMaxAggregateInputType = {
|
||||
export type GroupsCountAggregateInputType = {
|
||||
telegramID?: true
|
||||
name?: true
|
||||
username?: true
|
||||
linksDeleted?: true
|
||||
createdAt?: true
|
||||
updatedAt?: true
|
||||
_all?: true
|
||||
@@ -174,8 +190,10 @@ export type GroupsGroupByArgs<ExtArgs extends runtime.Types.Extensions.InternalA
|
||||
}
|
||||
|
||||
export type GroupsGroupByOutputType = {
|
||||
telegramID: number
|
||||
telegramID: bigint
|
||||
name: string
|
||||
username: string
|
||||
linksDeleted: bigint
|
||||
createdAt: Date
|
||||
updatedAt: Date
|
||||
_count: GroupsCountAggregateOutputType | null
|
||||
@@ -204,8 +222,10 @@ export type GroupsWhereInput = {
|
||||
AND?: Prisma.GroupsWhereInput | Prisma.GroupsWhereInput[]
|
||||
OR?: Prisma.GroupsWhereInput[]
|
||||
NOT?: Prisma.GroupsWhereInput | Prisma.GroupsWhereInput[]
|
||||
telegramID?: Prisma.IntFilter<"Groups"> | number
|
||||
telegramID?: Prisma.BigIntFilter<"Groups"> | bigint | number
|
||||
name?: Prisma.StringFilter<"Groups"> | string
|
||||
username?: Prisma.StringFilter<"Groups"> | string
|
||||
linksDeleted?: Prisma.BigIntFilter<"Groups"> | bigint | number
|
||||
createdAt?: Prisma.DateTimeFilter<"Groups"> | Date | string
|
||||
updatedAt?: Prisma.DateTimeFilter<"Groups"> | Date | string
|
||||
}
|
||||
@@ -213,16 +233,20 @@ export type GroupsWhereInput = {
|
||||
export type GroupsOrderByWithRelationInput = {
|
||||
telegramID?: Prisma.SortOrder
|
||||
name?: Prisma.SortOrder
|
||||
username?: Prisma.SortOrder
|
||||
linksDeleted?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type GroupsWhereUniqueInput = Prisma.AtLeast<{
|
||||
telegramID?: number
|
||||
telegramID?: bigint | number
|
||||
AND?: Prisma.GroupsWhereInput | Prisma.GroupsWhereInput[]
|
||||
OR?: Prisma.GroupsWhereInput[]
|
||||
NOT?: Prisma.GroupsWhereInput | Prisma.GroupsWhereInput[]
|
||||
name?: Prisma.StringFilter<"Groups"> | string
|
||||
username?: Prisma.StringFilter<"Groups"> | string
|
||||
linksDeleted?: Prisma.BigIntFilter<"Groups"> | bigint | number
|
||||
createdAt?: Prisma.DateTimeFilter<"Groups"> | Date | string
|
||||
updatedAt?: Prisma.DateTimeFilter<"Groups"> | Date | string
|
||||
}, "telegramID">
|
||||
@@ -230,6 +254,8 @@ export type GroupsWhereUniqueInput = Prisma.AtLeast<{
|
||||
export type GroupsOrderByWithAggregationInput = {
|
||||
telegramID?: Prisma.SortOrder
|
||||
name?: Prisma.SortOrder
|
||||
username?: Prisma.SortOrder
|
||||
linksDeleted?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
_count?: Prisma.GroupsCountOrderByAggregateInput
|
||||
@@ -243,53 +269,69 @@ export type GroupsScalarWhereWithAggregatesInput = {
|
||||
AND?: Prisma.GroupsScalarWhereWithAggregatesInput | Prisma.GroupsScalarWhereWithAggregatesInput[]
|
||||
OR?: Prisma.GroupsScalarWhereWithAggregatesInput[]
|
||||
NOT?: Prisma.GroupsScalarWhereWithAggregatesInput | Prisma.GroupsScalarWhereWithAggregatesInput[]
|
||||
telegramID?: Prisma.IntWithAggregatesFilter<"Groups"> | number
|
||||
telegramID?: Prisma.BigIntWithAggregatesFilter<"Groups"> | bigint | number
|
||||
name?: Prisma.StringWithAggregatesFilter<"Groups"> | string
|
||||
username?: Prisma.StringWithAggregatesFilter<"Groups"> | string
|
||||
linksDeleted?: Prisma.BigIntWithAggregatesFilter<"Groups"> | bigint | number
|
||||
createdAt?: Prisma.DateTimeWithAggregatesFilter<"Groups"> | Date | string
|
||||
updatedAt?: Prisma.DateTimeWithAggregatesFilter<"Groups"> | Date | string
|
||||
}
|
||||
|
||||
export type GroupsCreateInput = {
|
||||
telegramID: number
|
||||
telegramID: bigint | number
|
||||
name: string
|
||||
username?: string
|
||||
linksDeleted?: bigint | number
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
}
|
||||
|
||||
export type GroupsUncheckedCreateInput = {
|
||||
telegramID: number
|
||||
telegramID: bigint | number
|
||||
name: string
|
||||
username?: string
|
||||
linksDeleted?: bigint | number
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
}
|
||||
|
||||
export type GroupsUpdateInput = {
|
||||
name?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
username?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
linksDeleted?: Prisma.BigIntFieldUpdateOperationsInput | bigint | number
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
}
|
||||
|
||||
export type GroupsUncheckedUpdateInput = {
|
||||
name?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
username?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
linksDeleted?: Prisma.BigIntFieldUpdateOperationsInput | bigint | number
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
}
|
||||
|
||||
export type GroupsCreateManyInput = {
|
||||
telegramID: number
|
||||
telegramID: bigint | number
|
||||
name: string
|
||||
username?: string
|
||||
linksDeleted?: bigint | number
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
}
|
||||
|
||||
export type GroupsUpdateManyMutationInput = {
|
||||
name?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
username?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
linksDeleted?: Prisma.BigIntFieldUpdateOperationsInput | bigint | number
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
}
|
||||
|
||||
export type GroupsUncheckedUpdateManyInput = {
|
||||
name?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
username?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
linksDeleted?: Prisma.BigIntFieldUpdateOperationsInput | bigint | number
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
}
|
||||
@@ -297,17 +339,22 @@ export type GroupsUncheckedUpdateManyInput = {
|
||||
export type GroupsCountOrderByAggregateInput = {
|
||||
telegramID?: Prisma.SortOrder
|
||||
name?: Prisma.SortOrder
|
||||
username?: Prisma.SortOrder
|
||||
linksDeleted?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type GroupsAvgOrderByAggregateInput = {
|
||||
telegramID?: Prisma.SortOrder
|
||||
linksDeleted?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type GroupsMaxOrderByAggregateInput = {
|
||||
telegramID?: Prisma.SortOrder
|
||||
name?: Prisma.SortOrder
|
||||
username?: Prisma.SortOrder
|
||||
linksDeleted?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
}
|
||||
@@ -315,18 +362,29 @@ export type GroupsMaxOrderByAggregateInput = {
|
||||
export type GroupsMinOrderByAggregateInput = {
|
||||
telegramID?: Prisma.SortOrder
|
||||
name?: Prisma.SortOrder
|
||||
username?: Prisma.SortOrder
|
||||
linksDeleted?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type GroupsSumOrderByAggregateInput = {
|
||||
telegramID?: Prisma.SortOrder
|
||||
linksDeleted?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type StringFieldUpdateOperationsInput = {
|
||||
set?: string
|
||||
}
|
||||
|
||||
export type BigIntFieldUpdateOperationsInput = {
|
||||
set?: bigint | number
|
||||
increment?: bigint | number
|
||||
decrement?: bigint | number
|
||||
multiply?: bigint | number
|
||||
divide?: bigint | number
|
||||
}
|
||||
|
||||
export type DateTimeFieldUpdateOperationsInput = {
|
||||
set?: Date | string
|
||||
}
|
||||
@@ -336,6 +394,8 @@ export type DateTimeFieldUpdateOperationsInput = {
|
||||
export type GroupsSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
|
||||
telegramID?: boolean
|
||||
name?: boolean
|
||||
username?: boolean
|
||||
linksDeleted?: boolean
|
||||
createdAt?: boolean
|
||||
updatedAt?: boolean
|
||||
}, ExtArgs["result"]["groups"]>
|
||||
@@ -345,18 +405,22 @@ export type GroupsSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs =
|
||||
export type GroupsSelectScalar = {
|
||||
telegramID?: boolean
|
||||
name?: boolean
|
||||
username?: boolean
|
||||
linksDeleted?: boolean
|
||||
createdAt?: boolean
|
||||
updatedAt?: boolean
|
||||
}
|
||||
|
||||
export type GroupsOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"telegramID" | "name" | "createdAt" | "updatedAt", ExtArgs["result"]["groups"]>
|
||||
export type GroupsOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"telegramID" | "name" | "username" | "linksDeleted" | "createdAt" | "updatedAt", ExtArgs["result"]["groups"]>
|
||||
|
||||
export type $GroupsPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
name: "Groups"
|
||||
objects: {}
|
||||
scalars: runtime.Types.Extensions.GetPayloadResult<{
|
||||
telegramID: number
|
||||
telegramID: bigint
|
||||
name: string
|
||||
username: string
|
||||
linksDeleted: bigint
|
||||
createdAt: Date
|
||||
updatedAt: Date
|
||||
}, ExtArgs["result"]["groups"]>
|
||||
@@ -751,8 +815,10 @@ export interface Prisma__GroupsClient<T, Null = never, ExtArgs extends runtime.T
|
||||
* Fields of the Groups model
|
||||
*/
|
||||
export interface GroupsFieldRefs {
|
||||
readonly telegramID: Prisma.FieldRef<"Groups", 'Int'>
|
||||
readonly telegramID: Prisma.FieldRef<"Groups", 'BigInt'>
|
||||
readonly name: Prisma.FieldRef<"Groups", 'String'>
|
||||
readonly username: Prisma.FieldRef<"Groups", 'String'>
|
||||
readonly linksDeleted: Prisma.FieldRef<"Groups", 'BigInt'>
|
||||
readonly createdAt: Prisma.FieldRef<"Groups", 'DateTime'>
|
||||
readonly updatedAt: Prisma.FieldRef<"Groups", 'DateTime'>
|
||||
}
|
||||
|
||||
@@ -357,14 +357,6 @@ export type TotalStatsSumOrderByAggregateInput = {
|
||||
timesTriggered?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type BigIntFieldUpdateOperationsInput = {
|
||||
set?: bigint | number
|
||||
increment?: bigint | number
|
||||
decrement?: bigint | number
|
||||
multiply?: bigint | number
|
||||
divide?: bigint | number
|
||||
}
|
||||
|
||||
|
||||
|
||||
export type TotalStatsSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
|
||||
|
||||
@@ -15,10 +15,12 @@ datasource db {
|
||||
}
|
||||
|
||||
model Groups {
|
||||
telegramID Int @id @map("_id") @db.Int
|
||||
name String
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @default(now()) @updatedAt
|
||||
telegramID BigInt @id @map("_id") @db.Long
|
||||
name String
|
||||
username String @default("")
|
||||
linksDeleted BigInt @default(0) @db.Long
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @default(now()) @updatedAt
|
||||
}
|
||||
|
||||
model TotalStats {
|
||||
|
||||
Reference in New Issue
Block a user