<?xml version="1.0" encoding="UTF-8"?>
<!--
 * This file is part of FacturaScripts
 * Copyright (C) 2017-2024 Carlos Garcia Gomez <carlos@facturascripts.com>
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Lesser General Public License as
 * published by the Free Software Foundation, either version 3 of the
 * License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with this program. If not, see <http://www.gnu.org/licenses/>.
 *
 * @author Jose Antonio Cuello Principal <yopli2000@gmail.com>
 * @author Carlos García Gómez  <carlos@facturascripts.com>
-->
<view>
    <columns>
        <group name="period" numcolumns="12">
            <column name="id" display="none" order="100">
                <widget type="text" fieldname="idregiva"/>
            </column>
            <column name="company" titleurl="ListEmpresa" order="110">
                <widget type="select" fieldname="idempresa" onclick="EditEmpresa" readonly="dinamic"
                        required="true">
                    <values source="empresas" fieldcode="idempresa" fieldtitle="nombrecorto"/>
                </widget>
            </column>
            <column name="exercise" order="120">
                <widget type="select" fieldname="codejercicio" onclick="EditEjercicio" parent="idempresa" readonly="dinamic" required="true">
                    <values source="ejercicios" fieldcode="codejercicio" fieldtitle="nombre" fieldfilter="idempresa"/>
                </widget>
            </column>
            <column name="period" order="130">
                <widget type="select" fieldname="periodo" readonly="dinamic" required="true" translate="true">
                    <values title="first-quarter">T1</values>
                    <values title="second-quarter">T2</values>
                    <values title="third-quarter">T3</values>
                    <values title="fourth-quarter">T4</values>
                    <values title="year-model-390">Y</values>
                    <values title="january">01</values>
                    <values title="february">02</values>
                    <values title="march">03</values>
                    <values title="april">04</values>
                    <values title="may">05</values>
                    <values title="june">06</values>
                    <values title="july">07</values>
                    <values title="august">08</values>
                    <values title="september">09</values>
                    <values title="october">10</values>
                    <values title="november">11</values>
                    <values title="december">12</values>
                </widget>
            </column>
            <column name="start-date" order="140">
                <widget type="date" fieldname="fechainicio" readonly="true"/>
            </column>
            <column name="end-date" order="150">
                <widget type="date" fieldname="fechafin" readonly="true"/>
            </column>
        </group>
        <group name="accounting" valign="bottom" numcolumns="12">
            <column name="tax-credit-account" order="100">
                <widget type="autocomplete" fieldname="codsubcuentaacr">
                    <values source="subcuentas" fieldcode="codsubcuenta" fieldtitle="codsubcuenta"
                            fieldfilter="codejercicio"/>
                </widget>
            </column>
            <column name="tax-debit-account" order="110">
                <widget type="autocomplete" fieldname="codsubcuentadeu">
                    <values source="subcuentas" fieldcode="codsubcuenta" fieldtitle="codsubcuenta"
                            fieldfilter="codejercicio"/>
                </widget>
            </column>
            <column name="accounting-entry" order="120">
                <widget type="autocomplete" fieldname="idasiento" onclick="EditAsiento" readonly="true">
                    <values source="asientos" fieldcode="idasiento" fieldtitle="numero"/>
                </widget>
            </column>
            <column name="accounting-date" order="130">
                <widget type="date" fieldname="fechaasiento" readonly="true"/>
            </column>
            <column name="lock-accounting" order="140">
                <widget type="checkbox" fieldname="bloquear"/>
            </column>
        </group>
    </columns>
</view>