|
@@ -622,7 +622,7 @@
|
|
|
a.attachment_url attachmentUrl,a.apply_dep applyDep, a.pay_dep payDep, a.eaaid,a.district_name districtName,
|
|
a.attachment_url attachmentUrl,a.apply_dep applyDep, a.pay_dep payDep, a.eaaid,a.district_name districtName,
|
|
|
a.user_names userNames,a.create_time, a.release_start,a.release_end, a.duration,b.name applyDepName,
|
|
a.user_names userNames,a.create_time, a.release_start,a.release_end, a.duration,b.name applyDepName,
|
|
|
c.name payDepName,d.name ,d.bank ,d.accounts ,t0.amount settlementAmount,a.check_no checkNo,
|
|
c.name payDepName,d.name ,d.bank ,d.accounts ,t0.amount settlementAmount,a.check_no checkNo,
|
|
|
- a.liquidation_status liquidationStatus, a.remarks,
|
|
|
|
|
|
|
+ a.liquidation_status liquidationStatus, a.remarks,a.real_amount realAmount,
|
|
|
date_format(a.create_time,'%Y-%m-%d %H:%i:%S')createTimeStr,
|
|
date_format(a.create_time,'%Y-%m-%d %H:%i:%S')createTimeStr,
|
|
|
date_format(a.release_start,'%Y-%m-%d %H:%i:%S')releaseStartStr,
|
|
date_format(a.release_start,'%Y-%m-%d %H:%i:%S')releaseStartStr,
|
|
|
date_format(a.release_end,'%Y-%m-%d %H:%i:%S')releaseEndStr
|
|
date_format(a.release_end,'%Y-%m-%d %H:%i:%S')releaseEndStr
|
|
@@ -686,27 +686,27 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
<select id="selectByMainId" resultMap="MainMap">
|
|
<select id="selectByMainId" resultMap="MainMap">
|
|
|
- <include refid="mainAllSql"/>
|
|
|
|
|
- where a.id= #{id}
|
|
|
|
|
- </select>
|
|
|
|
|
-
|
|
|
|
|
- <sql id="mainAllSql">
|
|
|
|
|
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.order_no,o.contract_no,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.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.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.duration,pr.plan,pro.contract_no sonContractNo,c.real_amount sonRealAmount,
|
|
c.duration,pr.plan,pro.contract_no sonContractNo,c.real_amount sonRealAmount,
|
|
|
|
|
+ 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 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
|
|
|
|
|
- </sql>
|
|
|
|
|
|
|
+ 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 debit on c.debit_id=debit.id
|
|
|
|
|
+ where a.id= #{id}
|
|
|
|
|
+ </select>
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
|
|
|
<select id="selectListByMainId" resultMap="BaseResultMap">
|
|
<select id="selectListByMainId" resultMap="BaseResultMap">
|
|
|
select b.*
|
|
select b.*
|
|
@@ -759,6 +759,10 @@
|
|
|
<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="sonContractNo" jdbcType="VARCHAR" property="contractNo" />
|
|
|
|
|
+ <result column="debitId" jdbcType="INTEGER" property="debitId" />
|
|
|
|
|
+ <result column="debitRealAmount" jdbcType="DECIMAL" property="debitRealAmount" />
|
|
|
|
|
+ <result column="debitSettlementAmount" jdbcType="DECIMAL" property="debitSettlementAmount" />
|
|
|
|
|
+ <result column="debitLiquidationStatus" jdbcType="INTEGER" property="debitLiquidationStatus" />
|
|
|
<association property="detList" resultMap="ExpenseAccountDetailsMap"></association>
|
|
<association property="detList" resultMap="ExpenseAccountDetailsMap"></association>
|
|
|
</resultMap>
|
|
</resultMap>
|
|
|
|
|
|