Ajout d'une toto list pour les utilisateurs dans le markdown
This commit is contained in:
14
README.md
14
README.md
@@ -7,6 +7,20 @@
|
||||
- Dans le makefile il y a un sedf pour changer l'un ou l'autre.
|
||||
|
||||
|
||||
|
||||
### TODO List : Utilisateur édition.
|
||||
|
||||
- [x] Utilisateur : faire la base pour un utilisateur
|
||||
- [ ] Utilisateur : faire le système de requête amis
|
||||
- [ ] Utilisateur : mettre en place le système d'avatar
|
||||
- [ ] Utilisateur : mettre en place la double authentification
|
||||
- [ ] Utilisateur : mettre en place le système d'Oauth
|
||||
- [ ] Utilisateur : mettre en place la hashage de mot de passe (avec Oauth)
|
||||
- [ ] Utilisateur : mettre en place le système de statut
|
||||
- [ ] Utilisatateur : mettre en place le système de stats
|
||||
- [ ] Utilisateur : mettre en place l'historique des matches
|
||||
|
||||
|
||||
## questions :
|
||||
|
||||
- choose a secondary browser
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -1,7 +1,6 @@
|
||||
import { Friendship } from "../../friendship/entities/friendship.entity";
|
||||
export declare class User {
|
||||
id: number;
|
||||
name: string;
|
||||
username: string;
|
||||
email: string;
|
||||
password: string;
|
||||
|
||||
@@ -11,6 +11,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.User = void 0;
|
||||
const class_transformer_1 = require("class-transformer");
|
||||
const class_validator_1 = require("class-validator");
|
||||
const typeorm_1 = require("typeorm");
|
||||
const friendship_entity_1 = require("../../friendship/entities/friendship.entity");
|
||||
let User = class User {
|
||||
@@ -24,14 +25,12 @@ __decorate([
|
||||
], User.prototype, "id", void 0);
|
||||
__decorate([
|
||||
(0, typeorm_1.Column)(),
|
||||
__metadata("design:type", String)
|
||||
], User.prototype, "name", void 0);
|
||||
__decorate([
|
||||
(0, typeorm_1.Column)(),
|
||||
(0, class_validator_1.Length)(5, 25),
|
||||
__metadata("design:type", String)
|
||||
], User.prototype, "username", void 0);
|
||||
__decorate([
|
||||
(0, typeorm_1.Column)(),
|
||||
(0, class_validator_1.IsEmail)(),
|
||||
__metadata("design:type", String)
|
||||
], User.prototype, "email", void 0);
|
||||
__decorate([
|
||||
@@ -55,6 +54,7 @@ __decorate([
|
||||
], User.prototype, "addresseeId", void 0);
|
||||
User = __decorate([
|
||||
(0, typeorm_1.Entity)('users'),
|
||||
(0, typeorm_1.Unique)(['email', 'username']),
|
||||
__metadata("design:paramtypes", [Object])
|
||||
], User);
|
||||
exports.User = User;
|
||||
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"file":"user.entity.js","sourceRoot":"","sources":["../../../src/users/entities/user.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,yDAA4C;AAC5C,qCAA2G;AAC3G,mFAAyE;AAIlE,IAAM,IAAI,GAAV,MAAM,IAAI;IAgChB,YAAY,OAAsB;QACjC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC9B,CAAC;CACD,CAAA;AAjCA;IAAC,IAAA,gCAAsB,GAAE;;gCACd;AAEX;IAAC,IAAA,gBAAM,GAAE;;kCACI;AAEb;IAAC,IAAA,gBAAM,GAAE;;sCACQ;AAGjB;IAAC,IAAA,gBAAM,GAAE;;mCACK;AAId;IAAC,IAAA,gBAAM,GAAE;IACR,IAAA,2BAAO,GAAE;;sCACO;AAEjB;IAAC,IAAA,gBAAM,EAAC,MAAM,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;oCAClB;AAEjB;IAAC,IAAA,mBAAS,GAAE;IACX,IAAA,mBAAS,EAAC,IAAI,CAAC,EAAE,CAAC,8BAAU,EAAG,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC,WAAW,CAAC;;yCAC7C;AAE1B;IAAC,IAAA,mBAAS,GAAE;IACX,IAAA,mBAAS,EAAC,IAAI,CAAC,EAAE,CAAC,8BAAU,EAAG,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC,WAAW,CAAC;;yCAC7C;AA9Bd,IAAI;IADhB,IAAA,gBAAM,EAAC,OAAO,CAAC;;GACH,IAAI,CAmChB;AAnCY,oBAAI"}
|
||||
{"version":3,"file":"user.entity.js","sourceRoot":"","sources":["../../../src/users/entities/user.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,yDAA4C;AAC5C,qDAAkD;AAClD,qCAA2G;AAC3G,mFAAyE;AAKlE,IAAM,IAAI,GAAV,MAAM,IAAI;IA+BhB,YAAY,OAAsB;QACjC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC9B,CAAC;CACD,CAAA;AAhCA;IAAC,IAAA,gCAAsB,GAAE;;gCACd;AAEX;IAAC,IAAA,gBAAM,GAAE;IACR,IAAA,wBAAM,EAAC,CAAC,EAAE,EAAE,CAAC;;sCACG;AAGjB;IAAC,IAAA,gBAAM,GAAE;IACR,IAAA,yBAAO,GAAE;;mCACI;AAId;IAAC,IAAA,gBAAM,GAAE;IACR,IAAA,2BAAO,GAAE;;sCACO;AAEjB;IAAC,IAAA,gBAAM,EAAC,MAAM,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;oCAClB;AAEjB;IAAC,IAAA,mBAAS,GAAE;IACX,IAAA,mBAAS,EAAC,IAAI,CAAC,EAAE,CAAC,8BAAU,EAAG,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC,WAAW,CAAC;;yCAC7C;AAE1B;IAAC,IAAA,mBAAS,GAAE;IACX,IAAA,mBAAS,EAAC,IAAI,CAAC,EAAE,CAAC,8BAAU,EAAG,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC,WAAW,CAAC;;yCAC7C;AA7Bd,IAAI;IAFhB,IAAA,gBAAM,EAAC,OAAO,CAAC;IACf,IAAA,gBAAM,EAAC,CAAC,OAAO,EAAE,UAAU,CAAC,CAAC;;GACjB,IAAI,CAkChB;AAlCY,oBAAI"}
|
||||
@@ -1,22 +1,23 @@
|
||||
import { Exclude } from "class-transformer";
|
||||
import { IsEmail, Length } from "class-validator";
|
||||
import { Column, Entity, JoinTable, ManyToMany, OneToMany, PrimaryGeneratedColumn, Unique } from "typeorm";
|
||||
import { Friendship } from "../../friendship/entities/friendship.entity";
|
||||
|
||||
|
||||
@Entity('users')
|
||||
@Unique(['email', 'username'])
|
||||
export class User {
|
||||
|
||||
@PrimaryGeneratedColumn()
|
||||
id: number;
|
||||
|
||||
@Column()
|
||||
name: string;
|
||||
|
||||
@Column()
|
||||
@Length(5, 25)
|
||||
username: string;
|
||||
|
||||
|
||||
@Column()
|
||||
@IsEmail()
|
||||
email: string;
|
||||
|
||||
//Dans le cadre d'un tableau on peut faire :
|
||||
|
||||
Reference in New Issue
Block a user