Skip to content

How can I override an Entity field dataFetcher? #303

Open
@brendanmoorep

Description

@brendanmoorep

Is there a way that I can override or add custom logic to the dataFetcher for a field of my entity?

For example, if I have a column "status" that is an integer column, but I'd like the API to respond with the status's corresponding enum value, how could I go about doing that?

@Entity
public class MyEntity {

        // other fields omitted

        // This will return the integer status, how can I return a corresponding ENUM value instead?
        @Column
	@GraphQLDescription("The status")
	private int status;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions