<?xml version="1.0" encoding="utf-8"?>
<Entity 
Schema="AKUZ" 
Name="IEMK_IHE_PIX_EVENT" 
Description="Уведомление о событии PIX профиля" 
PrimaryKey="IemkIhePixEventID">
  <Fields>
    <Attribute Name="IemkIhePixEventID" Index="9580001" Type="guid" Description="Идентификатор" />
    <Attribute Name="MessageType" Index="9580002" Type="string" Description="Тип сообщения" CharacterMaximumLength="16" Required="1" />
    <Attribute Name="TriggerEvent" Index="9580003" Type="string" Description="Событие" CharacterMaximumLength="16" Required="1" />
    <Attribute Name="MessageStructure" Index="9580004" Type="string" Description="Структура сообщения" CharacterMaximumLength="16" Required="1" />
    <Attribute Name="DataObject" Index="9580005" Type="binary" Description="DataObject" ContentType="text/zip" />
    <Attribute Name="OwnerID" Index="9580006" Type="string" Description="OwnerID" CharacterMaximumLength="256" Required="1" />
    <Attribute Name="OrderNum" Index="9580007" Type="int" Description="Порядковый номер" Required="1" />
    <Attribute Name="EventTime" Index="9580010" Type="datetime" DefaultFormat="{0:dd.MM.yyyy HH:mm:ss}" Description="Время события" Required="1" />
    <Child Name="IheTransactionLogs" Index="9580009" Type="AKUZ.IHE_TRANSACTION_LOG" Description="Лог транзакций IHE" ChildAttribute="IemkIhePixEvent" />
    <Choice Name="Status" Index="9580008" Description="Статус" Required="1">
      <Item Name="На отправку" Index="0" />
      <Item Name="Отправлен" Index="1" />
      <Item Name="Ошибка" Index="2" />
    </Choice>
    <Attribute Name="ErrorText" Type="string" Description="Текст ошибки" CharacterMaximumLength="4000" />
  </Fields>
  <DbMapping>
    <Table name="T_IEMK_IHE_PIX_EVENT">
      <Map Name="IemkIhePixEventID" Column="IemkIhePixEventID" />
      <Map Name="MessageType" Column="MessageType" />
      <Map Name="TriggerEvent" Column="TriggerEvent" />
      <Map Name="MessageStructure" Column="MessageStructure" />
      <Map Name="DataObject" Column="DataObject" />
      <Map Name="OwnerID" Column="OwnerID" />
      <Map Name="OrderNum" Column="OrderNum" />
      <Map Name="EventTime" Column="EventTime" />
      <Map Name="Status" Column="Status" />
      <Map Name="ErrorText" Column="ErrorText" />
    </Table>
  </DbMapping>
</Entity>