def process_formdata(self, valuelist): super(IndicoLocationField, self).process_formdata(valuelist) self.data['room'] = Room.get(int(self.data['room_id'])) if self.data.get('room_id') else None self.data['venue'] = (Location.get(int(self.data['venue_id']), is_deleted=False) if self.data.get('venue_id') else None) self.data['source'] = self.object_data.get('source') if self.object_data else None
def process_formdata(self, valuelist): from indico.modules.rb.models.locations import Location from indico.modules.rb.models.rooms import Room super().process_formdata(valuelist) self.data['room'] = Room.get(int(self.data['room_id'])) if self.data.get('room_id') else None self.data['venue'] = (Location.get(int(self.data['venue_id']), is_deleted=False) if self.data.get('venue_id') else None) self.data['source'] = self.object_data.get('source') if self.object_data else None
def _checkParams(self): self._location = Location.get(int(request.form['location_id'])) if not self._location: raise NoReportError(u'No such location')
def _process_args(self): self._location = Location.get(int(request.form['location_id'])) if not self._location: raise NotFound(u'No such location')
def _checkParams(self): self._location = Location.get(int(request.form['location_id'])) if not self._location: raise NoReportError(u'No such location')
def process_formdata(self, valuelist): super(IndicoLocationField, self).process_formdata(valuelist) self.data['room'] = Room.get(int( self.data['room_id'])) if self.data.get('room_id') else None self.data['venue'] = Location.get(int( self.data['venue_id'])) if self.data.get('venue_id') else None
def _process_args(self): self._location = Location.get(int(request.form['location_id'])) if not self._location: raise NotFound(u'No such location')
def process_formdata(self, valuelist): super(IndicoLocationField, self).process_formdata(valuelist) self.data['room'] = Room.get(int(self.data['room_id'])) if self.data.get('room_id') else None self.data['venue'] = Location.get(int(self.data['venue_id'])) if self.data.get('venue_id') else None