<?xml version="1.0" encoding="utf-8"?>
<Entity 
Schema="AKUZ" 
Name="AMBULANCE_SURGICAL_OPERATION" 
Description="Амбулаторное хирургическое вмешательство или манипуляция" 
DNAttributes="{MedicalService/Code}" 
DisplayName="{0}" 
Inherits="AKUZ.AMBULANCE_RECORD">
  <Customs>
    <Custom Name="ExcludeChildControlCommands" Value="Add;Open;Delete" />
  </Customs>
  <Fields>
    <Attribute Name="Ratio" Index="5780004" Type="int" Description="Кратность" Required="1" />
    <Attribute Name="OperationDate" Index="5780005" Type="date" Description="Дата проведения" Required="1" />
    <Attribute Name="MkbCode" Index="5780007" Type="string" Description="Код МКБ" CharacterMaximumLength="8" />
    <Attribute Name="ToothNumber" Index="5780008" Type="string" Description="Номер зуба" />
    <Attribute Name="Uet" Index="5780009" Type="float" DefaultFormat="{0:N}" Description="Количество УЕТ" NumericPrecision="12" NumericScale="2" />
    <Attribute Name="TreatmentStartDate" Index="5780010" Type="date" Description="Дата начала лечения" />
    <Attribute Name="TreatmentEndDate" Type="date" Description="Дата окончания лечения" />
    <Parent Name="MedicalService" Index="5780006" Type="AKUZ.MEDICAL_SERVICE" Description="Медицинские услуги" Required="1" />
    <Child Name="PatientAppointmentExecutions" Index="5780011" Type="AKUZ.PATIENT_APPOINTMENT_EXECUTION" Description="Выполнение назначения на пациента" ChildAttribute="AmbulanceSurgicalOperation" />
    <Choice Name="STM_BLACK" Index="5780012" Description="Класс по Блэку">
      <Item Name="1" Index="1" />
      <Item Name="2" Index="2" />
      <Item Name="3" Index="3" />
      <Item Name="4" Index="4" />
      <Item Name="5" Index="5" />
      <Item Name="6" Index="6" />
    </Choice>
    <Child Name="BaseInterventionProtocols" Index="5780013" Type="AKUZ.BASE_INTERVENTION_PROTOCOL" Description="Базовый протокол хир вмешательства" ChildAttribute="AmbulanceSurgicalOperation" />
    <Child Name="SurgicalOperationExtensionLinks" Type="AKUZ.SURGICAL_OPERATION_EXTENSION_LINK" Description="Примененные импланты" ChildAttribute="AmbulanceSurgicalOperation" />
    <Attribute Name="DENTAL_KPU" Type="int" Description="Индекс КПУ+КП" />
    <Attribute Name="DENTAL_KOL" Type="int" Description="Количество нелеченых кариозных зубов" />
    <Parent Name="DentalSide" Type="AKUZ.DENTAL_SIDE" Description="Пораженная поверхность зуба" />
    <Link Name="OnkoService" Type="AKUZ.ONKO_SERVICE" Description="Сведения об услуге при лечении онкологического заболевания" LinkAttribute="AmbulanceSurgicalOperation" RemoveAction="0" />
    <Parent Name="PerformedServicePost" Type="AKUZ.POST" Description="Исполнитель" Required="1" />
    <Attribute Name="OperationTime" Type="datetime" DefaultFormat="{0:HH:mm}" Description="Время проведения" />
    <Attribute Name="Result" Type="binary" Description="Результат" ContentType="text/zip" />
    <Parent Name="MOPerformer" Type="AKUZ.LPU_MAIN" Description="МО-исполнитель" />
    <Parent Name="DivisionPerformer" Type="AKUZ.DIVISION" Description="Отделение-исполнитель" />
  </Fields>
  <DbMapping>
    <Table name="T_AMBULANCE_SURGICAL_OPERATION">
      <Map Name="Ratio" Column="Ratio" />
      <Map Name="OperationDate" Column="OperationDate" />
      <Map Name="MkbCode" Column="MkbCode" />
      <Map Name="ToothNumber" Column="ToothNumber" />
      <Map Name="Uet" Column="Uet" />
      <Map Name="TreatmentStartDate" Column="TreatmentStartDate" />
      <Map Name="TreatmentEndDate" Column="TreatmentEndDate" />
      <Map Name="MedicalService" Column="MedicalService" />
      <Map Name="STM_BLACK" Column="STM_BLACK" />
      <Map Name="DENTAL_KPU" Column="DENTAL_KPU" />
      <Map Name="DENTAL_KOL" Column="DENTAL_KOL" />
      <Map Name="DentalSide" Column="DentalSide" />
      <Map Name="PerformedServicePost" Column="PerformedServicePost" />
      <Map Name="OperationTime" Column="OperationTime" />
      <Map Name="Result" Column="Result" />
      <Map Name="MOPerformer" Column="MOPerformer" />
      <Map Name="DivisionPerformer" Column="DivisionPerformer" />
    </Table>
  </DbMapping>
</Entity>