def get_fields(self): fields = super().get_fields() authority = get_the_authority(self.context['request'].user) fields['clients'] = hyperlinkedRelatedFieldByAuthority(Client, 'client-detail', authority) fields['addresses'] = hyperlinkedRelatedFieldByAuthority(Address, 'address-detail', authority) return fields
def get_fields(self): fields = super().get_fields() authority = get_the_authority(self.context['request'].user) fields['assigned_to'] = hyperlinkedRelatedFieldByAuthority(Staff, 'staff-detail', authority, False) fields['status'] = hyperlinkedRelatedFieldByAuthority(Status, 'status-detail', authority, False) return fields
def get_fields(self): fields = super().get_fields() authority = get_the_authority(self.context['request'].user) fields['project'] = hyperlinkedRelatedFieldByAuthority(Project, 'project-detail', authority, False) return fields
def get_fields(self): fields = super().get_fields() authority = get_the_authority(self.context['request'].user) fields['status_group'] = hyperlinkedRelatedFieldByAuthority(StatusGroup, 'statusgroup-detail', authority, False) return fields
def get_fields(self): fields = super().get_fields() authority = get_the_authority(self.context['request'].user) fields['company'] = hyperlinkedRelatedFieldByAuthority(Company, 'company-detail', authority, False) return fields
def get_fields(self): fields = super().get_fields() authority = get_the_authority(self.context['request'].user) fields['work_day'] = hyperlinkedRelatedFieldByAuthority(WorkDay, 'workday-detail', authority, False) return fields