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

This commit is contained in:
wangzhijiang
2023-03-27 14:16:57 +08:00
28 changed files with 758 additions and 374 deletions
@@ -204,7 +204,10 @@ public class OtaBaCxAqcsController extends JeroController<OtaBaCxAqcs, IOtaBaCxA
@RequestParam(value = "otaId", required = false) String otaId) throws Exception {
OtaBaCxAqcs res;
try {
res = this.otaBaCxAqcsService.importData(file, otaId, cut);
String[] params = otaId.split("\\?");
otaId = params[0].equals("null") ? "" : params[0];
cut = params[1].replace("cut=", "");
res = this.otaBaCxAqcsService.importData(file, params[0], cut);
} catch (Exception e) {
e.printStackTrace();
return Result.error(e.getMessage());
@@ -198,6 +198,9 @@ public class OtaBaCxJbxxController extends JeroController<OtaBaCxJbxx, IOtaBaCxJ
@RequestParam(value = "otaId", required = false) String otaId) throws Exception {
OtaBaCxJbxx res;
try {
String[] params = otaId.split("\\?");
otaId = params[0].equals("null") ? "" : params[0];
cut = params[1].replace("cut=", "");
res = this.otaBaCxJbxxService.importData(file, otaId, cut);
} catch (Exception e) {
e.printStackTrace();
@@ -200,6 +200,9 @@ public class OtaBaCxJsfzbacsController extends JeroController<OtaBaCxJsfzbacs, I
@RequestParam(value = "cut", required = false) String cut,
@RequestParam(value = "otaId", required = false) String otaId) throws Exception {
try {
String[] params = otaId.split("\\?");
otaId = params[0].equals("null") ? "" : params[0];
cut = params[1].replace("cut=", "");
this.otaBaCxJsfzbacsService.importData(file, otaId, cut);
} catch (Exception e) {
e.printStackTrace();
@@ -201,6 +201,9 @@ public class OtaBaCxKsjjsmccsController extends JeroController<OtaBaCxKsjjsmccs,
@RequestParam(value = "cut", required = false) String cut,
@RequestParam(value = "otaId", required = false) String otaId) throws Exception {
try {
String[] params = otaId.split("\\?");
otaId = params[0].equals("null") ? "" : params[0];
cut = params[1].replace("cut=", "");
this.otaBaCxKsjjsmccsService.importData(file, otaId, cut);
} catch (Exception e) {
e.printStackTrace();
@@ -203,6 +203,9 @@ public class OtaBaCxKsjxtmccsController extends JeroController<OtaBaCxKsjxtmccs,
@RequestParam(value = "cut", required = false) String cut,
@RequestParam(value = "otaId", required = false) String otaId) throws Exception {
try {
String[] params = otaId.split("\\?");
otaId = params[0].equals("null") ? "" : params[0];
cut = params[1].replace("cut=", "");
this.otaBaCxKsjxtmccsService.importData(file, otaId, cut);
} catch (Exception e) {
e.printStackTrace();
@@ -199,6 +199,9 @@ public class OtaBaCxZxsjyqController extends JeroController<OtaBaCxZxsjyq, IOtaB
@RequestParam(value = "otaId", required = false) String otaId) throws Exception {
OtaBaCxZxsjyq res;
try {
String[] params = otaId.split("\\?");
otaId = params[0].equals("null") ? "" : params[0];
cut = params[1].replace("cut=", "");
res = this.otaBaCxZxsjyqService.importData(file, otaId, cut);
} catch (Exception e) {
e.printStackTrace();
@@ -68,35 +68,35 @@ public class OtaBaCxJsfzbacs implements Serializable {
@ApiModelProperty(value = "otaid")
private java.lang.String otaId;
/**网络安全要求配置*/
@Excel(name = "网络安全要求配置", width = 15)
@ApiModelProperty(value = "网络安全要求配置")
private java.lang.String wlaqyqPz;
/**激光雷达配置*/
@Excel(name = "激光雷达配置", width = 15)
@ApiModelProperty(value = "激光雷达配置")
private java.lang.Integer jgldPz;
/**网络安全要求数量*/
@Excel(name = "网络安全要求数量", width = 15)
@ApiModelProperty(value = "网络安全要求数量")
private java.lang.String wlaqyqSl;
/**激光雷达数量*/
@Excel(name = "激光雷达数量", width = 15)
@ApiModelProperty(value = "激光雷达数量")
private java.lang.String jgldSl;
/**网络安全要求布置位置*/
@Excel(name = "网络安全要求布置位置", width = 15)
@ApiModelProperty(value = "网络安全要求布置位置")
private java.lang.String wlaqyqBzwz;
/**激光雷达布置位置*/
@Excel(name = "激光雷达布置位置", width = 15)
@ApiModelProperty(value = "激光雷达布置位置")
private java.lang.String jgldBzwz;
/**网络安全要求规格型号*/
@Excel(name = "网络安全要求规格型号", width = 15)
@ApiModelProperty(value = "网络安全要求规格型号")
private java.lang.String wlaqyqGgxh;
/**激光雷达规格型号*/
@Excel(name = "激光雷达规格型号", width = 15)
@ApiModelProperty(value = "激光雷达规格型号")
private java.lang.String jgldGgxh;
/**网络安全要求生产企业*/
@Excel(name = "网络安全要求生产企业", width = 15)
@ApiModelProperty(value = "网络安全要求生产企业")
private java.lang.String wlaqyqScqy;
/**激光雷达生产企业*/
@Excel(name = "激光雷达生产企业", width = 15)
@ApiModelProperty(value = "激光雷达生产企业")
private java.lang.String jgldScqy;
/**毫米波雷达配置*/
@Excel(name = "毫米波雷达配置", width = 15)
@ApiModelProperty(value = "毫米波雷达配置")
private java.lang.String hmbldPz;
private java.lang.Integer hmbldPz;
/**毫米波雷达数量*/
@Excel(name = "毫米波雷达数量", width = 15)
@@ -121,7 +121,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**超声波雷达配置*/
@Excel(name = "超声波雷达配置", width = 15)
@ApiModelProperty(value = "超声波雷达配置")
private java.lang.String csbldPz;
private java.lang.Integer csbldPz;
/**超声波雷达数量*/
@Excel(name = "超声波雷达数量", width = 15)
@@ -146,7 +146,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**摄像头倒车影像/(环视)配置*/
@Excel(name = "摄像头倒车影像/(环视)配置", width = 15)
@ApiModelProperty(value = "摄像头倒车影像/(环视)配置")
private java.lang.String sxthsPz;
private java.lang.Integer sxthsPz;
/**摄像头倒车影像/(环视)数量*/
@Excel(name = "摄像头倒车影像/(环视)数量", width = 15)
@@ -171,7 +171,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**摄像头单双多目配置*/
@Excel(name = "摄像头单双多目配置", width = 15)
@ApiModelProperty(value = "摄像头单双多目配置")
private java.lang.String sxtdsdPz;
private java.lang.Integer sxtdsdPz;
/**摄像头单双多目数量*/
@Excel(name = "摄像头单双多目数量", width = 15)
@@ -196,7 +196,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**驾驶员监控摄像头配置*/
@Excel(name = "驾驶员监控摄像头配置", width = 15)
@ApiModelProperty(value = "驾驶员监控摄像头配置")
private java.lang.String jsyjkPz;
private java.lang.Integer jsyjkPz;
/**驾驶员监控摄像头数量*/
@Excel(name = "驾驶员监控摄像头数量", width = 15)
@@ -221,7 +221,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**驾驶员监控红外传感器配置*/
@Excel(name = "驾驶员监控红外传感器配置", width = 15)
@ApiModelProperty(value = "驾驶员监控红外传感器配置")
private java.lang.String jsyhwPz;
private java.lang.Integer jsyhwPz;
/**驾驶员监控红外传感器数量*/
@Excel(name = "驾驶员监控红外传感器数量", width = 15)
@@ -246,7 +246,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**车载卫星定位设备配置*/
@Excel(name = "车载卫星定位设备配置", width = 15)
@ApiModelProperty(value = "车载卫星定位设备配置")
private java.lang.String czwxdwPz;
private java.lang.Integer czwxdwPz;
/**车载卫星定位设备规格型号*/
@Excel(name = "车载卫星定位设备规格型号", width = 15)
@@ -261,7 +261,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**惯性导航系统配置*/
@Excel(name = "惯性导航系统配置", width = 15)
@ApiModelProperty(value = "惯性导航系统配置")
private java.lang.String gxdhPz;
private java.lang.Integer gxdhPz;
/**惯性导航系统规格型号*/
@Excel(name = "惯性导航系统规格型号", width = 15)
@@ -276,7 +276,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**轮速计配置*/
@Excel(name = "轮速计配置", width = 15)
@ApiModelProperty(value = "轮速计配置")
private java.lang.String lsjPz;
private java.lang.Integer lsjPz;
/**轮速计规格型号*/
@Excel(name = "轮速计规格型号", width = 15)
@@ -291,7 +291,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**高精度地图配置*/
@Excel(name = "高精度地图配置", width = 15)
@ApiModelProperty(value = "高精度地图配置")
private java.lang.String gjddtPz;
private java.lang.Integer gjddtPz;
/**高精度地图规格型号*/
@Excel(name = "高精度地图规格型号", width = 15)
@@ -306,7 +306,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**电子围栏配置*/
@Excel(name = "电子围栏配置", width = 15)
@ApiModelProperty(value = "电子围栏配置")
private java.lang.String dzwlPz;
private java.lang.Integer dzwlPz;
/**电子围栏*/
@Excel(name = "电子围栏", width = 15)
@@ -316,7 +316,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**车载通信系统配置*/
@Excel(name = "车载通信系统配置", width = 15)
@ApiModelProperty(value = "车载通信系统配置")
private java.lang.String cztxPz;
private java.lang.Integer cztxPz;
/**车载通信系统系统名称*/
@Excel(name = "车载通信系统系统名称", width = 15)
@@ -346,7 +346,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**驾驶辅助功能操纵件配置*/
@Excel(name = "驾驶辅助功能操纵件配置", width = 15)
@ApiModelProperty(value = "驾驶辅助功能操纵件配置")
private java.lang.String jsfzczjPz;
private java.lang.Integer jsfzczjPz;
/**驾驶辅助功能操纵件名称*/
@Excel(name = "驾驶辅助功能操纵件名称", width = 15)
@@ -366,7 +366,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**驾驶辅助功能指示器配置*/
@Excel(name = "驾驶辅助功能指示器配置", width = 15)
@ApiModelProperty(value = "驾驶辅助功能指示器配置")
private java.lang.String jsfzzsqPz;
private java.lang.Integer jsfzzsqPz;
/**驾驶辅助功能指示器名称*/
@Excel(name = "驾驶辅助功能指示器名称", width = 15)
@@ -386,7 +386,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**方向盘脱手提示器配置*/
@Excel(name = "方向盘脱手提示器配置", width = 15)
@ApiModelProperty(value = "方向盘脱手提示器配置")
private java.lang.String fxptstsPz;
private java.lang.Integer fxptstsPz;
/**方向盘脱手提示器名称*/
@Excel(name = "方向盘脱手提示器名称", width = 15)
@@ -406,7 +406,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**驾驶员注意力提醒指示器配置*/
@Excel(name = "驾驶员注意力提醒指示器配置", width = 15)
@ApiModelProperty(value = "驾驶员注意力提醒指示器配置")
private java.lang.String jsyzyltsPz;
private java.lang.Integer jsyzyltsPz;
/**驾驶员注意力提醒指示器名称*/
@Excel(name = "驾驶员注意力提醒指示器名称", width = 15)
@@ -426,7 +426,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**自动驾驶数据记录系统配置*/
@Excel(name = "自动驾驶数据记录系统配置", width = 15)
@ApiModelProperty(value = "自动驾驶数据记录系统配置")
private java.lang.String dssadPz;
private java.lang.Integer dssadPz;
/**自动驾驶数据记录系统规格型号*/
@Excel(name = "自动驾驶数据记录系统规格型号", width = 15)
@@ -441,7 +441,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
/**事件数据记录系统配置*/
@Excel(name = "事件数据记录系统配置", width = 15)
@ApiModelProperty(value = "事件数据记录系统配置")
private java.lang.String edrPz;
private java.lang.Integer edrPz;
/**事件数据记录系统规格型号*/
@Excel(name = "事件数据记录系统规格型号", width = 15)
@@ -457,7 +457,7 @@ public class OtaBaCxJsfzbacs implements Serializable {
}
public OtaBaCxJsfzbacs(String id, String createBy, Date createTime, String updateBy, Date updateTime, String sysOrgCode, String otaId, String wlaqyqPz, String wlaqyqSl, String wlaqyqBzwz, String wlaqyqGgxh, String wlaqyqScqy, String hmbldPz, String hmbldSl, String hmbldBzwz, String hmbldGgxh, String hmbldScqy, String csbldPz, String csbldSl, String csbldBzwz, String csbldGgxh, String csbldScqy, String sxthsPz, String sxthsSl, String sxthsBzwz, String sxthsGgxh, String sxthsScqy, String sxtdsdPz, String sxtdsdSl, String sxtdsdBzwz, String sxtdsdGgxh, String sxtdsdScqy, String jsyjkPz, String jsyjkSl, String jsyjkBzwz, String jsyjkGgxh, String jsyjkScqy, String jsyhwPz, String jsyhwSl, String jsyhwBzwz, String jsyhwGgxh, String jsyhwScqy, String czwxdwPz, String czwxdwGgxh, String czwxdwScqy, String gxdhPz, String gxdhGgxh, String gxdhScqy, String lsjPz, String lsjGgxh, String lsjScqy, String gjddtPz, String gjddtGgxh, String gjddtScqy, String dzwlPz, String dzwlDxxgcs, String cztxPz, String cztxXtmc, String cztxGgxh, String cztxScqy, String cztxBbh, String cztxKfqy, String jsfzczjPz, String jsfzczjMc, String jsfzczjYjxh, String jsfzczjScqy, String jsfzzsqPz, String jsfzzsqMc, String jsfzzsqYjxh, String jsfzzsqScqy, String fxptstsPz, String fxptstsMc, String fxptstsYjxh, String fxptstsScqy, String jsyzyltsPz, String jsyzyltsMc, String jsyzyltsYjxh, String jsyzyltsScqy, String dssadPz, String dssadGgxh, String dssadScqy, String edrPz, String edrGgxh, String edrScqy) {
public OtaBaCxJsfzbacs(String id, String createBy, Date createTime, String updateBy, Date updateTime, String sysOrgCode, String otaId, int jgldPz, String jgldSl, String jgldBzwz, String jgldGgxh, String jgldScqy, int hmbldPz, String hmbldSl, String hmbldBzwz, String hmbldGgxh, String hmbldScqy, int csbldPz, String csbldSl, String csbldBzwz, String csbldGgxh, String csbldScqy, int sxthsPz, String sxthsSl, String sxthsBzwz, String sxthsGgxh, String sxthsScqy, int sxtdsdPz, String sxtdsdSl, String sxtdsdBzwz, String sxtdsdGgxh, String sxtdsdScqy, int jsyjkPz, String jsyjkSl, String jsyjkBzwz, String jsyjkGgxh, String jsyjkScqy, int jsyhwPz, String jsyhwSl, String jsyhwBzwz, String jsyhwGgxh, String jsyhwScqy, int czwxdwPz, String czwxdwGgxh, String czwxdwScqy, int gxdhPz, String gxdhGgxh, String gxdhScqy, int lsjPz, String lsjGgxh, String lsjScqy, int gjddtPz, String gjddtGgxh, String gjddtScqy, int dzwlPz, String dzwlDxxgcs, int cztxPz, String cztxXtmc, String cztxGgxh, String cztxScqy, String cztxBbh, String cztxKfqy, int jsfzczjPz, String jsfzczjMc, String jsfzczjYjxh, String jsfzczjScqy, int jsfzzsqPz, String jsfzzsqMc, String jsfzzsqYjxh, String jsfzzsqScqy, int fxptstsPz, String fxptstsMc, String fxptstsYjxh, String fxptstsScqy, int jsyzyltsPz, String jsyzyltsMc, String jsyzyltsYjxh, String jsyzyltsScqy, int dssadPz, String dssadGgxh, String dssadScqy, int edrPz, String edrGgxh, String edrScqy) {
this.id = id;
this.createBy = createBy;
this.createTime = createTime;
@@ -465,11 +465,11 @@ public class OtaBaCxJsfzbacs implements Serializable {
this.updateTime = updateTime;
this.sysOrgCode = sysOrgCode;
this.otaId = otaId;
this.wlaqyqPz = wlaqyqPz;
this.wlaqyqSl = wlaqyqSl;
this.wlaqyqBzwz = wlaqyqBzwz;
this.wlaqyqGgxh = wlaqyqGgxh;
this.wlaqyqScqy = wlaqyqScqy;
this.jgldPz = jgldPz;
this.jgldSl = jgldSl;
this.jgldBzwz = jgldBzwz;
this.jgldGgxh = jgldGgxh;
this.jgldScqy = jgldScqy;
this.hmbldPz = hmbldPz;
this.hmbldSl = hmbldSl;
this.hmbldBzwz = hmbldBzwz;
@@ -65,11 +65,11 @@ public enum OtaTitleEnum {
CSYZSJ("csyzsj", "初始软件包的完整性验证数据", "0"),
FJ("fj", "附件", "0"),
WLAQYQ_PZ("wlaqyqPz", "网络安全要求配置", "2"),
WLAQYQ_SL("wlaqyqSl", "网络安全要求数量", "0"),
WLAQYQ_BZWZ("wlaqyqBzwz", "网络安全要求布置位置", "0"),
WLAQYQ_GGXH("wlaqyqGgxh", "网络安全要求规格型号", "0"),
WLAQYQ_SCQY("wlaqyqScqy", "网络安全要求生产企业", "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"),
@@ -5,9 +5,7 @@ import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.jero.common.exception.JeroBootException;
import com.jero.modules.ota.entity.OtaBaCxJsfzbacs;
import com.jero.modules.ota.entity.OtaBaCxSjmk;
import com.jero.modules.ota.entity.OtaBaCxTxjl;
import com.jero.modules.ota.entity.*;
import com.jero.modules.ota.enums.OtaModuleEnum;
import com.jero.modules.ota.enums.OtaTitleEnum;
import com.jero.modules.ota.mapper.OtaBaCxJsfzbacsMapper;
@@ -18,6 +16,11 @@ import com.jero.modules.ota.utils.ComparisonUtil;
import com.jero.modules.ota.utils.ImportFileUtil;
import com.jero.modules.system.service.ISysDictService;
import org.apache.commons.lang3.ObjectUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.poi.ss.usermodel.Cell;
import org.apache.poi.ss.usermodel.Row;
import org.apache.poi.ss.usermodel.Sheet;
import org.apache.poi.ss.usermodel.Workbook;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;
@@ -60,12 +63,12 @@ public class OtaBaCxJsfzbacsServiceImpl extends ServiceImpl<OtaBaCxJsfzbacsMappe
public void add(JSONObject json) {
OtaBaCxJsfzbacs otaBaCxJsfzbacs = new OtaBaCxJsfzbacs();
String otaId = json.getString("otaId");
OtaBaCxJsfzbacs otaBaCxJsfzbacsOld = this.getByOtaId(otaId);
otaBaCxJsfzbacs.setOtaId(otaId);
parseBjData(json, otaBaCxJsfzbacs);
Date now = new Date();
otaBaCxJsfzbacs.setCreateTime(now);
otaBaCxJsfzbacs.setUpdateTime(now);
OtaBaCxJsfzbacs otaBaCxJsfzbacsOld = this.getByOtaId(otaId);
ComparisonUtil cu = new ComparisonUtil();
if (ObjectUtils.isEmpty(otaBaCxJsfzbacsOld)) {
otaBaCxJsfzbacsOld = new OtaBaCxJsfzbacs();
@@ -251,15 +254,321 @@ public class OtaBaCxJsfzbacsServiceImpl extends ServiceImpl<OtaBaCxJsfzbacsMappe
if (null == upFile) {
throw new JeroBootException("请上传正确的文件");
}
JSONObject json = parseFile(upFile, otaId, cut);
OtaBaCxJsfzbacs basc = parseFile(upFile, otaId, cut);
Date now = new Date();
basc.setCreateTime(now);
basc.setUpdateTime(now);
OtaBaCxJsfzbacs otaBaCxJsfzbacsOld = this.getByOtaId(otaId);
ComparisonUtil cu = new ComparisonUtil();
if (ObjectUtils.isEmpty(otaBaCxJsfzbacsOld)) {
otaBaCxJsfzbacsOld = new OtaBaCxJsfzbacs();
}
List<OtaBaCxTxjl> reList = cu.comparisonRecord(otaId, OtaModuleEnum.CX_JSFZXTJCBACS, otaBaCxJsfzbacsOld, basc, sysDictService);
saveOrUpdate(basc);
List<OtaBaCxSjmk> oldList = OtaBaCxSjmkService.queryByOtaId(otaId);
OtaBaCxSjmkService.deleteByOtaId(otaId);
List<OtaBaCxSjmk> sjmkList = parseList(upFile, otaId, cut);
reList.addAll(cu.comparisonListRecord(otaId, OtaModuleEnum.CX_JSFZXTJCBACS, OtaTitleEnum.BJMC.getName(), oldList, sjmkList, sysDictService));
OtaBaCxSjmkService.saveOrUpdateBatch(sjmkList);
otaBaCxTxjlService.saveBatch(reList);
}
private JSONObject parseFile(File upFile, String otaId, String cut) {
JSONObject jsonObj = new JSONObject();
jsonObj.put("otaId",otaId);
private List<OtaBaCxSjmk> parseList(File upFile, String otaId, String cut) throws Exception {
Date now = new Date();
List<OtaBaCxSjmk> sjmkList = new ArrayList<>();
Workbook wb = ImportFileUtil.readExcel(upFile);
Sheet s = wb.getSheetAt(0);
int rows = s.getPhysicalNumberOfRows();
for (int i = 63; i < rows; i++) {
Row row = s.getRow(i);
Cell cell = row.getCell(0);
String str = ImportFileUtil.getCellValue(cell, wb);
OtaBaCxSjmk sjmk = new OtaBaCxSjmk();
if (StringUtils.isEmpty(str)) {
//列表数据数量,部件名称为空时结束
break;
} else {
sjmk.setOtaId(otaId);
sjmk.setCreateTime(now);
sjmk.setBjmc(str);
cell = row.getCell(1);
sjmk.setPzqk(ImportFileUtil.getCellValueYesOrNo(cell, wb));
cell = row.getCell(2);
sjmk.setKzqmc(ImportFileUtil.getCellValue(cell, wb));
cell = row.getCell(3);
sjmk.setYjggxh(ImportFileUtil.getCellValue(cell, wb));
cell = row.getCell(4);
sjmk.setYjscqy(ImportFileUtil.getCellValue(cell, wb));
cell = row.getCell(5);
sjmk.setRjbb(ImportFileUtil.getCellValue(cell, wb));
cell = row.getCell(6);
sjmk.setRjkfqy(ImportFileUtil.getCellValue(cell, wb));
cell = row.getCell(7);
sjmk.setBzwz(ImportFileUtil.getCellValue(cell, wb));
sjmkList.add(sjmk);
}
}
return sjmkList;
}
private OtaBaCxJsfzbacs parseFile(File upFile, String otaId, String cut) throws Exception {
Workbook wb = ImportFileUtil.readExcel(upFile);
Sheet s = wb.getSheetAt(0);
OtaBaCxJsfzbacs bass = new OtaBaCxJsfzbacs();
bass.setOtaId(otaId);
Row row = s.getRow(2);
Cell cell = row.getCell(2);
bass.setJsfzczjPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(2);
cell = row.getCell(4);
bass.setJgldSl(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(3);
cell = row.getCell(4);
bass.setJgldBzwz(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(4);
cell = row.getCell(4);
bass.setJgldGgxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(5);
cell = row.getCell(4);
bass.setJgldScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(6);
cell = row.getCell(2);
bass.setHmbldPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(6);
cell = row.getCell(4);
bass.setHmbldSl(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(7);
cell = row.getCell(4);
bass.setHmbldBzwz(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(8);
cell = row.getCell(4);
bass.setHmbldGgxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(9);
cell = row.getCell(4);
bass.setHmbldScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(10);
cell = row.getCell(2);
bass.setCsbldPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(10);
cell = row.getCell(4);
bass.setCsbldSl(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(11);
cell = row.getCell(4);
bass.setCsbldBzwz(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(12);
cell = row.getCell(4);
bass.setCsbldGgxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(13);
cell = row.getCell(4);
bass.setCsbldScqy(ImportFileUtil.getCellValue(cell, wb));
return jsonObj;
row = s.getRow(14);
cell = row.getCell(2);
bass.setSxthsPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(14);
cell = row.getCell(4);
bass.setSxthsSl(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(15);
cell = row.getCell(4);
bass.setSxthsBzwz(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(16);
cell = row.getCell(4);
bass.setSxthsGgxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(17);
cell = row.getCell(4);
bass.setSxthsScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(18);
cell = row.getCell(2);
bass.setSxtdsdPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(18);
cell = row.getCell(4);
bass.setSxtdsdSl(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(19);
cell = row.getCell(4);
bass.setSxtdsdBzwz(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(20);
cell = row.getCell(4);
bass.setSxtdsdGgxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(21);
cell = row.getCell(4);
bass.setSxtdsdScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(22);
cell = row.getCell(2);
bass.setJsyjkPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(22);
cell = row.getCell(4);
bass.setJsyjkSl(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(23);
cell = row.getCell(4);
bass.setJsyjkBzwz(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(24);
cell = row.getCell(4);
bass.setJsyjkGgxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(25);
cell = row.getCell(4);
bass.setJsyjkScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(26);
cell = row.getCell(2);
bass.setJsyhwPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(26);
cell = row.getCell(4);
bass.setJsyhwSl(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(27);
cell = row.getCell(4);
bass.setJsyhwBzwz(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(28);
cell = row.getCell(4);
bass.setJsyhwGgxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(29);
cell = row.getCell(4);
bass.setJsyhwScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(30);
cell = row.getCell(2);
bass.setCzwxdwPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(30);
cell = row.getCell(4);
bass.setCzwxdwGgxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(31);
cell = row.getCell(4);
bass.setCzwxdwScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(32);
cell = row.getCell(2);
bass.setGxdhPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(32);
cell = row.getCell(4);
bass.setGxdhGgxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(33);
cell = row.getCell(4);
bass.setGxdhScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(34);
cell = row.getCell(2);
bass.setLsjPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(34);
cell = row.getCell(4);
bass.setLsjGgxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(35);
cell = row.getCell(4);
bass.setLsjScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(36);
cell = row.getCell(2);
bass.setGjddtPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(36);
cell = row.getCell(4);
bass.setGjddtGgxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(37);
cell = row.getCell(4);
bass.setGjddtScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(38);
cell = row.getCell(2);
bass.setDzwlPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(38);
cell = row.getCell(4);
bass.setDzwlDxxgcs(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(39);
cell = row.getCell(2);
bass.setCztxPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(39);
cell = row.getCell(4);
bass.setCztxXtmc(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(40);
cell = row.getCell(4);
bass.setCztxGgxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(41);
cell = row.getCell(4);
bass.setCztxScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(42);
cell = row.getCell(4);
bass.setCztxBbh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(43);
cell = row.getCell(4);
bass.setCztxKfqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(44);
cell = row.getCell(2);
bass.setJsfzczjPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(44);
cell = row.getCell(4);
bass.setJsfzczjMc(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(45);
cell = row.getCell(4);
bass.setJsfzczjYjxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(46);
cell = row.getCell(4);
bass.setJsfzczjScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(47);
cell = row.getCell(2);
bass.setJsfzzsqPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(47);
cell = row.getCell(4);
bass.setJsfzzsqMc(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(48);
cell = row.getCell(4);
bass.setJsfzzsqYjxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(49);
cell = row.getCell(4);
bass.setJsfzzsqScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(50);
cell = row.getCell(2);
bass.setFxptstsPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(50);
cell = row.getCell(4);
bass.setFxptstsMc(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(51);
cell = row.getCell(4);
bass.setFxptstsYjxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(52);
cell = row.getCell(4);
bass.setFxptstsScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(53);
cell = row.getCell(2);
bass.setJsyzyltsPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(53);
cell = row.getCell(4);
bass.setJsyzyltsMc(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(54);
cell = row.getCell(4);
bass.setJsyzyltsYjxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(55);
cell = row.getCell(4);
bass.setJsyzyltsScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(56);
cell = row.getCell(2);
bass.setDssadPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(56);
cell = row.getCell(4);
bass.setDssadGgxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(57);
cell = row.getCell(4);
bass.setDssadScqy(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(58);
cell = row.getCell(2);
bass.setEdrPz(Integer.parseInt(ImportFileUtil.getCellValueYesOrNo(cell, wb)));
row = s.getRow(58);
cell = row.getCell(4);
bass.setEdrGgxh(ImportFileUtil.getCellValue(cell, wb));
row = s.getRow(59);
cell = row.getCell(4);
bass.setEdrScqy(ImportFileUtil.getCellValue(cell, wb));
return bass;
}
}
@@ -98,6 +98,9 @@ public class OtaBaCxKsjjsmccsServiceImpl extends ServiceImpl<OtaBaCxKsjjsmccsMap
otaBaCxJsfzbacs.setUpdateTime(now);
newList.add(otaBaCxJsfzbacs);
}
if(ObjectUtils.isEmpty(oldList)){
oldList = new ArrayList<>();
}
ComparisonUtil cu = new ComparisonUtil();
List<OtaBaCxTxjl> reList = cu.comparisonListRecord(otaId, OtaModuleEnum.CX_KZXSJDJSFZGNMCYCS, OtaTitleEnum.GNMC.getName(), oldList, newList, sysDictService);
saveOrUpdateBatch(newList);
@@ -278,7 +281,6 @@ public class OtaBaCxKsjjsmccsServiceImpl extends ServiceImpl<OtaBaCxKsjjsmccsMap
cell = row.getCell(13);
mssc.setCsyzsj(ImportFileUtil.getCellValue(cell, wb));
mssc.setCreateTime(now);
mssc.setUpdateTime(now);
mccsList.add(mssc);
}
}
@@ -69,7 +69,7 @@ public class ComparisonUtil<T> {
field.setAccessible(true);
Object newVal = field.get(newObj);
String newStr = "";
if (ObjectUtils.isNotEmpty(newVal)) {
if (ObjectUtils.isNotEmpty(newVal) && !field.getName().equals(tableField.getName())) {
newStr = newVal.toString();
content = tableField.get(newObj).toString() + "-" + title + "由'空'改为'" + newStr + "'";
resList.add(new OtaBaCxTxjl(otaId, otaModuleEnum.getName(), content));
@@ -93,7 +93,7 @@ public class ComparisonUtil<T> {
for (T newObj : newList) {
if (ObjectUtils.isNotEmpty(newObj)) {
Object newId = idField.get(newObj);
if (ObjectUtils.isNotEmpty(newObj) && oldId.equals(newId.toString())) {
if (ObjectUtils.isNotEmpty(newId) && oldId.equals(newId.toString())) {
break;
}
}
@@ -2251,7 +2251,7 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
});
this.processInfoDetailEOService.updateBatchById(processInfoDetailEOList);
}
List<String> userIdList = Arrays.asList(transferUserId.split(","));
List<SysUser> userInfoList = this.sysUserService.querySysUserListByIdList(userIdList);
this.sendMessageByTemplateId(
@@ -2427,7 +2427,7 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
return flag;
}).collect(Collectors.toList());
if (CollectionUtils.isNotEmpty(toBeSubmitDataList)) {
this.sendMessageByTemplateId(
toBeSubmitDataList,
TemplateInfoEnum2.CERTIFICATION_MESSAGE18.getValue(),
@@ -3053,21 +3053,21 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
try {
String title = "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEO.getCut())){
title = "类别,检验项目,配置项,WVTA ID," +
"*标准编号,*责任领域,工程接口人,责任人," +
"交付物类型,截止日期";
title = "*类别,*检验项目,*配置项,*WVTA ID," +
"*标准编号,*责任领域,*工程接口人,*责任人," +
"交付物类型,*交付物模板,*截止日期";
}else {
title = "Category,Inspection Items,Configuration Item,WVTA ID," +
"*Standard No,*Responsible Field,Eng. Interface,Assignee," +
"Deliverable Type,Due Date";
title = "*Category,*Inspection Items,*Configuration Item,*WVTA ID," +
"*Standard No,*Responsible Field,*Eng. Interface,*Assignee," +
"Deliverable Type,*Deliverable Template,*Due Date";
}
List<String> list = Arrays.asList(title.split(","));
int index = 0;
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEO.getCut())){
index = list.indexOf("截止日期") + 1;
index = list.indexOf("*截止日期") + 1;
}else{
index = list.indexOf("Due Date") + 1;
index = list.indexOf("*Due Date") + 1;
}
//创建临时文件夹
@@ -3087,25 +3087,23 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
cellStyleTemp.setWrapText(true);//自动换行
CellRangeAddress region =
new CellRangeAddress(1, 1, 0, 15); //参数1:起始行 参数2:终止行 参数3:起始列 参数4:终止列
new CellRangeAddress(1, 1, 0, 10); //参数1:起始行 参数2:终止行 参数3:起始列 参数4:终止列
sheet.addMergedRegion(region);
String explain= "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEO.getCut())){
explain = "填写说明\n" +
"1.导入数据从第三行开始\n" +
"2.所有带*号的字段必须填写\n"+
"3.责任人,交付物类型,工程接口人,字段是单选属性,必须和系统中的对应字段选项相匹配\n" +
"4.编号,责任领域,字段是多选属性,必须和系统中的对应字段选项相匹配,填写多个时采用英文或中文逗号分割\n" +
"5.类别,WVTA ID,检验项目,填写文本内容\n" +
"6.交付物模板字段为文件属性,填写时需要在本文件同级目录下以标准号为名称建立文件夹,并在文件夹下放置文件,假设在AAA标准号下放置了B.docx,则应填写AAA/B.docx";
"3.责任人,交付物类型,工程接口人,编号,责任领域,字段是单选属性,必须和系统中的对应字段选项相匹配\n" +
"4.类别,WVTA ID,检验项目,配置项,填写文本内容\n" +
"5.交付物模板字段为文件属性,填写时需要在本文件同级目录下以标准号为名称建立文件夹,并在文件夹下放置文件,假设在AAA标准号下放置了B.docx,则应填写AAA/B.docx";
}else{
explain = "Filling explanation\n" +
"1.Import data starts at the fourth line\n" +
"2.All fields marked with * must be filled in\n"+
"3.Assignee,Deliverable Type,Deliverable Type,Eng. Interface,Fields are radio attributes that must match the corresponding field option in the system\n" +
"4.Standard No,Responsible Field, field is a multi-select attribute and must match the corresponding field in the system. If multiple fields are filled in, separate them by commas (,)\n" +
"5.Category,WVTA ID,Inspection Items,Fill in the text\n" +
"6.Deliverable Template,When filling in the field, you need to create a folder in the directory of the same level as the file with the name of the standard number and place the file in the folder. If b. diocx is stored under the AAA standard number, enter AAA/B.docx";
"3.Assignee,Deliverable Type,Eng. Interface,Standard No,Responsible Field,Fields are radio attributes that must match the corresponding field option in the system\n" +
"4.Category,WVTA ID,Configuration Item,Inspection Items,Fill in the text\n" +
"5.Deliverable Template,When filling in the field, you need to create a folder in the directory of the same level as the file with the name of the standard number and place the file in the folder. If b. diocx is stored under the AAA standard number, enter AAA/B. doc";
}
for(int i = 0; i < 2; i++){
//表头
@@ -3120,7 +3118,7 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
}
}
}else {
short height = (short) (7 * 252);
short height = (short) (6 * 252);
row.setHeight((short) height);
Cell cell = row.createCell(0);
cell.setCellStyle(cellStyleTemp);
+3
View File
@@ -1716,4 +1716,7 @@ module.exports = {
pleaseFillInTheInformationTaskProcess:'Please fill in the information of the project interface person and responsible person before initiating the task process',
complianceReporting:'Compliance Reporting',
youCanOnlySelectStatusClearSubmit:'You can only select data with a process status of Clear to Submit',
note:'Note: The attachment includes the list of test items and test report. Test standard or technical specification',
format:'It supports doc/docx/pdf format and is less than 50M in size',
cantTransferToYourself:"Can't transfer to yourself",
}
+4 -1
View File
@@ -1743,7 +1743,7 @@ module.exports = {
afterthesoftwareversionupgraded:'软件版本号升级后',
beforetheOSversionupgraded:'操作系统版本号升级前',
aftertheoperatingsystemversionupgraded:'操作系统版本号升级后',
initialpackageforintegrityinflammatorydata:'初始软件包的完整性炎症数据',
initialpackageforintegrityinflammatorydata:'初始软件包的完整性验证数据',
upgradepackageintegrityverificationdata:'升级包完整性验证数据',
upgradepackagesize:'升级包大小',
differentialupgradeornot:'是否差分升级',
@@ -1816,4 +1816,7 @@ module.exports = {
pleaseFillInTheInformationTaskProcess:'请填写工程接口人和责任人信息后再发起任务流程',
complianceReporting:'合规报告',
youCanOnlySelectStatusClearSubmit:'只能选择流程状态为清单待提交的数据',
note:':附件包括测试项目清单测试报告测试标准或技术规范',
format:'支持doc/docx/pdf格式,大小50M以内',
cantTransferToYourself:"不能转办给自己",
}
@@ -120,6 +120,9 @@
})
} else {
if (this.isTrue) {
if(info.file.response.result != null && info.file.response.result.otaId){
localStorage.setItem('otaId', info.file.response.result.otaId)
}
this.$emit('getList',info.file.response.result)
} else {
eventBUs.$emit('searchGetData')
+12 -1
View File
@@ -34,7 +34,7 @@
export default {
name: 'file',
props: ['disableds', 'disabled', 'thisFileUploadUrl', 'readonly', 'thisFileType', 'isUploadFile', 'isMultiple', 'restrictUploads', 'Uploadable'],
props: ['disableds', 'disabled', 'thisFileUploadUrl','accept', 'readonly', 'thisFileType', 'isUploadFile', 'isMultiple', 'restrictUploads', 'Uploadable'],
data() {
return {
visible: false,
@@ -88,6 +88,16 @@
// let thisFileType = this.thisFileType.replace(/\s+/g, "");
console.log(file)
this.fileTypeSatus = true
//根据格式拦截
if(this.accept){
let fileNames = file.name.split('.')
let fileType = fileNames[fileNames.length - 1].toLocaleLowerCase()
let extList = this.accept.split(',')
if (!extList.find((item) => item == fileType)) {
this.$message.error(this.$t('uploadOnly') + this.accept + this.$t('type'))
reject(false)
}
}
if (this.isMultiple) {
if ((this.myfileList && this.myfileList.length == 1) || this.myfileList && this.myfileList.length > 1) {
this.$message.warning(this.$t('onlyOnefileUploaded'))
@@ -121,6 +131,7 @@
// }else{
// this.fileTypeSatus = false;
// }
// }
// }
this.$message.destroy()
},
@@ -22,41 +22,39 @@
:columns="columns"
style="margin-bottom: 20px"
>
<!-- 配置情况-->
<span slot="configuration" slot-scope="text,record">
<a-radio-group>
<a-radio :value="1"> {{ $t('yes') }} </a-radio>
<a-radio :value="2"> {{ $t('not') }} </a-radio>
</a-radio-group>
<span slot="functionname" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" :title="$t('ifNot')" v-model="record.gnmc"></a-input>
</span>
<!-- 可升级-->
<span slot="whetheritcanbeupgraded" slot-scope="text,record">
<a-radio-group>
<a-radio :value="1"> {{ $t('yes') }} </a-radio>
<a-radio :value="2"> {{ $t('not') }} </a-radio>
</a-radio-group>
<span slot="upgradedestinationype" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" :title="$t('ifNot')" v-model="record.sjmdlx"></a-input>
</span>
<!-- 自动化级别-->
<span slot="drivingautomationlevel" slot-scope="text,record">
<j-dict-select-tag class="box-input"
:disabled="disable"
:placeholder="$t('PleaseSelect')"
:type="'select'"
:triggerChange="false"/>
</span>
<!-- 升级前-->
<span slot="preupgrade" slot-scope="text,record">
<a-input :placeholder="$t('ifNot')" :title="$t('ifNot')"></a-input>
<a-input :placeholder="$t('ifNot')" :title="$t('ifNot')" v-model="record.sjqbgcs"></a-input>
</span>
<!-- 升级后-->
<span slot="afterupgrade" slot-scope="text,record">
<a-input :placeholder="$t('ifNot')" :title="$t('ifNot')"></a-input>
<a-input :placeholder="$t('ifNot')" :title="$t('ifNot')" v-model="record.sjhbgcs"></a-input>
</span>
<span slot="functionalchangedescription" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" v-model="record.gnbgms" ></a-input>
</span>
<span slot="variationofapplicableconditions" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" :title="$t('ifNot')" v-model="record.sytjbg"></a-input>
</span>
<span slot="upgradetheelectroniccontrollerinvolved" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" :title="$t('ifNot')" v-model="record.sjsjkzq"></a-input>
</span>
<span slot="functiondescription" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" :title="$t('ifNot')" v-model="record.gnbgms"></a-input>
</span>
<span slot="applicationconditions" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" :title="$t('ifNot')" v-model="record.sytjbg"></a-input>
</span>
<!-- 操作列-->
<span slot="operation" slot-scope="text,record">
<a class="text-operation">{{$t('addcontroller')}}</a>
<a class="text-operation">{{$t('addfunction')}}</a>
<a class="text-operation">{{$t('delete')}}</a>
<a class="text-operation" @click="addlineAtBot">{{$t('add')}}</a>
<a class="text-operation" @click="deleteData(record)">{{$t('delete')}}</a>
</span>
</a-table>
<div>
@@ -86,8 +84,7 @@ export default {
return {
dataSource: [
{
key:1,
functionname:'ceshi',
}
],
loading: false,
@@ -98,108 +95,83 @@ export default {
align: 'left',
dataIndex: 'functionname',
ellipsis: true,
width: 170
width: 170,
scopedSlots: { customRender: 'functionname' },
},
{
title: this.$t('configuration'),
title: this.$t('upgradedestinationype'),
align: 'left',
dataIndex: 'configuration',
dataIndex: 'upgradedestinationype',
ellipsis: true,
width: 170
width: 170,
scopedSlots: { customRender: 'upgradedestinationype' },
},
{
title: this.$t('adjustmentofchangedBulletinparameters'),
align: 'left',
dataIndex: 'adjustmentofchangedBulletinparameters',
ellipsis: true,
width: 170,
children: [
{
title: this.$t('preupgrade'),
align: 'left',
dataIndex: 'preupgrade',
ellipsis: true,
width: 170,
scopedSlots: { customRender: 'preupgrade' },
},
{
title: this.$t('afterupgrade'),
align: 'left',
dataIndex: 'afterupgrade',
ellipsis: true,
width: 170,
scopedSlots: { customRender: 'afterupgrade' },
},
]
},
{
title: this.$t('whetheritcanbeupgraded'),
title: this.$t('functionalchangedescription'),
align: 'left',
dataIndex: 'whetheritcanbeupgraded',
dataIndex: 'functionalchangedescription',
ellipsis: true,
width: 170
width: 170,
scopedSlots: { customRender: 'functionalchangedescription' },
},
{
title: this.$t('drivingautomationlevel'),
title: this.$t('variationofapplicableconditions'),
align: 'left',
dataIndex: 'drivingautomationlevel',
dataIndex: 'variationofapplicableconditions',
ellipsis: true,
width: 170
width: 170,
scopedSlots: { customRender: 'variationofapplicableconditions' },
},
{
title: this.$t('technicalparameters'),
title: this.$t('upgradetheelectroniccontrollerinvolved'),
align: 'left',
dataIndex: 'technicalparameters',
dataIndex: 'upgradetheelectroniccontrollerinvolved',
ellipsis: true,
width: 170
width: 170,
scopedSlots: { customRender: 'upgradetheelectroniccontrollerinvolved' },
},
{
title: this.$t('functiondescription'),
align: 'left',
dataIndex: 'functiondescription',
ellipsis: true,
width: 170
width: 170,
scopedSlots: { customRender: 'functiondescription' },
},
{
title: this.$t('applicationconditions'),
align: 'left',
dataIndex: 'applicationconditions',
ellipsis: true,
width: 170
},
{
title: this.$t('controllerparameter'),
align: 'left',
dataIndex: 'controllerparameter',
ellipsis: true,
width: 170,
children: [
{
title: this.$t('electronic'),
align: 'left',
dataIndex: 'electronic',
ellipsis: true,
width: 170
},
{
title: this.$t('electroniccontrollerproductionenterprises'),
align: 'left',
dataIndex: 'electroniccontrollerproductionenterprises',
ellipsis: true,
width: 170
},
{
title: this.$t('electroniccontrollertype'),
align: 'left',
dataIndex: 'electroniccontrollertype',
ellipsis: true,
width: 170
},
{
title: this.$t('hardwareversioninformation'),
align: 'left',
dataIndex: 'hardwareversioninformation',
ellipsis: true,
width: 170
},
{
title: this.$t('softwaredevelopmententerprise'),
align: 'left',
dataIndex: 'softwaredevelopmententerprise',
ellipsis: true,
width: 170
},
{
title: this.$t('operatingsystemversion'),
align: 'left',
dataIndex: 'operatingsystemversion',
ellipsis: true,
width: 170
},
{
title: this.$t('inflammatorydata'),
align: 'left',
dataIndex: 'inflammatorydata',
ellipsis: true,
width: 170
},
]
scopedSlots: { customRender: 'applicationconditions' },
},
{
title: this.$t('operation'),
align: 'left',
@@ -216,6 +188,7 @@ export default {
},
mounted() {
// this.getList()
this.getData()
},
methods: {
// 模板下载
@@ -250,12 +223,40 @@ export default {
}
})
},
getData(){
let otaIdT=localStorage.getItem('otaIdT')
if(otaIdT==null){
otaIdT=''
}
let otaId=localStorage.getItem('otaId')
if(otaId==null){
otaId=''
}
getAction('/ota/otaBaSjSjfzbh/queryByOtaId',{otaIdT:otaIdT,otaId:otaId}).then(res=>{
this.dataSource =res.result.list == null ? {} : res.result.list
})
},
save(){
postAction('/ota/otaBaSjSjfzbh/add' ,{otaId:localStorage.getItem('otaId')== undefined ? '' :localStorage.getItem('otaId'),list:this.dataSource}).then(res=>{
console.log(res);
this.$message.success(this.$t('SavedSuccessfully'))
})
},
last(){
this.save()
this.$emit('beupgradedonlineup')
},
next(){
this.save()
this.$emit('beupgradedonlinedown')
},
addlineAtBot(){
let obj={}
this.dataSource.push(obj)
},
deleteData(record){
this.dataSource.splice(this.dataSource.indexOf(record),1)
},
uploadSuccess(data) {
let attIdList = []
if (data && data.length > 0) {
@@ -37,34 +37,28 @@
<a-input :placeholder="$t('pleaseEnter')" v-model="record.sjkzqmc" ></a-input>
</span>
<span slot="adaptivehardwareversion" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" v-model="record.xtmc"></a-input>
<a-input :placeholder="$t('pleaseEnter')" v-model="record.yjbb"></a-input>
</span>
<span slot="beforethesoftwareversionupgraded" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" v-model="record.xtmc" ></a-input>
<a-input :placeholder="$t('pleaseEnter')" v-model="record.sjqrjbb" ></a-input>
</span>
<span slot="afterthesoftwareversionupgraded" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" v-model="record.xtmc"></a-input>
<a-input :placeholder="$t('pleaseEnter')" v-model="record.sjhrjbb"></a-input>
</span>
<span slot="beforetheOSversionupgraded" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" v-model="record.xtmc"></a-input>
<a-input :placeholder="$t('pleaseEnter')" v-model="record.sjqczxt"></a-input>
</span>
<span slot="aftertheoperatingsystemversionupgraded" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" v-model="record.xtmc"></a-input>
</span>
<span slot="softwaredevelopmententerprise" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" v-model="record.xtmc" ></a-input>
</span>
<span slot="initialpackageforintegrityinflammatorydata" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" v-model="record.xtmc"></a-input>
<a-input :placeholder="$t('pleaseEnter')" v-model="record.sjhczxt"></a-input>
</span>
<span slot="upgradepackageintegrityverificationdata" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" v-model="record.xtmc" ></a-input>
<a-input :placeholder="$t('pleaseEnter')" v-model="record.sjbyzsj" ></a-input>
</span>
<span slot="upgradepackagesize" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" v-model="record.xtmc"></a-input>
<a-input :placeholder="$t('pleaseEnter')" v-model="record.sjbdx"></a-input>
</span>
<span slot="differentialupgradeornot" slot-scope="text,record">
<a-input :placeholder="$t('pleaseEnter')" v-model="record.xtmc"></a-input>
<a-input :placeholder="$t('pleaseEnter')" v-model="record.sfcfsj"></a-input>
</span>
<!-- 操作列-->
<span slot="operation" slot-scope="text,record">
@@ -76,7 +70,7 @@
<a-button @click="clickButtonToUpload" type="primary">{{$t('uploadattachment')}}</a-button>
</div>
<div class="bootom-button">
<a-button style="margin-right:50px">{{$t('preservation')}}</a-button>
<a-button style="margin-right:50px" @click="save">{{$t('preservation')}}</a-button>
<a-button type="primary" style='width: 73px;margin-right: 50px' @click='last'>{{$t('last')}}</a-button>
<a-button type="primary" style='width: 73px' @click='next'>{{$t('next')}}</a-button>
</div>
@@ -194,22 +188,7 @@ export default {
width: 170,
scopedSlots: { customRender: 'aftertheoperatingsystemversionupgraded' },
},
{
title: this.$t('softwaredevelopmententerprise'),
align: 'left',
dataIndex: 'softwaredevelopmententerprise',
ellipsis: true,
width: 170,
scopedSlots: { customRender: 'softwaredevelopmententerprise' },
},
{
title: this.$t('initialpackageforintegrityinflammatorydata'),
align: 'left',
dataIndex: 'initialpackageforintegrityinflammatorydata',
ellipsis: true,
width: 170,
scopedSlots: { customRender: 'initialpackageforintegrityinflammatorydata' },
},
{
title: this.$t('upgradepackageintegrityverificationdata'),
align: 'left',
@@ -252,6 +231,7 @@ export default {
},
mounted() {
// this.getList()
this.getData()
},
methods: {
// 模板下载
@@ -298,10 +278,31 @@ export default {
}
})
},
getData(){
let otaIdT=localStorage.getItem('otaIdT')
if(otaIdT==null){
otaIdT=''
}
let otaId=localStorage.getItem('otaId')
if(otaId==null){
otaId=''
}
getAction('/ota/otaBaSjSjxtbh/queryByOtaId',{otaIdT:otaIdT,otaId:otaId}).then(res=>{
this.dataSource =res.result.list == null ? {} : res.result.list
})
},
save(){
postAction('/ota/otaBaSjSjxtbh/add' ,{otaId:localStorage.getItem('otaId')== undefined ? '' :localStorage.getItem('otaId'),list:this.dataSource}).then(res=>{
console.log(res);
this.$message.success(this.$t('SavedSuccessfully'))
})
},
last(){
this.save()
this.$emit('upgradedonlineup')
},
next(){
this.save()
this.$emit('upgradedonlinedown')
},
addlineAtBot(){
@@ -2,7 +2,7 @@
<div class="box">
<div class="table-operator">
<div class="operator-text">
<ImportFile :url="url" :dummyInventoryBaseId="$route.query.id" :isTrue="true" :accept="'.zip'" />
<ImportFile :url="url" :dummyInventoryBaseId="$route.query.id" :isTrue="true" :accept="'.zip'" @getList="getData"/>
</div>
<div @click='handleModule' class="operator-text">
<a-icon type="download"/>
@@ -360,10 +360,14 @@ import { message } from 'ant-design-vue'
})
},
async save(){
save(){
this.$refs.ruleForm.validate(valid=>{
if(valid){
postAction('/ota/otaBaCxJbxx/add',{ otaId:localStorage.getItem('otaId'),...this.form}).then( res => {
let otaId = localStorage.getItem('otaId')
if(otaId==null || otaId == undefined){
otaId=''
}
postAction('/ota/otaBaCxJbxx/add',{ otaId:otaId,...this.form}).then( res => {
if(res.code == 200){
localStorage.setItem('otaId', res.result.otaId)
this.$message.success(this.$t('SavedSuccessfully'))
@@ -2,7 +2,7 @@
<div class="box">
<div class="table-operator">
<div class="operator-text">
<ImportFile :url="url" :dummyInventoryBaseId="$route.query.id" :isTrue="true" :accept="'.zip'" />
<ImportFile :url="url" :dummyInventoryBaseId="$route.query.id" :isTrue="true" :accept="'.zip'" @getList="getData"/>
</div>
<div @click='handleModule' class="operator-text">
<a-icon type="download"/>
@@ -45,7 +45,7 @@
:placeholder="$t('PleaseSelect')"
:type="'select'"
:triggerChange="false"
:dictCode="record.dictCode"
:dictCode="'driving_automation_level'"
v-model="record.jszdhjb"/>
</span>
<!-- 技术参数-->
@@ -2,7 +2,7 @@
<div class="box">
<div class="table-operator">
<div class="operator-text">
<ImportFile :url="url" :dummyInventoryBaseId="$route.query.id" :isTrue="true" :accept="'.zip'" />
<ImportFile :url="url" :dummyInventoryBaseId="$route.query.id" :isTrue="true" :accept="'.zip'" @getList="getData"/>
</div>
<div @click='handleModule' class="operator-text">
<a-icon type="download"/>
@@ -95,7 +95,7 @@
<div style='width: 300px'>
<span class='content-text' style='background: #f3f6f6;line-height: 50px;text-align: center;color: #191E29;font-weight: bold'>{{$t('fillincontent')}}</span>
<span class='radio-text'>
<a-radio-group style='margin-left: 40px;' v-model="query.wlaqyqPz">
<a-radio-group style='margin-left: 40px;' v-model="query.jgld">
<a-radio :value="1"> {{ $t('yes') }} </a-radio>
<a-radio :value="2"> {{ $t('not') }} </a-radio>
</a-radio-group>
@@ -299,7 +299,7 @@ export default {
},
dataSource: [
{
key: 'wlaqyqSl',
key: 'jgldSl',
val:'',
componentname: this.$t('networksecurityrequirements'),
configuration: this.$t('ineffectiveupgrades'),
@@ -307,7 +307,7 @@ export default {
fillincontent:this.$t('yesisselected'),
},
{
key: 'wlaqyqBzwz',
key: 'jgldBzwz',
val:'',
componentname: this.$t('networksecurityrequirements'),
configuration: this.$t('ineffectiveupgrades'),
@@ -315,7 +315,7 @@ export default {
fillincontent:this.$t('forwardXquantity'),
},
{
key: 'wlaqyqGgxh',
key: 'jgldGgxh',
val:'',
componentname: this.$t('networksecurityrequirements'),
configuration: this.$t('ineffectiveupgrades'),
@@ -323,7 +323,7 @@ export default {
fillincontent:this.$t('yesisselected'),
},
{
key: 'wlaqyqScqy',
key: 'jgldScqy',
val:'',
componentname: this.$t('networksecurityrequirements'),
configuration: this.$t('productionenterprise'),
@@ -890,10 +890,6 @@ export default {
this.dataSource.forEach(item=>{
for(let key in res.result.bj){
if(Number(res.result.bj[key])!=NaN &&Number(res.result.bj[key])!=0 && key !='id'){
console.log(key);
res.result.bj[key]=Number(res.result.bj[key])
}
if(item.key==key){
item.val=res.result.bj[key]
}
@@ -2,7 +2,7 @@
<div class="box">
<div class="table-operator">
<div class="operator-text">
<ImportFile :url="url" :dummyInventoryBaseId="$route.query.id" :isTrue="true" :accept="'.zip'" />
<ImportFile :url="url" :dummyInventoryBaseId="$route.query.id" :isTrue="true" :accept="'.zip'" @getList="getData"/>
</div>
<div @click='handleModule' class="operator-text">
<a-icon type="download"/>
@@ -2,7 +2,7 @@
<div class="box">
<div class="table-operator">
<div class="operator-text">
<ImportFile :url="url" :dummyInventoryBaseId="$route.query.id" :isTrue="true" :accept="'.zip'" />
<ImportFile :url="url" :dummyInventoryBaseId="$route.query.id" :isTrue="true" :accept="'.zip'" @getList="getData"/>
</div>
<div @click='handleModule' class="operator-text">
<a-icon type="download"/>
@@ -18,16 +18,23 @@
<a-radio :value="2"> {{ $t('not') }} </a-radio>
</a-radio-group>
</span>
<span slot="certifyingmaterials" slot-scope="text,record">
<a-button type="primary" v-model="record.relevantverification">{{ $t('uploadattachment') }}</a-button>
</span>
<!-- <span slot="certifyingmaterials" slot-scope="text,record">-->
<!-- <a-button type="primary" v-model="record.relevantverification">{{ $t('uploadattachment') }}</a-button>-->
<!-- </span>-->
</a-table>
<div>
<div style='margin-top: 20px'>
<p>{{$t('note')}}</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;{{$t('format')}}</p>
</div>
</div>
<div class="bootom-button">
<a-button class='btn' @click="save">{{ $t('preservation') }}</a-button>
<a-button type="primary" style='width: 73px;margin-right: 50px' @click="last">{{ $t('last') }}</a-button>
<a-button type="primary" style='width: 73px' @click='next'>{{ $t('next') }}</a-button>
</div>
<uploadFile ref="uploadFile" @uploadSuccess="uploadSuccess"></uploadFile>
<uploadFile ref="uploadFile" :accept="'.doc,.docx,.pdf'" @uploadSuccess="uploadSuccess"></uploadFile>
</div>
</template>
@@ -228,7 +235,7 @@ export default {
this.$refs.uploadFile.perentHandleFunc(this.fileList.uploadName)
this.$forceUpdate()
})
},
click(value) {
this.fileList = value
@@ -2,7 +2,7 @@
<div class="box">
<div class="table-operator">
<div class="operator-text">
<ImportFile :url="url" :dummyInventoryBaseId="$route.query.id" :isTrue="true" :accept="'.zip'" />
<ImportFile :url="url" :dummyInventoryBaseId="$route.query.id" :isTrue="true" :accept="'.zip'" @getList="getData"/>
</div>
<div @click='handleModule' class="operator-text">
<a-icon type="download"/>
@@ -179,7 +179,7 @@
</div>
<a-form-model-item class="itemModel" prop="deliverableTemplate">
<a-button type="primary" class="button-text"
@click="clickButtonToUpload('deliverableTemplate',index)">
@click="clickButtonToUpload('deliverableTemplate',index,true)">
{{ (item.deliverableTemplate === 'null' || item.deliverableTemplate === ''
||
item.deliverableTemplate == null) ? $t('clickUpload') : $t('viewUploadedFiles')
@@ -719,12 +719,19 @@
}
this.formInline = { ...this.formInline }
},
clickButtonToUpload(item, index) {
clickButtonToUpload(item, index,isTrue) {
this.numIndex = index
this.$refs.uploadFile.perentHandleFunc()
this.$refs.uploadFile.visible = true
this.uploadName = item
getAction('sys/common/getFileInfos', { id: this.formInline[item] }).then((res) => {
let ids = ''
console.log(index)
if (isTrue){
ids = this.formInline.dataList[index][item]
}else{
ids = this.formInline[item]
}
getAction('sys/common/getFileInfos', { id: ids }).then((res) => {
if (res.success) {
this.$refs.uploadFile.perentHandleFunc(res.result)
} else {
@@ -1383,13 +1383,13 @@
for (let i = 0; i < this.selectedRowKeysList.length; i++) {
if (this.selectedRowKeysList[i].flowStatus == 'Results to be submitted') {
isTrue = true
}else{
} else {
isTrue = false
this.$message.warning(this.$t('youCanOnlySelectStatusClearSubmit'))
return
}
}
if (isTrue){
if (isTrue) {
this.$refs.referenceDeliverablesListRef.transferModel(JSON.parse(JSON.stringify(this.selectedRowKeys)))
}
} else {
@@ -1453,6 +1453,11 @@
},
//转办接口
SelectedByForm(userIds) {
if (this.userInfo().id == userIds) {
this.$refs.SelectedByRef.submitLoading = false
this.$message.warning(this.$t('cantTransferToYourself'))
return
}
let query = {
transferUserId: userIds,
'projectLibraryId': this.$route.query.id,
@@ -2511,7 +2511,7 @@
}).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
this.selectedRowKeys = []
_this.selectedRowKeys = []
_this.getList()
} else {
_this.$message.warning(_this.$t('operationFailed'))
@@ -1,148 +1,153 @@
<template>
<a-drawer
:title="$t('edit')"
:maskClosable="false"
:width="900"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<a-spin :spinning="confirmLoading">
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('regulationNo')">{{$t('regulationNo')}}</span>
<div>
<a-drawer
:title="$t('edit')"
:maskClosable="false"
:width="900"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<a-spin :spinning="confirmLoading">
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('regulationNo')">{{$t('regulationNo')}}</span>
</div>
<a-form-model-item class="itemModel" prop="serialNumber">
<a-input @click.native="serialNumberClick"
class="box-input"
:placeholder="$t('PleaseSelect')+$t('regulationNo')"
v-model="formInline.serialNumber"></a-input>
</a-form-model-item>
</div>
<a-form-model-item class="itemModel" prop="serialNumber">
<j-dict-select-tag class="box-input"
v-model="formInline.serialNumber"
:disabled="true"
:placeholder="$t('PleaseSelect')+$t('regulationNo')"
:type="'select'"
:triggerChange="false"/>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('areaOfResponsibility')">{{$t('areaOfResponsibility')}}</span>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('areaOfResponsibility')">{{$t('areaOfResponsibility')}}</span>
</div>
<a-form-model-item class="itemModel" prop="dutyTerritory">
<j-dict-select-tag class="box-input"
v-model="formInline.dutyTerritory"
:disabled="disabled"
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
:type="'select'"
:triggerChange="false" :dictCode="'duty_territory'"/>
</a-form-model-item>
</div>
<a-form-model-item class="itemModel" prop="dutyTerritory">
<j-dict-select-tag class="box-input"
v-model="formInline.dutyTerritory"
:disabled="disabled"
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
:type="'select'"
:triggerChange="false" :dictCode="'duty_territory'"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="'WVTA ID'">WVTA ID</span>
</div>
<a-form-model-item class="itemModel" prop="wvtaId">
<a-input class="box-input"
:disabled="disabled"
v-model="formInline.wvtaId"
:placeholder="$t('PleaseEnter')+'WVTA ID'"/>
</a-form-model-item>
</div>
</a-col>
</a-col>
</a-row>
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('category')">{{$t('category')}}</span>
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="'WVTA ID'">WVTA ID</span>
</div>
<a-form-model-item class="itemModel" prop="wvtaId">
<a-input class="box-input"
:disabled="disabled"
v-model="formInline.wvtaId"
:placeholder="$t('PleaseEnter')+'WVTA ID'"/>
</a-form-model-item>
</div>
<a-form-model-item class="itemModel" prop="category">
<a-input class="box-input"
v-model="formInline.category"
:disabled="disabled"
:placeholder="$t('PleaseEnter')+$t('category')" />
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('inspectionItems')">{{$t('inspectionItems')}}</span>
</a-col>
</a-row>
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('category')">{{$t('category')}}</span>
</div>
<a-form-model-item class="itemModel" prop="category">
<a-input class="box-input"
v-model="formInline.category"
:disabled="disabled"
:placeholder="$t('PleaseEnter')+$t('category')" />
</a-form-model-item>
</div>
<a-form-model-item class="itemModel" prop="inspectionItem">
<a-input class="box-input"
v-model="formInline.inspectionItem"
:disabled="disabled"
:placeholder="$t('PleaseEnter')+$t('inspectionItems')"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('configurationItem')">{{$t('configurationItem')}}</span>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('inspectionItems')">{{$t('inspectionItems')}}</span>
</div>
<a-form-model-item class="itemModel" prop="inspectionItem">
<a-input class="box-input"
v-model="formInline.inspectionItem"
:disabled="disabled"
:placeholder="$t('PleaseEnter')+$t('inspectionItems')"/>
</a-form-model-item>
</div>
<a-form-model-item class="itemModel" prop="configItem">
<a-input class="box-input"
v-model="formInline.configItem"
:placeholder="$t('PleaseEnter')+$t('configurationItem')"/>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('typeOfDeliverables')">{{$t('typeOfDeliverables')}}</span>
</a-col>
</a-row>
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('configurationItem')">{{$t('configurationItem')}}</span>
</div>
<a-form-model-item class="itemModel" prop="configItem">
<a-input class="box-input"
v-model="formInline.configItem"
:placeholder="$t('PleaseEnter')+$t('configurationItem')"/>
</a-form-model-item>
</div>
<a-form-model-item class="itemModel"
prop="deliverableType"
:rules="[{ required: true, message: $t('typeOfDeliverables') + $t('cannotEmpty'), trigger: 'change'},]"
>
<a-tree-select
tree-node-filter-prop="title"
v-model="formInline.deliverableType"
:maxTagCount="1"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
class="box-input"
style="width: 100%"
:tree-data="DeliverableTreeList"
:placeholder="$t('PleaseSelect')+$t('typeOfDeliverables')"
/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-spin>
<div class="drawer-bootom-button">
<a-button style="margin-right: .8rem" @click="handleCancel">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
</div>
</a-drawer>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('typeOfDeliverables')">{{$t('typeOfDeliverables')}}</span>
</div>
<a-form-model-item class="itemModel"
prop="deliverableType"
:rules="[{ required: true, message: $t('typeOfDeliverables') + $t('cannotEmpty'), trigger: 'change'},]"
>
<a-tree-select
tree-node-filter-prop="title"
v-model="formInline.deliverableType"
:maxTagCount="1"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
class="box-input"
style="width: 100%"
:tree-data="DeliverableTreeList"
:placeholder="$t('PleaseSelect')+$t('typeOfDeliverables')"
/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-spin>
<div class="drawer-bootom-button">
<a-button style="margin-right: .8rem" @click="handleCancel">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
</div>
</a-drawer>
<codeNumber ref="codeNumber" @regulation="regulation" />
</div>
</template>
<script>
import { getAction, postAction, downloadFile, deleteAction } from '@/api/manage'
import codeNumber from './codeNumber'
export default {
name:'editModel',
props: ['url'],
components:{
codeNumber
},
data() {
return {
visible: false,
@@ -215,6 +220,9 @@ export default {
handleCancel() {
this.visible = false
},
serialNumberClick(){
this.$refs.codeNumber.add()
},
editModel(item) {
this.visible = true
this.$nextTick(() => {
@@ -261,6 +269,14 @@ export default {
}
})
},
regulation(item,data) {
this.formInline.serialNumber = item
this.formInline.bussDocumentLibraryId = data
this.$nextTick(()=>{
this.formInline = {... this.formInline}
this.$refs.ruleForm.validateField(['serialNumber'])
})
}
}
}
</script>