修改嗲体和被代替逻辑
This commit is contained in:
+4
-2
@@ -237,13 +237,15 @@ public class OtaBaCxListController extends JeroController<OtaBaCxList, IOtaBaCxL
|
||||
// @RequiresPermissions("otaBaCx:importData")
|
||||
public Result<?> importData(@RequestParam(value = "file", required = false) MultipartFile file,
|
||||
@RequestParam(value = "cut", required = false) String cut) throws Exception {
|
||||
StringBuilder errMsg = new StringBuilder();
|
||||
errMsg.append("导入成功! 提示信息:");
|
||||
try {
|
||||
this.otaBaCxListService.importData(file, cut);
|
||||
this.otaBaCxListService.importData(file, cut, errMsg);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
return Result.error(e.getMessage());
|
||||
}
|
||||
return Result.OK("导入成功");
|
||||
return Result.error(errMsg.toString());
|
||||
}
|
||||
|
||||
@ApiOperation(value = "车型及功能备案列表-数据导出")
|
||||
|
||||
+211
-189
@@ -3,215 +3,221 @@ package com.jero.modules.ota.enums;
|
||||
public enum OtaTitleEnum {
|
||||
|
||||
|
||||
CPDJBH("cpdjbh", "产品登记编号", "0"),
|
||||
GGPC("ggpc", "公告批次", "0"),
|
||||
CPSB("cpsb", "产品商标", "0"),
|
||||
CPMC("cpmc", "产品名称", "0"),
|
||||
CPXH("cpxh", "产品型号", "0"),
|
||||
BAZT("bazt", "备案状态", "recordstatus"),
|
||||
BATJSJ("batjsj", "备案提交时间", "0"),
|
||||
CJSJ("cjsj", "创建时间", "0"),
|
||||
BZ("bz", "备注", "0"),
|
||||
CPDJBH("cpdjbh", "产品登记编号", "0", "Product registration number", 50),
|
||||
GGPC("ggpc", "公告批次", "0", "Notice batch", 500),
|
||||
CPSB("cpsb", "产品商标", "0", "Product Trademark", 50),
|
||||
CPMC("cpmc", "产品名称", "0", "Product Name", 50),
|
||||
CPXH("cpxh", "产品型号", "0", "Product Model", 50),
|
||||
BAZT("bazt", "备案状态", "recordstatus", "Record status", 0),
|
||||
BATJSJ("batjsj", "备案提交时间", "0", "Filing time", 50),
|
||||
CJSJ("cjsj", "创建时间", "0", "Create Time", 50),
|
||||
BZ("bz", "备注", "0", "remarks", 500),
|
||||
|
||||
CXMB("cxmb", "车型模板", "0"),
|
||||
// QYMC("qymc", "企业名称", "0"),
|
||||
DJBH("djbh", "产品登记编号", "0"),
|
||||
CPLB("cplb", "产品类别", "product_category"),
|
||||
DLLX1("dllx1", "车辆动力类型", "0"),
|
||||
DLLX2("dllx2", "车辆动力类型", "0"),
|
||||
TXZD("txzd", "通信终端", "communication_terminal"),
|
||||
CDOTASJ("cdotasj", "车端OTA升级管理系统", "0"),
|
||||
CXMB("cxmb", "车型模板", "0", "Model template", 500),
|
||||
// QYMC("qymc", "企业名称", "0","enterprise name ",0),
|
||||
DJBH("djbh", "产品登记编号", "0", "Product Registration Number ", 50),
|
||||
CPLB("cplb", "产品类别", "product_category", "Product category", 0),
|
||||
DLLX1("dllx1", "车辆动力类型", "0", "Vehicle Power Type", 50),
|
||||
DLLX2("dllx2", "车辆动力类型", "0", "Vehicle Power Type", 50),
|
||||
TXZD("txzd", "通信终端", "communication_terminal", "communication terminal", 0),
|
||||
CDOTASJ("cdotasj", "车端OTA升级管理系统", "0", "OTA Upgrade Management System", 500),
|
||||
|
||||
BHSJB("bhsjb", "激光雷达-应保护升级包的真实性和完整性,以合理地防止其受到损害,并合理地防止无效升级", "2"),
|
||||
BHCLBB("bhclbb", "激光雷达-应保护车辆上的软件版本(集),防止未经授权的修改", "2"),
|
||||
CLGXNL("clgxnl", "升级功能要求-车辆应具备更新软件版本(集)的能力,应通过使用电子通信接口,至少用过标准接口(如OBD端口),以标准化的方式易于读取", "2"),
|
||||
CLSJTJ("clsjtj", "升级功能要求-应确保车辆在执行软件升级之前满足先决条件", "2"),
|
||||
CLSJDL("clsjdl", "升级功能要求-应确保只有当车辆有充足电量完成升级过程时,才能执行软件升级(包括可能恢复到以前版本或使车辆进入安全状态所需的电量)", "2"),
|
||||
SJBHAQ("sjbhaq", "升级功能要求-当执行升级可能影响车辆安全时,应在升级执行过程中通过技术手段确保车辆安全", "2"),
|
||||
SJANTJ("sjantj", "升级功能要求-若升级的执行影响驾驶安全,至少应满足: (a)确保升级执行期间无法驾驶车辆; (b)确保驾驶员不能使用任何可能影响车辆安全或成功执行升级的车辆功能", "2"),
|
||||
SJSBAQ("sjsbaq", "升级功能要求-车辆能够恢复到以前的可用版本,或确保车辆处于安全状态。", "2"),
|
||||
SJGG("sjgg", "用户告知要求-在升级执行前,应告知车辆用户升级信息,告知的信息应包括: (a)升级目的; (b)车辆功能升级所实施的任何变更; (c)完成升级执行的预计时间; (d)升级执行期间可能不可用的任何车辆功能; (e)可能帮助车辆用户安全执行升级的任何指导信息。", "2"),
|
||||
SJZT("sjzt", "用户告知要求-在执行升级后,车辆应: (a)告知车辆用户车辆升级的结果(成功或失败); (b)若升级成功,告知车辆用户已实施的变更,用户手册(如果适用)的任何相关更新。", "2"),
|
||||
BHSJB("bhsjb", "激光雷达-应保护升级包的真实性和完整性,以合理地防止其受到损害,并合理地防止无效升级", "2", "LiDAR - Shall protect the authenticity and integrity of the upgrade package to reasonably prevent damage to it and reasonably prevent ineffective upgrades", 0),
|
||||
BHCLBB("bhclbb", "激光雷达-应保护车辆上的软件版本(集),防止未经授权的修改", "2", "Lidar - Software Versions on Vehicles should be protected (set) against unauthorized modifications", 0),
|
||||
CLGXNL("clgxnl", "升级功能要求-车辆应具备更新软件版本(集)的能力,应通过使用电子通信接口,至少用过标准接口(如OBD端口),以标准化的方式易于读取", "2", "Upgrade function Requirements - The vehicle shall have the ability to update the software version (set) and shall be easily read in a standardized manner by using an electronic communication interface that has at least used a standard interface (such as an OBD port)", 0),
|
||||
CLSJTJ("clsjtj", "升级功能要求-应确保车辆在执行软件升级之前满足先决条件", "2", "Upgrade function Requirements - should ensure that vehicle meets prerequisites before performing software upgrade", 0),
|
||||
CLSJDL("clsjdl", "升级功能要求-应确保只有当车辆有充足电量完成升级过程时,才能执行软件升级(包括可能恢复到以前版本或使车辆进入安全状态所需的电量)", "2", "Upgrade Function Requirements - It shall be ensured that software upgrades (including the amount of power that may be required to restore to a previous version or bring the vehicle into a safe condition) are performed only when the vehicle has sufficient power to complete the upgrade process", 0),
|
||||
SJBHAQ("sjbhaq", "升级功能要求-当执行升级可能影响车辆安全时,应在升级执行过程中通过技术手段确保车辆安全", "2", "Upgrade function Requirements - When performing an upgrade may affect the safety of the vehicle, the safety of the vehicle shall be ensured by technical means during the execution of the upgrade", 0),
|
||||
SJANTJ("sjantj", "升级功能要求-若升级的执行影响驾驶安全,至少应满足: (a)确保升级执行期间无法驾驶车辆; (b)确保驾驶员不能使用任何可能影响车辆安全或成功执行升级的车辆功能", "2", "", 0),
|
||||
SJSBAQ("sjsbaq", "升级功能要求-车辆能够恢复到以前的可用版本,或确保车辆处于安全状态。", "2", "Upgrade Function Requirements - If the execution of the upgrade affects driving safety, it shall at least: (a) ensure that the vehicle cannot be driven during the execution of the upgrade; (b) Ensure that the driver cannot use any vehicle feature that may affect the safety of the vehicle or the successful execution of the upgrade", 0),
|
||||
SJGG("sjgg", "用户告知要求-在升级执行前,应告知车辆用户升级信息,告知的信息应包括: (a)升级目的; (b)车辆功能升级所实施的任何变更; (c)完成升级执行的预计时间; (d)升级执行期间可能不可用的任何车辆功能; (e)可能帮助车辆用户安全执行升级的任何指导信息。", "2", "", 0),
|
||||
SJZT("sjzt", "用户告知要求-在执行升级后,车辆应: (a)告知车辆用户车辆升级的结果(成功或失败); (b)若升级成功,告知车辆用户已实施的变更,用户手册(如果适用)的任何相关更新。", "2", "Upgrade feature requirements - The ability to restore the vehicle to a previously available version, or to ensure that the vehicle is in a safe condition.", 0),
|
||||
|
||||
BHJZ("bhjz", "真实性、完整性保护机制", "protection_mechanism"),
|
||||
FSXJZ("fsxjz", "防失效保护机制", "fail_safe_mechanism"),
|
||||
SJSBCS("sjsbcs", "升级失败后车辆安全措施", "upgrade_failure"),
|
||||
XXAQJZ("xxaqjz", "信息安全机制", "Information_security_mechanism"),
|
||||
BHJZ("bhjz", "真实性、完整性保护机制", "protection_mechanism", "", 0),
|
||||
FSXJZ("fsxjz", "防失效保护机制", "fail_safe_mechanism", "", 0),
|
||||
SJSBCS("sjsbcs", "升级失败后车辆安全措施", "upgrade_failure", "", 0),
|
||||
XXAQJZ("xxaqjz", "信息安全机制", "Information_security_mechanism", "", 0),
|
||||
|
||||
XTLB("xtlb", "系统类别", "0"),
|
||||
SFKSJ("sfksj", "是否可升级", "2"),
|
||||
SJBGCS("sjbgcs", "升级可能变更的《公告》技术参数", "0"),
|
||||
//TPT("tpt", "系统-电子控制器架构拓扑图(附件需含拓扑图介绍)", "0"),
|
||||
KZQMC("kzqmc", "电子控制器名称", "0"),
|
||||
AQWZXDJ("aqwzxdj", "电子控制器汽车安全完整性等级(ASIL)", "0"),
|
||||
KZQSCQY("kzqscqy", "电子控制器生产企业", "0"),
|
||||
KZQXH("kzqxh", "电子控制器型号", "0"),
|
||||
YJBBXX("yjbbxx", "硬件版本信息", "0"),
|
||||
CSRJBBH("csrjbbh", "初始软件版本号", "0"),
|
||||
CSRJBWZSJ("csrjbwzsj", "初始软件包的完整性验证数据", "0"),
|
||||
SJSFYX("sjsfyx", "升级是否影响整车安全、节能、环保、防盗等性能", "0"),
|
||||
CZXTLX("czxtlx", "操作系统类型", "0"),
|
||||
CZXTSCQY("czxtscqy", "操作系统生产企业", "0"),
|
||||
CZXTBBH("czxtbbh", "软件版本号", "0"),
|
||||
XTLB("xtlb", "系统类别", "0", "System class", 50),
|
||||
SFKSJ("sfksj", "是否可升级", "2", "Whether it can be upgraded", 0),
|
||||
SJBGCS("sjbgcs", "升级可能变更的《公告》技术参数", "0", "Upgrade Bulletin technical parameters that may change", 500),
|
||||
//TPT("tpt", "系统-电子控制器架构拓扑图(附件需含拓扑图介绍)", "0","",0),
|
||||
KZQMC("kzqmc", "电子控制器名称", "0", "Electronic controller name", 50),
|
||||
AQWZXDJ("aqwzxdj", "电子控制器汽车安全完整性等级(ASIL)", "0", "", 50),
|
||||
KZQSCQY("kzqscqy", "电子控制器生产企业", "0", "", 50),
|
||||
KZQXH("kzqxh", "电子控制器型号", "0", "", 50),
|
||||
YJBBXX("yjbbxx", "硬件版本信息", "0", "", 50),
|
||||
CSRJBBH("csrjbbh", "初始软件版本号", "0", "", 50),
|
||||
CSRJBWZSJ("csrjbwzsj", "初始软件包的完整性验证数据", "0", "", 50),
|
||||
SJSFYX("sjsfyx", "升级是否影响整车安全、节能、环保、防盗等性能", "0", "", 50),
|
||||
CZXTLX("czxtlx", "操作系统类型", "0", "", 50),
|
||||
CZXTSCQY("czxtscqy", "操作系统生产企业", "0", "", 50),
|
||||
CZXTBBH("czxtbbh", "软件版本号", "0", "", 50),
|
||||
|
||||
GNMC("gnmc", "功能名称", "0"),
|
||||
PZQK("pzqk", "配置情况", "2"),
|
||||
JSZDHJB("jszdhjb", "驾驶自动化级别", "driving_automation_level"),
|
||||
SJGGCS("sjggcs", "升级可能变更的《公告》技术参数", "0"),
|
||||
GNMS("gnms", "功能描述", "0"),
|
||||
SYTJ("sytj", "适用条件(边界条件)", "0"),
|
||||
RJKFQY("rjkfqy", "软件开发企业", "0"),
|
||||
CSYZSJ("csyzsj", "初始软件包的完整性验证数据", "0"),
|
||||
FJ("fj", "附件", "0"),
|
||||
GNMC("gnmc", "功能名称", "0", "", 50),
|
||||
PZQK("pzqk", "配置情况", "2", "", 0),
|
||||
JSZDHJB("jszdhjb", "驾驶自动化级别", "driving_automation_level", "", 0),
|
||||
SJGGCS("sjggcs", "升级可能变更的《公告》技术参数", "0", "", 500),
|
||||
GNMS("gnms", "功能描述", "0", "", 500),
|
||||
SYTJ("sytj", "适用条件(边界条件)", "0", "", 500),
|
||||
RJKFQY("rjkfqy", "软件开发企业", "0", "", 50),
|
||||
CSYZSJ("csyzsj", "初始软件包的完整性验证数据", "0", "", 500),
|
||||
FJ("fj", "附件", "0", "", 0),
|
||||
|
||||
WLAQYQ_PZ("jgldPz", "激光雷达-配置", "2"),
|
||||
WLAQYQ_SL("jgldSl", "激光雷达-数量", "0"),
|
||||
WLAQYQ_BZWZ("jgldBzwz", "激光雷达-布置位置", "0"),
|
||||
WLAQYQ_GGXH("jgldGgxh", "激光雷达-规格型号", "0"),
|
||||
WLAQYQ_SCQY("jgldScqy", "激光雷达-生产企业", "0"),
|
||||
HMBLD_PZ("hmbldPz", "毫米波雷达-配置", "2"),
|
||||
HMBLD_SL("hmbldSl", "毫米波雷达-数量", "0"),
|
||||
HMBLD_BZWZ("hmbldBzwz", "毫米波雷达-布置位置", "0"),
|
||||
HMBLD_GGXH("hmbldGgxh", "毫米波雷达-规格型号", "0"),
|
||||
HMBLD_SCQY("hmbldScqy", "毫米波雷达-生产企业", "0"),
|
||||
CSBLD_PZ("csbldPz", "超声波雷达-配置", "2"),
|
||||
CSBLD_SL("csbldSl", "超声波雷达-数量", "0"),
|
||||
CSBLD_BZWZ("csbldBzwz", "超声波雷达-布置位置", "0"),
|
||||
CSBLD_GGXH("csbldGgxh", "超声波雷达-规格型号", "0"),
|
||||
CSBLD_SCQY("csbldScqy", "超声波雷达-生产企业", "0"),
|
||||
SXTHS_PZ("sxthsPz", "摄像头-倒车影像/360(环视)-配置", "2"),
|
||||
SXTHS_SL("sxthsSl", "摄像头-倒车影像/360(环视)-数量", "0"),
|
||||
SXTHS_BZWZ("sxthsBzwz", "摄像头-倒车影像/360(环视)-布置位置", "0"),
|
||||
SXTHS_GGXH("sxthsGgxh", "摄像头-倒车影像/360(环视)-规格型号", "0"),
|
||||
SXTHS_SCQY("sxthsScqy", "摄像头-倒车影像/360(环视)-生产企业", "0"),
|
||||
SXTDSD_PZ("sxtdsdPz", "摄像头-单目/双目/多目-配置", "2"),
|
||||
SXTDSD_SL("sxtdsdSl", "摄像头-单目双目多目-数量", "0"),
|
||||
SXTDSD_BZWZ("sxtdsdBzwz", "摄像头-单目双多目-布置位置", "0"),
|
||||
SXTDSD_GGXH("sxtdsdGgxh", "摄像头-单目/双目/多目-规格型号", "0"),
|
||||
SXTDSD_SCQY("sxtdsdScqy", "摄像头-单目/双目/多目-生产企业", "0"),
|
||||
JSYJK_PZ("jsyjkPz", "驾驶员注意力监测系统DMS-驾驶员监控摄像头-配置", "2"),
|
||||
JSYJK_SL("jsyjkSl", "驾驶员注意力监测系统DMS-驾驶员监控摄像头-数量", "0"),
|
||||
JSYJK_BZWZ("jsyjkBzwz", "驾驶员注意力监测系统DMS-驾驶员监控摄像头-布置位置", "0"),
|
||||
JSYJK_GGXH("jsyjkGgxh", "驾驶员注意力监测系统DMS-驾驶员监控摄像头-规格型号", "0"),
|
||||
JSYJK_SCQY("jsyjkScqy", "驾驶员注意力监测系统DMS-驾驶员监控摄像头-生产企业", "0"),
|
||||
JSYHW_PZ("jsyhwPz", "驾驶员注意力监测系统DMS-驾驶员监控红外传感器-配置", "2"),
|
||||
JSYHW_SL("jsyhwSl", "驾驶员注意力监测系统DMS-驾驶员监控红外传感器-数量", "0"),
|
||||
JSYHW_BZWZ("jsyhwBzwz", "驾驶员注意力监测系统DMS-驾驶员监控红外传感器-布置位置", "0"),
|
||||
JSYHW_GGXH("jsyhwGgxh", "驾驶员注意力监测系统DMS-驾驶员监控红外传感器-规格型号", "0"),
|
||||
JSYHW_SCQY("jsyhwScqy", "驾驶员注意力监测系统DMS-驾驶员监控红外传感器-生产企业", "0"),
|
||||
CZWXDW_PZ("czwxdwPz", "定位及导航系统-车载卫星定位设备(接收卫星信号及辅助定位信号的装置,PPP/GNSS/RTK)-配置", "2"),
|
||||
CZWXDW_GGXH("czwxdwGgxh", "定位及导航系统-车载卫星定位设备(接收卫星信号及辅助定位信号的装置,PPP/GNSS/RTK)-规格型号", "0"),
|
||||
CZWXDW_SCQY("czwxdwScqy", "定位及导航系统-车载卫星定位设备(接收卫星信号及辅助定位信号的装置,PPP/GNSS/RTK)-生产企业", "0"),
|
||||
GXDH_PZ("gxdhPz", "定位及导航系统-惯性导航系统-配置", "2"),
|
||||
GXDH_GGXH("gxdhGgxh", "定位及导航系统-惯性导航系统-规格型号", "0"),
|
||||
GXDH_SCQY("gxdhScqy", "定位及导航系统-惯性导航系统-生产企业", "0"),
|
||||
LSJ_PZ("lsjPz", "定位及导航系统-轮速计-配置", "2"),
|
||||
LSJ_GGXH("lsjGgxh", "定位及导航系统-轮速计-规格型号", "0"),
|
||||
LSJ_SCQY("lsjScqy", "定位及导航系统-轮速计-生产企业", "0"),
|
||||
GJDDT_PZ("gjddtPz", "定位及导航系统-高精度地图-配置", "2"),
|
||||
GJDDT_GGXH("gjddtGgxh", "定位及导航系统-高精度地图-规格型号", "0"),
|
||||
GJDDT_SCQY("gjddtScqy", "定位及导航系统-高精度地图-生产企业", "0"),
|
||||
DZWL_PZ("dzwlPz", "定位及导航系统-电子围栏-配置", "2"),
|
||||
DZWL_DXXGCS("dzwlDxxgcs", "定位及导航系统-电子围栏-定性描述相关场所", "0"),
|
||||
CZTX_PZ("cztxPz", "车载通信系统-配置", "2"),
|
||||
CZTX_XTMC("cztxXtmc", "车载通信系统-系统名称", "0"),
|
||||
CZTX_GGXH("cztxGgxh", "车载通信系统-规格型号", "0"),
|
||||
CZTX_SCQY("cztxScqy", "车载通信系统-生产企业", "0"),
|
||||
CZTX_BBH("cztxBbh", "车载通信系统-版本号", "0"),
|
||||
CZTX_KFQY("cztxKfqy", "车载通信系统-软件开发企业", "0"),
|
||||
JSFZCZJ_PZ("jsfzczjPz", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能操纵件-配置", "2"),
|
||||
JSFZCZJ_MC("jsfzczjMc", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能操纵件-操纵件名称", "0"),
|
||||
JSFZCZJ_YJXH("jsfzczjYjxh", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能操纵件-硬件规格型号", "0"),
|
||||
JSFZCZJ_SCQY("jsfzczjScqy", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能操纵件-生产企业", "0"),
|
||||
JSFZZSQ_PZ("jsfzzsqPz", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能指示器/信号装置-配置", "2"),
|
||||
JSFZZSQ_MC("jsfzzsqMc", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能指示器/信号装置-指示器/信号装置名称", "0"),
|
||||
JSFZZSQ_YJXH("jsfzzsqYjxh", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能指示器/信号装置-硬件规格型号", "0"),
|
||||
JSFZZSQ_SCQY("jsfzzsqScqy", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能指示器/信号装置-生产企业", "0"),
|
||||
FXPTSTS_PZ("fxptstsPz", "驾驶辅助系统操纵件、指示器及信号装置-方向盘脱手提示器/信号装置-配置", "2"),
|
||||
FXPTSTS_MC("fxptstsMc", "驾驶辅助系统操纵件、指示器及信号装置-方向盘脱手提示器/信号装置-指示器/信号装置名称", "0"),
|
||||
FXPTSTS_YJXH("fxptstsYjxh", "驾驶辅助系统操纵件、指示器及信号装置-方向盘脱手提示器/信号装置-硬件规格型号", "0"),
|
||||
FXPTSTS_SCQY("fxptstsScqy", "驾驶辅助系统操纵件、指示器及信号装置-方向盘脱手提示器/信号装置-生产企业", "0"),
|
||||
JSYZYLTS_PZ("jsyzyltsPz", "驾驶辅助系统操纵件、指示器及信号装置-驾驶员注意力提醒指示器/信号装置-配置", "2"),
|
||||
JSYZYLTS_MC("jsyzyltsMc", "驾驶辅助系统操纵件、指示器及信号装置-驾驶员注意力提醒指示器/信号装置-指示器/信号装置名称", "0"),
|
||||
JSYZYLTS_YJXH("jsyzyltsYjxh", "驾驶辅助系统操纵件、指示器及信号装置-驾驶员注意力提醒指示器/信号装置-硬件规格型号", "0"),
|
||||
JSYZYLTS_SCQY("jsyzyltsScqy", "驾驶辅助系统操纵件、指示器及信号装置-驾驶员注意力提醒指示器/信号装置-生产企业", "0"),
|
||||
DSSAD_PZ("dssadPz", "自动驾驶数据记录系统(DSSAD)-系统配置", "2"),
|
||||
DSSAD_GGXH("dssadGgxh", "自动驾驶数据记录系统(DSSAD)-规格型号", "0"),
|
||||
DSSAD_SCQY("dssadScqy", "自动驾驶数据记录系统(DSSAD)-生产企业", "0"),
|
||||
EDR_PZ("edrPz", "事件数据记录系统(EDR)-配置", "2"),
|
||||
EDR_GGXH("edrGgxh", "事件数据记录系统(EDR)-规格型号", "0"),
|
||||
EDR_SCQY("edrScqy", "事件数据记录系统(EDR)-生产企业", "0"),
|
||||
WLAQYQ_PZ("jgldPz", "激光雷达-配置", "2", "", 0),
|
||||
WLAQYQ_SL("jgldSl", "激光雷达-数量", "0", "", 50),
|
||||
WLAQYQ_BZWZ("jgldBzwz", "激光雷达-布置位置", "0", "", 50),
|
||||
WLAQYQ_GGXH("jgldGgxh", "激光雷达-规格型号", "0", "", 0),
|
||||
WLAQYQ_SCQY("jgldScqy", "激光雷达-生产企业", "0", "", 50),
|
||||
HMBLD_PZ("hmbldPz", "毫米波雷达-配置", "2", "", 0),
|
||||
HMBLD_SL("hmbldSl", "毫米波雷达-数量", "0", "", 50),
|
||||
HMBLD_BZWZ("hmbldBzwz", "毫米波雷达-布置位置", "0", "", 50),
|
||||
HMBLD_GGXH("hmbldGgxh", "毫米波雷达-规格型号", "0", "", 50),
|
||||
HMBLD_SCQY("hmbldScqy", "毫米波雷达-生产企业", "0", "", 50),
|
||||
CSBLD_PZ("csbldPz", "超声波雷达-配置", "2", "", 0),
|
||||
CSBLD_SL("csbldSl", "超声波雷达-数量", "0", "", 50),
|
||||
CSBLD_BZWZ("csbldBzwz", "超声波雷达-布置位置", "0", "", 50),
|
||||
CSBLD_GGXH("csbldGgxh", "超声波雷达-规格型号", "0", "", 50),
|
||||
CSBLD_SCQY("csbldScqy", "超声波雷达-生产企业", "0", "", 50),
|
||||
SXTHS_PZ("sxthsPz", "摄像头-倒车影像/360(环视)-配置", "2", "", 0),
|
||||
SXTHS_SL("sxthsSl", "摄像头-倒车影像/360(环视)-数量", "0", "", 50),
|
||||
SXTHS_BZWZ("sxthsBzwz", "摄像头-倒车影像/360(环视)-布置位置", "0", "", 50),
|
||||
SXTHS_GGXH("sxthsGgxh", "摄像头-倒车影像/360(环视)-规格型号", "0", "", 50),
|
||||
SXTHS_SCQY("sxthsScqy", "摄像头-倒车影像/360(环视)-生产企业", "0", "", 50),
|
||||
SXTDSD_PZ("sxtdsdPz", "摄像头-单目/双目/多目-配置", "2", "", 50),
|
||||
SXTDSD_SL("sxtdsdSl", "摄像头-单目双目多目-数量", "0", "", 50),
|
||||
SXTDSD_BZWZ("sxtdsdBzwz", "摄像头-单目双多目-布置位置", "0", "", 50),
|
||||
SXTDSD_GGXH("sxtdsdGgxh", "摄像头-单目/双目/多目-规格型号", "0", "", 50),
|
||||
SXTDSD_SCQY("sxtdsdScqy", "摄像头-单目/双目/多目-生产企业", "0", "", 50),
|
||||
JSYJK_PZ("jsyjkPz", "驾驶员注意力监测系统DMS-驾驶员监控摄像头-配置", "2", "", 0),
|
||||
JSYJK_SL("jsyjkSl", "驾驶员注意力监测系统DMS-驾驶员监控摄像头-数量", "0", "", 50),
|
||||
JSYJK_BZWZ("jsyjkBzwz", "驾驶员注意力监测系统DMS-驾驶员监控摄像头-布置位置", "0", "", 50),
|
||||
JSYJK_GGXH("jsyjkGgxh", "驾驶员注意力监测系统DMS-驾驶员监控摄像头-规格型号", "0", "", 50),
|
||||
JSYJK_SCQY("jsyjkScqy", "驾驶员注意力监测系统DMS-驾驶员监控摄像头-生产企业", "0", "", 50),
|
||||
JSYHW_PZ("jsyhwPz", "驾驶员注意力监测系统DMS-驾驶员监控红外传感器-配置", "2", "", 0),
|
||||
JSYHW_SL("jsyhwSl", "驾驶员注意力监测系统DMS-驾驶员监控红外传感器-数量", "0", "", 50),
|
||||
JSYHW_BZWZ("jsyhwBzwz", "驾驶员注意力监测系统DMS-驾驶员监控红外传感器-布置位置", "0", "", 50),
|
||||
JSYHW_GGXH("jsyhwGgxh", "驾驶员注意力监测系统DMS-驾驶员监控红外传感器-规格型号", "0", "", 50),
|
||||
JSYHW_SCQY("jsyhwScqy", "驾驶员注意力监测系统DMS-驾驶员监控红外传感器-生产企业", "0", "", 50),
|
||||
CZWXDW_PZ("czwxdwPz", "定位及导航系统-车载卫星定位设备(接收卫星信号及辅助定位信号的装置,PPP/GNSS/RTK)-配置", "2", "", 0),
|
||||
CZWXDW_GGXH("czwxdwGgxh", "定位及导航系统-车载卫星定位设备(接收卫星信号及辅助定位信号的装置,PPP/GNSS/RTK)-规格型号", "0", "", 50),
|
||||
CZWXDW_SCQY("czwxdwScqy", "定位及导航系统-车载卫星定位设备(接收卫星信号及辅助定位信号的装置,PPP/GNSS/RTK)-生产企业", "0", "", 50),
|
||||
GXDH_PZ("gxdhPz", "定位及导航系统-惯性导航系统-配置", "2", "", 0),
|
||||
GXDH_GGXH("gxdhGgxh", "定位及导航系统-惯性导航系统-规格型号", "0", "", 50),
|
||||
GXDH_SCQY("gxdhScqy", "定位及导航系统-惯性导航系统-生产企业", "0", "", 50),
|
||||
LSJ_PZ("lsjPz", "定位及导航系统-轮速计-配置", "2", "", 0),
|
||||
LSJ_GGXH("lsjGgxh", "定位及导航系统-轮速计-规格型号", "0", "", 50),
|
||||
LSJ_SCQY("lsjScqy", "定位及导航系统-轮速计-生产企业", "0", "", 50),
|
||||
GJDDT_PZ("gjddtPz", "定位及导航系统-高精度地图-配置", "2", "", 0),
|
||||
GJDDT_GGXH("gjddtGgxh", "定位及导航系统-高精度地图-规格型号", "0", "", 50),
|
||||
GJDDT_SCQY("gjddtScqy", "定位及导航系统-高精度地图-生产企业", "0", "", 50),
|
||||
DZWL_PZ("dzwlPz", "定位及导航系统-电子围栏-配置", "2", "", 0),
|
||||
DZWL_DXXGCS("dzwlDxxgcs", "定位及导航系统-电子围栏-定性描述相关场所", "0", "", 50),
|
||||
CZTX_PZ("cztxPz", "车载通信系统-配置", "2", "", 0),
|
||||
CZTX_XTMC("cztxXtmc", "车载通信系统-系统名称", "0", "", 50),
|
||||
CZTX_GGXH("cztxGgxh", "车载通信系统-规格型号", "0", "", 50),
|
||||
CZTX_SCQY("cztxScqy", "车载通信系统-生产企业", "0", "", 50),
|
||||
CZTX_BBH("cztxBbh", "车载通信系统-版本号", "0", "", 50),
|
||||
CZTX_KFQY("cztxKfqy", "车载通信系统-软件开发企业", "0", "", 50),
|
||||
JSFZCZJ_PZ("jsfzczjPz", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能操纵件-配置", "2", "", 0),
|
||||
JSFZCZJ_MC("jsfzczjMc", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能操纵件-操纵件名称", "0", "", 50),
|
||||
JSFZCZJ_YJXH("jsfzczjYjxh", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能操纵件-硬件规格型号", "0", "", 50),
|
||||
JSFZCZJ_SCQY("jsfzczjScqy", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能操纵件-生产企业", "0", "", 50),
|
||||
JSFZZSQ_PZ("jsfzzsqPz", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能指示器/信号装置-配置", "2", "", 0),
|
||||
JSFZZSQ_MC("jsfzzsqMc", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能指示器/信号装置-指示器/信号装置名称", "0", "", 50),
|
||||
JSFZZSQ_YJXH("jsfzzsqYjxh", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能指示器/信号装置-硬件规格型号", "0", "", 50),
|
||||
JSFZZSQ_SCQY("jsfzzsqScqy", "驾驶辅助系统操纵件、指示器及信号装置-驾驶辅助功能指示器/信号装置-生产企业", "0", "", 50),
|
||||
FXPTSTS_PZ("fxptstsPz", "驾驶辅助系统操纵件、指示器及信号装置-方向盘脱手提示器/信号装置-配置", "2", "", 0),
|
||||
FXPTSTS_MC("fxptstsMc", "驾驶辅助系统操纵件、指示器及信号装置-方向盘脱手提示器/信号装置-指示器/信号装置名称", "0", "", 50),
|
||||
FXPTSTS_YJXH("fxptstsYjxh", "驾驶辅助系统操纵件、指示器及信号装置-方向盘脱手提示器/信号装置-硬件规格型号", "0", "", 50),
|
||||
FXPTSTS_SCQY("fxptstsScqy", "驾驶辅助系统操纵件、指示器及信号装置-方向盘脱手提示器/信号装置-生产企业", "0", "", 50),
|
||||
JSYZYLTS_PZ("jsyzyltsPz", "驾驶辅助系统操纵件、指示器及信号装置-驾驶员注意力提醒指示器/信号装置-配置", "2", "", 0),
|
||||
JSYZYLTS_MC("jsyzyltsMc", "驾驶辅助系统操纵件、指示器及信号装置-驾驶员注意力提醒指示器/信号装置-指示器/信号装置名称", "0", "", 50),
|
||||
JSYZYLTS_YJXH("jsyzyltsYjxh", "驾驶辅助系统操纵件、指示器及信号装置-驾驶员注意力提醒指示器/信号装置-硬件规格型号", "0", "", 50),
|
||||
JSYZYLTS_SCQY("jsyzyltsScqy", "驾驶辅助系统操纵件、指示器及信号装置-驾驶员注意力提醒指示器/信号装置-生产企业", "0", "", 50),
|
||||
DSSAD_PZ("dssadPz", "自动驾驶数据记录系统(DSSAD)-系统配置", "2", "", 0),
|
||||
DSSAD_GGXH("dssadGgxh", "自动驾驶数据记录系统(DSSAD)-规格型号", "0", "", 50),
|
||||
DSSAD_SCQY("dssadScqy", "自动驾驶数据记录系统(DSSAD)-生产企业", "0", "", 50),
|
||||
EDR_PZ("edrPz", "事件数据记录系统(EDR)-配置", "2", "", 0),
|
||||
EDR_GGXH("edrGgxh", "事件数据记录系统(EDR)-规格型号", "0", "", 50),
|
||||
EDR_SCQY("edrScqy", "事件数据记录系统(EDR)-生产企业", "0", "", 50),
|
||||
|
||||
BJMC("bjmc", "部件名称", "0"),
|
||||
YJGGXH("yjggxh", "硬件规格型号", "0"),
|
||||
YJSCQY("yjscqy", "硬件生产企业", "0"),
|
||||
RJBB("rjbb", "软件版本", "0"),
|
||||
BZWZ("bzwz", "布置位置", "0"),
|
||||
BJMC("bjmc", "部件名称", "0", "", 50),
|
||||
YJGGXH("yjggxh", "硬件规格型号", "0", "", 50),
|
||||
YJSCQY("yjscqy", "硬件生产企业", "0", "", 50),
|
||||
RJBB("rjbb", "软件版本", "0", "", 50),
|
||||
BZWZ("bzwz", "布置位置", "0", "", 50),
|
||||
|
||||
SJBBHCS("sjbbhcs", "软件版本(集)识别与存储", "0"),
|
||||
SJBBHCS("sjbbhcs", "软件版本(集)识别与存储", "0", "", 500),
|
||||
|
||||
|
||||
BABH("babh", "备案编号", "0"),
|
||||
BAPC("bapc", "备案批次", "0"),
|
||||
ZSL("zsl", "总数量", "0"),
|
||||
SCRQKS("scrqks", "生产日期开始", "3"),
|
||||
SCRQJS("scrqjs", "生产日期结束", "3"),
|
||||
VIN_LIST("vinList", "VIN码清单", "0"),
|
||||
SJMD("sjmd", "升级目的", "uipgrade_purpose"),
|
||||
SFBGCS("sfbgcs", "是否变更对应车型的《公告》技术参数", "2"),
|
||||
JSXNBH("jsxnbh", "是否涉及性能变化", "2"),
|
||||
FHGD("fhgd", "是否符合国家法律、行政法规、规章规定,以及道路机动车辆公告管理相关国家技术标准及安全技术条件等", "2"),
|
||||
ZDJSXG("zdjsxg", "是否涉及汽车自动驾驶功能相关升级", "2"),
|
||||
JRXXG("jrxxg", "兼容性评估相关", "2"),
|
||||
ZXSJ("zxsj", "如何执行升级", "conditions_upgrades"),
|
||||
AQJZ("aqjz", "升级失败或中断后,车辆采取的安全机制", "upgrade_failed"),
|
||||
SFYXAQ("sfyxaq", "升级活动是否影响车辆安全", "2"),
|
||||
YHQR("yhqr", "升级活动是否提供用户确认选项", "2"),
|
||||
SJBCS("sjbcs", "升级包测试", "package_test"),
|
||||
AQKKX("aqkkx", "是否已验证确认在线升级活动的安全性和可靠性", "2"),
|
||||
// BGFJ("bgfj", "提供变更或扩展后的《公告》批次及证明材料", "0"),
|
||||
// CLFJ("clfj", "提供证明材料", "0"),
|
||||
XTMC("xtmc", "系统名称", "0"),
|
||||
SJQBGCS("sjqbgcs", "升级前已变更《公告》参数的对应调整", "0"),
|
||||
SJHBGCS("sjhbgcs", "升级后已变更《公告》参数的对应调整", "0"),
|
||||
SJKZQMC("sjkzqmc", "升级的电子控制器名称", "0"),
|
||||
YJBB("yjbb", "适配的硬件版本", "0"),
|
||||
SJQRJBB("sjqrjbb", "软件版本号升级前", "0"),
|
||||
SJHRJBB("sjhrjbb", "软件版本号升级后", "0"),
|
||||
SJQCZXT("sjqczxt", "操作系统版本号升级前", "0"),
|
||||
SJHCZXT("sjhczxt", "操作系统版本号升级后", "0"),
|
||||
CSRJSJ("csrjsj", "初始软件包的完整性数据", "0"),
|
||||
SJBYZSJ("sjbyzsj", "升级包完整性验证数据", "0"),
|
||||
SJBDX("sjbdx", "升级包大小", "0"),
|
||||
SFCFSJ("sfcfsj", "是否差分升级", "0"),
|
||||
SJMDLX("sjmdlx", "升级目的类型", "0"),
|
||||
GNBGMS("gnbgms", "功能变更描述", "0"),
|
||||
SYTJBG("sytjbg", "适用条件变更", "0"),
|
||||
SJSJKZQ("sjsjkzq", "升级涉及的电子控制器", "0"),
|
||||
GXBH("gxbh", "由于软件升级活动而导致的车辆功能的任何变化", "0"),
|
||||
SJSJ("sjsj", "升级执行预计时间(分钟)", "0"),
|
||||
SJKY("sjky", "升级执行期问,车辆是否可用", "0"),
|
||||
SJBKYGN("sjbkygn", "升级执行期间不可用的车辆功能", "0"),
|
||||
ZDXX("zdxx", "帮助车辆用户安全执行升级的任何指导信息", "0"),
|
||||
SJSFCG("sjsfcg", "告知用户升级成功或失败", "2"),
|
||||
GZBG("gzbg", "告知实施的变更", "2"),
|
||||
GZSCNR("gzscnr", "告知了对用户手册的全部更新内容", "2"),
|
||||
GZYHFS("gzyhfs", "告知用户方式(可多选)", "user_notification_mode"),
|
||||
// XGWJ("xgwj", "用户告知相关文件", "0"),
|
||||
RWMC("rwmc", "任务名称", "0"),
|
||||
SJFBSJ("sjfbsj", "升级发布时间", "3"),
|
||||
SJJZSJ("sjjzsj", "升级计划截止时间", "3");
|
||||
BABH("babh", "备案编号", "0", "", 50),
|
||||
BAPC("bapc", "备案批次", "0", "", 50),
|
||||
ZSL("zsl", "总数量", "0", "", 50),
|
||||
SCRQKS("scrqks", "生产日期开始", "3", "", 0),
|
||||
SCRQJS("scrqjs", "生产日期结束", "3", "", 0),
|
||||
VIN_LIST("vinList", "VIN码清单", "0", "", 500),
|
||||
SJMD("sjmd", "升级目的", "uipgrade_purpose", "", 0),
|
||||
SFBGCS("sfbgcs", "是否变更对应车型的《公告》技术参数", "2", "", 0),
|
||||
JSXNBH("jsxnbh", "是否涉及性能变化", "2", "", 0),
|
||||
FHGD("fhgd", "是否符合国家法律、行政法规、规章规定,以及道路机动车辆公告管理相关国家技术标准及安全技术条件等", "2", "", 0),
|
||||
ZDJSXG("zdjsxg", "是否涉及汽车自动驾驶功能相关升级", "2", "", 0),
|
||||
JRXXG("jrxxg", "兼容性评估相关", "2", "", 0),
|
||||
ZXSJ("zxsj", "如何执行升级", "conditions_upgrades", "", 0),
|
||||
AQJZ("aqjz", "升级失败或中断后,车辆采取的安全机制", "upgrade_failed", "", 0),
|
||||
SFYXAQ("sfyxaq", "升级活动是否影响车辆安全", "2", "", 0),
|
||||
YHQR("yhqr", "升级活动是否提供用户确认选项", "2", "", 0),
|
||||
SJBCS("sjbcs", "升级包测试", "package_test", "", 0),
|
||||
AQKKX("aqkkx", "是否已验证确认在线升级活动的安全性和可靠性", "2", "", 0),
|
||||
// BGFJ("bgfj", "提供变更或扩展后的《公告》批次及证明材料", "0","",0),
|
||||
// CLFJ("clfj", "提供证明材料", "0","",0),
|
||||
XTMC("xtmc", "系统名称", "0", "", 50),
|
||||
SJQBGCS("sjqbgcs", "升级前已变更《公告》参数的对应调整", "0", "", 500),
|
||||
SJHBGCS("sjhbgcs", "升级后已变更《公告》参数的对应调整", "0", "", 500),
|
||||
SJKZQMC("sjkzqmc", "升级的电子控制器名称", "0", "", 50),
|
||||
YJBB("yjbb", "适配的硬件版本", "0", "", 50),
|
||||
SJQRJBB("sjqrjbb", "软件版本号升级前", "0", "", 50),
|
||||
SJHRJBB("sjhrjbb", "软件版本号升级后", "0", "", 50),
|
||||
SJQCZXT("sjqczxt", "操作系统版本号升级前", "0", "", 50),
|
||||
SJHCZXT("sjhczxt", "操作系统版本号升级后", "0", "", 50),
|
||||
CSRJSJ("csrjsj", "初始软件包的完整性数据", "0", "", 500),
|
||||
SJBYZSJ("sjbyzsj", "升级包完整性验证数据", "0", "", 500),
|
||||
SJBDX("sjbdx", "升级包大小", "0", "", 50),
|
||||
SFCFSJ("sfcfsj", "是否差分升级", "0", "", 50),
|
||||
SJMDLX("sjmdlx", "升级目的类型", "0", "", 0),
|
||||
GNBGMS("gnbgms", "功能变更描述", "0", "", 500),
|
||||
SYTJBG("sytjbg", "适用条件变更", "0", "", 500),
|
||||
SJSJKZQ("sjsjkzq", "升级涉及的电子控制器", "0", "", 500),
|
||||
GXBH("gxbh", "由于软件升级活动而导致的车辆功能的任何变化", "0", "", 500),
|
||||
SJSJ("sjsj", "升级执行预计时间(分钟)", "0", "", 50),
|
||||
SJKY("sjky", "升级执行期问,车辆是否可用", "0", "", 50),
|
||||
SJBKYGN("sjbkygn", "升级执行期间不可用的车辆功能", "0", "", 50),
|
||||
ZDXX("zdxx", "帮助车辆用户安全执行升级的任何指导信息", "0", "", 500),
|
||||
SJSFCG("sjsfcg", "告知用户升级成功或失败", "2", "", 0),
|
||||
GZBG("gzbg", "告知实施的变更", "2", "", 0),
|
||||
GZSCNR("gzscnr", "告知了对用户手册的全部更新内容", "2", "", 0),
|
||||
GZYHFS("gzyhfs", "告知用户方式(可多选)", "user_notification_mode", "", 0),
|
||||
// XGWJ("xgwj", "用户告知相关文件", "0","",0),
|
||||
RWMC("rwmc", "任务名称", "0", "", 500),
|
||||
SJFBSJ("sjfbsj", "升级发布时间", "3", "", 0),
|
||||
SJJZSJ("sjjzsj", "升级计划截止时间", "3", "", 0);
|
||||
|
||||
String name;
|
||||
String value;
|
||||
|
||||
//0为不处理。1为数据字典2为处理是否 是1 否2
|
||||
String type;
|
||||
String valueEn;
|
||||
|
||||
OtaTitleEnum(String name, String value, String type) {
|
||||
//字段限制长度
|
||||
int len;
|
||||
|
||||
OtaTitleEnum(String name, String value, String type, String valueEn, int len) {
|
||||
this.name = name;
|
||||
this.value = value;
|
||||
this.type = type;
|
||||
this.valueEn = valueEn;
|
||||
this.len = len;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
@@ -239,6 +245,22 @@ public enum OtaTitleEnum {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
public String getValueEn() {
|
||||
return valueEn;
|
||||
}
|
||||
|
||||
public void setValueEn(String valueEn) {
|
||||
this.valueEn = valueEn;
|
||||
}
|
||||
|
||||
public int getLen() {
|
||||
return len;
|
||||
}
|
||||
|
||||
public void setLen(int len) {
|
||||
this.len = len;
|
||||
}
|
||||
|
||||
public static OtaTitleEnum getOtaTitleEnum(String name) {
|
||||
for (OtaTitleEnum e : values()) {
|
||||
if (e.getName().equals(name)) {
|
||||
|
||||
+2
-2
@@ -68,9 +68,9 @@ public interface IOtaBaCxAqcsService extends IService<OtaBaCxAqcs> {
|
||||
|
||||
void exportTemplate(HttpServletResponse response, HttpServletRequest request);
|
||||
|
||||
OtaBaCxAqcs importData(MultipartFile file, String otaId, String cut) throws Exception;
|
||||
OtaBaCxAqcs importData(MultipartFile file, String otaId, String cut, StringBuilder errMsg) throws Exception;
|
||||
|
||||
OtaBaCxAqcs parseFileList(List<File> upLoadFiles, String otaId, String cut) throws Exception;
|
||||
OtaBaCxAqcs parseFileList(List<File> upLoadFiles, String otaId, String cut, StringBuilder errMsg) throws Exception;
|
||||
|
||||
void exportData(File file, File attFile, String otaId, String cut) throws Exception;
|
||||
}
|
||||
|
||||
+4
-2
@@ -41,6 +41,8 @@ public interface IOtaBaCxJbxxService extends IService<OtaBaCxJbxx> {
|
||||
*/
|
||||
void deleteById(String id);
|
||||
|
||||
void deleteByOtaId(String id);
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
@@ -68,9 +70,9 @@ public interface IOtaBaCxJbxxService extends IService<OtaBaCxJbxx> {
|
||||
|
||||
void exportTemplate(HttpServletResponse response, HttpServletRequest request) throws Exception;
|
||||
|
||||
OtaBaCxJbxx importData(MultipartFile file, String otaId, String cut) throws Exception;
|
||||
OtaBaCxJbxx importData(MultipartFile file, String otaId, String cut, StringBuilder errMsg) throws Exception;
|
||||
|
||||
OtaBaCxJbxx parseFileList(List<File> upLoadFiles, String otaId, String cut) throws Exception;
|
||||
OtaBaCxJbxx parseFileList(List<File> upLoadFiles, String otaId, String cut, StringBuilder errMsg) throws Exception;
|
||||
|
||||
void exportData(File file, String otaId, String cut) throws Exception;
|
||||
}
|
||||
|
||||
+2
-2
@@ -68,9 +68,9 @@ public interface IOtaBaCxJsfzbacsService extends IService<OtaBaCxJsfzbacs> {
|
||||
|
||||
void exportTemplate(HttpServletResponse response, HttpServletRequest request);
|
||||
|
||||
void importData(MultipartFile file, String otaId, String cut) throws Exception;
|
||||
void importData(MultipartFile file, String otaId, String cut, StringBuilder errMsg) throws Exception;
|
||||
|
||||
void parseFileList(List<File> upLoadFiles, String otaId, String cut) throws Exception;
|
||||
void parseFileList(List<File> upLoadFiles, String otaId, String cut, StringBuilder errMsg) throws Exception;
|
||||
|
||||
void exportData(File file, String otaId, String cut) throws Exception;
|
||||
}
|
||||
|
||||
+2
-2
@@ -68,9 +68,9 @@ public interface IOtaBaCxKsjjsmccsService extends IService<OtaBaCxKsjjsmccs> {
|
||||
|
||||
void exportTemplate(HttpServletResponse response, HttpServletRequest request);
|
||||
|
||||
void importData(MultipartFile file, String otaId, String cut) throws Exception;
|
||||
void importData(MultipartFile file, String otaId, String cut, StringBuilder errMsg) throws Exception;
|
||||
|
||||
void parseFileList(List<File> upLoadFiles, String otaId, String cut) throws Exception;
|
||||
void parseFileList(List<File> upLoadFiles, String otaId, String cut, StringBuilder errMsg) throws Exception;
|
||||
|
||||
void exportData(File file, File attFile, String otaId, String cut) throws Exception;
|
||||
}
|
||||
|
||||
+2
-2
@@ -68,9 +68,9 @@ public interface IOtaBaCxKsjxtmccsService extends IService<OtaBaCxKsjxtmccs> {
|
||||
|
||||
void exportTemplate(HttpServletResponse response, HttpServletRequest request);
|
||||
|
||||
void importData(MultipartFile file, String otaId, String cut) throws Exception;
|
||||
void importData(MultipartFile file, String otaId, String cut, StringBuilder errMsg) throws Exception;
|
||||
|
||||
void parseFileList(List<File> upLoadFiles, String otaId, String cut) throws Exception;
|
||||
void parseFileList(List<File> upLoadFiles, String otaId, String cut, StringBuilder errMsg) throws Exception;
|
||||
|
||||
void exportData(File file, File attFile, String otaId, String cut) throws Exception;
|
||||
}
|
||||
|
||||
+1
-1
@@ -68,7 +68,7 @@ public interface IOtaBaCxListService extends IService<OtaBaCxList> {
|
||||
|
||||
void exportTemplate(HttpServletResponse response, HttpServletRequest request);
|
||||
|
||||
void importData(MultipartFile file, String cut) throws Exception;
|
||||
void importData(MultipartFile file, String cut, StringBuilder errMsg) throws Exception;
|
||||
|
||||
void exportData(String otaId, HttpServletResponse response, HttpServletRequest request) throws Exception;
|
||||
|
||||
|
||||
+2
-2
@@ -69,9 +69,9 @@ public interface IOtaBaCxZxsjyqService extends IService<OtaBaCxZxsjyq> {
|
||||
|
||||
void exportTemplate(HttpServletResponse response, HttpServletRequest request);
|
||||
|
||||
OtaBaCxZxsjyq importData(MultipartFile file, String otaId, String cut) throws Exception;
|
||||
OtaBaCxZxsjyq importData(MultipartFile file, String otaId, String cut, StringBuilder errMsg) throws Exception;
|
||||
|
||||
OtaBaCxZxsjyq parseFileList(List<File> upLoadFiles, String otaId, String cut) throws Exception;
|
||||
OtaBaCxZxsjyq parseFileList(List<File> upLoadFiles, String otaId, String cut, StringBuilder errMsg) throws Exception;
|
||||
|
||||
void exportData(File file, File attFile,String otaId, String cut) throws Exception;
|
||||
}
|
||||
|
||||
+12
-7
@@ -209,14 +209,14 @@ public class OtaBaCxAqcsServiceImpl extends ServiceImpl<OtaBaCxAqcsMapper, OtaBa
|
||||
}
|
||||
|
||||
@Override
|
||||
public OtaBaCxAqcs importData(MultipartFile file, String otaId, String cut) throws Exception {
|
||||
public OtaBaCxAqcs importData(MultipartFile file, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
List<File> upLoadFiles = ImportFileUtil.importZip(file, cut, uploadPath);
|
||||
OtaBaCxAqcs aqcs = parseFileList(upLoadFiles, otaId, cut);
|
||||
OtaBaCxAqcs aqcs = parseFileList(upLoadFiles, otaId, cut, errMsg);
|
||||
return aqcs;
|
||||
}
|
||||
|
||||
@Override
|
||||
public OtaBaCxAqcs parseFileList(List<File> upLoadFiles, String otaId, String cut) throws Exception {
|
||||
public OtaBaCxAqcs parseFileList(List<File> upLoadFiles, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
File attFile = null;
|
||||
File upFile = null;
|
||||
for (File f : upLoadFiles) {
|
||||
@@ -229,13 +229,13 @@ public class OtaBaCxAqcsServiceImpl extends ServiceImpl<OtaBaCxAqcsMapper, OtaBa
|
||||
if (null == upFile || null == attFile) {
|
||||
throw new JeroBootException("请上传正确的文件");
|
||||
}
|
||||
OtaBaCxAqcs aqcs = parseFile(upFile, attFile, cut);
|
||||
OtaBaCxAqcs aqcs = parseFile(upFile, attFile, cut, errMsg);
|
||||
aqcs.setOtaId(otaId);
|
||||
add(aqcs);
|
||||
return aqcs;
|
||||
}
|
||||
|
||||
private OtaBaCxAqcs parseFile(File upFile, File attFile, String cut) throws Exception {
|
||||
private OtaBaCxAqcs parseFile(File upFile, File attFile, String cut, StringBuilder errMsg) throws Exception {
|
||||
OtaBaCxAqcs aqcs = new OtaBaCxAqcs();
|
||||
Workbook wb = ImportFileUtil.readExcel(upFile);
|
||||
Sheet s = wb.getSheetAt(0);
|
||||
@@ -256,10 +256,15 @@ public class OtaBaCxAqcsServiceImpl extends ServiceImpl<OtaBaCxAqcsMapper, OtaBa
|
||||
cell = row.getCell(2);
|
||||
aqcs.setXxaqjz(ImportFileUtil.getCellValueDict(cell, wb, "Information_security_mechanism", sysDictService, cut));
|
||||
|
||||
ComparisonUtil cu = new ComparisonUtil();
|
||||
cu.checkError(aqcs, errMsg, sysDictService, cut);
|
||||
|
||||
row = s.getRow(2);
|
||||
cell = row.getCell(3);
|
||||
String[] strs = ImportFileUtil.getCellValue(cell, wb).split(",");
|
||||
List<OSSFile> list = ImportFileUtil.uploadFiles1(attFile, strs, ossFileService);
|
||||
String attStr = ImportFileUtil.getCellValue(cell, wb);
|
||||
String[] strs = attStr.split(",");
|
||||
|
||||
List<OSSFile> list = ImportFileUtil.uploadFiles1(attFile, strs, ossFileService,errMsg, "证明材料", cut);
|
||||
JSONArray obj = new JSONArray();
|
||||
for (OSSFile f : list) {
|
||||
AttachmentEO aeo = new AttachmentEO();
|
||||
|
||||
+35
-19
@@ -117,6 +117,13 @@ public class OtaBaCxJbxxServiceImpl extends ServiceImpl<OtaBaCxJbxxMapper, OtaBa
|
||||
removeById(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void deleteByOtaId(String id) {
|
||||
LambdaQueryWrapper<OtaBaCxJbxx> queryWrapper = new LambdaQueryWrapper<>();
|
||||
queryWrapper.eq(OtaBaCxJbxx::getOtaId, id);
|
||||
remove(queryWrapper);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
@@ -174,14 +181,14 @@ public class OtaBaCxJbxxServiceImpl extends ServiceImpl<OtaBaCxJbxxMapper, OtaBa
|
||||
}
|
||||
|
||||
@Override
|
||||
public OtaBaCxJbxx importData(MultipartFile file, String otaId, String cut) throws Exception {
|
||||
public OtaBaCxJbxx importData(MultipartFile file, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
List<File> upLoadFiles = ImportFileUtil.importZip(file, cut, uploadPath);
|
||||
OtaBaCxJbxx jbxx = parseFileList(upLoadFiles, otaId, cut);
|
||||
OtaBaCxJbxx jbxx = parseFileList(upLoadFiles, otaId, cut, errMsg);
|
||||
return jbxx;
|
||||
}
|
||||
|
||||
@Override
|
||||
public OtaBaCxJbxx parseFileList(List<File> upLoadFiles, String otaId, String cut) throws Exception {
|
||||
public OtaBaCxJbxx parseFileList(List<File> upLoadFiles, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
File upFile = null;
|
||||
for (File f : upLoadFiles) {
|
||||
if (f.getName().equals("车型基本信息.xlsx")) {
|
||||
@@ -189,41 +196,47 @@ public class OtaBaCxJbxxServiceImpl extends ServiceImpl<OtaBaCxJbxxMapper, OtaBa
|
||||
}
|
||||
}
|
||||
if (null == upFile) {
|
||||
throw new JeroBootException("请上传正确的文件");
|
||||
throw new JeroBootException("找不到文件:车型基本信息.xlsx");
|
||||
}
|
||||
OtaBaCxJbxx jbxx = parseFile(upFile, cut);
|
||||
OtaBaCxJbxx jbxx = parseFile(upFile, cut, errMsg);
|
||||
jbxx.setOtaId(otaId);
|
||||
add(jbxx);
|
||||
return jbxx;
|
||||
}
|
||||
|
||||
private OtaBaCxJbxx parseFile(File file, String cut) throws Exception {
|
||||
private OtaBaCxJbxx parseFile(File file, String cut, StringBuilder errMsg) throws Exception {
|
||||
OtaBaCxJbxx jbxx = new OtaBaCxJbxx();
|
||||
Workbook wb = ImportFileUtil.readExcel(file);
|
||||
Sheet s = wb.getSheetAt(0);
|
||||
|
||||
Row row = s.getRow(1);
|
||||
Row row = s.getRow(2);
|
||||
Cell cell = row.getCell(1);
|
||||
jbxx.setQymc(ImportFileUtil.getCellValue(cell, wb));
|
||||
|
||||
row = s.getRow(2);
|
||||
cell = row.getCell(1);
|
||||
String cpbh = ImportFileUtil.getCellValue(cell, wb);
|
||||
if (StringUtils.isEmpty(cpbh)) {
|
||||
throw new JeroBootException("产品编号不能为空");
|
||||
}
|
||||
if (cpbh.length() > 50) {
|
||||
throw new JeroBootException("产品编号字数超过50");
|
||||
}
|
||||
jbxx.setDjbh(cpbh);
|
||||
row = s.getRow(3);
|
||||
cell = row.getCell(1);
|
||||
jbxx.setCplb(ImportFileUtil.getCellValue(cell, wb));
|
||||
|
||||
row = s.getRow(4);
|
||||
cell = row.getCell(1);
|
||||
String ggpc = ImportFileUtil.getCellValue(cell, wb);
|
||||
if (StringUtils.isEmpty(cpbh)) {
|
||||
throw new JeroBootException("公告批次不能为空");
|
||||
if (StringUtils.isNotEmpty(ggpc)) {
|
||||
List<OtaBaCxJbxx> xxList = this.list();
|
||||
for (OtaBaCxJbxx xx : xxList) {
|
||||
if (ggpc.equals(xx.getGgpc())) {
|
||||
throw new JeroBootException("公告批次重复");
|
||||
}
|
||||
}
|
||||
}
|
||||
jbxx.setGgpc(ImportFileUtil.getCellValue(cell, wb));
|
||||
|
||||
jbxx.setGgpc(ggpc);
|
||||
row = s.getRow(1);
|
||||
cell = row.getCell(1);
|
||||
jbxx.setQymc(ImportFileUtil.getCellValue(cell, wb));
|
||||
row = s.getRow(3);
|
||||
cell = row.getCell(1);
|
||||
jbxx.setCplb(ImportFileUtil.getCellValue(cell, wb));
|
||||
row = s.getRow(5);
|
||||
cell = row.getCell(1);
|
||||
jbxx.setCpsb(ImportFileUtil.getCellValue(cell, wb));
|
||||
@@ -245,6 +258,9 @@ public class OtaBaCxJbxxServiceImpl extends ServiceImpl<OtaBaCxJbxxMapper, OtaBa
|
||||
row = s.getRow(11);
|
||||
cell = row.getCell(1);
|
||||
jbxx.setCdotasj(ImportFileUtil.getCellValue(cell, wb));
|
||||
|
||||
ComparisonUtil cu = new ComparisonUtil();
|
||||
cu.checkError(jbxx, errMsg, sysDictService, cut);
|
||||
return jbxx;
|
||||
}
|
||||
|
||||
|
||||
+11
-9
@@ -73,7 +73,7 @@ public class OtaBaCxJsfzbacsServiceImpl extends ServiceImpl<OtaBaCxJsfzbacsMappe
|
||||
ComparisonUtil cu = new ComparisonUtil();
|
||||
if (ObjectUtils.isEmpty(otaBaCxJsfzbacsOld)) {
|
||||
otaBaCxJsfzbacsOld = new OtaBaCxJsfzbacs();
|
||||
}else{
|
||||
} else {
|
||||
otaBaCxJsfzbacs.setId(otaBaCxJsfzbacsOld.getId());
|
||||
}
|
||||
List<OtaBaCxTxjl> reList = cu.comparisonRecord(otaId, OtaModuleEnum.CX_JSFZXTJCBACS, otaBaCxJsfzbacsOld, otaBaCxJsfzbacs, sysDictService);
|
||||
@@ -239,7 +239,7 @@ public class OtaBaCxJsfzbacsServiceImpl extends ServiceImpl<OtaBaCxJsfzbacsMappe
|
||||
}
|
||||
|
||||
private OtaBaCxJsfzbacs getByOtaId(String otaId) {
|
||||
if(StringUtils.isEmpty(otaId)){
|
||||
if (StringUtils.isEmpty(otaId)) {
|
||||
return null;
|
||||
}
|
||||
LambdaQueryWrapper<OtaBaCxJsfzbacs> queryWrapper = new LambdaQueryWrapper<>();
|
||||
@@ -253,14 +253,14 @@ public class OtaBaCxJsfzbacsServiceImpl extends ServiceImpl<OtaBaCxJsfzbacsMappe
|
||||
}
|
||||
|
||||
@Override
|
||||
public void importData(MultipartFile file, String otaId, String cut) throws Exception {
|
||||
public void importData(MultipartFile file, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
List<File> upLoadFiles = ImportFileUtil.importZip(file, cut, uploadPath);
|
||||
parseFileList(upLoadFiles, otaId, cut);
|
||||
parseFileList(upLoadFiles, otaId, cut, errMsg);
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void parseFileList(List<File> upLoadFiles, String otaId, String cut) throws Exception {
|
||||
public void parseFileList(List<File> upLoadFiles, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
File upFile = null;
|
||||
for (File f : upLoadFiles) {
|
||||
if (f.getName().equals("驾驶辅助系统基础备案参数.xlsx")) {
|
||||
@@ -270,7 +270,7 @@ public class OtaBaCxJsfzbacsServiceImpl extends ServiceImpl<OtaBaCxJsfzbacsMappe
|
||||
if (null == upFile) {
|
||||
throw new JeroBootException("请上传正确的文件");
|
||||
}
|
||||
OtaBaCxJsfzbacs basc = parseFile(upFile, otaId, cut);
|
||||
OtaBaCxJsfzbacs basc = parseFile(upFile, otaId, cut, errMsg);
|
||||
Date now = new Date();
|
||||
basc.setCreateTime(now);
|
||||
basc.setUpdateTime(now);
|
||||
@@ -284,7 +284,7 @@ public class OtaBaCxJsfzbacsServiceImpl extends ServiceImpl<OtaBaCxJsfzbacsMappe
|
||||
|
||||
List<OtaBaCxSjmk> oldList = OtaBaCxSjmkService.queryByOtaId(otaId);
|
||||
OtaBaCxSjmkService.deleteByOtaId(otaId);
|
||||
List<OtaBaCxSjmk> sjmkList = parseList(upFile, otaId, cut);
|
||||
List<OtaBaCxSjmk> sjmkList = parseList(upFile, otaId, cut, errMsg);
|
||||
if (ObjectUtils.isEmpty(oldList)) {
|
||||
oldList = new ArrayList<>();
|
||||
}
|
||||
@@ -294,7 +294,7 @@ public class OtaBaCxJsfzbacsServiceImpl extends ServiceImpl<OtaBaCxJsfzbacsMappe
|
||||
}
|
||||
|
||||
|
||||
private List<OtaBaCxSjmk> parseList(File upFile, String otaId, String cut) throws Exception {
|
||||
private List<OtaBaCxSjmk> parseList(File upFile, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
Date now = new Date();
|
||||
List<OtaBaCxSjmk> sjmkList = new ArrayList<>();
|
||||
Workbook wb = ImportFileUtil.readExcel(upFile);
|
||||
@@ -326,13 +326,15 @@ public class OtaBaCxJsfzbacsServiceImpl extends ServiceImpl<OtaBaCxJsfzbacsMappe
|
||||
sjmk.setRjkfqy(ImportFileUtil.getCellValue(cell, wb));
|
||||
cell = row.getCell(7);
|
||||
sjmk.setBzwz(ImportFileUtil.getCellValue(cell, wb));
|
||||
ComparisonUtil cu = new ComparisonUtil();
|
||||
cu.checkError(sjmk, errMsg, sysDictService, cut);
|
||||
sjmkList.add(sjmk);
|
||||
}
|
||||
}
|
||||
return sjmkList;
|
||||
}
|
||||
|
||||
private OtaBaCxJsfzbacs parseFile(File upFile, String otaId, String cut) throws Exception {
|
||||
private OtaBaCxJsfzbacs parseFile(File upFile, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
Workbook wb = ImportFileUtil.readExcel(upFile);
|
||||
Sheet s = wb.getSheetAt(0);
|
||||
OtaBaCxJsfzbacs bass = new OtaBaCxJsfzbacs();
|
||||
|
||||
+9
-6
@@ -240,13 +240,13 @@ public class OtaBaCxKsjjsmccsServiceImpl extends ServiceImpl<OtaBaCxKsjjsmccsMap
|
||||
}
|
||||
|
||||
@Override
|
||||
public void importData(MultipartFile file, String otaId, String cut) throws Exception {
|
||||
public void importData(MultipartFile file, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
List<File> upLoadFiles = ImportFileUtil.importZip(file, cut, uploadPath);
|
||||
parseFileList(upLoadFiles, otaId, cut);
|
||||
parseFileList(upLoadFiles, otaId, cut, errMsg);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void parseFileList(List<File> upLoadFiles, String otaId, String cut) throws Exception {
|
||||
public void parseFileList(List<File> upLoadFiles, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
File attFile = null;
|
||||
File upFile = null;
|
||||
for (File f : upLoadFiles) {
|
||||
@@ -264,7 +264,7 @@ public class OtaBaCxKsjjsmccsServiceImpl extends ServiceImpl<OtaBaCxKsjjsmccsMap
|
||||
if (ObjectUtils.isEmpty(oldList)) {
|
||||
oldList = new ArrayList<>();
|
||||
}
|
||||
List<OtaBaCxKsjjsmccs> mccsList = parseFile(upFile, attFile, otaId, cut);
|
||||
List<OtaBaCxKsjjsmccs> mccsList = parseFile(upFile, attFile, otaId, cut, errMsg);
|
||||
ComparisonUtil cu = new ComparisonUtil();
|
||||
List<OtaBaCxTxjl> reList = cu.comparisonListRecord(otaId, OtaModuleEnum.CX_KZXSJDJSFZGNMCYCS, OtaTitleEnum.GNMC.getName(), oldList, mccsList, sysDictService);
|
||||
deleteByOtaId(otaId);
|
||||
@@ -273,7 +273,7 @@ public class OtaBaCxKsjjsmccsServiceImpl extends ServiceImpl<OtaBaCxKsjjsmccsMap
|
||||
|
||||
}
|
||||
|
||||
private List<OtaBaCxKsjjsmccs> parseFile(File upFile, File attFile, String otaId, String cut) throws Exception {
|
||||
private List<OtaBaCxKsjjsmccs> parseFile(File upFile, File attFile, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
Date now = new Date();
|
||||
List<OtaBaCxKsjjsmccs> mccsList = new ArrayList<>();
|
||||
Workbook wb = ImportFileUtil.readExcel(upFile);
|
||||
@@ -291,7 +291,7 @@ public class OtaBaCxKsjjsmccsServiceImpl extends ServiceImpl<OtaBaCxKsjjsmccsMap
|
||||
cell = row.getCell(1);
|
||||
str = ImportFileUtil.getCellValue(cell, wb);
|
||||
String[] strs = str.split(",");
|
||||
otaBaCxList.setZxsjjsfj(ImportFileUtil.uploadFiles(attFile, strs, ossFileService));
|
||||
otaBaCxList.setZxsjjsfj(ImportFileUtil.uploadFiles(attFile, strs, ossFileService, errMsg, "证明材料", cut));
|
||||
otaBaCxListService.editById(otaBaCxList);
|
||||
}
|
||||
break;
|
||||
@@ -329,6 +329,9 @@ public class OtaBaCxKsjjsmccsServiceImpl extends ServiceImpl<OtaBaCxKsjjsmccsMap
|
||||
cell = row.getCell(13);
|
||||
mssc.setCsyzsj(ImportFileUtil.getCellValue(cell, wb));
|
||||
mssc.setCreateTime(now);
|
||||
|
||||
ComparisonUtil cu = new ComparisonUtil();
|
||||
cu.checkError(mssc, errMsg, sysDictService, cut);
|
||||
mccsList.add(mssc);
|
||||
}
|
||||
}
|
||||
|
||||
+10
-7
@@ -308,13 +308,13 @@ public class OtaBaCxKsjxtmccsServiceImpl extends ServiceImpl<OtaBaCxKsjxtmccsMap
|
||||
}
|
||||
|
||||
@Override
|
||||
public void importData(MultipartFile file, String otaId, String cut) throws Exception {
|
||||
public void importData(MultipartFile file, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
List<File> upLoadFiles = ImportFileUtil.importZip(file, cut, uploadPath);
|
||||
parseFileList(upLoadFiles, otaId, cut);
|
||||
parseFileList(upLoadFiles, otaId, cut, errMsg);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void parseFileList(List<File> upLoadFiles, String otaId, String cut) throws Exception {
|
||||
public void parseFileList(List<File> upLoadFiles, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
File attFile = null;
|
||||
File upFile = null;
|
||||
for (File f : upLoadFiles) {
|
||||
@@ -331,7 +331,7 @@ public class OtaBaCxKsjxtmccsServiceImpl extends ServiceImpl<OtaBaCxKsjxtmccsMap
|
||||
if (ObjectUtils.isEmpty(oldList)) {
|
||||
oldList = new ArrayList<>();
|
||||
}
|
||||
List<OtaBaCxKsjxtmccs> mccsList = parseFile(upFile, attFile, otaId, cut);
|
||||
List<OtaBaCxKsjxtmccs> mccsList = parseFile(upFile, attFile, otaId, cut, errMsg);
|
||||
ComparisonUtil cu = new ComparisonUtil();
|
||||
List<OtaBaCxTxjl> reList = cu.comparisonListRecord(otaId, OtaModuleEnum.CX_KSJDXTMCYCS, OtaTitleEnum.XTLB.getName(), oldList, mccsList, sysDictService);
|
||||
deleteByOtaId(otaId);
|
||||
@@ -339,7 +339,7 @@ public class OtaBaCxKsjxtmccsServiceImpl extends ServiceImpl<OtaBaCxKsjxtmccsMap
|
||||
otaBaCxTxjlService.saveBatch(reList);
|
||||
}
|
||||
|
||||
private List<OtaBaCxKsjxtmccs> parseFile(File upFile, File attFile, String otaId, String cut) throws Exception {
|
||||
private List<OtaBaCxKsjxtmccs> parseFile(File upFile, File attFile, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
Date now = new Date();
|
||||
List<OtaBaCxKsjxtmccs> mccsList = new ArrayList<>();
|
||||
Workbook wb = ImportFileUtil.readExcel(upFile);
|
||||
@@ -357,7 +357,7 @@ public class OtaBaCxKsjxtmccsServiceImpl extends ServiceImpl<OtaBaCxKsjxtmccsMap
|
||||
cell = row.getCell(1);
|
||||
str = ImportFileUtil.getCellValue(cell, wb);
|
||||
String[] strs = str.split(",");
|
||||
otaBaCxList.setZxsjxtfj(ImportFileUtil.uploadFiles(attFile, strs, ossFileService));
|
||||
otaBaCxList.setZxsjxtfj(ImportFileUtil.uploadFiles(attFile, strs, ossFileService, errMsg, "证明材料", cut));
|
||||
otaBaCxListService.editById(otaBaCxList);
|
||||
}
|
||||
break;
|
||||
@@ -374,7 +374,7 @@ public class OtaBaCxKsjxtmccsServiceImpl extends ServiceImpl<OtaBaCxKsjxtmccsMap
|
||||
mssc.setSjbgcs(ImportFileUtil.getCellValue(cell, wb));
|
||||
cell = row.getCell(3);
|
||||
String[] strs = ImportFileUtil.getCellValue(cell, wb).split(",");
|
||||
mssc.setTpt(ImportFileUtil.uploadFiles(attFile, strs, ossFileService));
|
||||
mssc.setTpt(ImportFileUtil.uploadFiles(attFile, strs, ossFileService, errMsg, "系统电子控制器架构拓扑图", cut));
|
||||
cell = row.getCell(4);
|
||||
mssc.setKzqmc(ImportFileUtil.getCellValue(cell, wb));
|
||||
cell = row.getCell(5);
|
||||
@@ -399,6 +399,9 @@ public class OtaBaCxKsjxtmccsServiceImpl extends ServiceImpl<OtaBaCxKsjxtmccsMap
|
||||
mssc.setCzxtbbh(ImportFileUtil.getCellValue(cell, wb));
|
||||
mssc.setCreateTime(now);
|
||||
mssc.setUpdateTime(now);
|
||||
|
||||
ComparisonUtil cu = new ComparisonUtil();
|
||||
cu.checkError(mssc, errMsg, sysDictService, cut);
|
||||
mccsList.add(mssc);
|
||||
}
|
||||
}
|
||||
|
||||
+8
-7
@@ -106,6 +106,7 @@ public class OtaBaCxListServiceImpl extends ServiceImpl<OtaBaCxListMapper, OtaBa
|
||||
@Override
|
||||
public void deleteById(String id) {
|
||||
removeById(id);
|
||||
otaBaCxJbxxService.deleteByOtaId(id);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -173,16 +174,16 @@ public class OtaBaCxListServiceImpl extends ServiceImpl<OtaBaCxListMapper, OtaBa
|
||||
}
|
||||
|
||||
@Override
|
||||
public void importData(MultipartFile file, String cut) throws Exception {
|
||||
public void importData(MultipartFile file, String cut, StringBuilder errMsg) throws Exception {
|
||||
List<File> fileList = ImportFileUtil.importZip(file, cut, uploadPath);
|
||||
OtaBaCxJbxx jbxx = otaBaCxJbxxService.parseFileList(fileList, "", cut);
|
||||
OtaBaCxJbxx jbxx = otaBaCxJbxxService.parseFileList(fileList, "", cut, errMsg);
|
||||
String otaId = jbxx.getOtaId();
|
||||
if (StringUtils.isNotEmpty(otaId)) {
|
||||
otaBaCxZxsjyqService.parseFileList(fileList, otaId, cut);
|
||||
otaBaCxAqcsService.parseFileList(fileList, otaId, cut);
|
||||
otaBaCxKsjxtmccsService.parseFileList(fileList, otaId, cut);
|
||||
otaBaCxKsjjsmccsService.parseFileList(fileList, otaId, cut);
|
||||
otaBaCxJsfzbacsService.parseFileList(fileList, otaId, cut);
|
||||
otaBaCxZxsjyqService.parseFileList(fileList, otaId, cut, errMsg);
|
||||
otaBaCxAqcsService.parseFileList(fileList, otaId, cut, errMsg);
|
||||
otaBaCxKsjxtmccsService.parseFileList(fileList, otaId, cut, errMsg);
|
||||
otaBaCxKsjjsmccsService.parseFileList(fileList, otaId, cut, errMsg);
|
||||
otaBaCxJsfzbacsService.parseFileList(fileList, otaId, cut, errMsg);
|
||||
} else {
|
||||
throw new JeroBootException("导入失败");
|
||||
}
|
||||
|
||||
+9
-6
@@ -201,14 +201,14 @@ public class OtaBaCxZxsjyqServiceImpl extends ServiceImpl<OtaBaCxZxsjyqMapper, O
|
||||
}
|
||||
|
||||
@Override
|
||||
public OtaBaCxZxsjyq importData(MultipartFile file, String otaId, String cut) throws Exception {
|
||||
public OtaBaCxZxsjyq importData(MultipartFile file, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
List<File> upLoadFiles = ImportFileUtil.importZip(file, cut, uploadPath);
|
||||
OtaBaCxZxsjyq otaBaCxZxsjyq = parseFileList(upLoadFiles, otaId, cut);
|
||||
OtaBaCxZxsjyq otaBaCxZxsjyq = parseFileList(upLoadFiles, otaId, cut, errMsg);
|
||||
return otaBaCxZxsjyq;
|
||||
}
|
||||
|
||||
@Override
|
||||
public OtaBaCxZxsjyq parseFileList(List<File> upLoadFiles, String otaId, String cut) throws Exception {
|
||||
public OtaBaCxZxsjyq parseFileList(List<File> upLoadFiles, String otaId, String cut, StringBuilder errMsg) throws Exception {
|
||||
File attFile = null;
|
||||
File upFile = null;
|
||||
for (File f : upLoadFiles) {
|
||||
@@ -221,13 +221,13 @@ public class OtaBaCxZxsjyqServiceImpl extends ServiceImpl<OtaBaCxZxsjyqMapper, O
|
||||
if (null == upFile || null == attFile) {
|
||||
throw new JeroBootException("请上传正确的文件");
|
||||
}
|
||||
OtaBaCxZxsjyq otaBaCxZxsjyq = parseFile(upFile, attFile, cut);
|
||||
OtaBaCxZxsjyq otaBaCxZxsjyq = parseFile(upFile, attFile, cut, errMsg);
|
||||
otaBaCxZxsjyq.setOtaId(otaId);
|
||||
add(otaBaCxZxsjyq);
|
||||
return otaBaCxZxsjyq;
|
||||
}
|
||||
|
||||
private OtaBaCxZxsjyq parseFile(File upFile, File attFile, String cut) throws Exception {
|
||||
private OtaBaCxZxsjyq parseFile(File upFile, File attFile, String cut, StringBuilder errMsg) throws Exception {
|
||||
OtaBaCxZxsjyq otaBaCxZxsjyq = new OtaBaCxZxsjyq();
|
||||
Workbook wb = ImportFileUtil.readExcel(upFile);
|
||||
Sheet s = wb.getSheetAt(0);
|
||||
@@ -262,10 +262,13 @@ public class OtaBaCxZxsjyqServiceImpl extends ServiceImpl<OtaBaCxZxsjyqMapper, O
|
||||
cell = row.getCell(2);
|
||||
otaBaCxZxsjyq.setSjzt(ImportFileUtil.getCellValueYesOrNo(cell, wb));
|
||||
|
||||
ComparisonUtil cu = new ComparisonUtil();
|
||||
cu.checkError(otaBaCxZxsjyq, errMsg, sysDictService, cut);
|
||||
|
||||
row = s.getRow(2);
|
||||
cell = row.getCell(3);
|
||||
String[] strs = ImportFileUtil.getCellValue(cell, wb).split(",");
|
||||
List<OSSFile> list = ImportFileUtil.uploadFiles1(attFile, strs, ossFileService);
|
||||
List<OSSFile> list = ImportFileUtil.uploadFiles1(attFile, strs, ossFileService, errMsg, "证明材料", cut);
|
||||
JSONArray obj = new JSONArray();
|
||||
for (OSSFile f : list) {
|
||||
AttachmentEO aeo = new AttachmentEO();
|
||||
|
||||
+50
@@ -177,6 +177,56 @@ public class ComparisonUtil<T> {
|
||||
return resList;
|
||||
}
|
||||
|
||||
public void checkAttError(String[] strs, StringBuilder errMsg, String title, String cut) {
|
||||
for (String str:strs) {
|
||||
if(!str.endsWith(".doc")&&!str.endsWith(".docx")&&!str.endsWith(".pdf")&&!str.endsWith(".DOC")&&!str.endsWith(".DOCX")&&!str.endsWith(".PDF")){
|
||||
errMsg.append(title + " 支持doc/docx/pdf格式 , ");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void checkError(T clazz, StringBuilder errMsg, ISysDictService sysDictService, String cut) {
|
||||
Field[] fields = clazz.getClass().getDeclaredFields();
|
||||
for (Field field : fields) {
|
||||
OtaTitleEnum ote = OtaTitleEnum.getOtaTitleEnum(field.getName());
|
||||
if (null == ote) {
|
||||
continue;
|
||||
}
|
||||
String title = ote.getValue();
|
||||
field.setAccessible(true);
|
||||
try {
|
||||
Object val = field.get(clazz);
|
||||
if (ObjectUtils.isNotEmpty(val)) {
|
||||
String str = val.toString();
|
||||
if ("0".equals(ote.getType())) {
|
||||
if (str.length() > ote.getLen()) {
|
||||
errMsg.append(title + " 的长度超过了 " + ote.getLen() + ", ");
|
||||
field.set(clazz, "");
|
||||
}
|
||||
} else if ("2".equals(ote.getType())) {
|
||||
if (!"是".equals(str) && !"否".equals(str)) {
|
||||
errMsg.append(title + " 必须填写是或否 , ");
|
||||
field.set(clazz, "");
|
||||
}
|
||||
} else if ("3".equals(ote.getType())) {
|
||||
//不处理
|
||||
} else {
|
||||
String[] strs = str.split(",");
|
||||
for (String s : strs) {
|
||||
String res = sysDictService.queryDictItemByValue(ote.getType(), s, cut);
|
||||
if (StringUtils.isEmpty(res)) {
|
||||
errMsg.append(title + " 填写了无法识别的选项 , ");
|
||||
field.set(clazz, "");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (IllegalAccessException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public List<OtaBaCxTxjl> comparisonCertRecord(String otaId, OtaModuleEnum otaModuleEnum, String tableTitle, T oldClazz, T newClazz, ISysDictService sysDictService) {
|
||||
List<OtaBaCxTxjl> resList = new ArrayList<>();
|
||||
|
||||
+25
-8
@@ -91,10 +91,7 @@ public class ImportFileUtil {
|
||||
List<File> fileList = new ArrayList<>();
|
||||
File fileNew = ImportFileUtil.copyZip(file, cut, uploadPath);
|
||||
for (File file1 : fileNew.listFiles()) {
|
||||
if (file1.getName().contains(".xls") || file1.getName().contains(".xlsx") || file1.isDirectory()
|
||||
|| file1.getName().contains(".docx") || file1.getName().contains(".doc")) {
|
||||
fileList.add(file1);
|
||||
}
|
||||
fileList.add(file1);
|
||||
}
|
||||
return fileList;
|
||||
}
|
||||
@@ -278,13 +275,23 @@ public class ImportFileUtil {
|
||||
return mFile;
|
||||
}
|
||||
|
||||
public static List<OSSFile> uploadFiles1(File attFile, String[] strs, IOSSFileService ossFileService) throws Exception {
|
||||
public static List<OSSFile> uploadFiles1(File attFile, String[] strs, IOSSFileService ossFileService, StringBuilder errMsg, String title, String cut) throws Exception {
|
||||
List<OSSFile> res = new ArrayList<>();
|
||||
for (int i = 0; i < strs.length; i++) {
|
||||
if (StringUtils.isNotEmpty(strs[i])) {
|
||||
File file = ImportFileUtil.findFile(attFile, strs[i]);
|
||||
if (null == file) {
|
||||
throw new JeroBootException("找不到文件:" + strs[i]);
|
||||
errMsg.append(title + " 找不到文件 , ");
|
||||
continue;
|
||||
}
|
||||
if (!file.getName().endsWith(".doc") && !file.getName().endsWith(".docx") && !file.getName().endsWith(".pdf")
|
||||
&& !file.getName().endsWith(".DOC") && !file.getName().endsWith(".DOCX") && !file.getName().endsWith(".PDF")) {
|
||||
errMsg.append(title + " 只支持doc/docx/pdf格式 , ");
|
||||
continue;
|
||||
}
|
||||
if (file.length() > 50 * 1024 * 1024) {
|
||||
errMsg.append(title + " 上传文件不可以超过50MB , ");
|
||||
continue;
|
||||
}
|
||||
OSSFile ossFile = ossFileService.uploadLocalOfCos(ImportFileUtil.createMfileByFile(file), "", null, null);
|
||||
if (ObjectUtils.isNotEmpty(ossFile)) {
|
||||
@@ -304,13 +311,23 @@ public class ImportFileUtil {
|
||||
return res;
|
||||
}
|
||||
|
||||
public static String uploadFiles(File attFile, String[] strs, IOSSFileService ossFileService) throws Exception {
|
||||
public static String uploadFiles(File attFile, String[] strs, IOSSFileService ossFileService, StringBuilder errMsg, String title, String cut) throws Exception {
|
||||
String res = "";
|
||||
for (int i = 0; i < strs.length; i++) {
|
||||
if (StringUtils.isNotEmpty(strs[i])) {
|
||||
File file = ImportFileUtil.findFile(attFile, strs[i]);
|
||||
if (null == file) {
|
||||
throw new JeroBootException("找不到文件:" + strs[i]);
|
||||
errMsg.append(title + " 找不到文件 , ");
|
||||
continue;
|
||||
}
|
||||
if (!file.getName().endsWith(".doc") && !file.getName().endsWith(".docx") && !file.getName().endsWith(".pdf")
|
||||
&& !file.getName().endsWith(".DOC") && !file.getName().endsWith(".DOCX") && !file.getName().endsWith(".PDF")) {
|
||||
errMsg.append(title + " 只支持doc/docx/pdf格式 , ");
|
||||
continue;
|
||||
}
|
||||
if (file.length() > 50 * 1024 * 1024) {
|
||||
errMsg.append(title + " 上传文件不可以超过50MB , ");
|
||||
continue;
|
||||
}
|
||||
OSSFile ossFile = ossFileService.uploadLocalOfCos(ImportFileUtil.createMfileByFile(file), "", null, null);
|
||||
if (ObjectUtils.isNotEmpty(ossFile)) {
|
||||
|
||||
Reference in New Issue
Block a user