base

admin

class CardapioAdmin(model, admin_site)[source]

Bases: ModelAdmin

list_display = ['data', 'criado_em', 'ativo']
property media
ordering = ['data', 'criado_em']
class ComboDoVinculoTipoAlimentacaoPeriodoTipoUEModelAdmin(model, admin_site)[source]

Bases: ModelAdmin

filter_horizontal = ('tipos_alimentacao',)
inlines = [<class 'sme_sigpae_api.cardapio.base.admin.SubstituicaoComboInline'>]
property media
readonly_fields = ('vinculo',)
search_fields = ('vinculo__tipo_unidade_escolar__iniciais',)
class ComboVinculoLine(parent_model, admin_site)[source]

Bases: TabularInline

extra = 1
property media
model

alias of ComboDoVinculoTipoAlimentacaoPeriodoTipoUE

class SubstituicaoComboInline(parent_model, admin_site)[source]

Bases: TabularInline

extra = 2
property media
model

alias of SubstituicaoDoComboDoVinculoTipoAlimentacaoPeriodoTipoUE

class SubstituicaoDoComboDoVinculoTipoAlimentacaoPeriodoTipoUEModelAdmin(model, admin_site)[source]

Bases: ModelAdmin

list_display = ('__str__',)
property media
class VinculoTipoAlimentacaoModelAdmin(model, admin_site)[source]

Bases: ModelAdmin

inlines = [<class 'sme_sigpae_api.cardapio.base.admin.ComboVinculoLine'>]
list_filter = ('periodo_escolar__nome', 'tipo_unidade_escolar__iniciais', 'ativo')
property media

behaviors

class TemLabelDeTiposDeAlimentacao(*args, **kwargs)[source]

Bases: Model

class Meta[source]

Bases: object

abstract = False
property label: str

models

class Cardapio(*args, **kwargs)[source]

Bases: ExportModelOperationsMixin('cardapio'), Descritivel, Ativavel, TemData, TemChaveExterna, CriadoEm

Cardápio escolar.

tem 1 data pra acontecer ex (26/06) tem 1 lista de tipos de alimentação (Dejejum, Colação, Almoço, LANCHE DE 4 HS OU 8 HS; LANCHE DE 5HS OU 6 HS; REFEIÇÃO).

!!!OBS!!! PARA CEI varia por faixa de idade.

exception DoesNotExist

Bases: ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: MultipleObjectsReturned

ativo

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

cardapio_de

Accessor to the related objects manager on the reverse side of a many-to-one relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Parent.children is a ReverseManyToOneDescriptor instance.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

cardapio_para

Accessor to the related objects manager on the reverse side of a many-to-one relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Parent.children is a ReverseManyToOneDescriptor instance.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

criado_em

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

data

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

descricao

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

edital

Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Child.parent is a ForwardManyToOneDescriptor instance.

edital_id
get_next_by_criado_em(*, field=<django.db.models.fields.DateTimeField: criado_em>, is_next=True, **kwargs)
get_next_by_data(*, field=<django.db.models.fields.DateField: data>, is_next=True, **kwargs)
get_previous_by_criado_em(*, field=<django.db.models.fields.DateTimeField: criado_em>, is_next=False, **kwargs)
get_previous_by_data(*, field=<django.db.models.fields.DateField: data>, is_next=False, **kwargs)
id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
tipos_alimentacao

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

tipos_unidade_escolar

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

uuid

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

class ComboDoVinculoTipoAlimentacaoPeriodoTipoUE(id, uuid, vinculo)[source]

Bases: ExportModelOperationsMixin('substituicoes_vinculo_alimentacao'), TemChaveExterna, TemLabelDeTiposDeAlimentacao

exception DoesNotExist

Bases: ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: MultipleObjectsReturned

id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
pode_excluir()[source]
substituicoes

Accessor to the related objects manager on the reverse side of a many-to-one relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Parent.children is a ReverseManyToOneDescriptor instance.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

tipos_alimentacao

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

uuid

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

vinculo

Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Child.parent is a ForwardManyToOneDescriptor instance.

vinculo_id
class HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar(id, uuid, hora_inicial, hora_final, escola, tipo_alimentacao, periodo_escolar)[source]

Bases: TemChaveExterna

exception DoesNotExist

Bases: ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: MultipleObjectsReturned

escola

Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Child.parent is a ForwardManyToOneDescriptor instance.

escola_id
hora_final

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

hora_inicial

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
periodo_escolar

Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Child.parent is a ForwardManyToOneDescriptor instance.

periodo_escolar_id
tipo_alimentacao

Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Child.parent is a ForwardManyToOneDescriptor instance.

tipo_alimentacao_id
uuid

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

class MotivoDRENaoValida(*args, **kwargs)[source]

Bases: ExportModelOperationsMixin('motivo_dre_nao_valida'), Nomeavel, TemChaveExterna

Usado em conjunto com Solicitações que passam por validação da DRE.

Exemplos:
  • Em desacordo com o contrato

  • Preenchimento incorreto

  • Outro

exception DoesNotExist

Bases: ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: MultipleObjectsReturned

id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

nome

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
uuid

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

class SubstituicaoDoComboDoVinculoTipoAlimentacaoPeriodoTipoUE(id, uuid, combo)[source]

Bases: TemChaveExterna, TemLabelDeTiposDeAlimentacao

exception DoesNotExist

Bases: ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: MultipleObjectsReturned

combo

Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Child.parent is a ForwardManyToOneDescriptor instance.

combo_id
id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
pode_excluir()[source]
tipos_alimentacao

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

uuid

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

class TipoAlimentacao(*args, **kwargs)[source]

Bases: ExportModelOperationsMixin('tipo_alimentacao'), Nomeavel, TemChaveExterna, Posicao

Compõe parte do cardápio.

Dejejum Colação Almoço Refeição Sobremesa Lanche 4 horas Lanche 5 horas Lanche 6 horas Lanche Emergencial

exception DoesNotExist

Bases: ObjectDoesNotExist

LANCHE_4H = 'Lanche 4h'
LANCHE_EMERGENCIAL = 'Lanche Emergencial'
exception MultipleObjectsReturned

Bases: MultipleObjectsReturned

cardapio_combodovinculotipoalimentacaoperiodotipoue_possibilidades

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

cardapio_set

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

cardapio_substituicaodocombodovinculotipoalimentacaoperiodotipoue_possibilidades

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

horariodocombodotipodealimentacaoporunidadeescolar_set

Accessor to the related objects manager on the reverse side of a many-to-one relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Parent.children is a ReverseManyToOneDescriptor instance.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

inclusaoalimentacaodacei_set

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

inversaocardapio_set

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

nome

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
parametrizacao_valor_tipo_alimentacao

Accessor to the related objects manager on the reverse side of a many-to-one relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Parent.children is a ReverseManyToOneDescriptor instance.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

periodos_escolares

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

posicao

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

quantidadedealunosemeiinclusaodealimentacaocemei_set

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

quantidadeporperiodo_set

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

quantidadeporperiodosuspensaoalimentacao_set

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

recreionasferiasunidadetipoalimentacao_set

Accessor to the related objects manager on the reverse side of a many-to-one relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Parent.children is a ReverseManyToOneDescriptor instance.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

respostas_relatorio_imr

Accessor to the related objects manager on the reverse side of a many-to-one relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Parent.children is a ReverseManyToOneDescriptor instance.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

substituicoes_alimento_para

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

substituicoes_alimentos_de

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

substituicoes_cei_tipo_alimentacao_de

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

substituicoes_cei_tipo_alimentacao_para

Accessor to the related objects manager on the reverse side of a many-to-one relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Parent.children is a ReverseManyToOneDescriptor instance.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

substituicoes_cemei_cei_alimento_para

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

substituicoes_cemei_cei_tipo_alimentacao_de

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

substituicoes_cemei_emei_alimento_para

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

substituicoes_cemei_emei_tipo_alimentacao_de

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

property substituicoes_periodo_escolar
suspensoes_periodo_escolar

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

uuid

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

valormedicao_set

Accessor to the related objects manager on the reverse side of a many-to-one relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Parent.children is a ReverseManyToOneDescriptor instance.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

vinculos

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

class VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar(*args, **kwargs)[source]

Bases: ExportModelOperationsMixin('vinculo_alimentacao_periodo_escolar_tipo_ue'), Ativavel, TemChaveExterna

Vincular vários tipos de alimentação a um periodo e tipo de U.E.

Dado o tipo_unidade_escolar (EMEI, EMEF…) e em seguida o periodo_escolar(MANHA, TARDE..), trazer os tipos de alimentação que podem ser servidos. Ex.: Para CEI(creche) pela manhã (período) faz sentido ter mingau e não café da tarde.

exception DoesNotExist

Bases: ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: MultipleObjectsReturned

ativo

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

combos

Accessor to the related objects manager on the reverse side of a many-to-one relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Parent.children is a ReverseManyToOneDescriptor instance.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
periodo_escolar

Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Child.parent is a ForwardManyToOneDescriptor instance.

periodo_escolar_id
tipo_unidade_escolar

Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

Child.parent is a ForwardManyToOneDescriptor instance.

tipo_unidade_escolar_id
tipos_alimentacao

Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.

In the example:

class Pizza(Model):
    toppings = ManyToManyField(Topping, related_name='pizzas')

Pizza.toppings and Topping.pizzas are ManyToManyDescriptor instances.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

uuid

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

api

api/serializers

class CardapioSerializer(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

exclude = ('id',)
model

alias of Cardapio

class CardapioSimplesSerializer(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

exclude = ('id',)
model

alias of Cardapio

class CombosVinculoTipoAlimentoSimplesSerializer(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

fields = ('uuid', 'tipos_alimentacao', 'vinculo', 'substituicoes', 'label')
model

alias of ComboDoVinculoTipoAlimentacaoPeriodoTipoUE

get_label(obj)[source]
class CombosVinculoTipoAlimentoSimplissimaSerializer(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

fields = ('uuid', 'label')
model

alias of ComboDoVinculoTipoAlimentacaoPeriodoTipoUE

get_label(obj)[source]
class HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolarSerializer(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

fields = ('uuid', 'hora_inicial', 'hora_final', 'escola', 'tipo_alimentacao', 'periodo_escolar')
model

alias of HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar

class MotivoDRENaoValidaSerializer(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

exclude = ('id',)
model

alias of MotivoDRENaoValida

class SubstituicaoDoComboVinculoTipoAlimentoSimplesSerializer(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

fields = ('uuid', 'tipos_alimentacao', 'combo', 'label')
model

alias of SubstituicaoDoComboDoVinculoTipoAlimentacaoPeriodoTipoUE

class TipoAlimentacaoSerializer(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

exclude = ('id',)
model

alias of TipoAlimentacao

class TipoAlimentacaoSimplesSerializer(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

fields = ('uuid', 'nome')
model

alias of TipoAlimentacao

class TipoUnidadeEscolarAgrupadoSerializer(*args, **kwargs)[source]

Bases: Serializer

static agrupar_vinculos_por_tipo_ue(vinculos)[source]
get_periodos_escolares(obj)[source]
class VinculoTipoAlimentoPeriodoSerializer(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

fields = ('nome', 'tipos_alimentacao')
model

alias of VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar

get_nome(obj)[source]
class VinculoTipoAlimentoSimplesSerializer(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

fields = ('uuid', 'tipo_unidade_escolar', 'periodo_escolar', 'tipos_alimentacao')
model

alias of VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar

api/serializers_create

class CardapioCreateSerializer(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

exclude = ('id',)
model

alias of Cardapio

validate_data(data)[source]
class ComboDoVinculoTipoAlimentoSimplesSerializerCreate(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

fields = ('uuid', 'tipos_alimentacao', 'vinculo')
model

alias of ComboDoVinculoTipoAlimentacaoPeriodoTipoUE

validate_tipos_alimentacao(tipos_alimentacao)[source]
class HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolarSerializerCreate(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

fields = ('uuid', 'hora_inicial', 'hora_final', 'escola', 'tipo_alimentacao', 'periodo_escolar')
model

alias of HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar

create(validated_data)[source]

We have a bit of extra checking around this in order to provide descriptive messages when something goes wrong, but this method is essentially just:

return ExampleModel.objects.create(**validated_data)

If there are many to many fields present on the instance then they cannot be set until the model is instantiated, in which case the implementation is like so:

example_relationship = validated_data.pop(‘example_relationship’) instance = ExampleModel.objects.create(**validated_data) instance.example_relationship = example_relationship return instance

The default implementation also does not handle nested relationships. If you want to support writable nested relationships you’ll need to write an explicit .create() method.

update(instance, validated_data)[source]
validate(attrs)[source]
class SubstituicaoDoComboVinculoTipoAlimentoSimplesSerializerCreate(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

fields = ('uuid', 'tipos_alimentacao', 'combo')
model

alias of SubstituicaoDoComboDoVinculoTipoAlimentacaoPeriodoTipoUE

validate_tipos_alimentacao(tipos_alimentacao)[source]
class VinculoTipoAlimentoCreateSerializer(*args, **kwargs)[source]

Bases: ModelSerializer

class Meta[source]

Bases: object

fields = ('uuid', 'tipos_alimentacao', 'tipo_unidade_escolar', 'periodo_escolar')
model

alias of VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar

update(instance, validated_data)[source]
validate_tipos_alimentacao(tipos_alimentacao)[source]

api/validators

escola_nao_pode_cadastrar_dois_combos_iguais(escola, tipo_alimentacao, periodo_escolar)[source]

Se o horário de tipo de alimentação já estiver cadastrado para a Escola e Período escolar, deve retornar erro.

Pois para cada tipo de alimentação só é possivel registrar um intervalo de horario, caso o tipo de alimentação já estiver cadastrado, só será possivel atualizar o objeto HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar.

hora_inicio_nao_pode_ser_maior_que_hora_final(hora_inicial, hora_final)[source]

api/viewsets

class CardapioViewSet(**kwargs)[source]

Bases: ModelViewSet

get_serializer_class()[source]

Return the class to use for the serializer. Defaults to using self.serializer_class.

You may want to override this if you need to provide different serializations depending on the incoming request.

(Eg. admins get full serialization, others get basic serialization)

lookup_field = 'uuid'
queryset = <QuerySet []>
serializer_class

alias of CardapioSerializer

class CombosDoVinculoTipoAlimentacaoPeriodoTipoUEViewSet(**kwargs)[source]

Bases: RetrieveModelMixin, ListModelMixin, CreateModelMixin, DestroyModelMixin, GenericViewSet

destroy(request, *args, **kwargs)[source]
get_serializer_class()[source]

Return the class to use for the serializer. Defaults to using self.serializer_class.

You may want to override this if you need to provide different serializations depending on the incoming request.

(Eg. admins get full serialization, others get basic serialization)

lookup_field = 'uuid'
queryset = <QuerySet [<ComboDoVinculoTipoAlimentacaoPeriodoTipoUE: TiposAlim.: ['Almoço']>]>
serializer_class

alias of CombosVinculoTipoAlimentoSimplesSerializer

class HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolarViewSet(**kwargs)[source]

Bases: ModelViewSet

filtro_por_escola(request, escola_uuid=None)[source]
get_serializer_class()[source]

Return the class to use for the serializer. Defaults to using self.serializer_class.

You may want to override this if you need to provide different serializations depending on the incoming request.

(Eg. admins get full serialization, others get basic serialization)

lookup_field = 'uuid'
queryset = <QuerySet [<HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Refeição DE: 11:10:00 ATE: 12:00:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Lanche Emergencial DE: 08:30:00 ATE: 08:50:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Refeição da tarde DE: 16:00:00 ATE: 17:10:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Colação DE: 09:30:00 ATE: 10:20:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Almoço DE: 11:30:00 ATE: 13:00:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Desjejum DE: 08:20:00 ATE: 09:05:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Lanche DE: 14:00:00 ATE: 14:45:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Lanche DE: 08:00:00 ATE: 09:00:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Lanche DE: 08:30:00 ATE: 09:35:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Refeição DE: 11:50:00 ATE: 12:15:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Lanche DE: 07:40:00 ATE: 08:40:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Refeição DE: 10:40:00 ATE: 12:00:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Lanche DE: 07:00:00 ATE: 07:10:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Refeição DE: 09:25:00 ATE: 09:45:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Lanche Emergencial DE: 08:30:00 ATE: 09:05:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Lanche DE: 13:10:00 ATE: 13:20:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Lanche DE: 09:20:00 ATE: 10:25:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Refeição DE: 11:55:00 ATE: 13:50:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Lanche DE: 08:30:00 ATE: 08:50:00>, <HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolar: Refeição DE: 11:50:00 ATE: 12:10:00>, '...(remaining elements truncated)...']>
serializer_class

alias of HorarioDoComboDoTipoDeAlimentacaoPorUnidadeEscolarSerializer

class MotivosDRENaoValidaViewSet(**kwargs)[source]

Bases: ReadOnlyModelViewSet

lookup_field = 'uuid'
queryset = <QuerySet [<MotivoDRENaoValida: Em desacordo com o contrato>, <MotivoDRENaoValida: Preenchimento incorreto>, <MotivoDRENaoValida: Outro>]>
serializer_class

alias of MotivoDRENaoValidaSerializer

class SubstituicaoDoCombosDoVinculoTipoAlimentacaoPeriodoTipoUEViewSet(**kwargs)[source]

Bases: RetrieveModelMixin, ListModelMixin, CreateModelMixin, DestroyModelMixin, GenericViewSet

destroy(request, *args, **kwargs)[source]
get_serializer_class()[source]

Return the class to use for the serializer. Defaults to using self.serializer_class.

You may want to override this if you need to provide different serializations depending on the incoming request.

(Eg. admins get full serialization, others get basic serialization)

lookup_field = 'uuid'
queryset = <QuerySet []>
serializer_class

alias of SubstituicaoDoComboVinculoTipoAlimentoSimplesSerializer

class TipoAlimentacaoViewSet(**kwargs)[source]

Bases: ModelViewSet

lookup_field = 'uuid'
queryset = <QuerySet [<TipoAlimentacao: Desjejum>, <TipoAlimentacao: Colação>, <TipoAlimentacao: Almoço>, <TipoAlimentacao: Lanche>, <TipoAlimentacao: Refeição da tarde>, <TipoAlimentacao: Refeição>, <TipoAlimentacao: Sobremesa>, <TipoAlimentacao: Lanche 4h>, <TipoAlimentacao: Lanche Emergencial>]>
serializer_class

alias of TipoAlimentacaoSerializer

class VinculoTipoAlimentacaoViewSet(**kwargs)[source]

Bases: ModelViewSet, RetrieveModelMixin, ListModelMixin, GenericViewSet

atualizar_lista_de_vinculos(request)[source]
filtro_por_escola(request, escola_uuid=None)[source]
filtro_por_tipo_ue(request, tipo_unidade_escolar_uuid=None)[source]
get_serializer_class()[source]

Return the class to use for the serializer. Defaults to using self.serializer_class.

You may want to override this if you need to provide different serializations depending on the incoming request.

(Eg. admins get full serialization, others get basic serialization)

get_vinculos_inclusoes_evento_especifico(mes, ano, tipo_solicitacao, escola)[source]
lookup_field = 'uuid'
motivo_inclusao_especifico(request)[source]
queryset = <QuerySet [<VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEU GESTAO - NOITE>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEU GESTAO - TARDE>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEU GESTAO - MANHA>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEU GESTAO - INTEGRAL>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CCI/CIPS - MANHA>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CCI/CIPS - TARDE>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CCI/CIPS - INTEGRAL>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CECI - INTEGRAL>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEI - MANHA>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEI - TARDE>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEI - INTEGRAL>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEI DIRET - MANHA>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEI DIRET - TARDE>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEI DIRET - INTEGRAL>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEI INDIR - INTEGRAL>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEMEI - MANHA>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEMEI - TARDE>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEMEI - INTEGRAL>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEU AT COMPL - MANHA>, <VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolar: CEU AT COMPL - INTERMEDIARIO>, '...(remaining elements truncated)...']>
serializer_class

alias of VinculoTipoAlimentoSimplesSerializer

trata_inclusao_continua_medicao_inicial(request, escola, ano, pega_atualmente)[source]
vinculos_inclusoes_evento_especifico_autorizadas(request)[source]
class VinculosPorTipoUnidadeEscolarViewSet(**kwargs)[source]

Bases: ListModelMixin, GenericViewSet

list(request)[source]

Lista todos os tipos de UE com seus períodos e tipos de alimentação

fixtures

fixtures/factories

class TipoAlimentacaoFactory(**kwargs)[source]

Bases: DjangoModelFactory

nome = <factory.declarations.Sequence object>
class VinculoTipoAlimentacaoComPeriodoEscolarETipoUnidadeEscolarFactory(**kwargs)[source]

Bases: DjangoModelFactory

periodo_escolar = <factory.declarations.SubFactory object>
tipo_unidade_escolar = <factory.declarations.SubFactory object>
tipos_alimentacao = <factory.declarations.PostGeneration object>