<?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.by4cloud.platformx.business.mapper.PaymentCreditMapper">
|
|
<resultMap id="paymentReceiveMap" type="com.by4cloud.platformx.business.entity.PaymentCreditSale">
|
<id property="id" column="id"/>
|
<result property="compId" column="comp_id"/>
|
<result property="creditAmount" column="receive_amount"/>
|
<result property="creditDate" column="receive_date"/>
|
</resultMap>
|
<select id="genReceivePayment" resultType="java.math.BigDecimal">
|
SELECT IFNULL(sum(unit_price*(out_bound_num-advance_num-invoice_num)),0) from contract_out_bound
|
where del_flag='0'
|
<if test="compId!=null">
|
AND comp_id = #{compId}
|
</if>
|
</select>
|
<select id="genReceivePaymentSmj" resultType="java.math.BigDecimal">
|
SELECT IFNULL(sum(unit_price*(out_bound_num-advance_num-invoice_num)),0) from contract_out_bound
|
where del_flag='0'
|
AND (comp_id = 2089995177814495234 or comp_id = 2089996921978040321 or comp_id = 2089997578009128962 or
|
comp_id = 2101966257365045249)
|
</select>
|
</mapper>
|