Browse Source

更改

master
ligaode 4 months ago
parent
commit
51dd7461e8
  1. 38
      anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehicle/BaseVehicleMapper.xml
  2. 2
      anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehicle/BaseVehicleService.java

38
anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehicle/BaseVehicleMapper.xml

@ -1337,10 +1337,10 @@
<select id="specialRebateDisGetVehPageList"
resultType="com.yxt.anrui.base.api.basevehicle.BaseSpecialRebateDisGetVehVo">
SELECT
bvm.brandName,
bv.carBrandName AS brandName,
bmc.carColor color,
bv.locationName location,
bv.sid as vehSid,
bv.sid AS vehSid,
bv.modelSid,
bv.modelName,
bv.vinNo,
@ -1350,23 +1350,20 @@
bv.solidDate
FROM
base_vehicle bv
LEFT JOIN base_vehicle_model bvm
ON bv.modelSid = bvm.sid
AND bv.createOrgSid = bvm.createOrg
LEFT JOIN base_vehicle_brand bvb
ON bvm.carBrand = bvb.sid
LEFT JOIN base_model_config bmc ON bv.modelConfigSid = bmc.sid
LEFT JOIN base_model_config bmc
ON bv.modelConfigSid = bmc.sid
<where>
${ew.sqlSegment}
</where>
</select>
<select id="getVehBySpecialRebateSid" resultType="com.yxt.anrui.base.api.basevehicle.BaseSpecialRebateDisGetVehVo">
SELECT bvm.brandName,
SELECT
bv.carBrandName AS brandName,
bmc.carColor color,
bv.locationName location,
ssv.vehSid,
ssv.sid as specialRebateVehSid,
ssv.sid AS specialRebateVehSid,
bv.modelSid,
bv.modelName,
ssv.vinNo,
@ -1374,13 +1371,12 @@
bv.priceDate,
bv.salesDate,
bv.solidDate
FROM anrui_scm.scm_specialrebate_vehs ssv
FROM
anrui_scm.scm_specialrebate_vehs ssv
LEFT JOIN anrui_base.base_vehicle bv
ON ssv.vehSid = bv.sid
LEFT JOIN base_vehicle_model bvm
ON bv.modelSid = bvm.sid
AND bv.createOrgSid = bvm.createOrg
LEFT JOIN base_model_config bmc ON bv.modelConfigSid = bmc.sid
LEFT JOIN base_model_config bmc
ON bv.modelConfigSid = bmc.sid
WHERE ssv.specialRebateSid = #{specialRebateSid}
</select>
@ -1535,18 +1531,14 @@
<select id="vehicleCollectionPageList" resultType="com.yxt.anrui.base.api.basevehicle.BaseChoiceVehicleVo">
SELECT bv.sid,
bvm.vehicleAlias,
bvm.sid as carModelSid,
LEFT(bv.vinNo,8) as vinNo,
bv.costPrice as guidedPrice,
bv.modelName AS vehicleAlias,
bv.modelSid AS carModelSid,
RIGHT(bv.vinNo,8) AS vinNo,
bv.costPrice AS guidedPrice,
bv.priceDate,
bv.salesDate,
bv.solidDate
FROM base_vehicle bv
LEFT JOIN base_vehicle_model bvm ON bv.modelSid = bvm.sid
LEFT JOIN base_model_config bmc ON bv.modelConfigSid = bmc.sid
LEFT JOIN base_vehmodel_config bvc
ON bvc.modelSid = bvm.sid AND bvc.configurationItemsSid = bmc.sid AND bvc.useOrgSid = bv.createOrgSid
<where>
(bv.solidDate IS NULL AND bv.salesDate IS NOT NULL OR bv.salesDate IS NOT NULL) AND
${ew.sqlSegment}

2
anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehicle/BaseVehicleService.java

@ -3335,7 +3335,7 @@ public class BaseVehicleService extends MybatisBaseService<BaseVehicleMapper, Ba
qw.apply(StringUtils.isNotEmpty(solidStartDate), "date_format (bv.solidDate,'%Y-%m-%d') >= date_format('" + solidStartDate + "','%Y-%m-%d')").
apply(StringUtils.isNotEmpty(solidEndDate), "date_format (bv.solidDate,'%Y-%m-%d') <= date_format('" + solidEndDate + "','%Y-%m-%d')"
);
qw.eq("bvb.sid", params.getBrandSid());
qw.eq("bv.carBrandSid", params.getBrandSid());
qw.eq("bv.purchaseSystemSid", params.getPurchaseSystemSid());
qw.eq("bv.isDelete", 0);
qw.eq("bv.createOrgSid", params.getCreateOrgSid());

Loading…
Cancel
Save