yys
2 天以前 bf84fec7d8dd5e7fbcc93030b8d83da7ec0ece91
src/main/resources/mapper/sales/SalesLedgerProductMapper.xml
@@ -8,7 +8,7 @@
        SELECT
        T1.*,
        CASE
        WHEN t2.qualitity > T1.quantity THEN 1
        WHEN sum(t2.qualitity) > T1.quantity THEN 1
        ELSE 0
        END as has_sufficient_stock
        FROM
@@ -23,6 +23,7 @@
                AND T1.type = #{salesLedgerProduct.type}
            </if>
        </where>
        group by T1.id
        ORDER BY T1.register_date DESC
    </select>
    <select id="selectSalesLedgerProductByMainId" resultType="com.ruoyi.sales.pojo.SalesLedgerProduct">
@@ -97,7 +98,7 @@
                AND slp.product_category like concat('%',#{req.productCategory},'%')
            </if>
            <if test="req.status != null and req.status ">
                AND slp.pending_invoice_total &gt; 0
                AND slp.pending_tickets_total &gt; 0
            </if>
        </where>
        order by slp.register_date desc