Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Enzo Yair
/
turismo-api
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
Enzo Yair
2024-10-02 08:35:40 -0300
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
eb06852eed3531dc8034e7b22018c3618b44912e
eb06852e
1 parent
d8cd3a22
se agrega el contendio de los objetos en el serializer
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
1 deletions
project/apps/evento/serializers.py
project/apps/evento/serializers.py
View file @
eb06852
from
rest_framework_json_api
import
serializers
from
.models
import
Evento
from
.models
import
Evento
,
FechaEvento
from
organismo.serializers
import
OrganismoSerializer
,
DependenciaSerializer
class
FechaEventoSerializer
(
serializers
.
ModelSerializer
):
class
Meta
:
model
=
FechaEvento
fields
=
serializers
.
ALL_FIELDS
class
EventoSerializer
(
serializers
.
ModelSerializer
):
organismo
=
OrganismoSerializer
(
many
=
True
,
read_only
=
True
)
dependencia
=
DependenciaSerializer
(
many
=
True
,
read_only
=
True
)
fechas
=
FechaEventoSerializer
(
many
=
True
,
read_only
=
True
)
class
Meta
:
model
=
Evento
fields
=
(
...
...
Please
register
or
login
to post a comment