<?xml version="1.0" encoding="UTF-8"?>
<!--
 * This file is part of Servicios plugin FacturaScripts
 * Copyright (C) 2020-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 Carlos García Gómez <carlos@facturascripts.com>
-->
<view>
    <columns>
        <group name="data" numcolumns="12">
            <column name="code" display="none" order="100">
                <widget type="text" fieldname="idtrabajo"/>
            </column>
            <column name="service" numcolumns="2" order="110">
                <widget type="autocomplete" fieldname="idservicio" onclick="EditServicioAT">
                    <values source="serviciosat" fieldcode="idservicio"/>
                </widget>
            </column>
            <column name="from-date" numcolumns="2" order="120">
                <widget type="date" fieldname="fechainicio" required="true"/>
            </column>
            <column name="from-hour" numcolumns="2" order="130">
                <widget type="time" fieldname="horainicio" required="true"/>
            </column>
            <column name="until-date" numcolumns="2" order="140">
                <widget type="date" fieldname="fechafin"/>
            </column>
            <column name="until-hour" numcolumns="2" order="150">
                <widget type="time" fieldname="horafin"/>
            </column>
            <column name="user" order="160">
                <widget type="select" fieldname="nick">
                    <values source="users" fieldcode="nick" fieldtitle="nick"/>
                </widget>
            </column>
            <column name="agent" titleurl="ListAgente" order="170">
                <widget type="select" fieldname="codagente" onclick="EditAgente">
                    <values source="agentes" fieldcode="codagente" fieldtitle="nombre"/>
                </widget>
            </column>
            <column name="observations" numcolumns="12" order="180">
                <widget type="textarea" fieldname="observaciones" rows="1"/>
            </column>
        </group>
        <group name="invoice" title="invoice" numcolumns="12">
            <column name="reference" titleurl="ListProducto" numcolumns="2" order="100">
                <widget type="variante" fieldname="referencia"/>
            </column>
            <column name="description" description="optional-or-product" numcolumns="4" order="110">
                <widget type="textarea" fieldname="descripcion" rows="1"/>
            </column>
            <column name="quantity" numcolumns="2" order="120">
                <widget type="number" fieldname="cantidad"/>
            </column>
            <column name="price" description="optional" numcolumns="2" order="130">
                <widget type="money" fieldname="precio"/>
            </column>
            <column name="action" numcolumns="2" order="140">
                <widget type="select" fieldname="estado" translate="true" required="true">
                    <values/>
                </widget>
            </column>
        </group>
    </columns>
</view>