Commit 98bd3cb4 authored by jiaorz's avatar jiaorz

Merge branch 'master-modify-cutAmount' into dev

parents dcf2761e 391a6c51
...@@ -4,6 +4,7 @@ import cn.hutool.core.bean.BeanUtil; ...@@ -4,6 +4,7 @@ import cn.hutool.core.bean.BeanUtil;
import cn.hutool.core.collection.CollUtil; import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.lang.Dict; import cn.hutool.core.lang.Dict;
import cn.hutool.core.util.StrUtil; import cn.hutool.core.util.StrUtil;
import cn.hutool.json.JSONObject;
import cn.hutool.json.JSONUtil; import cn.hutool.json.JSONUtil;
import com.github.wxiaoqi.security.admin.constant.enumerate.MemberEnum; import com.github.wxiaoqi.security.admin.constant.enumerate.MemberEnum;
import com.github.wxiaoqi.security.admin.feign.UserFeign; import com.github.wxiaoqi.security.admin.feign.UserFeign;
...@@ -414,13 +415,13 @@ public class OrderRentVehicleService extends AbstractOrderHandle<OrderRentVehicl ...@@ -414,13 +415,13 @@ public class OrderRentVehicleService extends AbstractOrderHandle<OrderRentVehicl
*/ */
private void costDetail(RentVehiclePriceVO vo, String children) { private void costDetail(RentVehiclePriceVO vo, String children) {
OrderTemplate template = orderTemplateBiz.selectByCode(OrderCostEnum.RENT_VEHICLE.getCode()); OrderTemplate template = orderTemplateBiz.selectByCode(OrderCostEnum.RENT_VEHICLE.getCode());
// (Map<String, String>)CollUtil.zip(CollUtil.newArrayList("children", "vehicleAmount", "realAmount", "paramJson")
// , CollUtil.newArrayList(children, vo.getVehicleAmount()+"", vo.getRealAmount()+"", vo.getParamJson()));
template.setTemplate(orderTemplateBiz.result(template.getTemplate() template.setTemplate(orderTemplateBiz.result(template.getTemplate()
, CollUtil.zip(CollUtil.newArrayList("children", "vehicleAmount", "realAmount", "paramJson") , CollUtil.zip(CollUtil.newArrayList("children", "vehicleAmount", "realAmount", "paramJson")
, CollUtil.newArrayList(children, vo.getVehicleAmount() , CollUtil.newArrayList(children, vo.getVehicleAmount(), vo.getRealAmount(), ""))));
, vo.getRealAmount(), vo.getParamJson()))));
String result = orderTemplateBiz.result(template, Dict.parse(vo)); String result = orderTemplateBiz.result(template, Dict.parse(vo));
JSONObject jsonObject = JSONUtil.parseObj(result);
jsonObject.put("paramJson", vo.getParamJson());
result = JSONUtil.toJsonStr(jsonObject);
vo.setCostDetail(result); vo.setCostDetail(result);
} }
......
...@@ -383,9 +383,6 @@ ...@@ -383,9 +383,6 @@
<if test="numberPlate != null"> <if test="numberPlate != null">
and v1.number_plate = #{numberPlate} and v1.number_plate = #{numberPlate}
</if> </if>
<if test="keywords != null and keywords != ''">
and (v1.number_plate like concat('%', #{keywords}, '%') or v1.code like concat('%', #{keywords}, '%'))
</if>
<if test="status != null"> <if test="status != null">
and v1.status = #{status} and v1.status = #{status}
</if> </if>
...@@ -421,6 +418,9 @@ ...@@ -421,6 +418,9 @@
<if test="code != null and code != ''"> <if test="code != null and code != ''">
and v1.code = #{code} and v1.code = #{code}
</if> </if>
<if test="keywords != null and keywords != ''">
and (v1.number_plate like concat('%', #{keywords}, '%') or v1.code like concat('%', #{keywords}, '%'))
</if>
<if test="companyIds != null and companyIds.size > 0"> <if test="companyIds != null and companyIds.size > 0">
and v1.park_branch_company_id in and v1.park_branch_company_id in
<foreach collection="companyIds" item="id" open="(" separator="," close=")"> <foreach collection="companyIds" item="id" open="(" separator="," close=")">
...@@ -485,6 +485,9 @@ ...@@ -485,6 +485,9 @@
<if test="status != null"> <if test="status != null">
and v1.status = #{status} and v1.status = #{status}
</if> </if>
<if test="code !=null">
and v1.code=#{code}
</if>
<if test="companyIds != null and companyIds.size > 0"> <if test="companyIds != null and companyIds.size > 0">
and v1.park_branch_company_id in and v1.park_branch_company_id in
<foreach collection="companyIds" item="id" open="(" separator="," close=")"> <foreach collection="companyIds" item="id" open="(" separator="," close=")">
...@@ -508,6 +511,9 @@ ...@@ -508,6 +511,9 @@
<if test="status != null"> <if test="status != null">
and v2.status = #{status} and v2.status = #{status}
</if> </if>
<if test="code !=null">
and v2.code=#{code}
</if>
<if test="companyIds != null and companyIds.size > 0"> <if test="companyIds != null and companyIds.size > 0">
and v2.park_branch_company_id in and v2.park_branch_company_id in
<foreach collection="companyIds" item="id" open="(" separator="," close=")"> <foreach collection="companyIds" item="id" open="(" separator="," close=")">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment