backend.globaleaks.handlers.admin.modelimgs

Module Contents

Functions

db_get_model_img(session, obj_type, obj_id) Transaction for retrieving the image associated to a model type
add_model_img(session, obj_key, obj_id, data)
del_model_img(session, obj_key, obj_id)
backend.globaleaks.handlers.admin.modelimgs.model_map[source]
backend.globaleaks.handlers.admin.modelimgs.db_get_model_img(session, obj_type, obj_id)[source]

Transaction for retrieving the image associated to a model type

Parameters:
  • session – An ORM session
  • obj_type – The model type
  • obj_id – The object ID
Returns:

The image for the specified object

backend.globaleaks.handlers.admin.modelimgs.add_model_img(session, obj_key, obj_id, data)[source]
backend.globaleaks.handlers.admin.modelimgs.del_model_img(session, obj_key, obj_id)[source]
class backend.globaleaks.handlers.admin.modelimgs.ModelImgInstance[source]

Bases: globaleaks.handlers.base.BaseHandler

check_roles = admin[source]
invalidate_cache = True[source]
upload_handler = True[source]
post(self, obj_key, obj_id)[source]
delete(self, obj_key, obj_id)[source]