I have a join query like bellow and i'm trying to convert it to typeOrm query
SELECT a.actionName
FROM walletAppActions wa
INNER JOIN actions a on a.actionId = wa.actionId
WHERE wa.appId = 1
ActionConfig.entity.ts
@Entity('actions')
export class WalletAppActionsEntity{
@PrimaryGeneratedColumn("increment")
actionId: number;
@Column()
actionName: string;
@OneToOne( type => Actions , config => config.action)
config: Actions;
}
appActions.entity.ts
@Entity('walletAppActions')
export class Actions{
@PrimaryGeneratedColumn("increment")
id: number;
@Column()
appId: number;
@Column()
actionId: number;
@OneToOne( type => WalletAppActionsEntity , action => action.config)
action: WalletAppActionsEntity;
}
table structure has attached here
walletAppActions table
Actions table

