<odoo>
    <data>
        <!--Показатели. Пункт меню.-->
        <record id="mklab_base_indicators.hypergraph_index_window" model="ir.actions.act_window">
            <field name="name">Показатели</field>
            <field name="res_model">hg.index</field>
            <field name="view_mode">list,form</field>
        </record>
        <!--Показатели. Форма.-->
        <record id="mklab_base_indicators.hypergraph_index_view_form" model="ir.ui.view">
            <field name="name">hg.index.form</field>
            <field name="model">hg.index</field>
            <field name="arch" type="xml">
                <form name="index">
                    <sheet>
                        <group>
                            <group string="Показатель">
                                <field name="name"/>
                                <field name="internal_code_id"/>
                                <field name="external_code"/>
                                <field name="public"/>
                                <field name="node_id"/>
                                <field name="current_value"/>
                            </group>
                            <notebook>
                                <page string="Значения" name="choose_values">
                                    <field name="value_ids">
                                        <list editable="bottom" limit="10">
                                            <field name="value_float_actual"/>
                                            <field name="value_float_plan"/>
                                            <field name="date_due"/>
                                            <field name="type"/>
                                            <field name="formula"/>
                                        </list>
                                    </field>
                                </page>
                            </notebook>
                        </group>
                    </sheet>
                </form>
            </field>
        </record>
        <!--Показатели. Список.-->
        <record id="mklab_base_indicators.hypergraph_index_view_list" model="ir.ui.view">
            <field name="name">hg.index.list</field>
            <field name="model">hg.index</field>
            <field name="arch" type="xml">
                <list>
                    <field name="name"/>
                    <field name="internal_code_id"/>
                    <field name="external_code"/>
                    <field name="public"/>
                    <field name="current_value"></field>
                </list>
            </field>
        </record>
        <!--Вершины графа. Пункт меню.-->
        <record id="mklab_base_indicators.hypergraph_node_window" model="ir.actions.act_window">
            <field name="name">Вершины графа</field>
            <field name="res_model">hg.node</field>
            <field name="view_mode">list,form</field>
        </record>
        <!--Вершины графа. Форма.-->
        <record id="mklab_base_indicators.hypergraph_node_view_form" model="ir.ui.view">
            <field name="name">hg.node.form</field>
            <field name="model">hg.node</field>
            <field name="arch" type="xml">
                <form name="node">
                    <sheet>
                        <group>
                            <group string="Вершина графа">
                                <field name="name"/>
                                <field name="res_id"/>
                                <field name="res_model"/>
                            </group>
                        </group>
                    </sheet>
                </form>
            </field>
        </record>

        <!--Вершины графа. Список.-->
        <record id="mklab_base_indicators.hypergraph_node_view_list" model="ir.ui.view">
            <field name="name">hg.node.list</field>
            <field name="model">hg.node</field>
            <field name="arch" type="xml">
                <list>
                    <field name="name"/>
                    <field name="res_id"/>
                    <field name="res_model"/>
                </list>
            </field>
        </record>

        <!--Матрица связности. Пункт меню.-->
        <record id="mklab_base_indicators.hypergraph_matrix_window" model="ir.actions.act_window">
            <field name="name">Матрица связности</field>
            <field name="res_model">hg.link</field>
            <field name="view_mode">list,form</field>
        </record>

        <!--Матрица связности. Форма.-->
        <record id="mklab_base_indicators.hypergraph_matrix_view_form" model="ir.ui.view">
            <field name="name">hg.link.form</field>
            <field name="model">hg.link</field>
            <field name="arch" type="xml">
                <form name="matrix">
                    <sheet>
                        <group>
                            <group string="Матрица связности">
                                <field name="source_id" widget="selection"/>
                                <field name="target_ids" widget="many2many_tags"/>
                            </group>
                        </group>
                    </sheet>
                </form>
            </field>
        </record>

        <!--Матрица связности. Список.-->
        <record id="mklab_base_indicators.hypergraph_matrix_view_list" model="ir.ui.view">
            <field name="name">hg.link.list</field>
            <field name="model">hg.link</field>
            <field name="arch" type="xml">
                <list>
                    <field name="id"/>
                    <field name="name"/>
                    <field name="source_id"/>
                    <field name="target_ids"/>
                </list>
            </field>
        </record>

        <!--Значение показателей. Пункт меню.-->
        <record id="mklab_base_indicators.hypergraph_shows_keys_window" model="ir.actions.act_window">
            <field name="name">Значения показателей</field>
            <field name="res_model">hg.value</field>
            <field name="view_mode">list,form</field>
        </record>

        <!--Значения показателей. Форма.-->
        <record id="mklab_base_indicators.hypergraph_keys_view_form" model="ir.ui.view">
            <field name="name">hg.value.form</field>
            <field name="model">hg.value</field>
            <field name="arch" type="xml">
                <form name="keys">
                    <sheet>
                        <group>
                            <group string="Показатели">
                                <field name="value_float_actual"/>
                                <field name="value_float_plan"/>
                                <field name="date_due"/>
                                <field name="type"/>
                                <field name="formula"/>
                            </group>
                        </group>
                    </sheet>
                </form>
            </field>
        </record>

        <!--Значение показателей. Список.-->
        <record id="mklab_base_indicators.hypergraph_keys_view_list" model="ir.ui.view">
            <field name="name">hg.value.list</field>
            <field name="model">hg.value</field>
            <field name="arch" type="xml">
                <list>
                    <field name="value_float_actual"/>
                    <field name="value_float_plan"/>
                    <field name="date_due"/>
                    <field name="type"/>
                    <field name="formula"/>
                </list>
            </field>
        </record>

        <!--Внутренний код. Пункт меню.-->
        <record id="mklab_base_indicators.hypergraph_index_code_window" model="ir.actions.act_window">
            <field name="name">Внутренний показатель</field>
            <field name="res_model">hg.index.code</field>
            <field name="view_mode">list,form</field>
        </record>

        <!--Внутренний код. Список.-->
        <record id="mklab_base_indicators.hypergraph_index_code_view_form" model="ir.ui.view">
            <field name="name">hg.index.code.form</field>
            <field name="model">hg.index.code</field>
            <field name="arch" type="xml">
                <form>
                    <sheet>
                        <group>
                            <group>
                                <field name="name"/>
                            </group>
                        </group>
                    </sheet>
                </form>
            </field>
        </record>

        <!--Внутренний код. Список.-->
        <record id="mklab_base_indicators.hypergraph_index_code_view_list" model="ir.ui.view">
            <field name="name">hg.index.code.list</field>
            <field name="model">hg.index.code</field>
            <field name="arch" type="xml">
                <list>
                    <field name="name"/>
                </list>
            </field>
        </record>


        <menuitem name="Слои показателей" id="hypergraph_base_menu_root"
                  web_icon="mklab_base_indicators,static/description/icon.png"/>
        <menuitem name="Граф" id="hypergraph_base_menu_graph_list" parent="hypergraph_base_menu_root"
                  action="mklab_base_indicators.hypergraph_matrix_window"/>
        <menuitem name="Вершины графа" id="hypergraph_base_graph_head" parent="hypergraph_base_menu_graph_list"
                  action="mklab_base_indicators.hypergraph_node_window"/>
        <menuitem name="Матрица связности" id="hypergraph_base_conn_matrix" parent="hypergraph_base_menu_graph_list"
                  action="mklab_base_indicators.hypergraph_matrix_window"/>
        <menuitem name="Показатели" id="hypergraph_base_shows_list" parent="hypergraph_base_menu_root"
                  action="mklab_base_indicators.hypergraph_matrix_window"/>
        <menuitem name="Показатели" id="hypergraph_base_shows_keys" parent="hypergraph_base_shows_list"
                  action="mklab_base_indicators.hypergraph_index_window"/>
        <menuitem name="Значения показателей" id="hypergraph_base_shows_values" parent="hypergraph_base_shows_list"
                  action="mklab_base_indicators.hypergraph_shows_keys_window"/>
        <menuitem name="Внутренний код" id="hypergraph_base_index_code" parent="hypergraph_base_shows_list"
                  action="mklab_base_indicators.hypergraph_index_code_window"/>
    </data>
</odoo>