The status for each newly created item should default to either the status mapping as defined for the table (stored in directus_collection.status_mapping) or 鈥斅爄f that's not setup 鈥斅爐he default global status mapping in directus_settings
I don't think we have a "default" in the status mapping. Users can SET the status to any options they are allowed to... or, if they are NOT allowed to then it should use the column default value.
In that case, we should require the default value of the status column when it's set up. As of right now, if the column defaults to null, the item will disappear immediately since it's basically invisible to the api @benhaynes
Yes, absolutely. We should have the ability to require/limit DEFAULT and LENGTH when creating/setting-up fields based on the interface.
a related question, Where in settings is going to be stored the global status mapping? (key, scope and group combo)?
Group = global
Scope = status
Key = status_mapping
Thoughts @benhaynes @WellingGuzman?
Yeah, I like that.
I set the status interface required if the default value is null. Ref: https://github.com/directus/api/commit/f53efd842001db6c7f9bf11ab2c47843fa2617ce
So at this point all that lasts is making sure the application starts giving errors when you try to create a status interface without a default value correct? If so, we can close this issue here and move it over to directus/app :)
Exactly, a value for status interface is required.