PackagesCanonicalsLogsProblems
    Packages
    br.go.ses.core@1.1.0
    https://fhir.saude.go.gov.br/r4/core/StructureDefinition/historico-gestacional
description: null
package_name: br.go.ses.core
derivation: constraint
name: HistoricoGestacional
type: Observation
elements:
  identifier:
    index: 0
    elements:
      system:
        pattern: {type: Uri, value: 'http://www.saude.go.gov.br/fhir/r4/NamingSystem/dnv'}
        index: 1
      value: {short: Número da Declaração de Nascido Vivo, index: 2}
      period:
        elements:
          start: {short: Data do preenchimento, index: 3}
        required: [start]
    required: [value, system]
  status:
    short: Gestações anteriores ou histórico gestacional
    pattern: {type: Code, value: final}
    index: 4
  code:
    elements:
      coding:
        index: 5
        elements:
          system:
            pattern: {type: Uri, value: 'http://loinc.org'}
            index: 6
          code:
            pattern: {type: Code, value: 10163-4}
            index: 7
        required: [system, code]
    required: [coding]
  subject:
    type: Reference
    short: Parturiente
    refers: ['https://fhir.saude.go.gov.br/r4/core/StructureDefinition/individuo']
    index: 8
    elements:
      identifier:
        constraint:
          CPFouCNS: {human: O sistema de identificação do indivíduo deve ser ou CPF ou CNS, source: 'https://fhir.saude.go.gov.br/r4/core/StructureDefinition/historico-gestacional', severity: error, expression: 'system = ''https://fhir.saude.go.gov.br/sid/cpf'' or system = ''https://fhir.saude.go.gov.br/sid/cns'''}
        index: 9
        elements:
          system: {index: 10}
          value: {index: 11}
        required: [value, system]
    required: [identifier]
  encounter:
    type: Reference
    short: Local de Atendimento do Parto
    refers: ['https://fhir.saude.go.gov.br/r4/core/StructureDefinition/atendimento-parto']
    index: 12
  component:
    array: true
    min: 3
    max: 3
    index: 13
    slicing:
      rules: closed
      discriminator:
      - {path: code.coding.code, type: value}
      min: 3
      max: 3
      slices:
        cesareas:
          match:
            code:
              coding: {code: 68497-7}
          schema:
            _required: true
            index: 14
            elements:
              code:
                elements:
                  coding:
                    elements:
                      system:
                        pattern: {type: Uri, value: 'http://loinc.org'}
                        index: 15
                      code:
                        pattern: {type: Code, value: 68497-7}
                        index: 16
                    required: [code]
              value:
                choices: []
                index: 18
                slicing:
                  rules: open
                  ordered: false
                  discriminator:
                  - {path: $this, type: type}
                  min: 1
                  slices:
                    valueInteger:
                      match: {}
                      schema:
                        short: Número de cesáreas
                        choices: [valueInteger]
                        _required: true
                        index: 20
                      min: 1
                      max: 1
              valueInteger:
                type: integer
                short: Número de cesáreas
                choiceOf: value
                index: 21
                slicing:
                  slices:
                    valueInteger:
                      match: {}
                      schema: {type: integer, short: Número de cesáreas, choiceOf: value, _required: true, index: 21}
                      min: 1
                      max: 1
            required: [value, valueInteger]
        nascidosVivos:
          match:
            code:
              coding: {code: 11636-8}
          schema:
            _required: true
            index: 22
            elements:
              code:
                elements:
                  coding:
                    elements:
                      system:
                        pattern: {type: Uri, value: 'http://loinc.org'}
                        index: 23
                      code:
                        pattern: {type: Code, value: 11636-8}
                        index: 24
                    required: [code]
              value:
                choices: []
                index: 26
                slicing:
                  rules: open
                  ordered: false
                  discriminator:
                  - {path: $this, type: type}
                  min: 1
                  slices:
                    valueInteger:
                      match: {}
                      schema:
                        short: Número de nascidos vivos
                        choices: [valueInteger]
                        _required: true
                        index: 28
                      min: 1
                      max: 1
              valueInteger:
                type: integer
                short: Número de nascidos vivos
                choiceOf: value
                index: 29
                slicing:
                  slices:
                    valueInteger:
                      match: {}
                      schema: {type: integer, short: Número de nascidos vivos, choiceOf: value, _required: true, index: 29}
                      min: 1
                      max: 1
            required: [value, valueInteger]
        perdasFetaisOuAbortos:
          match:
            code:
              coding: {code: 11612-9}
          schema:
            _required: true
            index: 30
            elements:
              code:
                elements:
                  coding:
                    elements:
                      system:
                        pattern: {type: Uri, value: 'http://loinc.org'}
                        index: 31
                      code:
                        pattern: {type: Code, value: 11612-9}
                        index: 32
                    required: [code]
              value:
                choices: []
                index: 34
                slicing:
                  rules: open
                  ordered: false
                  discriminator:
                  - {path: $this, type: type}
                  min: 1
                  slices:
                    valueInteger:
                      match: {}
                      schema:
                        short: Número de perdas fetais ou abortos
                        choices: [valueInteger]
                        _required: true
                        index: 36
                      min: 1
                      max: 1
              valueInteger:
                type: integer
                short: Número de perdas fetais ou abortos
                choiceOf: value
                index: 37
                slicing:
                  slices:
                    valueInteger:
                      match: {}
                      schema: {type: integer, short: Número de perdas fetais ou abortos, choiceOf: value, _required: true, index: 37}
                      min: 1
                      max: 1
            required: [value, valueInteger]
package_version: 1.1.0
class: profile
kind: resource
url: https://fhir.saude.go.gov.br/r4/core/StructureDefinition/historico-gestacional
base: http://hl7.org/fhir/StructureDefinition/Observation
version: 1.1.0
required: [encounter, identifier, subject]