Merge remote-tracking branch 'origin/dev_20230808_OTA' into dev_20230808_OTA

This commit is contained in:
zyx.net
2023-08-24 10:35:49 +08:00
14 changed files with 1435 additions and 1219 deletions
@@ -147,8 +147,8 @@ public class OtaManageApplyEOController extends JeroController<OtaManageApplyEO,
@AutoLog(value = "下拉数据-全部和分车型(不含年款)") @AutoLog(value = "下拉数据-全部和分车型(不含年款)")
@ApiOperation(value="下拉数据-全部和分车型(不含年款)", notes="下拉数据-全部和分车型(不含年款)") @ApiOperation(value="下拉数据-全部和分车型(不含年款)", notes="下拉数据-全部和分车型(不含年款)")
@GetMapping(value = "/getCarList") @GetMapping(value = "/getCarList")
public Result<?> getCarList() { public Result<?> getCarList(String cut) {
List<String> result = otaManageApplyEOService.getCarList(); List<String> result = otaManageApplyEOService.getCarList(cut);
return Result.OK(result); return Result.OK(result);
} }
@@ -5,6 +5,7 @@ import java.util.List;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import com.jero.common.api.vo.Result; import com.jero.common.api.vo.Result;
import com.jero.common.constant.enums.CutEnum;
import com.jero.common.system.query.QueryGenerator; import com.jero.common.system.query.QueryGenerator;
import com.jero.modules.ota.entity.OtaManageHistory; import com.jero.modules.ota.entity.OtaManageHistory;
import com.jero.modules.ota.service.IOtaManageHistoryService; import com.jero.modules.ota.service.IOtaManageHistoryService;
@@ -48,7 +49,7 @@ public class OtaManageHistoryController extends JeroController<OtaManageHistory,
@AutoLog(value = "OTA管理列表历史记录-分页列表查询") @AutoLog(value = "OTA管理列表历史记录-分页列表查询")
@ApiOperation(value="OTA管理列表历史记录-分页列表查询", notes="OTA管理列表历史记录-分页列表查询") @ApiOperation(value="OTA管理列表历史记录-分页列表查询", notes="OTA管理列表历史记录-分页列表查询")
@GetMapping(value = "/page") @GetMapping(value = "/page")
public Result<?> queryPageList(OtaManageHistory otaManageHistory, public Result<?> queryPageList(OtaManageHistory otaManageHistory,String cut,
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo, @RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize, @RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
HttpServletRequest req) { HttpServletRequest req) {
@@ -56,6 +57,14 @@ public class OtaManageHistoryController extends JeroController<OtaManageHistory,
queryWrapper.orderByDesc("create_time"); queryWrapper.orderByDesc("create_time");
Page<OtaManageHistory> page = new Page<OtaManageHistory>(pageNo, pageSize); Page<OtaManageHistory> page = new Page<OtaManageHistory>(pageNo, pageSize);
IPage<OtaManageHistory> pageList = otaManageHistoryService.page(page, queryWrapper); IPage<OtaManageHistory> pageList = otaManageHistoryService.page(page, queryWrapper);
List<OtaManageHistory> records = pageList.getRecords();
for (OtaManageHistory omh : records) {
if (CutEnum.CN.getValue().equals(cut)) {
omh.setContent(omh.getContentCn());
} else {
omh.setContent(omh.getContentEn());
}
}
return Result.OK(pageList); return Result.OK(pageList);
} }
@@ -89,6 +89,9 @@ public class OtaManageApplyEO implements Serializable {
@ApiModelProperty(value = "备注") @ApiModelProperty(value = "备注")
private java.lang.String remark; private java.lang.String remark;
@ApiModelProperty(value = "适用车型")
private java.lang.String appliedVehicleProject;
//-------------------------------------------------------- //--------------------------------------------------------
@@ -96,9 +99,7 @@ public class OtaManageApplyEO implements Serializable {
@ApiModelProperty(value = "软件版本") @ApiModelProperty(value = "软件版本")
private java.lang.String plannedBpLaunchBatch; private java.lang.String plannedBpLaunchBatch;
@TableField(exist = false)
@ApiModelProperty(value = "适用车型")
private java.lang.String appliedVehicleProject;
@TableField(exist = false) @TableField(exist = false)
@ApiModelProperty(value = "市场") @ApiModelProperty(value = "市场")
@@ -4,6 +4,7 @@ import java.io.Serializable;
import java.io.UnsupportedEncodingException; import java.io.UnsupportedEncodingException;
import java.math.BigDecimal; import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName; import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data; import lombok.Data;
@@ -66,8 +67,18 @@ public class OtaManageHistory implements Serializable {
@ApiModelProperty(value = "关联applyID") @ApiModelProperty(value = "关联applyID")
private String applyId; private String applyId;
/**操作记录*/ /**操作记录cn*/
@Excel(name = "操作记录", width = 15) @Excel(name = "操作记录cn", width = 15)
@ApiModelProperty(value = "操作记录cn")
private String contentCn;
/**操作记录en*/
@Excel(name = "操作记录en", width = 15)
@ApiModelProperty(value = "操作记录en")
private String contentEn;
@TableField(exist = false)
@ApiModelProperty(value = "操作记录") @ApiModelProperty(value = "操作记录")
private String content; private String content;
@@ -15,6 +15,7 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
public interface OtaManageReceiveMapper extends BaseMapper<OtaManageReceive> { public interface OtaManageReceiveMapper extends BaseMapper<OtaManageReceive> {
List<OtaManageReceive> getReceiveByVdr(@Param("vdrList") List<String> vdrList); List<OtaManageReceive> getReceiveByVdr(@Param("vdrList") List<String> vdrList);
List<OtaManageReceive> getReceiveList();
List<OtaManageReceive> getReceiveSync(); List<OtaManageReceive> getReceiveSync();
} }
@@ -21,7 +21,7 @@
<where> <where>
ota_manage_apply.project_version =#{projectId} ota_manage_apply.project_version =#{projectId}
<if test="plannedBpLaunchBatch != null and plannedBpLaunchBatch != ''"> <if test="plannedBpLaunchBatch != null and plannedBpLaunchBatch != ''">
and ota_manage_receive.planned_bp_launch_batch_ =#{plannedBpLaunchBatch} and ota_manage_receive.planned_bp_launch_batch =#{plannedBpLaunchBatch}
</if> </if>
</where> </where>
</select> </select>
@@ -30,7 +30,7 @@
select * from ota_manage_receive select * from ota_manage_receive
<where> <where>
<if test="otaManageApplyEO.plannedBpLaunchBatch != null and otaManageApplyEO.plannedBpLaunchBatch != ''"> <if test="otaManageApplyEO.plannedBpLaunchBatch != null and otaManageApplyEO.plannedBpLaunchBatch != ''">
planned_bp_launch_batch_ =#{otaManageApplyEO.plannedBpLaunchBatch} planned_bp_launch_batch =#{otaManageApplyEO.plannedBpLaunchBatch}
</if> </if>
<if test="otaManageApplyEO.appliedVehicleProject != null and otaManageApplyEO.appliedVehicleProject != ''"> <if test="otaManageApplyEO.appliedVehicleProject != null and otaManageApplyEO.appliedVehicleProject != ''">
@@ -56,7 +56,7 @@
</select> </select>
<select id="getOtaCarPage" resultType="com.jero.modules.ota.entity.OtaManageApplyEO"> <select id="getOtaCarPage" resultType="com.jero.modules.ota.entity.OtaManageApplyEO">
select omr.id as vdr,omr.planned_bp_launch_batch_,omr.update_date, select omr.id as vdr,omr.planned_bp_launch_batch,omr.update_date,
omr.summary,omr.status, omr.summary,omr.status,
omr.homologation_impact,omr.homologation, omr.homologation_impact,omr.homologation,
omr.impact_cn_homo,omr.impact_eu_homo, omr.impact_cn_homo,omr.impact_eu_homo,
@@ -67,7 +67,7 @@
<where> <where>
1=1 1=1
<if test="otaManageApplyEO.plannedBpLaunchBatch != null and otaManageApplyEO.plannedBpLaunchBatch != ''"> <if test="otaManageApplyEO.plannedBpLaunchBatch != null and otaManageApplyEO.plannedBpLaunchBatch != ''">
and omr.planned_bp_launch_batch_ =#{otaManageApplyEO.plannedBpLaunchBatch} and omr.planned_bp_launch_batch =#{otaManageApplyEO.plannedBpLaunchBatch}
</if> </if>
<if test="otaManageApplyEO.vdr != null and otaManageApplyEO.vdr != ''"> <if test="otaManageApplyEO.vdr != null and otaManageApplyEO.vdr != ''">
@@ -80,6 +80,9 @@
and (omr.impact_cn_homo LIKE CONCAT(CONCAT('%',#{otaManageApplyEO.impactHomo}),'%') and (omr.impact_cn_homo LIKE CONCAT(CONCAT('%',#{otaManageApplyEO.impactHomo}),'%')
and omr.impact_eu_homo LIKE CONCAT(CONCAT('%',#{otaManageApplyEO.impactHomo}),'%')) and omr.impact_eu_homo LIKE CONCAT(CONCAT('%',#{otaManageApplyEO.impactHomo}),'%'))
</if> </if>
<if test="otaManageApplyEO.appliedVehicleProject != null and otaManageApplyEO.appliedVehicleProject != ''">
and omr.applied_vehicle_project LIKE CONCAT(CONCAT('%',#{otaManageApplyEO.appliedVehicleProject}),'%'
</if>
</where> </where>
order by omr.id desc order by omr.id desc
</select> </select>
@@ -8,7 +8,7 @@
<result column="update_by" property="updateBy" /> <result column="update_by" property="updateBy" />
<result column="update_time" property="updateTime" /> <result column="update_time" property="updateTime" />
<result column="sys_org_code" property="sysOrgCode" /> <result column="sys_org_code" property="sysOrgCode" />
<result column="planned_bp_launch_batch_" property="plannedBpLaunchBatch" /> <result column="planned_bp_launch_batch" property="plannedBpLaunchBatch" />
<result column="update_date" property="updateDate" /> <result column="update_date" property="updateDate" />
<result column="summary" property="summary" /> <result column="summary" property="summary" />
<result column="status" property="status" /> <result column="status" property="status" />
@@ -28,6 +28,10 @@
</foreach> </foreach>
</select> </select>
<select id="getReceiveList" resultType="com.jero.modules.ota.entity.OtaManageReceive">
select * from ota_manage_receive
</select>
<select id="getReceiveSync" resultType="com.jero.modules.ota.entity.OtaManageReceive"> <select id="getReceiveSync" resultType="com.jero.modules.ota.entity.OtaManageReceive">
select * from ota_manage_receive_sync select * from ota_manage_receive_sync
</select> </select>
@@ -15,7 +15,7 @@
<result column="release_date" property="releaseDate" /> <result column="release_date" property="releaseDate" />
<result column="created_at" property="createdAt" /> <result column="created_at" property="createdAt" />
</resultMap> </resultMap>
<select id="getOtaManageReceiveNsdpSync" resultType="com.jero.modules.ota.entity.OtaManageReceive"> <select id="getOtaManageReceiveNsdpSync" resultType="com.jero.modules.ota.entity.OtaManageReceiveNsdp">
select * from ota_manage_receive_nsdp_sync select * from ota_manage_receive_nsdp_sync
</select> </select>
</mapper> </mapper>
@@ -88,7 +88,7 @@ public interface IOtaManageApplyEOService extends IService<OtaManageApplyEO> {
下拉数据-全部和分车型(不含年款) 下拉数据-全部和分车型(不含年款)
* @return * @return
*/ */
List<String> getCarList(); List<String> getCarList(String cut);
/** /**
* *
@@ -21,7 +21,7 @@ public interface IOtaManageHistoryService extends IService<OtaManageHistory> {
void add(OtaManageHistory otaManageHistory); void add(OtaManageHistory otaManageHistory);
void add(String appId,String content); void add(String appId,String contentCn, String contentEn);
/** /**
* 更新 * 更新
@@ -17,6 +17,7 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
@Service @Service
public class OtaManageHistoryServiceImpl extends ServiceImpl<OtaManageHistoryMapper, OtaManageHistory> implements IOtaManageHistoryService { public class OtaManageHistoryServiceImpl extends ServiceImpl<OtaManageHistoryMapper, OtaManageHistory> implements IOtaManageHistoryService {
/** /**
* 保存 * 保存
* *
@@ -32,10 +33,11 @@ public class OtaManageHistoryServiceImpl extends ServiceImpl<OtaManageHistoryMap
} }
@Override @Override
public void add(String appId,String content) { public void add(String appId, String contentCn, String contentEn) {
OtaManageHistory his = new OtaManageHistory(); OtaManageHistory his = new OtaManageHistory();
his.setApplyId(appId); his.setApplyId(appId);
his.setContent(content); his.setContentCn(contentCn);
his.setContentEn(contentEn);
this.add(his); this.add(his);
} }
@@ -85,7 +85,7 @@ public class OtaManageReceiveServiceImpl extends ServiceImpl<OtaManageReceiveMap
*/ */
@Override @Override
public List<OtaManageReceive> queryList() { public List<OtaManageReceive> queryList() {
return list(); return this.getBaseMapper().getReceiveList();
} }
@Override @Override
@@ -15,6 +15,8 @@ public enum CertificationProgressEnum {
COMPONENT_REPORT_NOT_SUBMITTED("部件报告未提交","Component report not submitted","5"), COMPONENT_REPORT_NOT_SUBMITTED("部件报告未提交","Component report not submitted","5"),
COMPONENT_REPORT_SUBMITTED("部件报告已提交","Component report submitted","6"), COMPONENT_REPORT_SUBMITTED("部件报告已提交","Component report submitted","6"),
COMPONENT_REPORT_HAS_BEEN_STORED("部件报告已入库","Component report has been stored","7"), COMPONENT_REPORT_HAS_BEEN_STORED("部件报告已入库","Component report has been stored","7"),
NA("空","null","8"),
; ;
String name; String name;
@@ -74,4 +76,14 @@ public enum CertificationProgressEnum {
} }
return null; return null;
} }
public static CertificationProgressEnum getByValue(String value) {
CertificationProgressEnum[] values = values();
for (CertificationProgressEnum certificationProgressEnum : values) {
if (certificationProgressEnum.value.equals(value)) {
return certificationProgressEnum;
}
}
return NA;
}
} }