﻿<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
	elementFormDefault="qualified">
	<xs:complexType name="ObjectOfControlType">
		<xs:annotation>
			<xs:documentation>Тип - объект контроля</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element name="title" type="xs:string">
				<xs:annotation>
					<xs:documentation>Название</xs:documentation>
				</xs:annotation>
			</xs:element>
		</xs:sequence>
	</xs:complexType>
	<xs:complexType name="ControlActionType">
		<xs:annotation>
			<xs:documentation>Тип - контрольное или экспертно-аналитическое мероприятие</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element name="objectsOfControl">
				<xs:annotation>
					<xs:documentation>Объекты контроля</xs:documentation>
				</xs:annotation>
				<xs:complexType>
					<xs:sequence maxOccurs="unbounded" minOccurs="0">
						<xs:element name="objectOfControl" type="ObjectOfControlType">
							<xs:annotation>
								<xs:documentation>Объект контроля</xs:documentation>
							</xs:annotation>
						</xs:element>
					</xs:sequence>
				</xs:complexType>
			</xs:element>
			<xs:element name="title" type="xs:string">
				<xs:annotation>
					<xs:documentation>Наименование</xs:documentation>
				</xs:annotation>
			</xs:element>
			<xs:element name="startDate" type="xs:date">
				<xs:annotation>
					<xs:documentation>Дата начала</xs:documentation>
				</xs:annotation>
			</xs:element>
			<xs:element name="endDate" type="xs:date">
				<xs:annotation>
					<xs:documentation>Дата окончания</xs:documentation>
				</xs:annotation>
			</xs:element>
			<xs:element name="violationsNumber" type="xs:int">
				<xs:annotation>
					<xs:documentation>Колличество выявленных нарушений
					</xs:documentation>
				</xs:annotation>
			</xs:element>
			<xs:element name="violationsRevealedAmount" type="xs:double">
				<xs:annotation>
					<xs:documentation>Финансовая оценка выявленных нарушений (тыс.
						руб.)
					</xs:documentation>
				</xs:annotation>
			</xs:element>
		</xs:sequence>
	</xs:complexType>
	<xs:complexType name="ControlActivityType">
		<xs:annotation>
			<xs:documentation>Тип - контрольная деятельность</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element name="workYear" type="xs:int">
				<xs:annotation>
					<xs:documentation>Рабочий год</xs:documentation>
				</xs:annotation>
			</xs:element>
			<xs:element name="controlActions">
				<xs:annotation>
					<xs:documentation>Контрольные и экспертно-аналитические мероприятия</xs:documentation>
				</xs:annotation>
				<xs:complexType>
					<xs:sequence maxOccurs="unbounded" minOccurs="0">
						<xs:element name="controlAction" type="ControlActionType">
							<xs:annotation>
								<xs:documentation>Контрольные и экспертно-аналитические мероприятия</xs:documentation>
							</xs:annotation>
						</xs:element>
					</xs:sequence>
				</xs:complexType>
			</xs:element>
		</xs:sequence>
	</xs:complexType>
	<xs:element name="controlActivity" type="ControlActivityType">
		<xs:annotation>
			<xs:documentation>Контрольная деятельность</xs:documentation>
		</xs:annotation>
	</xs:element>
</xs:schema>

