<?xml version="1.0" encoding="UTF-8"?>
<!--
 * This file is part of FacturaScripts
 * Copyright (C) 2017-2023 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 Carlos García Gómez  <carlos@facturascripts.com>
 * @author Artex Trading sa     <jcuello@artextrading.com>
-->
<view>
    <columns>
        <column name="id" display="none" order="90">
            <widget type="text" fieldname="idasiento" onclick="EditAsiento"/>
        </column>
        <column name="number" order="100">
            <widget type="text" fieldname="numero"/>
        </column>
        <column name="company" display="none" order="110">
            <widget type="select" fieldname="idempresa">
                <values source="empresas" fieldcode="idempresa" fieldtitle="nombrecorto"/>
            </widget>
        </column>
        <column name="exercise" order="120">
            <widget type="select" fieldname="codejercicio">
                <values source="ejercicios" fieldcode="codejercicio" fieldtitle="nombre"/>
            </widget>
        </column>
        <column name="journal" display="none" order="130">
            <widget type="select" fieldname="iddiario" onclick="EditDiario">
                <values source="diarios" fieldcode="iddiario" fieldtitle="descripcion"/>
            </widget>
        </column>
        <column name="channel" display="none" order="140">
            <widget type="number" decimal="0" fieldname="canal"/>
        </column>
        <column name="accounting-concept" order="150">
            <widget type="text" fieldname="concepto"/>
        </column>
        <column name="amount" display="right" order="160">
            <widget type="money" fieldname="importe">
                <option color="danger">lt:0</option>
            </widget>
        </column>
        <column name="date" display="right" order="170">
            <widget type="date" fieldname="fecha"/>
        </column>
    </columns>
    <modals>
        <group name="renumber" title="renumber-accounting" icon="fa-solid fa-sort-numeric-down">
            <column name="exercise" description="renumber-accounting-p">
                <widget type="select" fieldname="exercise" required="true">
                    <values source="ejercicios" fieldcode="codejercicio"/>
                </widget>
            </column>
        </group>
    </modals>
    <rows>
        <row type="status">
            <option color="secondary" title="special-accounting-entries" fieldname="operacion">notnull:</option>
            <option color="warning" title="non-editable-accounting-entry" fieldname="editable">0</option>
            <option color="info" title="invoice" fieldname="documento">neq:</option>
        </row>
    </rows>
</view>