<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.njzscloud.dispose.finance.mapper.ExpenseItemMapper">

    <select id="paging" resultType="com.njzscloud.dispose.finance.pojo.result.SearchExpenseItemResult">
        SELECT
        a.id,
        a.user_id,
        a.customer_id,
        a.org_id,
        a.station_id,
        a.goods_id,
        a.expense_item_category,
        a.expense_item_name,
        a.expense_strategy,
        a.unit,
        a.tax_rate,
        a.unit_price,
        a.initial_price,
        a.initial_quantity,
        a.every_quantity,
        a.canuse,
        a.memo,
        a.creator_id,
        a.modifier_id,
        a.create_time,
        a.modify_time,
        a.deleted,
        b.goods_name
        FROM fin_expense_item a
        LEFT JOIN gds_goods b ON b.id = a.goods_id
        <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''">
            ${ew.customSqlSegment}
        </if>
    </select>
</mapper>
