<?xml version="1.0" encoding="utf-8"?>
<Entity 
Schema="STOR" 
Name="IMPORT_CONTRACT" 
Description="Загрузка гос. контрактов" 
Inherits="STOR.IMPORT_ELEMENTS">
  <Fields>
    <Attribute Name="SupplierContractID" Index="5420001" Type="guid" Description="Идентификатор контракта" />
    <Attribute Name="Date" Index="5420002" Type="date" Description="Дата договора" />
    <Attribute Name="Number" Index="5420003" Type="string" Description="Номер договора" />
    <Attribute Name="Comment" Index="5420004" Type="string" Description="Комментарий" CharacterMaximumLength="4096" />
    <Attribute Name="Amount" Index="5420008" Type="float" DefaultFormat="{0:F3}" Description="Количество" NumericPrecision="12" NumericScale="2" />
    <Attribute Name="Price" Index="5420009" Type="float" DefaultFormat="{0:F2}" Description="Цена" NumericPrecision="12" NumericScale="2" />
    <Attribute Name="Sum" Index="5420010" Type="float" DefaultFormat="{0:F2}" Description="Сумма" NumericPrecision="18" NumericScale="2" />
    <Attribute Name="LotNumber" Index="5420011" Type="int" Description="Номер лота" />
    <Attribute Name="OtherID" Index="5420014" Type="int" Description="ID в других программах" />
    <Attribute Name="PayType" Index="5420015" Type="string" Description="Вид оплаты" />
    <Attribute Name="Abr" Index="5420016" Type="string" Description="Аббревиатура" />
    <Parent Name="GoodsSupplier" Index="5420005" Type="STOR.GOODS_SUPPLIER" Description="Поставщик товара" />
    <Parent Name="PaymentType" Index="5420006" Type="STOR.PAYMENT_TYPE" Description="Источник финансирования" />
    <Parent Name="PackageType" Index="5420012" Type="PHARM.PACKAGE_TYPE" Description="Вид упаковки" />
    <Parent Name="BillOfGoods" Index="5420013" Type="PHARM.BILL_OF_GOODS" Description="Номенклатура товаров" />
    <Choice Name="VAT" Description="НДС">
      <Item Name="Без НДС" Index="0" />
      <Item Name="10%" Index="1" />
      <Item Name="18%" Index="2" />
      <Item Name="20%" Index="3" />
      <Item Name="5%" Index="4" />
      <Item Name="7%" Index="5" />
      <Item Name="22%" Index="6" />
    </Choice>
    <Attribute Name="gtin" Type="string" Description="gtin" CharacterMaximumLength="14" />
    <Attribute Name="sgtin" Type="string" Description="sgtin" CharacterMaximumLength="28" />
  </Fields>
  <DbMapping>
    <Table name="T_IMPORT_CONTRACT">
      <Map Name="SupplierContractID" Column="SupplierContractID" />
      <Map Name="Date" Column="Date" />
      <Map Name="Number" Column="Number" />
      <Map Name="Comment" Column="Comment" />
      <Map Name="Amount" Column="Amount" />
      <Map Name="Price" Column="Price" />
      <Map Name="Sum" Column="Sum" />
      <Map Name="LotNumber" Column="LotNumber" />
      <Map Name="OtherID" Column="OtherID" />
      <Map Name="PayType" Column="PayType" />
      <Map Name="Abr" Column="Abr" />
      <Map Name="GoodsSupplier" Column="GoodsSupplier" />
      <Map Name="PaymentType" Column="PaymentType" />
      <Map Name="PackageType" Column="PackageType" />
      <Map Name="BillOfGoods" Column="BillOfGoods" />
      <Map Name="VAT" Column="VAT" />
      <Map Name="gtin" Column="gtin" />
      <Map Name="sgtin" Column="sgtin" />
    </Table>
  </DbMapping>
</Entity>