collectiveaccess / providence

Cataloguing and data/media management application
GNU General Public License v3.0
290 stars 166 forks source link

Object Representation restrict by type #1591

Open Monica-Wood opened 4 days ago

Monica-Wood commented 4 days ago

I am using a media representation bundle on an entity, and have it restricted to a object representation type of 'image'. However when creating a representation, it uses the default object representation type (the one at the top or the one set explicitly as the default), even if this type is not the type you have restricted the bundle to. This means you can add a representation and then it disappears from view, because of your restriction. If however in the 'show for editing' you include the 'type' list, it will only show the type you have restricted it to and all is ok.

Should a check be put in place to make sure if it falls back to the default type value that it picks one of the types the bundle is restricted to? Obviously, if you don't have the type ticked in 'show for editing' it would usually mean there is only one type, so no need to have anyone select it.

Hope this makes sense.