def jobs_get_by_tag_range(jobid_range):
 job_list = []
 for job_index in jobid_range:
  tag_pattern = ('%s-' % job_index)
  jobs = Job.objects.filter(tag__startswith=tag_pattern)
  job_list += jobs
 return job_list

def jobs_get_by_tag_range ( jobid_range ) : job_list = [ ] for job_index in jobid_range : tag_pattern = ( '%s-' % job_index ) jobs = Job . objects . filter ( tag__startswith = tag_pattern ) job_list += jobs return job_list
return jobs based on range of job ids .