Merge branch 'prod/20260206' into develop
This commit is contained in:
commit
5ebcdf30e6
|
|
@ -221,7 +221,7 @@ public class AdminDeviceService {
|
|||
ent.setStartWarrantyDate(null);
|
||||
ent.setWarrantyState(null);
|
||||
}
|
||||
if (Objects.nonNull(u.getAgent__r())) {
|
||||
if (Objects.isNull(ent.getId()) && Objects.nonNull(u.getAgent__r())) {
|
||||
TBaseCustomer customer = agents.stream()
|
||||
.filter(agent -> agent.getAgencyCompanyCode().equals(u.getAgent__r().getId()))
|
||||
.findFirst()
|
||||
|
|
@ -238,10 +238,8 @@ public class AdminDeviceService {
|
|||
}
|
||||
ent.setAgentCode(customer.getAgencyCompanyCode());
|
||||
ent.setAgentName(customer.getAgencyCompanyName());
|
||||
if (Objects.isNull(ent.getId())) {
|
||||
ent.setServiceAgentCode(ent.getAgentCode());
|
||||
ent.setServiceAgentName(ent.getAgentName());
|
||||
}
|
||||
ent.setServiceAgentCode(ent.getAgentCode());
|
||||
ent.setServiceAgentName(ent.getAgentName());
|
||||
}
|
||||
ent.setAddress(u.getSpecificAddress__c());
|
||||
result.add(ent);
|
||||
|
|
|
|||
|
|
@ -232,7 +232,7 @@ public class AdminDeviceService {
|
|||
ent.setWarrantyState(null);
|
||||
}
|
||||
// VUtils.trueThrow(true).throwMessage(STATE.SystemErr,"测试");
|
||||
if (Objects.nonNull(u.getAgent__r())) {
|
||||
if (Objects.isNull(ent.getId()) && Objects.nonNull(u.getAgent__r())) {
|
||||
TBaseCustomer customer = agents.stream()
|
||||
.filter(agent -> agent.getAgencyCompanyCode().equals(u.getAgent__r().getId()))
|
||||
.findFirst()
|
||||
|
|
@ -249,10 +249,8 @@ public class AdminDeviceService {
|
|||
}
|
||||
ent.setAgentCode(customer.getAgencyCompanyCode());
|
||||
ent.setAgentName(customer.getAgencyCompanyName());
|
||||
if (Objects.isNull(ent.getId())) {
|
||||
ent.setServiceAgentCode(ent.getAgentCode());
|
||||
ent.setServiceAgentName(ent.getAgentName());
|
||||
}
|
||||
ent.setServiceAgentCode(ent.getAgentCode());
|
||||
ent.setServiceAgentName(ent.getAgentName());
|
||||
}
|
||||
ent.setAddress(u.getSpecificAddress__c());
|
||||
ent.setDataValidState(true);
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
LEFT JOIN t_base_device_type dt ON d.device_type=dt.device_type
|
||||
LEFT JOIN dictionary_item di ON d.warranty_state=di.id
|
||||
LEFT JOIN t_base_part p ON t.component_id=p.id
|
||||
LEFT JOIN t_base_customer c ON c.agency_company_code=d.agent_code
|
||||
LEFT JOIN t_base_customer c ON c.agency_company_code=d.service_agent_code
|
||||
<where>
|
||||
<if test="request.component!=null and request.component!=''">
|
||||
AND t.component=#{request.component}
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
LEFT JOIN gongfu_device_type dt ON d.device_type=dt.device_type
|
||||
LEFT JOIN dictionary_item di ON d.warranty_state=di.id
|
||||
LEFT JOIN gongfu_device_part p ON t.component_id=p.id
|
||||
LEFT JOIN t_base_customer c ON c.agency_company_code=d.agent_code
|
||||
LEFT JOIN t_base_customer c ON c.agency_company_code=d.service_agent_code
|
||||
<where>
|
||||
<if test="request.component!=null and request.component!=''">
|
||||
AND t.component=#{request.component}
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
"applyforId",if(da.create_by_id =#{userId} or da.handler_user_id = #{userId},1,0) AS usort,di.name as "typeDesc"
|
||||
FROM gongfu_dispatch da
|
||||
LEFT JOIN v_gongfu_device dv ON da.device_no=dv.device_no
|
||||
LEFT JOIN t_base_customer bc ON dv.agent_code=bc.agency_company_code
|
||||
LEFT JOIN t_base_customer bc ON dv.service_agent_code=bc.agency_company_code
|
||||
left join v_dispatch_applyfor af on da.id=af.ticket_id
|
||||
left join gongfu_dispatch_applyfor af2 on da.id=af2.ticket_id and af2.audit_state=0
|
||||
left join dictionary_item di on da.type=di.id
|
||||
|
|
@ -53,7 +53,7 @@
|
|||
, di2.name as "categoryDesc"
|
||||
FROM gongfu_dispatch da
|
||||
LEFT JOIN v_gongfu_device dv ON da.device_no=dv.device_no
|
||||
LEFT JOIN t_base_customer bc ON dv.agent_code=bc.agency_company_code
|
||||
LEFT JOIN t_base_customer bc ON dv.service_agent_code=bc.agency_company_code
|
||||
left join v_dispatch_applyfor af on da.id=af.ticket_id
|
||||
left join dictionary_item di1 on da.type = di1.id
|
||||
left join dictionary_item di2 on da.category = di2.id
|
||||
|
|
|
|||
|
|
@ -142,7 +142,7 @@
|
|||
LEFT JOIN v_device vd ON t.device_no=vd.device_no
|
||||
WHERE t.state!=4
|
||||
<if test="isPrimary==false">
|
||||
AND FIND_IN_SET(#{companyId},u.company_id) AND vd.agent_code=#{companyCode}
|
||||
AND FIND_IN_SET(#{companyId},u.company_id) AND vd.service_agent_code=#{companyCode}
|
||||
</if>
|
||||
<if test="isPrimary==true">
|
||||
AND (u.id=#{userId} OR FIND_IN_SET(u.company_id,#{companyId}))
|
||||
|
|
|
|||
|
|
@ -146,7 +146,7 @@
|
|||
LEFT JOIN v_all_device vd ON t.device_no=vd.device_no
|
||||
WHERE t.state!=4
|
||||
<if test="isPrimary!=null">
|
||||
AND t.user_platform='app' and vd.agent_code in
|
||||
AND t.user_platform='app' and vd.service_agent_code in
|
||||
<foreach collection="companyCodes" item="item" open="(" close=")" separator=",">
|
||||
#{item}
|
||||
</foreach>
|
||||
|
|
|
|||
Loading…
Reference in New Issue