Returns a list of objects coming from the "uids" request parameter
421309
def get_samples_from_request(self):
        
        uids = self.request.form.get("uids", "")
        if isinstance(uids, basestring):
            uids = uids.split(",")

        uids = list(set(uids))
        if not uids:
            return []

        # Filter those analysis requests "reject" transition is allowed
        query = dict(portal_type="AnalysisRequest", UID=uids)
        brains = api.search(query, CATALOG_ANALYSIS_REQUEST_LISTING)
        samples = map(api.get_object, brains)
        return filter(lambda ob: wf.isTransitionAllowed(ob, "reject"), samples)
658243
function() {

		return {
			uids: [],
			values: [],
			names: [],
			push: function(uid, value, name) {
				this.uids.push(uid);
				this.values.push(value);
				this.names.push(name);
			},
			getObject: function() {
				return {
					uids: this.uids,
					values: this.values,
					names: this.names
				}
			}
		}

	}
705296
function(validBidRequests) {
    let requests = [];
    validBidRequests.forEach(i => {
      let params = {
        jst: 'hb',
        ord: Math.random() * 10000000000000000,
        tz: getTz(),
        fl: getFl(),
        rr: getRr(),
        w: i.params.w,
        h: i.params.h,
        s: i.params.s,
        bidid: i.bidId,
        transactionid: i.transactionId,
        auctionid: i.auctionId
      };
      if (i.params.itu !== undefined) {
        params.itu = i.params.itu;
      }
      if (i.params.cur !== undefined) {
        params.cur = i.params.cur;
      }
      if (i.params.subid !== undefined) {
        params.subid = i.params.subid;
      }
      if (i.params.click3rd !== undefined) {
        params.click3rd = i.params.click3rd;
      }
      if (i.params.pubdata !== undefined) {
        for (let key in i.params.pubdata) {
          params['pubside_macro[' + key + ']'] = encodeURIComponent(i.params.pubdata[key]);
        }
      }
      requests.push({method: 'GET', url: 'https://ads.betweendigital.com/adjson', data: params})
    })
    return requests;
  }
720094
def post_object_list(request):
    """"""
    d1_gmn.app.views.assert_db.post_has_mime_parts(
        request, (('field', 'pid'), ('file', 'object'), ('file', 'sysmeta'))
    )
    url_pid = request.POST['pid']
    sysmeta_pyxb = d1_gmn.app.sysmeta.deserialize(request.FILES['sysmeta'])
    d1_gmn.app.views.assert_sysmeta.obsoletes_not_specified(sysmeta_pyxb)
    d1_gmn.app.views.assert_sysmeta.matches_url_pid(sysmeta_pyxb, url_pid)
    d1_gmn.app.views.assert_sysmeta.is_valid_sid_for_new_standalone(sysmeta_pyxb)
    d1_gmn.app.views.create.create_sciobj(request, sysmeta_pyxb)
    return url_pid
689152
def get_es_object_ids(self, objects):
        
        id_field = self.clean_id_name
        ids = [getattr(obj, id_field, obj) for obj in objects]
        return list(set(str(id_) for id_ in ids))
430248
def fetch_objects(self, oids):
        '''
        
        '''
        objects = self.model.objects.in_bulk(oids)
        if len(objects.keys()) != len(oids):
            non_existants = set(oids) - set(objects.keys())
            msg = _('Unknown identifiers: {identifiers}').format(
                identifiers=', '.join(str(ne) for ne in non_existants))
            raise validators.ValidationError(msg)

        return [objects[id] for id in oids]
567750
def get_ids(self, request_data, parameter_name='ids'):
        """"""
        if parameter_name not in request_data:
            raise ParseError("`{}` parameter is required".format(parameter_name))

        ids = request_data.get(parameter_name)
        if not isinstance(ids, list):
            raise ParseError("`{}` parameter not a list".format(parameter_name))

        if not ids:
            raise ParseError("`{}` parameter is empty".format(parameter_name))

        if any(map(lambda id: not isinstance(id, int), ids)):
            raise ParseError("`{}` parameter contains non-integers".format(parameter_name))

        return ids
44874
def get_pod_by_uid(uid, podlist):
    
    for pod in podlist.get("items", []):
        try:
            if pod["metadata"]["uid"] == uid:
                return pod
        except KeyError:
            continue
    return None
1180023
def get_queryset(self):
        
        queryset = super(MultipleIDMixin, self).get_queryset()
        if hasattr(self.request, 'query_params'):
            ids = dict(self.request.query_params).get('ids[]')
        else:
            ids = dict(self.request.QUERY_PARAMS).get('ids[]')
        if ids:
            queryset = queryset.filter(id__in=ids)
        return queryset
1209175
def get(self, uid):
        
        r = requests.get(self.apiurl + "/users/{}".format(uid), headers=self.header)

        if r.status_code != 200:
            raise ServerError

        jsd = r.json()

        if jsd['data']:
            return jsd['data']
        else:
            return None
928841
def get_services(cls, request=None):
        
        return {service['name']: reverse(service['list_view'], request=request)
                for service in cls._registry.values()}
5539
def get_supported_services_uids(self, referencesample):
        
        uids = referencesample.getSupportedServices(only_uids=True)
        return list(set(uids))
414541
def _parameter_objects(parameter_objects_from_pillars, parameter_object_overrides):
    '''
    
    '''
    from_pillars = copy.deepcopy(__salt__['pillar.get'](parameter_objects_from_pillars))
    from_pillars.update(parameter_object_overrides)
    parameter_objects = _standardize(_dict_to_list_ids(from_pillars))
    for parameter_object in parameter_objects:
        parameter_object['attributes'] = _properties_from_dict(parameter_object['attributes'])
    return parameter_objects
877482
def get_uids(self, filename=None):
        
        self._update()

        if filename:
            if filename not in self._reminders:
                return []
            return self._reminders[filename].keys()
        return [uid for uids in self._reminders.values() for uid in uids]
309966
def get_request_feature(self, name):
        
        if '[]' in name:
            # array-type
            return self.request.query_params.getlist(
                name) if name in self.features else None
        elif '{}' in name:
            # object-type (keys are not consistent)
            return self._extract_object_params(
                name) if name in self.features else {}
        else:
            # single-type
            return self.request.query_params.get(
                name) if name in self.features else None
395631
def _get_entities(self, user, ids):
        """"""
        queryset = get_objects_for_user(user, 'view_entity', Entity.objects.filter(id__in=ids))
        actual_ids = queryset.values_list('id', flat=True)
        missing_ids = list(set(ids) - set(actual_ids))
        if missing_ids:
            raise exceptions.ParseError(
                "Entities with the following ids not found: {}" .format(', '.join(map(str, missing_ids)))
            )

        return queryset
578016
def getAnalysisServiceSettings(self, uid):
        
        settings = self.getAnalysisServicesSettings()
        sets = [s for s in settings if s.get("uid", "") == uid]
        return sets[0] if sets else {"uid": uid}