def vocabulary_delete(context, data_dict):
 model = context['model']
 vocab_id = data_dict.get('id')
 if (not vocab_id):
  raise ValidationError({'id': _('id not in data')})
 vocab_obj = model.vocabulary.Vocabulary.get(vocab_id)
 if (vocab_obj is None):
  raise NotFound((_('Could not find vocabulary "%s"') % vocab_id))
 _check_access('vocabulary_delete', context, data_dict)
 vocab_obj.delete()
 model.repo.commit()

def vocabulary_delete ( context , data_dict ) : model = context [ 'model' ] vocab_id = data_dict . get ( 'id' ) if ( not vocab_id ) : raise ValidationError ( { 'id' : _ ( 'id not in data' ) } ) vocab_obj = model . vocabulary . Vocabulary . get ( vocab_id ) if ( vocab_obj is None ) : raise NotFound ( ( _ ( 'Could not find vocabulary "%s"' ) % vocab_id ) ) _check_access ( 'vocabulary_delete' , context , data_dict ) vocab_obj . delete ( ) model . repo . commit ( )
delete a tag vocabulary .