import { Column, Entity, ManyToOne, PrimaryColumn } from 'typeorm';
import { Place } from './place.entity';
import { LANGUAGES } from 'src/shared/enum/languages.enum';

@Entity()
export class PlaceTraduction {
  @PrimaryColumn()
  language: LANGUAGES = LANGUAGES.ES;

  @PrimaryColumn({ name: 'idPlace', type: Number })
  @ManyToOne(() => Place, (place) => place.availableDates, { nullable: false })
  idPlace: number;

  @Column({ length: 1024 })
  description: string;
}
