Merge remote-tracking branch 'origin/dev_2nd_LCYH' into dev_2nd_LCYH
This commit is contained in:
+49
-60
@@ -658,6 +658,43 @@ public class AuthDummyInventoryInfoEOServiceImpl extends ServiceImpl<AuthDummyIn
|
||||
}
|
||||
}
|
||||
}
|
||||
if(CutEnum.CN.getValue().equals(authDummyInventoryInfoEO.getCut())){
|
||||
for(int k = 0 ;k<rowList.size();k++){
|
||||
if("".equals(rowList.get("category")) ||
|
||||
"".equals(rowList.get("inspectionItem")) ||
|
||||
"".equals(rowList.get("configItem")) ||
|
||||
"".equals(rowList.get("wvtaId")) ||
|
||||
"".equals(rowList.get("serialNumber")) ||
|
||||
"".equals(rowList.get("dutyTerritoryName")) ||
|
||||
"".equals(rowList.get("deliverableTypeName")) ){
|
||||
//删除原上传文件
|
||||
FileUnZip.deleteDir(saveDirectory);
|
||||
if(CutEnum.CN.getValue().equals(authDummyInventoryInfoEO.getCut())){
|
||||
throw new JeroBootException("请填写必填字段内容,带*的为必填");
|
||||
}else{
|
||||
throw new JeroBootException("Please fill in the required fields marked with *");
|
||||
}
|
||||
}
|
||||
}
|
||||
}else {
|
||||
for(int k = 0 ;k<rowList.size();k++){
|
||||
if("".equals(rowList.get("category")) ||
|
||||
"".equals(rowList.get("inspectionItem")) ||
|
||||
"".equals(rowList.get("configItem")) ||
|
||||
"".equals(rowList.get("wvtaId")) ||
|
||||
"".equals(rowList.get("serialNumber")) ||
|
||||
"".equals(rowList.get("dutyTerritoryName")) ||
|
||||
"".equals(rowList.get("deliverableTypeNameEn")) ){
|
||||
//删除原上传文件
|
||||
FileUnZip.deleteDir(saveDirectory);
|
||||
if(CutEnum.CN.getValue().equals(authDummyInventoryInfoEO.getCut())){
|
||||
throw new JeroBootException("请填写必填字段内容,带*的为必填");
|
||||
}else{
|
||||
throw new JeroBootException("Please fill in the required fields marked with *");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (i > 1) {
|
||||
dataList.add(rowList);
|
||||
}
|
||||
@@ -797,86 +834,54 @@ public class AuthDummyInventoryInfoEOServiceImpl extends ServiceImpl<AuthDummyIn
|
||||
//WVTA ID
|
||||
|
||||
if(StringUtils.isNotBlank(wvtaId)){
|
||||
if(wvtaId.length() > 100){
|
||||
if(wvtaId.length() > 300){
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(authDummyInventoryInfoEOTemp.getCut())){
|
||||
message = errorMsg + "WVTA ID不能超过100个字符, ";
|
||||
message = errorMsg + "WVTA ID不能超过300个字符, ";
|
||||
}else{
|
||||
message = errorMsg + " The WVTA ID cannot contain more than 100 characters, ";
|
||||
message = errorMsg + " The WVTA ID cannot contain more than 300 characters, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
} else {
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(authDummyInventoryInfoEOTemp.getCut())){
|
||||
message = errorMsg + "WVTA ID不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The WVTA ID cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
//类别
|
||||
|
||||
if(StringUtils.isNotBlank(category)){
|
||||
if(category.length() > 100){
|
||||
if(category.length() > 300){
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(authDummyInventoryInfoEOTemp.getCut())){
|
||||
message = errorMsg + "类别不能超过100个字符, ";
|
||||
message = errorMsg + "类别不能超过300个字符, ";
|
||||
}else{
|
||||
message = errorMsg + " The Category cannot contain more than 100 characters, ";
|
||||
message = errorMsg + " The Category cannot contain more than 300 characters, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
}else {
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(authDummyInventoryInfoEOTemp.getCut())){
|
||||
message = errorMsg + "类别不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The Category cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
//检验项目
|
||||
|
||||
if(StringUtils.isNotBlank(inspectionItem)){
|
||||
if(inspectionItem.length() > 100){
|
||||
if(inspectionItem.length() > 300){
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(authDummyInventoryInfoEOTemp.getCut())){
|
||||
message = errorMsg + "检验项目不能超过100个字符, ";
|
||||
message = errorMsg + "检验项目不能超过300个字符, ";
|
||||
}else{
|
||||
message = errorMsg + " The InspectionItem cannot contain more than 100 characters, ";
|
||||
message = errorMsg + " The InspectionItem cannot contain more than 300 characters, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
}else {
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(authDummyInventoryInfoEOTemp.getCut())){
|
||||
message = errorMsg + "检验项目不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The InspectionItem cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
//配置项
|
||||
|
||||
if(StringUtils.isNotBlank(configItem)){
|
||||
if(configItem.length() > 100){
|
||||
if(configItem.length() > 300){
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(authDummyInventoryInfoEOTemp.getCut())){
|
||||
message = errorMsg + "配置项不能超过100个字符, ";
|
||||
message = errorMsg + "配置项不能超过300个字符, ";
|
||||
}else{
|
||||
message = errorMsg + " The ConfigItem cannot contain more than 100 characters, ";
|
||||
message = errorMsg + " The ConfigItem cannot contain more than 300 characters, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
}else {
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(authDummyInventoryInfoEOTemp.getCut())){
|
||||
message = errorMsg + "配置项不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The ConfigItem cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
//责任领域
|
||||
if(StringUtils.isNotBlank(dutyTerritory)){
|
||||
@@ -884,14 +889,6 @@ public class AuthDummyInventoryInfoEOServiceImpl extends ServiceImpl<AuthDummyIn
|
||||
if(StringUtils.isNotBlank(value)){
|
||||
authDummyInventoryInfoEO.setDutyTerritory(value);
|
||||
}
|
||||
}else {
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(authDummyInventoryInfoEOTemp.getCut())){
|
||||
message = errorMsg + "责任领域不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The Responsible Field cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
//交付物类型
|
||||
if(StringUtils.isNotEmpty(deliverableType)){
|
||||
@@ -900,14 +897,6 @@ public class AuthDummyInventoryInfoEOServiceImpl extends ServiceImpl<AuthDummyIn
|
||||
String treeId = getTreeId(categoryList, authDummyInventoryInfoEOTemp, treeNameList, value);
|
||||
authDummyInventoryInfoEO.setDeliverableType(treeId);
|
||||
}
|
||||
}else{
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(authDummyInventoryInfoEOTemp.getCut())){
|
||||
message = errorMsg + "交付物类型不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The Deliverable Type cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
}
|
||||
return msgList;
|
||||
|
||||
+1
-1
@@ -87,7 +87,7 @@ public class OtaBaCxListController extends JeroController<OtaBaCxList, IOtaBaCxL
|
||||
queryWrapper.like(OtaBaCxList::getCpmc, cpmc);
|
||||
}
|
||||
|
||||
String cpxh = req.getParameter("cpmc");
|
||||
String cpxh = req.getParameter("cpxh");
|
||||
if (StringUtils.isNotBlank(cpxh)) {
|
||||
cpxh = cpxh.replace("%", "\\%");
|
||||
queryWrapper.like(OtaBaCxList::getCpxh, cpxh);
|
||||
|
||||
+130
-121
@@ -4,6 +4,7 @@ import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.jero.common.api.vo.Result;
|
||||
import com.jero.common.system.query.QueryGenerator;
|
||||
import com.jero.modules.ota.entity.OtaBaSjGnxtwh;
|
||||
@@ -22,147 +23,155 @@ import io.swagger.annotations.ApiOperation;
|
||||
import com.jero.common.aspect.annotation.AutoLog;
|
||||
|
||||
|
||||
/**
|
||||
/**
|
||||
* @Description: 车型备案-功能系统维护
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Api(tags="车型备案-功能系统维护")
|
||||
@Api(tags = "车型备案-功能系统维护")
|
||||
@RestController
|
||||
@RequestMapping("/ota/otaBaSjGnxtwh")
|
||||
@Slf4j
|
||||
public class OtaBaSjGnxtwhController extends JeroController<OtaBaSjGnxtwh, IOtaBaSjGnxtwhService> {
|
||||
@Autowired
|
||||
private IOtaBaSjGnxtwhService otaBaSjGnxtwhService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param otaBaSjGnxtwh
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-分页列表查询")
|
||||
@ApiOperation(value="车型备案-功能系统维护-分页列表查询", notes="车型备案-功能系统维护-分页列表查询")
|
||||
@GetMapping(value = "/page")
|
||||
public Result<?> queryPageList(OtaBaSjGnxtwh otaBaSjGnxtwh,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<OtaBaSjGnxtwh> queryWrapper = QueryGenerator.initQueryWrapper(otaBaSjGnxtwh, req.getParameterMap());
|
||||
Page<OtaBaSjGnxtwh> page = new Page<OtaBaSjGnxtwh>(pageNo, pageSize);
|
||||
queryWrapper.orderByDesc("create_time");
|
||||
IPage<OtaBaSjGnxtwh> pageList = otaBaSjGnxtwhService.page(page, queryWrapper);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
@Autowired
|
||||
private IOtaBaSjGnxtwhService otaBaSjGnxtwhService;
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-列表查询")
|
||||
@ApiOperation(value="车型备案-功能系统维护-列表查询", notes="车型备案-功能系统维护-列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<List<OtaBaSjGnxtwh>> queryList() {
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param otaBaSjGnxtwh
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-分页列表查询")
|
||||
@ApiOperation(value = "车型备案-功能系统维护-分页列表查询", notes = "车型备案-功能系统维护-分页列表查询")
|
||||
@GetMapping(value = "/page")
|
||||
public Result<?> queryPageList(OtaBaSjGnxtwh otaBaSjGnxtwh,
|
||||
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<OtaBaSjGnxtwh> queryWrapper = QueryGenerator.initQueryWrapper(otaBaSjGnxtwh, req.getParameterMap());
|
||||
Page<OtaBaSjGnxtwh> page = new Page<OtaBaSjGnxtwh>(pageNo, pageSize);
|
||||
queryWrapper.orderByDesc("create_time");
|
||||
IPage<OtaBaSjGnxtwh> pageList = otaBaSjGnxtwhService.page(page, queryWrapper);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-列表查询")
|
||||
@ApiOperation(value = "车型备案-功能系统维护-列表查询", notes = "车型备案-功能系统维护-列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<List<OtaBaSjGnxtwh>> queryList() {
|
||||
List<OtaBaSjGnxtwh> list = otaBaSjGnxtwhService.queryList();
|
||||
return Result.OK(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param otaBaSjGnxtwh
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-添加")
|
||||
@ApiOperation(value="车型备案-功能系统维护-添加", notes="车型备案-功能系统维护-添加")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<?> add(@Validated @RequestBody OtaBaSjGnxtwh otaBaSjGnxtwh) {
|
||||
otaBaSjGnxtwhService.add(otaBaSjGnxtwh);
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param otaBaSjGnxtwh
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-编辑")
|
||||
@ApiOperation(value="车型备案-功能系统维护-编辑", notes="车型备案-功能系统维护-编辑")
|
||||
@PutMapping(value = "/edit")
|
||||
public Result<?> edit(@Validated @RequestBody OtaBaSjGnxtwh otaBaSjGnxtwh) {
|
||||
otaBaSjGnxtwhService.editById(otaBaSjGnxtwh);
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-通过id删除")
|
||||
@ApiOperation(value="车型备案-功能系统维护-通过id删除", notes="车型备案-功能系统维护-通过id删除")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<?> delete(@RequestParam(name="id",required=true) String id) {
|
||||
otaBaSjGnxtwhService.deleteById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-批量删除")
|
||||
@ApiOperation(value="车型备案-功能系统维护-批量删除", notes="车型备案-功能系统维护-批量删除")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<?> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
this.otaBaSjGnxtwhService.deleteByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-通过id查询")
|
||||
@ApiOperation(value="车型备案-功能系统维护-通过id查询", notes="车型备案-功能系统维护-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<?> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
OtaBaSjGnxtwh otaBaSjGnxtwh = otaBaSjGnxtwhService.queryById(id);
|
||||
if(otaBaSjGnxtwh==null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(otaBaSjGnxtwh);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param otaBaSjGnxtwh
|
||||
*/
|
||||
* 添加
|
||||
*
|
||||
* @param otaBaSjGnxtwh
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-添加")
|
||||
@ApiOperation(value = "车型备案-功能系统维护-添加", notes = "车型备案-功能系统维护-添加")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<?> add(@Validated @RequestBody OtaBaSjGnxtwh otaBaSjGnxtwh) {
|
||||
try {
|
||||
otaBaSjGnxtwhService.add(otaBaSjGnxtwh);
|
||||
} catch (Exception e) {
|
||||
return Result.error(e.getMessage());
|
||||
}
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param otaBaSjGnxtwh
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-编辑")
|
||||
@ApiOperation(value = "车型备案-功能系统维护-编辑", notes = "车型备案-功能系统维护-编辑")
|
||||
@PutMapping(value = "/edit")
|
||||
public Result<?> edit(@Validated @RequestBody OtaBaSjGnxtwh otaBaSjGnxtwh) {
|
||||
try {
|
||||
otaBaSjGnxtwhService.editById(otaBaSjGnxtwh);
|
||||
} catch (Exception e) {
|
||||
return Result.error(e.getMessage());
|
||||
}
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-通过id删除")
|
||||
@ApiOperation(value = "车型备案-功能系统维护-通过id删除", notes = "车型备案-功能系统维护-通过id删除")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<?> delete(@RequestParam(name = "id", required = true) String id) {
|
||||
otaBaSjGnxtwhService.deleteById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-批量删除")
|
||||
@ApiOperation(value = "车型备案-功能系统维护-批量删除", notes = "车型备案-功能系统维护-批量删除")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<?> deleteBatch(@RequestParam(name = "ids", required = true) String ids) {
|
||||
this.otaBaSjGnxtwhService.deleteByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-通过id查询")
|
||||
@ApiOperation(value = "车型备案-功能系统维护-通过id查询", notes = "车型备案-功能系统维护-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<?> queryById(@RequestParam(name = "id", required = true) String id) {
|
||||
OtaBaSjGnxtwh otaBaSjGnxtwh = otaBaSjGnxtwhService.queryById(id);
|
||||
if (otaBaSjGnxtwh == null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(otaBaSjGnxtwh);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param otaBaSjGnxtwh
|
||||
*/
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, OtaBaSjGnxtwh otaBaSjGnxtwh) {
|
||||
return super.exportXls(request, otaBaSjGnxtwh, OtaBaSjGnxtwh.class, "车型备案-功能系统维护");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, OtaBaSjGnxtwh.class);
|
||||
|
||||
+2
-2
@@ -19,7 +19,7 @@ public interface IOtaBaSjGnxtwhService extends IService<OtaBaSjGnxtwh> {
|
||||
* @param otaBaSjGnxtwh
|
||||
* @return
|
||||
*/
|
||||
void add(OtaBaSjGnxtwh otaBaSjGnxtwh);
|
||||
void add(OtaBaSjGnxtwh otaBaSjGnxtwh) throws Exception;
|
||||
|
||||
/**
|
||||
* 更新
|
||||
@@ -27,7 +27,7 @@ public interface IOtaBaSjGnxtwhService extends IService<OtaBaSjGnxtwh> {
|
||||
* @param otaBaSjGnxtwh
|
||||
* @return
|
||||
*/
|
||||
void editById(OtaBaSjGnxtwh otaBaSjGnxtwh);
|
||||
void editById(OtaBaSjGnxtwh otaBaSjGnxtwh) throws Exception;
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
|
||||
+2
@@ -90,6 +90,8 @@ public class OtaBaCxAqcsServiceImpl extends ServiceImpl<OtaBaCxAqcsMapper, OtaBa
|
||||
List<AttachmentEO> aeoList = JSONArray.parseArray(otaBaCxAqcsOld.getZmcl(), AttachmentEO.class);
|
||||
otaBaCxAqcsOld.setZmclList(aeoList);
|
||||
}
|
||||
deleteById(otaBaCxAqcs.getId());
|
||||
deleteById(otaBaCxAqcsOld.getId());
|
||||
saveOrUpdate(otaBaCxAqcs);
|
||||
ComparisonUtil cu = new ComparisonUtil();
|
||||
if (ObjectUtils.isEmpty(otaBaCxAqcsOld)) {
|
||||
|
||||
+1
-1
@@ -286,7 +286,7 @@ public class OtaBaCxJbxxServiceImpl extends ServiceImpl<OtaBaCxJbxxMapper, OtaBa
|
||||
cell.setCellValue(jbxx.getDllx2());
|
||||
row = s.getRow(10);
|
||||
cell = row.getCell(1);
|
||||
cell.setCellValue(sysDictService.queryDictItemByValue("communication_terminal", jbxx.getTxzd(), cut));
|
||||
cell.setCellValue(sysDictService.queryDictTextByKey("communication_terminal", jbxx.getTxzd()));
|
||||
row = s.getRow(11);
|
||||
cell = row.getCell(1);
|
||||
cell.setCellValue(jbxx.getCdotasj());
|
||||
|
||||
+1
-1
@@ -853,7 +853,7 @@ public class OtaBaCxJsfzbacsServiceImpl extends ServiceImpl<OtaBaCxJsfzbacsMappe
|
||||
List<OtaBaCxSjmk> sjmkList = OtaBaCxSjmkService.queryByOtaId(otaId);
|
||||
int startRow = 63;
|
||||
for (OtaBaCxSjmk sjmk : sjmkList) {
|
||||
row = s.getRow(startRow);
|
||||
row = s.createRow(startRow);
|
||||
cell = row.createCell(0);
|
||||
cell.setCellValue(sjmk.getBjmc());
|
||||
cell = row.createCell(1);
|
||||
|
||||
+57
-2
@@ -1,8 +1,10 @@
|
||||
package com.jero.modules.ota.service.impl;
|
||||
|
||||
import com.jero.common.exception.JeroBootException;
|
||||
import com.jero.modules.ota.entity.OtaBaSjGnxtwh;
|
||||
import com.jero.modules.ota.mapper.OtaBaSjGnxtwhMapper;
|
||||
import com.jero.modules.ota.service.IOtaBaSjGnxtwhService;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
@@ -26,10 +28,28 @@ public class OtaBaSjGnxtwhServiceImpl extends ServiceImpl<OtaBaSjGnxtwhMapper, O
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void add(OtaBaSjGnxtwh otaBaSjGnxtwh) {
|
||||
public void add(OtaBaSjGnxtwh otaBaSjGnxtwh) throws Exception {
|
||||
Date now = new Date();
|
||||
otaBaSjGnxtwh.setCreateTime(now);
|
||||
otaBaSjGnxtwh.setUpdateTime(now);
|
||||
String str = otaBaSjGnxtwh.getDykzq();
|
||||
if (StringUtils.isNotEmpty(str)) {
|
||||
String[] arr = str.split(",");
|
||||
for (int i = 0; i < arr.length - 1; i++) {
|
||||
for (int j = i + 1; j < arr.length; j++) {
|
||||
if (arr[i].equals(arr[j])) {
|
||||
throw new JeroBootException("对应控制器重复:" + arr[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
for (String s : arr) {
|
||||
if (null != queryGnxtByKzq(s)) {
|
||||
throw new JeroBootException("对应控制器重复:" + s);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
throw new JeroBootException("对应控制器不能为空");
|
||||
}
|
||||
save(otaBaSjGnxtwh);
|
||||
}
|
||||
|
||||
@@ -40,9 +60,26 @@ public class OtaBaSjGnxtwhServiceImpl extends ServiceImpl<OtaBaSjGnxtwhMapper, O
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void editById(OtaBaSjGnxtwh otaBaSjGnxtwh) {
|
||||
public void editById(OtaBaSjGnxtwh otaBaSjGnxtwh) throws Exception {
|
||||
Date now = new Date();
|
||||
otaBaSjGnxtwh.setUpdateTime(now);
|
||||
String str = otaBaSjGnxtwh.getDykzq();
|
||||
if (StringUtils.isNotEmpty(str)) {
|
||||
String[] arr = str.split(",");
|
||||
for (int i = 0; i < arr.length - 1; i++) {
|
||||
for (int j = i + 1; j < arr.length; j++) {
|
||||
if (arr[i].equals(arr[j])) {
|
||||
throw new JeroBootException("对应控制器重复:" + arr[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
String res = queryGnxtByKzq(otaBaSjGnxtwh);
|
||||
if (null != res) {
|
||||
throw new JeroBootException("对应控制器重复:" + res);
|
||||
}
|
||||
} else {
|
||||
throw new JeroBootException("对应控制器不能为空");
|
||||
}
|
||||
saveOrUpdate(otaBaSjGnxtwh);
|
||||
}
|
||||
|
||||
@@ -79,6 +116,24 @@ public class OtaBaSjGnxtwhServiceImpl extends ServiceImpl<OtaBaSjGnxtwhMapper, O
|
||||
return getById(id);
|
||||
}
|
||||
|
||||
public String queryGnxtByKzq(OtaBaSjGnxtwh kzq) {
|
||||
List<OtaBaSjGnxtwh> list = list();
|
||||
for (OtaBaSjGnxtwh wh : list) {
|
||||
if (kzq.getId().equals(wh.getId())) {
|
||||
continue;
|
||||
}
|
||||
String[] strs = wh.getDykzq().split(",");
|
||||
String[] strs1 = kzq.getDykzq().split(",");
|
||||
for (String str : strs) {
|
||||
for (String str1 : strs1) {
|
||||
if (str.equals(str1)) {
|
||||
return str;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String queryGnxtByKzq(String kzq) {
|
||||
|
||||
+92
-83
@@ -3049,7 +3049,7 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
|
||||
|
||||
//编号必填
|
||||
flag = must(projectCertificationInventoryEO, errorMsg, msgList, serialNumber, "编号", "Standard No");
|
||||
// flag = must(projectCertificationInventoryEO, errorMsg, msgList, serialNumber, "编号", "Standard No");
|
||||
|
||||
//报告编号
|
||||
if(StringUtils.isNotBlank(reportNumber)){
|
||||
@@ -3099,15 +3099,16 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
} else {
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
message = errorMsg + "WVTA ID不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The WVTA ID cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
// else {
|
||||
// String message = "";
|
||||
// if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
// message = errorMsg + "WVTA ID不能为空, ";
|
||||
// }else{
|
||||
// message = errorMsg + " The WVTA ID cannot null, ";
|
||||
// }
|
||||
// msgList.add(message);
|
||||
// }
|
||||
//类别
|
||||
|
||||
if(StringUtils.isNotBlank(category)){
|
||||
@@ -3120,15 +3121,16 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
}else {
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
message = errorMsg + "类别不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The Category cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
// else {
|
||||
// String message = "";
|
||||
// if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
// message = errorMsg + "类别不能为空, ";
|
||||
// }else{
|
||||
// message = errorMsg + " The Category cannot null, ";
|
||||
// }
|
||||
// msgList.add(message);
|
||||
// }
|
||||
//检验项目
|
||||
|
||||
if(StringUtils.isNotBlank(inspectionItem)){
|
||||
@@ -3141,15 +3143,16 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
}else {
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
message = errorMsg + "检验项目不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The InspectionItem cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
// else {
|
||||
// String message = "";
|
||||
// if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
// message = errorMsg + "检验项目不能为空, ";
|
||||
// }else{
|
||||
// message = errorMsg + " The InspectionItem cannot null, ";
|
||||
// }
|
||||
// msgList.add(message);
|
||||
// }
|
||||
//配置项
|
||||
|
||||
if(StringUtils.isNotBlank(configItem)){
|
||||
@@ -3162,15 +3165,16 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
}else {
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
message = errorMsg + "配置项不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The ConfigItem cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
// else {
|
||||
// String message = "";
|
||||
// if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
// message = errorMsg + "配置项不能为空, ";
|
||||
// }else{
|
||||
// message = errorMsg + " The ConfigItem cannot null, ";
|
||||
// }
|
||||
// msgList.add(message);
|
||||
// }
|
||||
|
||||
//责任领域
|
||||
|
||||
@@ -3179,15 +3183,16 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
if(StringUtils.isNotBlank(value)){
|
||||
projectCertificationInventoryEO.setDutyTerritory(value);
|
||||
}
|
||||
}else {
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
message = errorMsg + "责任领域不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The Responsible Field cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
// else {
|
||||
// String message = "";
|
||||
// if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
// message = errorMsg + "责任领域不能为空, ";
|
||||
// }else{
|
||||
// message = errorMsg + " The Responsible Field cannot null, ";
|
||||
// }
|
||||
// msgList.add(message);
|
||||
// }
|
||||
//工程接口人(责任领域下的工程接口人)
|
||||
Map<String, Object> objectMap = iProjectRelatedPersonnelService.queryPersonByProjectId(projectCertificationInventoryEOTemp.getProjectLibraryId(), value);
|
||||
|
||||
@@ -3209,30 +3214,32 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
nameEn = "Eng. Interface ";
|
||||
//验证人员是否存在
|
||||
personnelVerify(projectCertificationInventoryEO, errorMsg, msgList, sdt, mapPersonList,nameCn,nameEn, com.jero.modules.project.enums.ProjectRoleEnum.ENGINEERING_INTERFACE_PERSON.getValue());
|
||||
}else {
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
message = errorMsg + "工程接口人不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The Eng. Interface cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
// else {
|
||||
// String message = "";
|
||||
// if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
// message = errorMsg + "工程接口人不能为空, ";
|
||||
// }else{
|
||||
// message = errorMsg + " The Eng. Interface cannot null, ";
|
||||
// }
|
||||
// msgList.add(message);
|
||||
// }
|
||||
//责任人
|
||||
if(StringUtils.isNotBlank(dutyPerson)){
|
||||
nameCn = "责任人";
|
||||
nameEn = "Assignee";
|
||||
//验证人员是否存在
|
||||
personDutyPerson(projectCertificationInventoryEO, errorMsg, msgList, dutyPerson, listUserName,nameCn,nameEn);
|
||||
}else {
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
message = errorMsg + "责任人不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The Assignee cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
// else {
|
||||
// String message = "";
|
||||
// if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
// message = errorMsg + "责任人不能为空, ";
|
||||
// }else{
|
||||
// message = errorMsg + " The Assignee cannot null, ";
|
||||
// }
|
||||
// msgList.add(message);
|
||||
// }
|
||||
//交付物类型
|
||||
if(StringUtils.isNotEmpty(deliverableType)){
|
||||
value = tree(categoryList,treeNameList, projectCertificationInventoryEO, errorMsg, deliverableType,msgList,"交付物类型","Deliverable Type","deliverable_template");
|
||||
@@ -3240,15 +3247,16 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
String treeId = getTreeId(categoryList, projectCertificationInventoryEOTemp, treeNameList, value);
|
||||
projectCertificationInventoryEO.setDeliverableType(treeId);
|
||||
}
|
||||
}else{
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
message = errorMsg + "交付物类型不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The Deliverable Type cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
// else{
|
||||
// String message = "";
|
||||
// if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
// message = errorMsg + "交付物类型不能为空, ";
|
||||
// }else{
|
||||
// message = errorMsg + " The Deliverable Type cannot null, ";
|
||||
// }
|
||||
// msgList.add(message);
|
||||
// }
|
||||
|
||||
//交付物模板
|
||||
value = templateTransition(zipEntryName, projectCertificationInventoryEO, errorMsg, deliverableTemplate,msgList,"交付物模板","Deliverable Template");
|
||||
@@ -3270,15 +3278,16 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
}
|
||||
projectCertificationInventoryEO.setEndTime(date);
|
||||
}
|
||||
}else{
|
||||
String message = "";
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
message = errorMsg + "截止时间不能为空, ";
|
||||
}else{
|
||||
message = errorMsg + " The Due Date Type cannot null, ";
|
||||
}
|
||||
msgList.add(message);
|
||||
}
|
||||
// else{
|
||||
// String message = "";
|
||||
// if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
|
||||
// message = errorMsg + "截止时间不能为空, ";
|
||||
// }else{
|
||||
// message = errorMsg + " The Due Date Type cannot null, ";
|
||||
// }
|
||||
// msgList.add(message);
|
||||
// }
|
||||
|
||||
}
|
||||
return msgList;
|
||||
@@ -3314,9 +3323,9 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
if (!DateUtils.isValidDate(field)) {
|
||||
flag = false;
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEO.getCut())){
|
||||
errorMsg += nameCn + "格式不正确, 正确格式如:yyyy/m/d、yyyy-MM-dd、yyyy年MM月dd日";
|
||||
errorMsg += nameCn + "格式不正确, 正确格式如:yyyy/m/d、yyyy-MM-dd、yyyy年MM月dd日, ";
|
||||
}else{
|
||||
errorMsg += nameEn + " Incorrect format correct format is:yyyy/m/d、yyyy-MM-dd、yyyy年MM月dd日";
|
||||
errorMsg += nameEn + " Incorrect format correct format is:yyyy/m/d、yyyy-MM-dd、yyyy年MM月dd日, ";
|
||||
}
|
||||
msgList.add(errorMsg);
|
||||
}
|
||||
@@ -3329,9 +3338,9 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
if(longnow>longdate){
|
||||
flag = false;
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEO.getCut())){
|
||||
errorMsg += nameCn + "不能导入今天之前的日期";
|
||||
errorMsg += nameCn + "不能导入今天之前的日期, ";
|
||||
}else{
|
||||
errorMsg += nameEn + " Cannot import dates before today ";
|
||||
errorMsg += nameEn + " Cannot import dates before today, ";
|
||||
}
|
||||
msgList.add(errorMsg);
|
||||
}
|
||||
@@ -3476,9 +3485,9 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
}
|
||||
if(count==0){
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEO.getCut())){
|
||||
errorMsg += nameCn+regulationOwnerId+"与所有人员名单不匹配";
|
||||
errorMsg += nameCn+regulationOwnerId+"与所有人员名单不匹配, ";
|
||||
}else{
|
||||
errorMsg += nameEn+regulationOwnerId+"does not match a person with all person list";
|
||||
errorMsg += nameEn+regulationOwnerId+"does not match a person with all person list, ";
|
||||
}
|
||||
msgList.add(errorMsg);
|
||||
}
|
||||
@@ -3510,17 +3519,17 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
}
|
||||
if(count == 0){
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEO.getCut())){
|
||||
errorMsg += nameCn+regulationOwnerId+"与相关人员名单中责任领域下的人员不匹配";
|
||||
errorMsg += nameCn+regulationOwnerId+"与相关人员名单中责任领域下的人员不匹配, ";
|
||||
}else{
|
||||
errorMsg += nameEn+regulationOwnerId+"does not match a person under the Responsible Field in the relevant person list";
|
||||
errorMsg += nameEn+regulationOwnerId+"does not match a person under the Responsible Field in the relevant person list, ";
|
||||
}
|
||||
msgList.add(errorMsg);
|
||||
}
|
||||
}else{
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEO.getCut())){
|
||||
errorMsg += nameCn+regulationOwnerId+"与相关人员名单中责任领域下的人员不匹配";
|
||||
errorMsg += nameCn+regulationOwnerId+"与相关人员名单中责任领域下的人员不匹配, ";
|
||||
}else{
|
||||
errorMsg += nameEn+regulationOwnerId+"does not match a person under the Responsible Field in the relevant person list";
|
||||
errorMsg += nameEn+regulationOwnerId+"does not match a person under the Responsible Field in the relevant person list, ";
|
||||
}
|
||||
msgList.add(errorMsg);
|
||||
}
|
||||
|
||||
@@ -291,7 +291,7 @@ export default {
|
||||
this.confirmLoading = false
|
||||
this.bussLogList()
|
||||
} else {
|
||||
this.$message.warning(this.$t('operationFailed'))
|
||||
this.$message.warning(res.message)
|
||||
this.confirmLoading = false
|
||||
}
|
||||
})
|
||||
|
||||
@@ -428,7 +428,7 @@ export default {
|
||||
localStorage.removeItem('otaIdT')
|
||||
this.$router.push({
|
||||
path: '/upgradeactivityrecord',
|
||||
query: {}
|
||||
query: { type:2}
|
||||
})
|
||||
},
|
||||
viewProcessClick(row) {
|
||||
|
||||
+4
-1
@@ -140,6 +140,9 @@ export default {
|
||||
}
|
||||
getAction('/ota/otaBaSjSjmbcl/queryByOtaId',{otaIdT:otaIdT,otaId:otaId}).then(res=>{
|
||||
if(res.code==200){
|
||||
if(res.result==null){
|
||||
res.result={}
|
||||
}
|
||||
this.formInline.zsl=res.result.zsl
|
||||
this.formInline.vinList=res.result.vinList
|
||||
this.formInline.csv=res.result.csv
|
||||
@@ -148,7 +151,7 @@ export default {
|
||||
res.result.scrqjs=res.result.scrqjs == null ? "" : res.result.scrqjs
|
||||
this.formInline.dateofproduction.push(res.result.scrqks)
|
||||
this.formInline.dateofproduction.push(res.result.scrqjs)
|
||||
this.formInline.id = res.result.vinList
|
||||
this.formInline.id = res.result.id
|
||||
this.$forceUpdate()
|
||||
|
||||
}
|
||||
|
||||
+56
-16
@@ -130,7 +130,7 @@
|
||||
</a-select>
|
||||
</a-form-model-item>
|
||||
<a-form-model-item class="itemModel" style="width: 40%;margin-left:-9px">
|
||||
<a-select v-model="form.dllx2" class="box-input" :disabled="disabled" :placeholder="$t('PleaseSelect')" @change="update">
|
||||
<a-select v-model="form.dllx2" class="box-input" :disabled="disabled" :placeholder="$t('PleaseSelect')" @change="update2">
|
||||
<a-select-option v-for="(item, key) in projectNameList2"
|
||||
:key="key"
|
||||
:value="item">
|
||||
@@ -168,7 +168,8 @@ import ImportFile from '@/components/ImportFileData/index'
|
||||
confirmLoading: false,
|
||||
disabled: false,
|
||||
form:{
|
||||
qymc:'安徽江淮汽车集团股份有限公司'
|
||||
qymc:'安徽江淮汽车集团股份有限公司',
|
||||
bapc:undefined
|
||||
},
|
||||
url: {
|
||||
exportData: '/ota/otaBaSjSjmbcx/exportData',
|
||||
@@ -216,8 +217,23 @@ import ImportFile from '@/components/ImportFileData/index'
|
||||
this.form.dllx1=undefined
|
||||
this.form.dllx2=undefined
|
||||
this.form.qymc='安徽江淮汽车集团股份有限公司'
|
||||
// if(this.$route.query.type == 1 && res.result.cxmb == null){
|
||||
// this.form.cxmb=this.form.ggpc+'-'+ this.form.cpmc+'-'+this.form.cpxh
|
||||
// }
|
||||
|
||||
}else{
|
||||
|
||||
this.form=res.result
|
||||
if(this.$route.query.type == 1 && res.result.cxmb == null){
|
||||
this.form.cxmb = this.form.babh+'-'+ this.form.bapc+'-'+this.form.cpxh
|
||||
}else {
|
||||
if(this.$route.query.type == 2 && res.result.cxmb == null){
|
||||
this.form.cxmb = this.form.babh+'-'+ this.form.bapc+'-'+this.form.cpxh
|
||||
}else{
|
||||
this.form.cxmb = res.result.cxmb ? res.result.cxmb : undefined
|
||||
}
|
||||
}
|
||||
|
||||
if(res.result.dllx1==null){
|
||||
this.form.dllx1=undefined
|
||||
|
||||
@@ -242,6 +258,11 @@ import ImportFile from '@/components/ImportFileData/index'
|
||||
if(otaId==null){
|
||||
otaId=''
|
||||
}
|
||||
// if(this.form.bapc!=null && this.form.bapc!=undefined && this.form.bapc!=''){
|
||||
// this.$nextTick(()=>{
|
||||
// this.$refs.ruleForm.clearValidate('bapc')
|
||||
// })
|
||||
// }
|
||||
this.$refs.ruleForm.validate(valid=>{
|
||||
if(valid){
|
||||
this.selectListPc.map(item=>{
|
||||
@@ -256,12 +277,19 @@ import ImportFile from '@/components/ImportFileData/index'
|
||||
this.getData()
|
||||
}
|
||||
})
|
||||
}else{
|
||||
this.form.bapc=undefined
|
||||
}
|
||||
})
|
||||
|
||||
},
|
||||
next(){
|
||||
this.save()
|
||||
// if(this.form.bapc!=null && this.form.bapc!=undefined && this.form.bapc!=''){
|
||||
// this.$nextTick(()=>{
|
||||
// this.$refs.ruleForm.clearValidate('bapc')
|
||||
// })
|
||||
// }
|
||||
this.$refs.ruleForm.validate(valid=>{
|
||||
if(valid){
|
||||
this.$emit('basicInformationForm')
|
||||
@@ -289,7 +317,7 @@ import ImportFile from '@/components/ImportFileData/index'
|
||||
res.result.forEach(item=>{
|
||||
let obj={}
|
||||
obj.id=item.id
|
||||
obj.cpdjbh=item.cpdjbh
|
||||
obj.cpdjbh=item.cpdjbh+'-'+item.ggpc+'-'+item.cpxh
|
||||
this.selectListMb.push(obj)
|
||||
})
|
||||
}
|
||||
@@ -309,21 +337,33 @@ import ImportFile from '@/components/ImportFileData/index'
|
||||
|
||||
},
|
||||
changeId(value,option){
|
||||
this.selectListPc.map(item=>{
|
||||
if(item.id==value){
|
||||
this.form.cpsb = item.cpsb
|
||||
this.form.cpmc = item.cpmc
|
||||
this.form.cpxh = item.cpxh
|
||||
getAction('/ota/otaBaCxJbxx/queryByOtaId',{otaIdT:'',otaId:item.id}).then(res=>{
|
||||
this.form.dllx1=res.result.dllx1 == null?undefined:res.result.dllx1
|
||||
this.form.dllx2=res.result.dllx2== null?undefined:res.result.dllx2
|
||||
this.$forceUpdate()
|
||||
})
|
||||
}
|
||||
})
|
||||
|
||||
this.$nextTick(()=>{
|
||||
this.form={...this.form}
|
||||
this.$refs.ruleForm.validateField('bapc')
|
||||
})
|
||||
this.selectListPc.map(item=>{
|
||||
if(item.id==value){
|
||||
this.form.cpsb = item.cpsb
|
||||
this.form.cpmc = item.cpmc
|
||||
this.form.cpxh = item.cpxh
|
||||
getAction('/ota/otaBaCxJbxx/queryByOtaId',{otaIdT:'',otaId:item.id}).then(res=>{
|
||||
this.form.dllx1=res.result.dllx1 == null?undefined:res.result.dllx1
|
||||
this.form.dllx2=res.result.dllx2== null?undefined:res.result.dllx2
|
||||
})
|
||||
}
|
||||
})
|
||||
this.$forceUpdate()
|
||||
},
|
||||
update(){
|
||||
update(val){
|
||||
this.$forceUpdate()
|
||||
localStorage.removeItem('otaId')
|
||||
localStorage.removeItem('otaIdT')
|
||||
localStorage.setItem('otaIdT',val)
|
||||
|
||||
this.getData()
|
||||
},
|
||||
update2(){
|
||||
this.$forceUpdate()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -331,7 +331,11 @@ import { message } from 'ant-design-vue'
|
||||
if(this.$route.query.type == 1 && res.result.cxmb == null){
|
||||
this.form.cxmb = this.form.ggpc+'-'+ this.form.cpmc+'-'+this.form.cpxh
|
||||
}else {
|
||||
this.form.cxmb = res.result.cxmb ? res.result.cxmb : undefined
|
||||
if(this.$route.query.type == 2 && res.result.cxmb == null){
|
||||
this.form.cxmb = this.form.ggpc+'-'+ this.form.cpmc+'-'+this.form.cpxh
|
||||
}else{
|
||||
this.form.cxmb = res.result.cxmb ? res.result.cxmb : undefined
|
||||
}
|
||||
}
|
||||
if(res.result.dllx1 == null ){
|
||||
res.result.dllx1 = undefined
|
||||
|
||||
@@ -385,7 +385,7 @@ export default {
|
||||
localStorage.removeItem('otaIdT')
|
||||
this.$router.push({
|
||||
path: '/vehicleinformation',
|
||||
query: { type:1}
|
||||
query: { type:2}
|
||||
})
|
||||
},
|
||||
viewProcessClick(row) {
|
||||
|
||||
Reference in New Issue
Block a user