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
How to change api_tokens table field from id to idapi_tokens, without using migration???
In the database it already has an idapi_tokens, now it needs to change the adonisJS 5.
tokenProvider: {
type: 'api',
driver: 'database',
//here I can change the table name
table: 'api_tokens',
// here I can change the name of the FK field
foreignKey: 'user_iduser',
},
Observation:
It's not in the database but in the adonis call...
I've already added the field names I want to replace against the default adonis names, now I just have to make the correct call of the fields in adonis for these new names, but I don't know which file to do this in.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
How to change api_tokens table field from id to idapi_tokens, without using migration???
In the database it already has an idapi_tokens, now it needs to change the adonisJS 5.
Observation:
It's not in the database but in the adonis call...
I've already added the field names I want to replace against the default adonis names, now I just have to make the correct call of the fields in adonis for these new names, but I don't know which file to do this in.
Beta Was this translation helpful? Give feedback.
All reactions