|
@@ -31,7 +31,7 @@
|
|
select contract.id,contract.company_id,contract.creator_id,contract.number,contract.name,contract.amounts,contract.type_id,sys_dict.name typeName,contract.status,contract.indate,contract.remarks,
|
|
select contract.id,contract.company_id,contract.creator_id,contract.number,contract.name,contract.amounts,contract.type_id,sys_dict.name typeName,contract.status,contract.indate,contract.remarks,
|
|
contract.start_date as startDate,contract.end_date as endDate,contract_type_sec.sec_type_name,contract.sec_type_id,
|
|
contract.start_date as startDate,contract.end_date as endDate,contract_type_sec.sec_type_name,contract.sec_type_id,
|
|
user.name as creatorName,user.corpwx_userid as creatorWxCorpId, contract.project_id, contract.payment, cp.pay_date AS next_payment_date, cp.amount AS next_payment_amount,
|
|
user.name as creatorName,user.corpwx_userid as creatorWxCorpId, contract.project_id, contract.payment, cp.pay_date AS next_payment_date, cp.amount AS next_payment_amount,
|
|
- contract.plate1,contract.plate2,contract.plate3,contract.plate4,contract.plate5,contract.need_pin,contract.pin_time,contract.department_id,d.department_name as departmentName
|
|
|
|
|
|
+ contract.plate1,contract.plate2,contract.plate3,contract.plate4,contract.plate5,contract.need_pin,contract.pin_time,contract.department_id
|
|
from contract
|
|
from contract
|
|
left join sys_dict on contract.type_id = sys_dict.id
|
|
left join sys_dict on contract.type_id = sys_dict.id
|
|
left join contract_type_sec on contract.sec_type_id = contract_type_sec.id
|
|
left join contract_type_sec on contract.sec_type_id = contract_type_sec.id
|
|
@@ -39,7 +39,6 @@
|
|
left join user
|
|
left join user
|
|
on contract.creator_id = user.id
|
|
on contract.creator_id = user.id
|
|
left join contract_custom cc on cc.contract_id=contract.id
|
|
left join contract_custom cc on cc.contract_id=contract.id
|
|
- left join department d.department_id=contract.department_id
|
|
|
|
where contract.company_id = #{companyId}
|
|
where contract.company_id = #{companyId}
|
|
<if test="number!=null">
|
|
<if test="number!=null">
|
|
and number like CONCAT('%', #{number}, '%')
|
|
and number like CONCAT('%', #{number}, '%')
|
|
@@ -168,7 +167,7 @@
|
|
left join user
|
|
left join user
|
|
on contract.creator_id = user.id
|
|
on contract.creator_id = user.id
|
|
left join contract_custom cc on cc.contract_id=contract.id
|
|
left join contract_custom cc on cc.contract_id=contract.id
|
|
- left join department d.department_id=contract.department_id
|
|
|
|
|
|
+ left join department d on d.department_id=contract.department_id
|
|
where contract.company_id = #{companyId}
|
|
where contract.company_id = #{companyId}
|
|
<if test="number!=null">
|
|
<if test="number!=null">
|
|
and number like CONCAT('%', #{number}, '%')
|
|
and number like CONCAT('%', #{number}, '%')
|
|
@@ -216,7 +215,7 @@
|
|
left join user
|
|
left join user
|
|
on contract.creator_id = user.id
|
|
on contract.creator_id = user.id
|
|
left join contract_custom cc on cc.contract_id=contract.id
|
|
left join contract_custom cc on cc.contract_id=contract.id
|
|
- left join department d.department_id=contract.department_id
|
|
|
|
|
|
+ left join department d on d.department_id=contract.department_id
|
|
where contract.company_id = #{companyId}
|
|
where contract.company_id = #{companyId}
|
|
<if test="number!=null">
|
|
<if test="number!=null">
|
|
and number like CONCAT('%', #{number}, '%')
|
|
and number like CONCAT('%', #{number}, '%')
|