Quantcast
Channel: Telerik Forums RSS
Viewing all articles
Browse latest Browse all 94857

MVC Wrappers: CRUD operations enabled via model properties

$
0
0

Using MVC wrappers, I would like to be able to show/hide the CRUD operations based on booleans in the model (CanCreate, CanUpdate, CanDelete). So, if the CanDelete property is true, the delete button should show up (if false, it should not). Same for other 2 properties.

How can I configure the MVC wrapper this way?

For example,

.ToolBar(commands => commands.Create())

should only be included if the Model.CanCreate is true.

Thanks,

--John


Viewing all articles
Browse latest Browse all 94857

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>