@require_context
def volume_get_all_active_by_window(context, begin, end=None, project_id=None):
 query = model_query(context, models.Volume, read_deleted='yes')
 query = query.filter(or_((models.Volume.deleted_at == None), (models.Volume.deleted_at > begin)))
 if end:
  query = query.filter((models.Volume.created_at < end))
 if project_id:
  query = query.filter_by(project_id=project_id)
 query = query.options(joinedload('volume_metadata')).options(joinedload('volume_type')).options(joinedload('volume_attachment')).options(joinedload('consistencygroup')).options(joinedload('group'))
 if is_admin_context(context):
  query = query.options(joinedload('volume_admin_metadata'))
 return query.all()

@ require_context def volume_get_all_active_by_window ( context , begin , end = None , project_id = None ) : query = model_query ( context , models . Volume , read_deleted = 'yes' ) query = query . filter ( or_ ( ( models . Volume . deleted_at == None ) , ( models . Volume . deleted_at > begin ) ) ) if end : query = query . filter ( ( models . Volume . created_at < end ) ) if project_id : query = query . filter_by ( project_id = project_id ) query = query . options ( joinedload ( 'volume_metadata' ) ) . options ( joinedload ( 'volume_type' ) ) . options ( joinedload ( 'volume_attachment' ) ) . options ( joinedload ( 'consistencygroup' ) ) . options ( joinedload ( 'group' ) ) if is_admin_context ( context ) : query = query . options ( joinedload ( 'volume_admin_metadata' ) ) return query . all ( )
get all the volumes inside the window .