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
{{ message }}
This repository was archived by the owner on Feb 26, 2024. It is now read-only.
Repository navigation
This repository was archived by the owner on Feb 26, 2024. It is now read-only.
Encountered this error:
body:error:"Collection 'login' id type is non-numeric or unknown. Can only generate numeric ids."
status:422
statusText:"Unprocessable Entity"
Encountered this error:
body:error:"Collection 'inputparams' id type is non-numeric or unknown. Can only generate numeric ids."
status:422
statusText:"Unprocessable Entity"
here is what the "param" consists of
common: OEGenericInputParameter;
fleet: OEInputParameterWideBody[];
optional: OEInputParameterOptions;
User gives details in the form
all the details are clubbed and made as param model
createDB(){
const inputparamsfun = () =>{
what to be given here?
}
}
Activity
chorsnell commentedon Oct 10, 2018
@angelitoTalens did you get to the bottom of this?
hungerregnuh commentedon Nov 29, 2018
This is working fine for me in v7, how did you setup your in memory data service?
angelitoTalens commentedon Nov 30, 2018
@hungerregnuh
mock-api.service.ts
export class MockApiService implements InMemoryDbService {createDb() {let login:{email:string, password:string}[] = [{email:'first.last@gmail.com',password:'pwd'}];return {login};}}In app.module.ts
imports: [...environment.production ?[] : HttpClientInMemoryWebApiModule.forRoot(MockApiService, {post204: false, post409: true, dataEncapsulation: false})],hungerregnuh commentedon Nov 30, 2018
@angelitoTalens
could you try this instead?
angelitoTalens commentedon Dec 4, 2018
@hungerregnuh
your suggestion worked for me.
let userCredentials = {email: email, password: password};return this.http.post<boolean>(apiUrl, userCredentials, options)keerthi42 commentedon Sep 7, 2019
Encountered this error:
body:error:"Collection 'inputparams' id type is non-numeric or unknown. Can only generate numeric ids."
status:422
statusText:"Unprocessable Entity"
when doing a post using:
Angular 7
angular-in-memory-web-api
const url =
${this.apiUrl};return this.http.post(url, JSON.stringify( param), httpOptions).pipe(map(this.serviceHelper.extractData))
.pipe(catchError(this.serviceHelper.handleError));](url)
here is what the "param" consists of
common: OEGenericInputParameter;
fleet: OEInputParameterWideBody[];
optional: OEInputParameterOptions;
User gives details in the form
all the details are clubbed and made as param model
createDB(){
const inputparamsfun = () =>{
what to be given here?
}
}