-
-
Notifications
You must be signed in to change notification settings - Fork 142
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
foal g rest-api post
results in "No overload matches this call"
#683
Comments
My guess it that it comes from the name |
Hi, I've the exact same issue on a fresh project with fresh rest-api generate
Looks like skip and take waiting for number value, and ctx.request.query.skip is String | Query On my side i've convert to async findEmployes(ctx: Context) {
let skip: number = 0;
let take: number = 20;
if(ctx.request.query.skip != undefined){
skip =parseInt(ctx.request.query.skip.toString());
take =parseInt(ctx.request.query.take.toString());
}
const employes = await getRepository(Employe).find({ skip: skip, take: take});
return new HttpResponseOK(employes);
} Don't know if it's the good way ... |
Okay, so I found out why it worked before and why it doesn't work anymore. This is a recurring problem with non-native TS libraries (here |
Follow-up: After one day of work, I ended up fixing this issue. The fix will be released with version 1.8 when #670 is merged. The problem was coming from the last version of To fix this, I defined a precise version of |
Excerpt of the automatically generated code.
Following is the error generated related to
skip
andtake
The text was updated successfully, but these errors were encountered: