|
@@ -706,22 +706,21 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
<select id="selectByMainId" resultMap="MainMap">
|
|
<select id="selectByMainId" resultMap="MainMap">
|
|
|
- select b.id,b.check_no,b.total_amount,b.amount,b.order_no,o.contract_no,b.aname,b.apply_dep,b.pay_dep,b.real_amount,b.type_other ,b.aid,
|
|
|
|
|
|
|
+ select b.id,b.check_no,b.total_amount,b.amount,b.aname,b.apply_dep,b.pay_dep,b.real_amount,b.type_other ,b.aid,
|
|
|
date_format(b.create_time,'%Y-%m-%d %H:%i:%S')createTimeStr,b.examine_name, dep.name applyDepName,dep2.name payDepName,
|
|
date_format(b.create_time,'%Y-%m-%d %H:%i:%S')createTimeStr,b.examine_name, dep.name applyDepName,dep2.name payDepName,
|
|
|
b.remarks,b.eaaid ,eap.name ,eap.bank ,eap.accounts ,b.status,b.process_status,
|
|
b.remarks,b.eaaid ,eap.name ,eap.bank ,eap.accounts ,b.status,b.process_status,
|
|
|
c.id sonId,c.total_amount sonTotalAmount,c.settlement_amount sonSettlementAmount,c.amount sonAmount, c.`type` sonType,c.type_other sonTypeOther,
|
|
c.id sonId,c.total_amount sonTotalAmount,c.settlement_amount sonSettlementAmount,c.amount sonAmount, c.`type` sonType,c.type_other sonTypeOther,
|
|
|
c.user_names ,c.release_start ,c.release_end , c.district_name districtName,c.user_names userNames,c.secondary_type ,c.secondary_type_other,c.attachment_url,
|
|
c.user_names ,c.release_start ,c.release_end , c.district_name districtName,c.user_names userNames,c.secondary_type ,c.secondary_type_other,c.attachment_url,
|
|
|
- c.duration,pr.plan,pro.contract_no sonContractNo,c.real_amount sonRealAmount,
|
|
|
|
|
|
|
+ c.duration,pr.plan,c.real_amount sonRealAmount,o.order_no,o.contract_no,pr.type publicReleaseType,
|
|
|
c.debit_id debitId, debit.real_amount DebitRealAmount ,debit.settlement_amount DebitSettlementAmount,debit.liquidation_status DebitliquidationStatus,
|
|
c.debit_id debitId, debit.real_amount DebitRealAmount ,debit.settlement_amount DebitSettlementAmount,debit.liquidation_status DebitliquidationStatus,
|
|
|
d.id detId,d.`type` detType,d.amount detAmount,d.real_amount detRealAmount ,d.start_district ,d.end_district,d.vehicle,d.vehicle_other,
|
|
d.id detId,d.`type` detType,d.amount detAmount,d.real_amount detRealAmount ,d.start_district ,d.end_district,d.vehicle,d.vehicle_other,
|
|
|
d.pay_type ,d.invoice_type ,d.invoice_no,d.payer_name ,d.open_bank ,d.bank_accounts ,d.open_bank_address,d.type_other detTypeOther,
|
|
d.pay_type ,d.invoice_type ,d.invoice_no,d.payer_name ,d.open_bank ,d.bank_accounts ,d.open_bank_address,d.type_other detTypeOther,
|
|
|
date_format(d.start_time,'%Y-%m-%d %H:%i:%S')startTime,date_format(d.end_time,'%Y-%m-%d %H:%i:%S')endTime,
|
|
date_format(d.start_time,'%Y-%m-%d %H:%i:%S')startTime,date_format(d.end_time,'%Y-%m-%d %H:%i:%S')endTime,
|
|
|
date_format(d.agree_time,'%Y-%m-%d')agreeTime
|
|
date_format(d.agree_time,'%Y-%m-%d')agreeTime
|
|
|
- from expense_relationship a left join expense_account b on a.id =b.id
|
|
|
|
|
|
|
+ from expense_relationship a left join expense_account b on a.id =b.id left join expense_account c on a.ea_id =c.id
|
|
|
left join department dep on b.apply_dep =dep.id left join department dep2 on b.pay_dep =dep2.id
|
|
left join department dep on b.apply_dep =dep.id left join department dep2 on b.pay_dep =dep2.id
|
|
|
- left join t_order_new o on b.order_no =o.order_no left join expense_account_private eap on b.eaaid =eap.id
|
|
|
|
|
- left join expense_account c on a.ea_id =c.id left join expense_account_details d on c.id =d.eaid
|
|
|
|
|
- left join public_release pr on c.prid=pr.id left join t_order_new pro on pr.order_no=pro.order_no
|
|
|
|
|
|
|
+ left join expense_account_private eap on b.eaaid =eap.id left join expense_account_details d on c.id =d.eaid
|
|
|
|
|
+ left join t_order_new o on c.order_no =o.order_no left join public_release pr on c.prid=pr.id left join t_order_new pro on pr.order_no=pro.order_no
|
|
|
left join expense_account debit on c.debit_id=debit.id
|
|
left join expense_account debit on c.debit_id=debit.id
|
|
|
where a.id= #{id}
|
|
where a.id= #{id}
|
|
|
</select>
|
|
</select>
|
|
@@ -742,8 +741,6 @@
|
|
|
<result column="total_amount" jdbcType="DECIMAL" property="totalAmount" />
|
|
<result column="total_amount" jdbcType="DECIMAL" property="totalAmount" />
|
|
|
<result column="real_amount" jdbcType="DECIMAL" property="realAmount" />
|
|
<result column="real_amount" jdbcType="DECIMAL" property="realAmount" />
|
|
|
<result column="amount" jdbcType="DECIMAL" property="amount" />
|
|
<result column="amount" jdbcType="DECIMAL" property="amount" />
|
|
|
- <result column="order_no" jdbcType="VARCHAR" property="orderNo" />
|
|
|
|
|
- <result column="contract_no" jdbcType="VARCHAR" property="contractNo" />
|
|
|
|
|
<result column="aname" jdbcType="VARCHAR" property="aname" />
|
|
<result column="aname" jdbcType="VARCHAR" property="aname" />
|
|
|
<result column="apply_dep" jdbcType="VARCHAR" property="applyDep" />
|
|
<result column="apply_dep" jdbcType="VARCHAR" property="applyDep" />
|
|
|
<result column="pay_dep" jdbcType="VARCHAR" property="payDep" />
|
|
<result column="pay_dep" jdbcType="VARCHAR" property="payDep" />
|
|
@@ -778,11 +775,13 @@
|
|
|
<result column="districtName" jdbcType="VARCHAR" property="districtName" />
|
|
<result column="districtName" jdbcType="VARCHAR" property="districtName" />
|
|
|
<result column="duration" jdbcType="VARCHAR" property="duration" />
|
|
<result column="duration" jdbcType="VARCHAR" property="duration" />
|
|
|
<result column="plan" jdbcType="VARCHAR" property="plan" />
|
|
<result column="plan" jdbcType="VARCHAR" property="plan" />
|
|
|
- <result column="sonContractNo" jdbcType="VARCHAR" property="contractNo" />
|
|
|
|
|
<result column="debitId" jdbcType="INTEGER" property="debitId" />
|
|
<result column="debitId" jdbcType="INTEGER" property="debitId" />
|
|
|
<result column="debitRealAmount" jdbcType="DECIMAL" property="debitRealAmount" />
|
|
<result column="debitRealAmount" jdbcType="DECIMAL" property="debitRealAmount" />
|
|
|
<result column="debitSettlementAmount" jdbcType="DECIMAL" property="debitSettlementAmount" />
|
|
<result column="debitSettlementAmount" jdbcType="DECIMAL" property="debitSettlementAmount" />
|
|
|
<result column="debitLiquidationStatus" jdbcType="INTEGER" property="debitLiquidationStatus" />
|
|
<result column="debitLiquidationStatus" jdbcType="INTEGER" property="debitLiquidationStatus" />
|
|
|
|
|
+ <result column="order_no" jdbcType="VARCHAR" property="orderNo" />
|
|
|
|
|
+ <result column="contract_no" jdbcType="VARCHAR" property="contractNo" />
|
|
|
|
|
+ <result column="publicReleaseType" jdbcType="INTEGER" property="publicReleaseType" />
|
|
|
<association property="detList" resultMap="ExpenseAccountDetailsMap"></association>
|
|
<association property="detList" resultMap="ExpenseAccountDetailsMap"></association>
|
|
|
</resultMap>
|
|
</resultMap>
|
|
|
|
|
|
|
@@ -909,7 +908,7 @@
|
|
|
</if>
|
|
</if>
|
|
|
<if test="listStatus ==1">
|
|
<if test="listStatus ==1">
|
|
|
and b.process_status > 3
|
|
and b.process_status > 3
|
|
|
- and ((b.process_status < eae.type ) or (b.process_status =8 and b.status=2))
|
|
|
|
|
|
|
+ and ((b.process_status > eae.type ) or (b.process_status =8 and b.status=2))
|
|
|
</if>
|
|
</if>
|
|
|
</if>
|
|
</if>
|
|
|
</if>
|
|
</if>
|