https://project.mdnd-it.cc/work_packages/94
This commit is contained in:
2025-08-23 04:25:28 +02:00
parent 725516ad6c
commit 19cfa031d0
25823 changed files with 1095587 additions and 2801760 deletions
+33
View File
@@ -0,0 +1,33 @@
export interface Message {
id: string;
date: Date;
userid: string;
text: string;
}
export declare const ChatState: {
readonly ACTIVE: 0;
readonly ARCHIVE: 1;
readonly SOFT_DELETE: 2;
};
export type ChatStateType = typeof ChatState[keyof typeof ChatState];
export declare const ChatType: {
readonly DIRECT: "direct";
readonly GROUP: "group";
readonly GAME: "game";
};
export type ChatTypeType = typeof ChatType[keyof typeof ChatType];
export declare class ChatAggregate {
id: string;
type: ChatTypeType;
name: string | null;
gameId: string | null;
createdBy: string | null;
users: string[];
messages: Message[];
lastActivity: Date | null;
createDate: Date;
updateDate: Date;
state: ChatStateType;
archiveDate: Date | null;
}
//# sourceMappingURL=ChatAggregate.d.ts.map
@@ -0,0 +1 @@
{"version":3,"file":"ChatAggregate.d.ts","sourceRoot":"","sources":["../../../src/Domain/Chat/ChatAggregate.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,OAAO;IACpB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,IAAI,CAAC;IACX,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,MAAM,CAAC;CAChB;AAED,eAAO,MAAM,SAAS;;;;CAIZ,CAAC;AAEX,MAAM,MAAM,aAAa,GAAG,OAAO,SAAS,CAAC,MAAM,OAAO,SAAS,CAAC,CAAC;AAErE,eAAO,MAAM,QAAQ;;;;CAIX,CAAC;AAEX,MAAM,MAAM,YAAY,GAAG,OAAO,QAAQ,CAAC,MAAM,OAAO,QAAQ,CAAC,CAAC;AAElE,qBACa,aAAa;IAEtB,EAAE,EAAG,MAAM,CAAC;IAGZ,IAAI,EAAG,YAAY,CAAC;IAGpB,IAAI,EAAG,MAAM,GAAG,IAAI,CAAC;IAGrB,MAAM,EAAG,MAAM,GAAG,IAAI,CAAC;IAGvB,SAAS,EAAG,MAAM,GAAG,IAAI,CAAC;IAG1B,KAAK,EAAG,MAAM,EAAE,CAAC;IAGjB,QAAQ,EAAG,OAAO,EAAE,CAAC;IAGrB,YAAY,EAAG,IAAI,GAAG,IAAI,CAAC;IAG3B,UAAU,EAAG,IAAI,CAAC;IAGlB,UAAU,EAAG,IAAI,CAAC;IAGlB,KAAK,EAAG,aAAa,CAAC;IAItB,WAAW,EAAG,IAAI,GAAG,IAAI,CAAC;CAC7B"}
+78
View File
@@ -0,0 +1,78 @@
"use strict";
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
return c > 3 && r && Object.defineProperty(target, key, r), r;
};
var __metadata = (this && this.__metadata) || function (k, v) {
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.ChatAggregate = exports.ChatType = exports.ChatState = void 0;
const typeorm_1 = require("typeorm");
exports.ChatState = {
ACTIVE: 0,
ARCHIVE: 1,
SOFT_DELETE: 2
};
exports.ChatType = {
DIRECT: 'direct',
GROUP: 'group',
GAME: 'game'
};
let ChatAggregate = class ChatAggregate {
};
exports.ChatAggregate = ChatAggregate;
__decorate([
(0, typeorm_1.PrimaryGeneratedColumn)('uuid'),
__metadata("design:type", String)
], ChatAggregate.prototype, "id", void 0);
__decorate([
(0, typeorm_1.Column)({ type: 'varchar', length: 50, default: exports.ChatType.DIRECT }),
__metadata("design:type", String)
], ChatAggregate.prototype, "type", void 0);
__decorate([
(0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
__metadata("design:type", Object)
], ChatAggregate.prototype, "name", void 0);
__decorate([
(0, typeorm_1.Column)({ type: 'uuid', nullable: true }),
__metadata("design:type", Object)
], ChatAggregate.prototype, "gameId", void 0);
__decorate([
(0, typeorm_1.Column)({ type: 'uuid', nullable: true }),
__metadata("design:type", Object)
], ChatAggregate.prototype, "createdBy", void 0);
__decorate([
(0, typeorm_1.Column)('uuid', { array: true }),
__metadata("design:type", Array)
], ChatAggregate.prototype, "users", void 0);
__decorate([
(0, typeorm_1.Column)('json', { default: [] }),
__metadata("design:type", Array)
], ChatAggregate.prototype, "messages", void 0);
__decorate([
(0, typeorm_1.Column)({ type: 'timestamp', nullable: true }),
__metadata("design:type", Object)
], ChatAggregate.prototype, "lastActivity", void 0);
__decorate([
(0, typeorm_1.CreateDateColumn)(),
__metadata("design:type", Date)
], ChatAggregate.prototype, "createDate", void 0);
__decorate([
(0, typeorm_1.UpdateDateColumn)(),
__metadata("design:type", Date)
], ChatAggregate.prototype, "updateDate", void 0);
__decorate([
(0, typeorm_1.Column)({ type: 'int', default: exports.ChatState.ACTIVE }),
__metadata("design:type", Number)
], ChatAggregate.prototype, "state", void 0);
__decorate([
(0, typeorm_1.Column)({ type: 'timestamp', nullable: true }),
__metadata("design:type", Object)
], ChatAggregate.prototype, "archiveDate", void 0);
exports.ChatAggregate = ChatAggregate = __decorate([
(0, typeorm_1.Entity)('Chats')
], ChatAggregate);
//# sourceMappingURL=ChatAggregate.js.map
@@ -0,0 +1 @@
{"version":3,"file":"ChatAggregate.js","sourceRoot":"","sources":["../../../src/Domain/Chat/ChatAggregate.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qCAAqG;AASxF,QAAA,SAAS,GAAG;IACrB,MAAM,EAAE,CAAC;IACT,OAAO,EAAE,CAAC;IACV,WAAW,EAAE,CAAC;CACR,CAAC;AAIE,QAAA,QAAQ,GAAG;IACpB,MAAM,EAAE,QAAQ;IAChB,KAAK,EAAE,OAAO;IACd,IAAI,EAAE,MAAM;CACN,CAAC;AAKJ,IAAM,aAAa,GAAnB,MAAM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13 @@
import { Message } from './ChatAggregate';
export declare class ChatArchiveAggregate {
id: string;
chatId: string;
archivedMessages: Message[];
archivedAt: Date;
createDate: Date;
chatType: string;
chatName: string | null;
gameId: string | null;
participants: string[];
}
//# sourceMappingURL=ChatArchiveAggregate.d.ts.map
@@ -0,0 +1 @@
{"version":3,"file":"ChatArchiveAggregate.d.ts","sourceRoot":"","sources":["../../../src/Domain/Chat/ChatArchiveAggregate.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAE1C,qBACa,oBAAoB;IAE7B,EAAE,EAAG,MAAM,CAAC;IAGZ,MAAM,EAAG,MAAM,CAAC;IAGhB,gBAAgB,EAAG,OAAO,EAAE,CAAC;IAG7B,UAAU,EAAG,IAAI,CAAC;IAGlB,UAAU,EAAG,IAAI,CAAC;IAIlB,QAAQ,EAAG,MAAM,CAAC;IAGlB,QAAQ,EAAG,MAAM,GAAG,IAAI,CAAC;IAGzB,MAAM,EAAG,MAAM,GAAG,IAAI,CAAC;IAGvB,YAAY,EAAG,MAAM,EAAE,CAAC;CAC3B"}
@@ -0,0 +1,56 @@
"use strict";
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
return c > 3 && r && Object.defineProperty(target, key, r), r;
};
var __metadata = (this && this.__metadata) || function (k, v) {
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.ChatArchiveAggregate = void 0;
const typeorm_1 = require("typeorm");
let ChatArchiveAggregate = class ChatArchiveAggregate {
};
exports.ChatArchiveAggregate = ChatArchiveAggregate;
__decorate([
(0, typeorm_1.PrimaryGeneratedColumn)('uuid'),
__metadata("design:type", String)
], ChatArchiveAggregate.prototype, "id", void 0);
__decorate([
(0, typeorm_1.Column)({ type: 'uuid' }),
__metadata("design:type", String)
], ChatArchiveAggregate.prototype, "chatId", void 0);
__decorate([
(0, typeorm_1.Column)('json'),
__metadata("design:type", Array)
], ChatArchiveAggregate.prototype, "archivedMessages", void 0);
__decorate([
(0, typeorm_1.Column)({ type: 'timestamp' }),
__metadata("design:type", Date)
], ChatArchiveAggregate.prototype, "archivedAt", void 0);
__decorate([
(0, typeorm_1.CreateDateColumn)(),
__metadata("design:type", Date)
], ChatArchiveAggregate.prototype, "createDate", void 0);
__decorate([
(0, typeorm_1.Column)({ type: 'varchar', length: 50 }),
__metadata("design:type", String)
], ChatArchiveAggregate.prototype, "chatType", void 0);
__decorate([
(0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
__metadata("design:type", Object)
], ChatArchiveAggregate.prototype, "chatName", void 0);
__decorate([
(0, typeorm_1.Column)({ type: 'uuid', nullable: true }),
__metadata("design:type", Object)
], ChatArchiveAggregate.prototype, "gameId", void 0);
__decorate([
(0, typeorm_1.Column)('uuid', { array: true }),
__metadata("design:type", Array)
], ChatArchiveAggregate.prototype, "participants", void 0);
exports.ChatArchiveAggregate = ChatArchiveAggregate = __decorate([
(0, typeorm_1.Entity)('ChatArchives')
], ChatArchiveAggregate);
//# sourceMappingURL=ChatArchiveAggregate.js.map
@@ -0,0 +1 @@
{"version":3,"file":"ChatArchiveAggregate.js","sourceRoot":"","sources":["../../../src/Domain/Chat/ChatArchiveAggregate.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qCAAmF;AAI5E,IAAM,oBAAoB,GAA1B,MAAM,oBAAoB;CA4BhC,CAAA;AA5BY,oDAAoB;AAE7B;IADC,IAAA,gCAAsB,EAAC,MAAM,CAAC;;gDACnB;AAGZ;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;oDACT;AAGhB;IADC,IAAA,gBAAM,EAAC,MAAM,CAAC;;8DACc;AAG7B;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,WAAW,EAAE,CAAC;8BACjB,IAAI;wDAAC;AAGlB;IADC,IAAA,0BAAgB,GAAE;8BACN,IAAI;wDAAC;AAIlB;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC;;sDACtB;AAGlB;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,EAAE,GAAG,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;sDAChC;AAGzB;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;oDAClB;AAGvB;IADC,IAAA,gBAAM,EAAC,MAAM,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;;0DACR;+BA3Bf,oBAAoB;IADhC,IAAA,gBAAM,EAAC,cAAc,CAAC;GACV,oBAAoB,CA4BhC"}