Commit 950aa19b by 杨林龙

新E盾 1.30 版本开发 修改里程统计

1 parent f1e99da4
...@@ -19,7 +19,7 @@ public class MileageSearch extends Page { ...@@ -19,7 +19,7 @@ public class MileageSearch extends Page {
* 组织Id * 组织Id
*/ */
@ApiModelProperty(value = "组织Id") @ApiModelProperty(value = "组织Id")
private Integer orgId; private Long orgId;
/** /**
* 工单号 * 工单号
......
...@@ -43,19 +43,19 @@ ...@@ -43,19 +43,19 @@
AND tvd.trial_type = 1 AND tvd.trial_type = 1
AND td.del_flag = 0 AND td.del_flag = 0
<if test="orgId != null"> <if test="orgId != null">
tv.created_by = #{orgId} and tv.created_by = #{orgId}
</if> </if>
<if test="orderNo != null and orderNo!='' "> <if test="orderNo != null and orderNo!='' ">
tw.order_no = #{orderNo} and tw.order_no = #{orderNo}
</if> </if>
<if test="vin != null and vin!='' "> <if test="vin != null and vin!='' ">
tv.vin = #{vin} and tv.vin = #{vin}
</if> </if>
<if test="ownerName != null and ownerName!='' "> <if test="ownerName != null and ownerName!='' ">
tv.owner_name = #{ownerName} and tv.owner_name = #{ownerName}
</if> </if>
<if test="sn != null and sn!='' "> <if test="sn != null and sn!='' ">
td.sn = #{sn} and td.sn = #{sn}
</if> </if>
group by tv.vin group by tv.vin
</select> </select>
...@@ -124,19 +124,19 @@ ...@@ -124,19 +124,19 @@
left join t_workorder tw on tw.id = tv.workorder_id left join t_workorder tw on tw.id = tv.workorder_id
<where> <where>
<if test="orgId != null"> <if test="orgId != null">
tv.created_by = #{orgId} and tv.created_by = #{orgId}
</if> </if>
<if test="orderNo != null and orderNo!='' "> <if test="orderNo != null and orderNo!='' ">
tw.order_no = #{orderNo} and tw.order_no = #{orderNo}
</if> </if>
<if test="vin != null and vin!='' "> <if test="vin != null and vin!='' ">
tv.vin = #{vin} and tv.vin = #{vin}
</if> </if>
<if test="ownerName != null and ownerName!='' "> <if test="ownerName != null and ownerName!='' ">
tv.owner_name = #{ownerName} and tv.owner_name = #{ownerName}
</if> </if>
<if test="sn != null and sn!='' "> <if test="sn != null and sn!='' ">
tefd.sn = #{sn} and tefd.sn = #{sn}
</if> </if>
<if test="mileageStartTime != null"> <if test="mileageStartTime != null">
and tefd.journey_time &gt;= #{mileageStartTime} and tefd.journey_time &gt;= #{mileageStartTime}
......
...@@ -26,6 +26,9 @@ public class MileageServiceTest { ...@@ -26,6 +26,9 @@ public class MileageServiceTest {
@Test @Test
public void search() { public void search() {
MileageSearch search = new MileageSearch(); MileageSearch search = new MileageSearch();
search.setOrgId(8131L);
search.setPageSize(10);
search.setPageNumber(1);
List<MileageReportExport> mileageReportExportList = mileageService.search(search); List<MileageReportExport> mileageReportExportList = mileageService.search(search);
System.out.println("mileageReportExportList = " + JSON.toJSONString(mileageReportExportList)); System.out.println("mileageReportExportList = " + JSON.toJSONString(mileageReportExportList));
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!