Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
cloud-platform
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
youjj
cloud-platform
Commits
dd717099
Commit
dd717099
authored
Oct 19, 2020
by
周健威
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改车辆查询重复车型问题
parent
84cda7f8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
2 deletions
+12
-2
VehicleMapper.xml
...ehicle-server/src/main/resources/mapper/VehicleMapper.xml
+12
-2
No files found.
xx-vehicle/xx-vehicle-server/src/main/resources/mapper/VehicleMapper.xml
View file @
dd717099
...
@@ -1019,6 +1019,12 @@
...
@@ -1019,6 +1019,12 @@
<select
id=
"searchUsableModel"
parameterType=
"java.util.Map"
<select
id=
"searchUsableModel"
parameterType=
"java.util.Map"
resultMap=
"searchUsableModelMap"
>
resultMap=
"searchUsableModelMap"
>
<if
test=
"startCompanyId != null or parkBranchCompanyId != null "
>
select model_id, company_id
<if
test=
"lon != null and lat != null"
>
, distance
</if>
<if
test=
" yearMonthAndParam !=null "
>
, max(hasVehicle) as hasVehicle
</if>
from (
</if>
(select distinct vm.id as model_id, bc.id as company_id
(select distinct vm.id as model_id, bc.id as company_id
<!-- , group_concat(v.id) as vehicle_ids -->
<!-- , group_concat(v.id) as vehicle_ids -->
<if
test=
" catas != null "
>
<if
test=
" catas != null "
>
...
@@ -1029,8 +1035,9 @@
...
@@ -1029,8 +1035,9 @@
,
,
<if
test=
"yearNo4Where != null and yearNo4Where == true"
>
<if
test=
"yearNo4Where != null and yearNo4Where == true"
>
(max(
(max(
ifnull(vbi.bit_str = #{yearMonthAndParamBitStr}, false)
ifnull(
<!-- 租车列表 不过滤前后预约记录不符的车辆 但是合并标示车型是否有车 即 hasVehicle-->
vbi.bit_str = #{yearMonthAndParamBitStr}, false)
<!-- 租车列表 不过滤前后预约记录不符的车辆 但是合并标示车型是否有车 即 hasVehicle-->
<if
test=
"withoutRecordWhere != null and withoutRecordWhere = 1 and startCompanyId != null and endCompanyId != null "
>
<if
test=
"withoutRecordWhere != null and withoutRecordWhere = 1 and startCompanyId != null and endCompanyId != null "
>
<!-- and (abr.to_lift_company is null or abr.to_lift_company = #{startCompanyId})-->
<!-- and (abr.to_lift_company is null or abr.to_lift_company = #{startCompanyId})-->
<!-- and (abr.to_return_company is null or abr.to_return_company = #{endCompanyId})-->
<!-- and (abr.to_return_company is null or abr.to_return_company = #{endCompanyId})-->
...
@@ -1105,6 +1112,9 @@
...
@@ -1105,6 +1112,9 @@
</otherwise>
</otherwise>
</choose>
</choose>
where vm.isdel = 0 and vm.status = 1 and vm.app_show = 1)
where vm.isdel = 0 and vm.status = 1 and vm.app_show = 1)
) as total_table
group by model_id, company_id
<if
test=
"lon != null and lat != null"
>
, distance
</if>
</if>
</if>
<if
test=
"lon != null and lat != null"
>
<if
test=
"lon != null and lat != null"
>
order by
order by
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment