<?xml version="1.0"?>
<!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping>
    <class name="com.arrebol.taxiservicios.model.view.report.PaymentClient" table="PAYMENT_CLIENT" 
           catalog="crov_spa" mutable="false">
        <id name="id" type="string">
            <column name="id" length="36"/>
            <generator class="assigned"></generator>
        </id>
        <many-to-one class="com.arrebol.taxiservicios.model.admin.Taxi" fetch="select" name="taxi">
            <column length="36" name="id_taxi"/>
        </many-to-one>
        <property name="activeStatus" column="active_status" not-null="true">
            <type name="org.hibernate.type.EnumType">
                <param name="enumClass">com.arrebol.taxiservicios.model.enums.BasicType</param>
                <param name="useNamed">true</param>
            </type>
        </property>   
        <property name="actionStatus" column="action_status" not-null="true">
            <type name="org.hibernate.type.EnumType">
                <param name="enumClass">com.arrebol.taxiservicios.model.enums.ActionStatus</param>
                <param name="useNamed">true</param>
            </type>
        </property> 
        <property name="amountToPay" type="double">
            <column name="amount_to_pay"/>
        </property>
        <property name="discount" type="double">
            <column name="discount"/>
        </property>
        <property name="commentsDiscount" type="string">
            <column length="500" name="comments_discount"/>
        </property>
        <property name="increase" type="double">
            <column name="increase"/>
        </property>
        <property name="commentsIncrease" type="string">
            <column length="500" name="comments_increase"/>
        </property>
        <property name="totalPayment" type="double">
            <column name="total_payment"/>
        </property>
        <property name="initDate" type="timestamp">
            <column length="19" name="init_date"/>
        </property>
        <property name="endDate" type="timestamp">
            <column length="19" name="end_date"/>
        </property>
        <property name="nextPaymentDate" type="timestamp">
            <column length="19" name="next_payment_date"/>
        </property>
        <property name="comments" type="string">
            <column length="500" name="comments"/>
        </property>
        <many-to-one name="createdBy" class="com.arrebol.taxiservicios.model.core.User" not-null="true" fetch="select">
            <column name="created_by" length="36" not-null="true"/>
        </many-to-one>
        <property name="createdOn" type="timestamp">
            <column length="19" name="created_on"/>
        </property>
        <many-to-one name="lastUpdatedBy" class="com.arrebol.taxiservicios.model.core.User" fetch="select">
            <column name="last_updated_by" length="36"/>
        </many-to-one>
        <property name="lastUpdatedOn" type="timestamp">
            <column length="19" name="last_updated_on" />
        </property>
        
        <property name="diasSeguroVentas" type="int">
            <column name="dias_seguro_ventas"/>
        </property>
        <property name="pagoSeguroVentas" type="float">
            <column name="pago_seguro_ventas"/>
        </property>
        
        <property name="totalContrato" type="float">
            <column name="total_contrato"/>
        </property>
        <property name="incrementoContrato" type="float">
            <column name="incremento_contrato"/>
        </property>
        <property name="descuentoContrato" type="float">
            <column name="descuento_contrato"/>
        </property>
        
        <property name="abonoAdeudo" type="double">
            <column name="abono_adeudo"/>
        </property>
        <property name="paid" column="paid" not-null="true">
            <type name="org.hibernate.type.EnumType">
                <param name="enumClass">com.arrebol.taxiservicios.model.enums.BasicType</param>
                <param name="useNamed">true</param>
            </type>
        </property> 
        <many-to-one class="com.arrebol.taxiservicios.model.catalog.Location" fetch="select" name="locationSend">
            <column length="36" name="id_location_send" not-null="false"/>
        </many-to-one>
        
         <property name="amountToCharge" type="float">
            <column name="amount_to_Charge"/>
        </property>
        
        <many-to-one class="com.arrebol.taxiservicios.model.catalog.Location" fetch="select" name="location">
            <column length="36" name="id_location" not-null="false"/>
        </many-to-one>
        
        <property name="descuentoPago" type="float">
            <column name="descuento_pago"/>
        </property>
        
        <property name="incrementoPago" type="float">
            <column name="incremento_pago"/>
        </property>
        
        <property name="descuentoPagoComentario" type="string">
            <column length="500" name="descuento_pago_comment"/>
        </property>
        <property name="incrementoPagoComentario" type="string">
            <column length="500" name="incremento_pago_comment"/>
        </property>
        
        <many-to-one class="com.arrebol.taxiservicios.model.catalog.BankCard" fetch="select" name="bankCard">
            <column length="36" name="id_bank_card" not-null="false"/>
        </many-to-one>
        
        <property name="depositStatus" column="deposit_status" not-null="true">
            <type name="org.hibernate.type.EnumType">
                <param name="enumClass">com.arrebol.taxiservicios.model.enums.ExpenseStatusType</param>
                <param name="useNamed">true</param>
            </type>
        </property>
    </class>
</hibernate-mapping>