Closed Egor-Pizyk closed 5 months ago
Same issue, the reference column value does not show.
You must explicitly define a @Column
for your foreign key, for example (customerId
):
@ManyToOne('Customer', { eager: false, nullable: true, onDelete: 'CASCADE' })
@JoinColumn({ name: 'customer_id' })
public customer: Customer;
@Column({ nullable: true })
@RelationId((material: Material) => material.customer)
public customerId: string;
Hi everyone. I use adminJs with nestJs and typeorm. I have two entities - PostEntity and UserEntity. Each post (PostEntity) have an owner (UserEntity) with ManyToOne relation. When I connect PostEntity to adminJs I don't see anything in the owner column, but I expect that I can see id or user email. (Also I don't find in docs that is possible to show user email or user name or another fields from UserEntity. Is it possible?)