fix from_date and to_date for est_employee

This commit is contained in:
alex 2020-01-20 15:51:47 +03:00
parent f026cfceba
commit a994e7214b

View File

@ -202,7 +202,7 @@ class EstablishmentEmployeeCreateSerializer(serializers.ModelSerializer):
"""Meta class."""
model = models.EstablishmentEmployee
fields = ('id',)
fields = ('id', 'from_date', 'to_date')
def _validate_entity(self, entity_id_param: str, entity_class):
entity_id = self.context.get('request').parser_context.get('kwargs').get(entity_id_param)