You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a type where one of the fields uses the @DtoOverrideType syntax to override the type of a field and add an import for that type (since it's an in-code enum rather than an in-db one).
This works fine in the primary DTO. However, this field is part of a unique index. When the generate outputs the <type><fields>UniqueInputDtoAttributes type, it remembers the type override and applies it correctly but loses the context of the custom import. That causes a compilation error.
The text was updated successfully, but these errors were encountered:
Yes, it turns out this is related to unique indices that use DtoOverrideType. In my case, I have an enum value in the code called Instance that indicates what org a user belongs to. It is exported from the package @app/instances.
The behavior previously (in 1.18.1, which I am upgrading from) was that the connect DTO would generate with the underlying, rather than overridden, type for instance:
I have a type where one of the fields uses the
@DtoOverrideType
syntax to override the type of a field and add an import for that type (since it's an in-code enum rather than an in-db one).This works fine in the primary DTO. However, this field is part of a unique index. When the generate outputs the
<type><fields>UniqueInputDtoAttributes
type, it remembers the type override and applies it correctly but loses the context of the custom import. That causes a compilation error.The text was updated successfully, but these errors were encountered: