How to hide some fields like password?
See original GitHub issueHow to return a custom model? For example, hide password or whatever i want and return response?
@Crud({
model: {
type: User,
},
routes: {
getManyBase: {
decorators: [
UseGuards(AuthGuard()),
],
},
},
})
@Controller('users')
When i call the endpoint like GET /users
it returns me something like this:
[
{
"id": 1,
"email": "erik.hac@outlook.com",
"password": "43587y34t9078eryht457089649",
"isActive": true,
"isEmailConfirmed": true,
"createdAt": "2019-07-16T03:05:50.020Z",
"updatedAt": "2019-07-19T21:11:16.032Z",
"lastSession": "2019-07-19T21:11:16.007Z",
"resetPasswordExpire": null,
"resetPasswordToken": null
}
]
Issue Analytics
- State:
- Created 4 years ago
- Comments:14 (7 by maintainers)
Top Results From Across the Web
Cleanest way to hide password input fields? - Stack Overflow
The cleanest way is to check the type attribute of the input element. The HTML5 specification has this to say about input type=password...
Read more >How to hide input similar to Password field - Jotform
You must be looking for a way to masked the text with asterisk (*) similar to that of a password. You can achieve...
Read more >How to Hide Password in HTML ? - GeeksforGeeks
Hiding the password is commonly known as Password Masking. It is hiding the password characters when entered by the users by the use...
Read more >How to Use Password Fields and Hidden Fields in Your ...
Use the element with its type attribute set to hidden. 2.Supply the name and value pair you want to send to the form...
Read more >Hide/unhide field based on password in a text fiel...
Hi, I'm sure this is probably a really easy one, but I'm a newbie to javascript... What I'd like to achieve is to...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
You can use exclude in the
CrudOptions
@eranshmil I’m going to publish RC version today probably. Will let you know 😉