-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unhandled type warnigns #8
Comments
Your model doesn't seem to have Date or object data types, where do they come from? |
@Entity({ abstract: true })
export abstract class OmputBaseEntity {
@PrimaryKey()
id: string = v4();
@Property({ hidden: true })
createdAt: Date = new Date();
@Property({ hidden: true, nullable: true, onUpdate: () => new Date() })
updatedAt?: Date; @dziraf |
Transferring to You should be able to set a specific type in your resource options for each property in the meantime |
Similar to ArrayType . For fixing date type, I can do a pr
This should fix for date. I just checked locally |
@rubiin Go ahead. Unfortuantely I don't have any active project with MikroORM at the moment to investigate those issues. We do have a dev repo: https://github.com/SoftwareBrothers/adminjs-dev but it would still require a lot of work to reproduce various ORM-specific types. I personally prefer if ORMs provide database types since it's easier to map across packages |
What about this issue? I also have plenty of errors like that (only with Date).
[EDIT] The solution proposed by @rubiin works like a charm in my case. |
Still no PR? |
Describe the bug
We can see a lot of unhandled type warnigns in the terminal output on load of any resource in the admin panel.
Installed libraries and their versions
"@adminjs/express": "^4.1.0"
"@adminjs/mikroorm": "^1.1.0"
"@adminjs/nestjs": "^4.0.0"
"@mikro-orm/core": "^5.0.5"
To Reproduce
Steps to reproduce the behavior:
Expected behavior
No unhandled type warning.
Screenshots
That's the console output.
AdminJSOptions with schema
Desktop (please complete the following information if relevant):
Additional context
Add any other context about the problem here.
That's our module setup using Nestjs.
The text was updated successfully, but these errors were encountered: