"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.Client = void 0;
const typeorm_1 = require("typeorm");
const Student_1 = require("./Student");
const Classes_1 = require("./Classes");
const ClientType_1 = require("./ClientType");
const Address_1 = require("./Address");
let Client = class Client {
};
exports.Client = Client;
__decorate([
    (0, typeorm_1.PrimaryGeneratedColumn)(),
    __metadata("design:type", Number)
], Client.prototype, "id", void 0);
__decorate([
    (0, typeorm_1.Column)(),
    __metadata("design:type", String)
], Client.prototype, "name", void 0);
__decorate([
    (0, typeorm_1.Column)({ type: 'text', nullable: true, default: null }),
    __metadata("design:type", String)
], Client.prototype, "description", void 0);
__decorate([
    (0, typeorm_1.Column)({ default: null, nullable: true }),
    __metadata("design:type", String)
], Client.prototype, "phoneNumber", void 0);
__decorate([
    (0, typeorm_1.Column)({ default: null, nullable: true }),
    __metadata("design:type", String)
], Client.prototype, "cellNumber", void 0);
__decorate([
    (0, typeorm_1.Column)({ default: null, nullable: true }),
    __metadata("design:type", String)
], Client.prototype, "fax", void 0);
__decorate([
    (0, typeorm_1.Column)({ default: null, nullable: true }),
    __metadata("design:type", String)
], Client.prototype, "email", void 0);
__decorate([
    (0, typeorm_1.Column)({ default: null, nullable: true }),
    __metadata("design:type", String)
], Client.prototype, "email2", void 0);
__decorate([
    (0, typeorm_1.Column)({ default: null, nullable: true }),
    __metadata("design:type", String)
], Client.prototype, "website", void 0);
__decorate([
    (0, typeorm_1.Column)({ default: null, nullable: true }),
    __metadata("design:type", String)
], Client.prototype, "contactName", void 0);
__decorate([
    (0, typeorm_1.Column)({ default: null, nullable: true }),
    __metadata("design:type", String)
], Client.prototype, "contactEmail", void 0);
__decorate([
    (0, typeorm_1.Column)({ default: null, nullable: true }),
    __metadata("design:type", String)
], Client.prototype, "contactPhoneNumber", void 0);
__decorate([
    (0, typeorm_1.Column)({ default: false }),
    __metadata("design:type", Boolean)
], Client.prototype, "newsletter", void 0);
__decorate([
    (0, typeorm_1.Column)({ type: 'decimal', default: 2, precision: 10, scale: 2 }),
    __metadata("design:type", Number)
], Client.prototype, "defaultTravelMilesAmount", void 0);
__decorate([
    (0, typeorm_1.Column)({ default: true }),
    __metadata("design:type", Boolean)
], Client.prototype, "enable", void 0);
__decorate([
    (0, typeorm_1.Column)({ type: 'text', nullable: true, default: null }),
    __metadata("design:type", String)
], Client.prototype, "note", void 0);
__decorate([
    (0, typeorm_1.ManyToOne)(type => ClientType_1.ClientType, ClientType => ClientType.Clients) // note: we will create author property in the Photo class below
    ,
    __metadata("design:type", ClientType_1.ClientType)
], Client.prototype, "ClientType", void 0);
__decorate([
    (0, typeorm_1.OneToMany)(type => Student_1.Student, Student => Student.Client) // note: we will create author property in the Photo class below
    ,
    __metadata("design:type", Array)
], Client.prototype, "Students", void 0);
__decorate([
    (0, typeorm_1.OneToMany)(type => Classes_1.Classes, Class => Class.client) // note: we will create author property in the Photo class below
    ,
    __metadata("design:type", Array)
], Client.prototype, "Classes", void 0);
__decorate([
    (0, typeorm_1.OneToMany)(type => Address_1.Address, Address => Address.Client) // note: we will create author property in the Photo class below
    ,
    __metadata("design:type", Array)
], Client.prototype, "Addresses", void 0);
exports.Client = Client = __decorate([
    (0, typeorm_1.Entity)()
], Client);
