A very simple question but I am unable to find the answer to it. So in my Sails app I have a User model and I am trying to make a boolean field with a default value to be False.
Is there a way to specify defaults like some kind of default attribute etc??
I want something like this:
is_admin: {
type: 'boolean',
default: 'false'
}
Thanks for your time.
use defaultsTo
look this Waterline Docs
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With