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

This commit is contained in:
gaosong
2023-10-25 09:49:31 +08:00
16 changed files with 865 additions and 535 deletions
@@ -1338,7 +1338,9 @@ ADD PRIMARY KEY (`vdr_id`);
ALTER TABLE `params_report` ALTER TABLE `params_report`
ADD COLUMN `project_version` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '相关项目版本' AFTER `target_market`; ADD COLUMN `project_version` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '相关项目版本' AFTER `target_market`;
-- 问题管理添加相关项目类型字段 2023-10-24
ALTER TABLE `problem_management`
ADD COLUMN `project_type` varchar(255) NULL COMMENT '相关项目类型' AFTER `problem_priority`;
@@ -25,11 +25,23 @@ import com.jero.modules.cert.collect.enums.ConfigDataTypeEnum;
import com.jero.modules.cert.collect.enums.ExportStateEnum; import com.jero.modules.cert.collect.enums.ExportStateEnum;
import com.jero.modules.cert.collect.service.IParamsCollectExportService; import com.jero.modules.cert.collect.service.IParamsCollectExportService;
import com.jero.modules.cert.collect.vo.ParamsConfigDataVO; import com.jero.modules.cert.collect.vo.ParamsConfigDataVO;
import com.jero.modules.cert.report.entity.*; import com.jero.modules.cert.report.entity.ParamsExportTemplateEO;
import com.jero.modules.cert.report.entity.ParamsReportConfigDataEO;
import com.jero.modules.cert.report.entity.ParamsReportConfigEO;
import com.jero.modules.cert.report.entity.ParamsReportDetailEO;
import com.jero.modules.cert.report.entity.ParamsReportDetailLogEO;
import com.jero.modules.cert.report.entity.ParamsReportExportHistoryEO;
import com.jero.modules.cert.report.entity.ReportCertCategoryParamsInfoEO;
import com.jero.modules.cert.report.enums.ExportTemplateStateEnum; import com.jero.modules.cert.report.enums.ExportTemplateStateEnum;
import com.jero.modules.cert.report.enums.ExportTypeEnum; import com.jero.modules.cert.report.enums.ExportTypeEnum;
import com.jero.modules.cert.report.mapper.ParamsReportDetailEOMapper; import com.jero.modules.cert.report.mapper.ParamsReportDetailEOMapper;
import com.jero.modules.cert.report.service.*; import com.jero.modules.cert.report.service.IParamsExportTemplateEOService;
import com.jero.modules.cert.report.service.IParamsReportConfigDataEOService;
import com.jero.modules.cert.report.service.IParamsReportConfigEOService;
import com.jero.modules.cert.report.service.IParamsReportDetailEOService;
import com.jero.modules.cert.report.service.IParamsReportDetailLogEOService;
import com.jero.modules.cert.report.service.IParamsReportExportHistoryEOService;
import com.jero.modules.cert.report.service.IReportCertCategoryParamsInfoEOService;
import com.jero.modules.cert.report.vo.ParamsReportDetailVO; import com.jero.modules.cert.report.vo.ParamsReportDetailVO;
import com.jero.modules.cert.template.enums.ControlTypeEnum; import com.jero.modules.cert.template.enums.ControlTypeEnum;
import com.jero.modules.cert.template.enums.ParamsIsMustEnum; import com.jero.modules.cert.template.enums.ParamsIsMustEnum;
@@ -50,7 +62,13 @@ import org.apache.poi.hssf.util.HSSFColor;
import org.apache.poi.ss.usermodel.Workbook; import org.apache.poi.ss.usermodel.Workbook;
import org.apache.poi.ss.usermodel.WorkbookFactory; import org.apache.poi.ss.usermodel.WorkbookFactory;
import org.apache.poi.util.IOUtils; import org.apache.poi.util.IOUtils;
import org.apache.poi.xssf.usermodel.*; import org.apache.poi.xssf.usermodel.XSSFCell;
import org.apache.poi.xssf.usermodel.XSSFCellStyle;
import org.apache.poi.xssf.usermodel.XSSFFont;
import org.apache.poi.xssf.usermodel.XSSFRichTextString;
import org.apache.poi.xssf.usermodel.XSSFRow;
import org.apache.poi.xssf.usermodel.XSSFSheet;
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
import org.apache.shiro.SecurityUtils; import org.apache.shiro.SecurityUtils;
import org.aspectj.util.FileUtil; import org.aspectj.util.FileUtil;
import org.docx4j.Docx4J; import org.docx4j.Docx4J;
@@ -68,14 +86,32 @@ import org.springframework.web.multipart.MultipartFile;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import java.io.*; import java.io.BufferedInputStream;
import java.io.BufferedOutputStream;
import java.io.ByteArrayOutputStream;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.lang.reflect.Field; import java.lang.reflect.Field;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.nio.file.Files; import java.nio.file.Files;
import java.nio.file.Paths; import java.nio.file.Paths;
import java.nio.file.StandardOpenOption; import java.nio.file.StandardOpenOption;
import java.text.SimpleDateFormat; import java.text.SimpleDateFormat;
import java.util.*; import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.Comparator;
import java.util.Date;
import java.util.HashMap;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import java.util.TreeSet;
import java.util.UUID;
import java.util.stream.Collectors; import java.util.stream.Collectors;
/** /**
@@ -1824,6 +1860,8 @@ public class ParamsReportDetailEOServiceImpl extends ServiceImpl<ParamsReportDet
List<ParamsReportConfigDataEO> paramsReportConfigDataEOList = paramsReportConfigDataEOService.queryListByConfigIdList(paramsReportConfigIdList); // 查询所有配置数据 List<ParamsReportConfigDataEO> paramsReportConfigDataEOList = paramsReportConfigDataEOService.queryListByConfigIdList(paramsReportConfigIdList); // 查询所有配置数据
LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
// List<String> idList = configDataList.stream().map(e -> e.get("id").toString()).collect(Collectors.toList());
// List<ParamsReportDetailEO> paramsReportDetailEOS = this.listByIds(idList);
// 处理数据 // 处理数据
for (Map<String, Object> map : configDataList) { for (Map<String, Object> map : configDataList) {
@@ -2041,10 +2079,28 @@ public class ParamsReportDetailEOServiceImpl extends ServiceImpl<ParamsReportDet
this.paramsReportConfigDataEOService.remove(removeConfigDataWrap); this.paramsReportConfigDataEOService.remove(removeConfigDataWrap);
} }
ParamsReportDetailLogEO insertLogEO = new ParamsReportDetailLogEO(); ParamsReportDetailLogEO insertLogEO = new ParamsReportDetailLogEO();
String ramarks = ""; String ramarks = "";
if(map.get("remarks") != null){ if(map.get("remarks") != null){
ramarks = map.get("remarks").toString(); ramarks = map.get("remarks").toString();
} }
boolean remarkFlag = false;
// List<ParamsReportDetailEO> collect = paramsReportDetailEOS.stream().filter(e -> paramsCollectManifestId.equals(e.getId())).collect(Collectors.toList());
// if(ObjectUtils.isNotEmpty(collect)){
// String remark = collect.get(0).getRemarks();
// if(StringUtils.isNotBlank(remark)
// && StringUtils.isNotBlank(ramarks)
// && !ramarks.equals(remark)){
// remarkFlag = true;
// }
// if(StringUtils.isBlank(remark) && StringUtils.isNotBlank(ramarks)){
// remarkFlag = true;
// }
// if(StringUtils.isNotBlank(remark) && StringUtils.isBlank(ramarks)){
// remarkFlag = true;
// }
// }
if(!loginUser.getUsername().equals(logCnContent.toString()) && !loginUser.getUsername().equals(logEnContent.toString())){ if(!loginUser.getUsername().equals(logCnContent.toString()) && !loginUser.getUsername().equals(logEnContent.toString())){
insertLogEO.setLogCnContent(logCnContent.toString().substring(0, logCnContent.length()-1)); insertLogEO.setLogCnContent(logCnContent.toString().substring(0, logCnContent.length()-1));
insertLogEO.setLogEnContent(logEnContent.toString().substring(0, logCnContent.length()-1)); insertLogEO.setLogEnContent(logEnContent.toString().substring(0, logCnContent.length()-1));
@@ -354,4 +354,10 @@ public class ProjectLibraryBaseController extends JeroController<ProjectLibraryB
public Result<?> overallReplacementUser(@RequestBody JSONObject json){ public Result<?> overallReplacementUser(@RequestBody JSONObject json){
return this.projectLibraryBaseService.overallReplacementUser(json); return this.projectLibraryBaseService.overallReplacementUser(json);
} }
@AutoLog(value = "查询数字平台或车型平台")
@ApiOperation(value="查询数字平台或车型平台", notes="查询数字平台或车型平台")
@GetMapping(value = "/getPlatform")
public List<String> getPlatform(String platform){
return projectLibraryBaseService.getPlatform(platform);
}
} }
@@ -175,4 +175,9 @@ public class ProblemManagementEO implements Serializable {
@ApiModelProperty(value = "旧数据->old,新数据->new") @ApiModelProperty(value = "旧数据->old,新数据->new")
private String flag; private String flag;
@ApiModelProperty(value = "相关项目类型")
private String projectType;
} }
@@ -0,0 +1,45 @@
package com.jero.modules.project.enums;
/**
* 任务状态枚举类
*/
public enum PlatformEnum {
NUMBER_PLATFORM("数字平台","numberPlatform"),
CAR_PLATFORM("车型平台","carPlatform"),
;
String name;
String value;
private PlatformEnum(String name, String value) {
this.name = name;
this.value = value;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getValue() {
return value;
}
public void setValue(String value) {
this.value = value;
}
public static String getTextByValue(String value) {
PlatformEnum[] values = values();
for (PlatformEnum taskStatusEnum : values) {
if (taskStatusEnum.value.equals(value)) {
return taskStatusEnum.name;
}
}
return null;
}
}
@@ -204,4 +204,6 @@ public interface IProjectLibraryBaseService extends IService<ProjectLibraryBase>
List<ProjectLibraryBase> queryList(List<String> projectIdList); List<ProjectLibraryBase> queryList(List<String> projectIdList);
List<ProjectLibraryBase> getListByIds(List<String> projectIdList); List<ProjectLibraryBase> getListByIds(List<String> projectIdList);
List<String> getPlatform(String platform);
} }
@@ -116,20 +116,6 @@ public class NcrTrackServiceImpl extends ServiceImpl<NcrTrackMapper, NcrTrackVO>
public List<NcrTrackVO> getPageInfo(NcrTrackVO ncrTrackVO) { public List<NcrTrackVO> getPageInfo(NcrTrackVO ncrTrackVO) {
LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
ncrTrackVO.setUserId(loginUser.getId()); ncrTrackVO.setUserId(loginUser.getId());
// if(StringUtils.isNotBlank(ncrTrackVO.getSerialNumber())){
// if(ncrTrackVO.getSerialNumber().contains("%")){
// ncrTrackVO.setSerialNumber(ncrTrackVO.getSerialNumber().replaceAll("%", "/%"));
// }
// ncrTrackVO.setSerialNumber(ncrTrackVO.getSerialNumber().replace("*",""));
// }
// if(StringUtils.isNotBlank(ncrTrackVO.getTitle())){
// if(ncrTrackVO.getTitle().contains("%")){
// ncrTrackVO.setTitle(ncrTrackVO.getTitle().replace("%","/%"));
// }
// ncrTrackVO.setTitle(ncrTrackVO.getTitle().replace("*",""));
// }
// List<SysUser> sysUserList = sysUserService.list();
ncrTrackVO.setInconformity(ReviewResultEnum.INCONFORMITY.getValue()); ncrTrackVO.setInconformity(ReviewResultEnum.INCONFORMITY.getValue());
ncrTrackVO.setTrack(ReviewResultEnum.TO_TRACK.getValue()); ncrTrackVO.setTrack(ReviewResultEnum.TO_TRACK.getValue());
@@ -10979,9 +10979,14 @@ public class ProjectLawsInventoryEOServiceImpl extends ServiceImpl<ProjectLawsIn
@NotNull @NotNull
private List<Map<String, Object>> getNewData(Map<String, Object> params, String cut,boolean administrator) { private List<Map<String, Object>> getNewData(Map<String, Object> params, String cut,boolean administrator) {
// params.put("numberPlatform","NT2");
// params.put("carPlatform","NT2");
//新数据 //新数据
LambdaQueryWrapper<ProblemManagementEO> wrapper = new LambdaQueryWrapper<>(); LambdaQueryWrapper<ProblemManagementEO> wrapper = new LambdaQueryWrapper<>();
wrapper.like(ProblemManagementEO::getProjectId,params.get("projectLibraryId")); wrapper.like(ProblemManagementEO::getProjectId,params.get("projectLibraryId"));
wrapper.or().eq(ProblemManagementEO::getProjectId,params.get("numberPlatform"));
wrapper.or().eq(ProblemManagementEO::getProjectId, params.get("carPlatform"));
List<ProblemManagementEO> managementEOList = problemManagementEOService.list(wrapper); List<ProblemManagementEO> managementEOList = problemManagementEOService.list(wrapper);
//法规 //法规
List<String> lawsIdList = managementEOList.stream() List<String> lawsIdList = managementEOList.stream()
@@ -11051,6 +11056,7 @@ public class ProjectLawsInventoryEOServiceImpl extends ServiceImpl<ProjectLawsIn
map.put("id",problemManagementEO.getId()); map.put("id",problemManagementEO.getId());
map.put("flag",DataEnum.NEW.getValue()); map.put("flag",DataEnum.NEW.getValue());
map.put("administrator",administrator ? "true" : "false"); map.put("administrator",administrator ? "true" : "false");
map.put("projectType",problemManagementEO.getProjectType());
List<DictModel> dictModelList = problemTypeList.stream().filter(e -> e.getValue().equals(problemManagementEO.getProblemType())).collect(Collectors.toList()); List<DictModel> dictModelList = problemTypeList.stream().filter(e -> e.getValue().equals(problemManagementEO.getProblemType())).collect(Collectors.toList());
@@ -11078,6 +11084,10 @@ public class ProjectLawsInventoryEOServiceImpl extends ServiceImpl<ProjectLawsIn
List<ProjectLibraryBase> projectLibraryBaseListTemp = projectLibraryBaseList.stream() List<ProjectLibraryBase> projectLibraryBaseListTemp = projectLibraryBaseList.stream()
.filter(e->StringUtils.isNotBlank(problemManagementEO.getProjectId()) .filter(e->StringUtils.isNotBlank(problemManagementEO.getProjectId())
&& problemManagementEO.getProjectId().contains(e.getId())).collect(Collectors.toList()); && problemManagementEO.getProjectId().contains(e.getId())).collect(Collectors.toList());
if(ObjectUtils.isEmpty(projectLibraryBaseListTemp)){
map.put("projectName",problemManagementEO.getProjectId());
map.put("projectId",problemManagementEO.getProjectId());
}
//目标市场数据字典 //目标市场数据字典
List<DictModel> targetMarketList = sysDictService.queryDictItemsByCode(DicCodeEnum.REGION.getCode()); List<DictModel> targetMarketList = sysDictService.queryDictItemsByCode(DicCodeEnum.REGION.getCode());
List<String> projectNameList = new ArrayList<>(); List<String> projectNameList = new ArrayList<>();
@@ -42,6 +42,7 @@ import com.jero.modules.project.enums.FlowStateEnum;
import com.jero.modules.project.enums.HSStatisticalNodesEnum; import com.jero.modules.project.enums.HSStatisticalNodesEnum;
import com.jero.modules.project.enums.OperatorTypeEnum; import com.jero.modules.project.enums.OperatorTypeEnum;
import com.jero.modules.project.enums.PermissionDescriptionEnum; import com.jero.modules.project.enums.PermissionDescriptionEnum;
import com.jero.modules.project.enums.PlatformEnum;
import com.jero.modules.project.enums.ProjectRoleEnum; import com.jero.modules.project.enums.ProjectRoleEnum;
import com.jero.modules.project.enums.ProjectTaskPlanningNameEnum; import com.jero.modules.project.enums.ProjectTaskPlanningNameEnum;
import com.jero.modules.project.enums.ProjectUserLocationEnum; import com.jero.modules.project.enums.ProjectUserLocationEnum;
@@ -4219,6 +4220,23 @@ public class ProjectLibraryBaseServiceImpl extends ServiceImpl<ProjectLibraryBas
} }
return res; return res;
} }
@Override
public List<String> getPlatform(String platform) {
List<ProjectLibraryBase> projectLibraryBaseList = this.list();
List<String> platformList = new ArrayList<>();
if(PlatformEnum.NUMBER_PLATFORM.getValue().equals(platform)){
platformList = projectLibraryBaseList.stream()
.filter(e -> StringUtils.isNotBlank(e.getDigitalPlatform()))
.map(ProjectLibraryBase::getDigitalPlatform).distinct().collect(Collectors.toList());
}
if(PlatformEnum.CAR_PLATFORM.getValue().equals(platform)){
platformList = projectLibraryBaseList.stream()
.filter(e -> StringUtils.isNotBlank(e.getVehiclePlatform()))
.map(ProjectLibraryBase::getVehiclePlatform).distinct().collect(Collectors.toList());
}
return platformList;
}
} }
@@ -258,6 +258,9 @@ public class NcrTrackVO implements Serializable {
private String platform; private String platform;
//相关项目类型
private String projectType;
@@ -698,10 +698,11 @@
this.deleteIds.push(item.id) this.deleteIds.push(item.id)
} }
for(let i=index;i<this.contentList.length-1;i++){ // for(let i=index;i<this.contentList.length-1;i++){
this.contentList[index]=this.contentList[index+1] // this.contentList[index]=this.contentList[index+1]
} // }
this.contentList.pop() this.contentList.splice(index,1)
// this.contentList.pop()
// console.log('this.content',this.contentList) // console.log('this.content',this.contentList)
}, },
//保存 //保存
@@ -167,6 +167,7 @@
</div> </div>
</div> </div>
<projectStatus ref="projectStatusRef" <projectStatus ref="projectStatusRef"
:queryForm="queryForm"
@currentStatus="currentStatus" @currentStatus="currentStatus"
@projectStatusForm="projectStatusForm"/> @projectStatusForm="projectStatusForm"/>
<versionStatistics ref="versionStatisticsRef" @versionStatisticsForm="versionStatisticsForm"/> <versionStatistics ref="versionStatisticsRef" @versionStatisticsForm="versionStatisticsForm"/>
@@ -239,6 +240,9 @@
if (res.success) { if (res.success) {
this.cut = res.cut this.cut = res.cut
this.queryForm = res.result[0] || {} this.queryForm = res.result[0] || {}
if (this.$refs.projectStatusRef){
this.$refs.projectStatusRef.getData(this.queryForm)
}
if (this.cut == 'en') { if (this.cut == 'en') {
this.queryForm.brandText = this.queryForm.brandTextEn this.queryForm.brandText = this.queryForm.brandTextEn
} else { } else {
@@ -149,7 +149,8 @@
<!-- </a>--> <!-- </a>-->
<!-- </span>--> <!-- </span>-->
<div slot="CertificationProgress" slot-scope="text,result"> <div slot="CertificationProgress" slot-scope="text,result">
<span v-if="result.problemState == $t('red')" class="box-content-Progress box-content-cou nonConformityColor" <span v-if="result.problemState == $t('red')"
class="box-content-Progress box-content-cou nonConformityColor"
:style="{'width':long=='zh-cn'?'90px' : '120px'}" :style="{'width':long=='zh-cn'?'90px' : '120px'}"
> >
{{result.problemState ? result.problemState : ''}} {{result.problemState ? result.problemState : ''}}
@@ -165,19 +166,22 @@
{{result.problemState ? result.problemState : ''}} {{result.problemState ? result.problemState : ''}}
</span> </span>
</div> </div>
<!-- <span slot="problemType" slot-scope="text,result">--> <!-- <span slot="problemType" slot-scope="text,result">-->
<!-- <span>{{result.flag== 'NEW'?result.problemType_dictText:result.problemType}}</span>--> <!-- <span>{{result.flag== 'NEW'?result.problemType_dictText:result.problemType}}</span>-->
<!-- </span>--> <!-- </span>-->
<span slot="operation" slot-scope="text,record"> <span slot="operation" slot-scope="text,record">
<a class="text-operation" v-has="'ncrTrack:check'" <a class="text-operation" v-has="'ncrTrack:check'"
@click="detil(record)"> @click="detil(record)">
{{ $t('See') }} {{ $t('See') }}
</a> </a>
<a class="text-operation" v-if="record.flag == 'NEW' && record.createBy == userInfo().username" v-has="'ncrTrack:edit'" <a class="text-operation" v-if="record.flag == 'NEW' && record.createBy == userInfo().username"
v-has="'ncrTrack:edit'"
@click="edit(record)"> @click="edit(record)">
{{ $t('edit') }} {{ $t('edit') }}
</a> </a>
<a class="text-operation" v-if="record.flag == 'NEW' && (record.administrator == 'true' || record.createBy == userInfo().username)" v-has="'ncrTrack:delete'" <a class="text-operation"
v-if="record.flag == 'NEW' && (record.administrator == 'true' || record.createBy == userInfo().username)"
v-has="'ncrTrack:delete'"
@click="deleteLib(record)"> @click="deleteLib(record)">
{{ $t('deleteLib') }} {{ $t('deleteLib') }}
</a> </a>
@@ -203,17 +207,17 @@
</template> </template>
<script> <script>
import { getAction, postAction, downloadFile, deleteAction ,downloadFilePost} from '@/api/manage' import { getAction, postAction, downloadFile, deleteAction, downloadFilePost } from '@/api/manage'
import PersonnelSelection from '@/components/PersonnelSelection/index' import PersonnelSelection from '@/components/PersonnelSelection/index'
import designCompliance from '../../toDoCenter/projectRegulationTasks/components/designCompliance' import designCompliance from '../../toDoCenter/projectRegulationTasks/components/designCompliance'
import store from '@/store/' import store from '@/store/'
import addModel from './addModelconformance' import addModel from '../../projectManagement/projectNonConformance/moudles/addModel'
import moment from 'moment' import moment from 'moment'
import detilModel from './detilModel' import detilModel from '../../projectManagement/projectNonConformance/moudles/detilModel'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header' import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
import { mapGetters } from 'vuex' import { mapGetters } from 'vuex'
export default { export default {
name: 'projectNonConformance', name: 'projectNonConformance',
components: { components: {
PersonnelSelection, PersonnelSelection,
@@ -221,7 +225,8 @@ export default {
detilModel, detilModel,
designCompliance designCompliance
}, },
mixins:[ResizeHeader, ResizeColumnProvide], props: ['queryForm'],
mixins: [ResizeHeader, ResizeColumnProvide],
data() { data() {
return { return {
queryParam: {}, queryParam: {},
@@ -229,8 +234,8 @@ export default {
dataSource: [], dataSource: [],
selectedRowKeys: [], selectedRowKeys: [],
projectNameList: [], projectNameList: [],
firstLevelDutyTerritoryList:[], firstLevelDutyTerritoryList: [],
ProblemstateList:[this.$t('red'),this.$t('yellow'),this.$t('green'),], ProblemstateList: [this.$t('red'), this.$t('yellow'), this.$t('green')],
// CertificationColor: { // CertificationColor: {
// $t('red'): 'nonConformityColor', // $t('red'): 'nonConformityColor',
// $t('green'): 'accordColor', // $t('green'): 'accordColor',
@@ -243,7 +248,7 @@ export default {
align: 'left', align: 'left',
dataIndex: 'title', dataIndex: 'title',
width: 170, width: 170,
sorter:true, sorter: true,
ellipsis: true ellipsis: true
}, },
{ {
@@ -251,7 +256,7 @@ export default {
align: 'left', align: 'left',
dataIndex: 'lawsName', dataIndex: 'lawsName',
width: 170, width: 170,
sorter:true, sorter: true,
ellipsis: true ellipsis: true
}, },
{ {
@@ -259,7 +264,7 @@ export default {
align: 'left', align: 'left',
dataIndex: 'projectName', dataIndex: 'projectName',
width: 170, width: 170,
sorter:true, sorter: true,
ellipsis: true ellipsis: true
}, },
{ {
@@ -267,7 +272,7 @@ export default {
align: 'left', align: 'left',
dataIndex: 'problemType_dictText', dataIndex: 'problemType_dictText',
width: 170, width: 170,
sorter:true, sorter: true,
ellipsis: true, ellipsis: true,
scopedSlots: { customRender: 'problemType' } scopedSlots: { customRender: 'problemType' }
}, },
@@ -276,7 +281,7 @@ export default {
align: 'left', align: 'left',
dataIndex: 'dutyTerritory', dataIndex: 'dutyTerritory',
width: 100, width: 100,
sorter:true, sorter: true,
ellipsis: true ellipsis: true
}, },
{ {
@@ -284,7 +289,7 @@ export default {
align: 'left', align: 'left',
dataIndex: 'createBy', dataIndex: 'createBy',
width: 100, width: 100,
sorter:true, sorter: true,
ellipsis: true ellipsis: true
}, },
{ {
@@ -292,7 +297,7 @@ export default {
align: 'left', align: 'left',
dataIndex: 'problemState', dataIndex: 'problemState',
width: 120, width: 120,
sorter:true, sorter: true,
ellipsis: true, ellipsis: true,
scopedSlots: { customRender: 'CertificationProgress' } scopedSlots: { customRender: 'CertificationProgress' }
}, },
@@ -300,14 +305,14 @@ export default {
title: this.$t('createTime'), title: this.$t('createTime'),
align: 'left', align: 'left',
dataIndex: 'createTime', dataIndex: 'createTime',
sorter:true, sorter: true,
width: 180 width: 180
}, },
{ {
title: this.$t('updateTime'), title: this.$t('updateTime'),
align: 'left', align: 'left',
dataIndex: 'updateTime', dataIndex: 'updateTime',
sorter:true, sorter: true,
width: 180 width: 180
}, },
{ {
@@ -324,12 +329,14 @@ export default {
orderBy: '1', orderBy: '1',
orderByField: '', orderByField: '',
long: '', long: '',
isPersonnelSelection:true, isPersonnelSelection: true,
url: { url: {
page: '/project/projectLawsInventoryEO/queryNotComplianList', page: '/project/projectLawsInventoryEO/queryNotComplianList',
exportData: '/project/projectLawsInventoryEO/exportNotComplianList' exportData: '/project/projectLawsInventoryEO/exportNotComplianList'
}, },
content: [] content: [],
numberPlatform: '',
carPlatform: ''
} }
}, },
created() { created() {
@@ -339,7 +346,7 @@ export default {
}, },
mounted() { mounted() {
this.long = localStorage.getItem('language') || 'zh-cn' this.long = localStorage.getItem('language') || 'zh-cn'
this.getList() // this.getList()
this.getNameList() this.getNameList()
this.getFirstLevelDutyTerritory() this.getFirstLevelDutyTerritory()
}, },
@@ -357,6 +364,11 @@ export default {
}, },
methods: { methods: {
...mapGetters(['userInfo']), ...mapGetters(['userInfo']),
getData(data) {
this.carPlatform = data.vehiclePlatform
this.numberPlatform = data.digitalPlatform
this.getList()
},
getFirstLevelDutyTerritory() { getFirstLevelDutyTerritory() {
getAction('/sys/dictItem/getFirstLevelDutyTerritory', {}).then((res) => { getAction('/sys/dictItem/getFirstLevelDutyTerritory', {}).then((res) => {
if (res.success) { if (res.success) {
@@ -382,7 +394,7 @@ export default {
this.pageNo = 1 this.pageNo = 1
this.getList() this.getList()
}, },
addModelForm(){ addModelForm() {
this.getList() this.getList()
}, },
onSelectChange(value) { onSelectChange(value) {
@@ -403,7 +415,7 @@ export default {
}, },
searchReset() { searchReset() {
this.isPersonnelSelection = false this.isPersonnelSelection = false
this.$nextTick(()=>{ this.$nextTick(() => {
this.isPersonnelSelection = true this.isPersonnelSelection = true
}) })
this.pageNo = 1 this.pageNo = 1
@@ -424,12 +436,12 @@ export default {
this.orderByField = sorter.columnKey this.orderByField = sorter.columnKey
this.getList() this.getList()
}, },
onChange(value){ onChange(value) {
console.log(value) console.log(value)
this.queryParam.problemType_dictText = value this.queryParam.problemType_dictText = value
}, },
getList() { getList() {
if(this.queryParam.problemType_dictText){ if (this.queryParam.problemType_dictText) {
delete this.queryParam.problemType delete this.queryParam.problemType
} }
let query = { let query = {
@@ -438,7 +450,9 @@ export default {
orderBy: this.orderBy, orderBy: this.orderBy,
orderByField: this.orderByField, orderByField: this.orderByField,
projectLibraryId: this.$route.query.id, projectLibraryId: this.$route.query.id,
projectName:this.$route.query.projectName, projectName: this.$route.query.projectName,
carPlatform: this.carPlatform,
numberPlatform: this.numberPlatform,
...this.queryParam ...this.queryParam
} }
this.loading = true this.loading = true
@@ -458,20 +472,20 @@ export default {
} }
}) })
}, },
handleAdd(){ handleAdd() {
this.$refs.addModelRef.add() this.$refs.addModelRef.add()
}, },
edit(record){ edit(record) {
this.$refs.addModelRef.edit(JSON.parse(JSON.stringify(record))) this.$refs.addModelRef.edit(JSON.parse(JSON.stringify(record)))
}, },
detil(record){ detil(record) {
if(record.flag == 'NEW'){ if (record.flag == 'NEW') {
this.$refs.detilModelRef.edit(JSON.parse(JSON.stringify(record))) this.$refs.detilModelRef.edit(JSON.parse(JSON.stringify(record)))
}else{ } else {
this.designFlowStatusClick(record) this.designFlowStatusClick(record)
} }
}, },
deleteLib(record){ deleteLib(record) {
let _this = this let _this = this
this.$confirm({ this.$confirm({
content: _this.$t('ConfirmDelete'), content: _this.$t('ConfirmDelete'),
@@ -492,7 +506,7 @@ export default {
...this.queryParam, ...this.queryParam,
ncrTrackVOList: this.content, ncrTrackVOList: this.content,
projectLibraryId: this.$route.query.id, projectLibraryId: this.$route.query.id,
projectName:this.$route.query.projectName, projectName: this.$route.query.projectName
} }
let date = moment(new Date()).format('YYYY-MM-DD') let date = moment(new Date()).format('YYYY-MM-DD')
downloadFilePost(this.url.exportData, this.$t('Problemanagement') + date + '.zip', query, this.Deselect) downloadFilePost(this.url.exportData, this.$t('Problemanagement') + date + '.zip', query, this.Deselect)
@@ -513,7 +527,7 @@ export default {
if (row.flowType == '2') { if (row.flowType == '2') {
if (row.flowStatus == 'Task to be confirmed' || row.flowStatus == 'Duty Person Rejected') { if (row.flowStatus == 'Task to be confirmed' || row.flowStatus == 'Duty Person Rejected') {
TaskKey = 'zrrqr' TaskKey = 'zrrqr'
} else if (row.flowStatus == 'Results to be submitted' || row.flowStatus == 'Non-Compliance' ||row.flowStatus == 'To be tracked') { } else if (row.flowStatus == 'Results to be submitted' || row.flowStatus == 'Non-Compliance' || row.flowStatus == 'To be tracked') {
TaskKey = 'zrrtjjfw' TaskKey = 'zrrtjjfw'
} else if (row.flowStatus == 'Results to be reviewed' || } else if (row.flowStatus == 'Results to be reviewed' ||
row.flowStatus == 'Compliance' || row.flowStatus == 'Compliance' ||
@@ -532,12 +546,12 @@ export default {
typeOfDeliverables: 'designDeliverableTypeName', typeOfDeliverables: 'designDeliverableTypeName',
deliverableTemplate: 'designDeliverableTemplate', deliverableTemplate: 'designDeliverableTemplate',
DueDate: 'designDueDate', DueDate: 'designDueDate',
remarks: 'designRemark', remarks: 'designRemark'
} }
} else if(row.flowType == '4'){ } else if (row.flowType == '4') {
if (row.flowStatus == 'Task to be confirmed' || row.flowStatus == 'Duty Person Rejected') { if (row.flowStatus == 'Task to be confirmed' || row.flowStatus == 'Duty Person Rejected') {
TaskKey = 'zrrqr' TaskKey = 'zrrqr'
} else if (row.flowStatus == 'Results to be submitted' || row.flowStatus == 'Non-Compliance' ||row.flowStatus == 'To be tracked') { } else if (row.flowStatus == 'Results to be submitted' || row.flowStatus == 'Non-Compliance' || row.flowStatus == 'To be tracked') {
TaskKey = 'zrrtjjfw' TaskKey = 'zrrtjjfw'
} else if (row.flowStatus == 'Results to be reviewed' || } else if (row.flowStatus == 'Results to be reviewed' ||
row.flowStatus == 'Compliance' || row.flowStatus == 'Compliance' ||
@@ -556,7 +570,7 @@ export default {
typeOfDeliverables: 'verifyDeliverableTypeName', typeOfDeliverables: 'verifyDeliverableTypeName',
deliverableTemplate: 'verifyDeliverableTemplate', deliverableTemplate: 'verifyDeliverableTemplate',
DueDate: 'verifyDueDate', DueDate: 'verifyDueDate',
remarks: 'verifyRemark', remarks: 'verifyRemark'
} }
} }
this.$refs.designComplianceRef.getList(JSON.parse(JSON.stringify(query)), row.flowTypeName) this.$refs.designComplianceRef.getList(JSON.parse(JSON.stringify(query)), row.flowTypeName)
@@ -611,19 +625,19 @@ export default {
window.open(newUrl.href, '_blank') window.open(newUrl.href, '_blank')
} }
} }
} }
</script> </script>
<style scoped> <style scoped>
@import '~@assets/less/common.less'; @import '~@assets/less/common.less';
.box-title-text { .box-title-text {
line-height: 1.4; line-height: 1.4;
display: flex; display: flex;
align-items: center; align-items: center;
margin-bottom: 10px; margin-bottom: 10px;
} }
.title-text { .title-text {
width: 110px; width: 110px;
color: #000F16; color: #000F16;
display: inline-block; display: inline-block;
@@ -635,25 +649,26 @@ export default {
white-space: nowrap; white-space: nowrap;
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
} }
.box-input { .box-input {
display: inline-block; display: inline-block;
width: 70%; width: 70%;
height: 38px; height: 38px;
margin-top: 2px; margin-top: 2px;
} }
.box-button { .box-button {
height: 38px; height: 38px;
/*margin-top: 2px;*/ /*margin-top: 2px;*/
} }
.page { .page {
text-align: right; text-align: right;
margin-top: 20px; margin-top: 20px;
} }
.box-content-Progress {
.box-content-Progress {
width: 78px; width: 78px;
height: 32px; height: 32px;
display: inline-block; display: inline-block;
@@ -662,32 +677,34 @@ export default {
border-radius: 4px; border-radius: 4px;
background: #f1f3f5; background: #f1f3f5;
color: #919399; color: #919399;
} }
.accordColor {
.accordColor {
background: #dbf6e2; background: #dbf6e2;
color: #26BD4B; color: #26BD4B;
} }
.nonConformityColor { .nonConformityColor {
background: #f3dddd; background: #f3dddd;
color: #E83030; color: #E83030;
} }
.TrackedColor { .TrackedColor {
background: #f6ebdb; background: #f6ebdb;
color: #FDA71C; color: #FDA71C;
} }
.notInvolvedColor { .notInvolvedColor {
background: #eef1f4; background: #eef1f4;
color: #707486; color: #707486;
} }
.submittedColor { .submittedColor {
color: #00B3BE; color: #00B3BE;
background: #ddf3f4; background: #ddf3f4;
} }
.textName {
.textName {
width: 100%; width: 100%;
overflow: hidden; overflow: hidden;
display: -webkit-box; display: -webkit-box;
@@ -698,5 +715,5 @@ export default {
/*! autoprefixer: on;*/ /*! autoprefixer: on;*/
text-justify: inter-ideograph; text-justify: inter-ideograph;
word-break: break-all word-break: break-all
} }
</style> </style>
@@ -29,7 +29,8 @@
<otastatus @currentStatus="currentStatus" :idList="idList" v-if="activeKey == $t('otastatus')"/> <otastatus @currentStatus="currentStatus" :idList="idList" v-if="activeKey == $t('otastatus')"/>
</a-tab-pane> </a-tab-pane>
<a-tab-pane :key="$t('Problemanagement')" :tab="$t('Problemanagement')"> <a-tab-pane :key="$t('Problemanagement')" :tab="$t('Problemanagement')">
<nonConformance @currentStatus="currentStatus" v-if="activeKey == $t('Problemanagement')"/> <nonConformance ref="nonConformanceRef" @currentStatus="currentStatus"
v-if="activeKey == $t('Problemanagement')"/>
</a-tab-pane> </a-tab-pane>
</a-tabs> </a-tabs>
</a-card> </a-card>
@@ -56,12 +57,25 @@
return { return {
activeKey: this.$t('regulatoryComplianceManagement'), activeKey: this.$t('regulatoryComplianceManagement'),
selectedRowKeys: [], selectedRowKeys: [],
idList: [] idList: [],
queryForm: {}
} }
}, },
methods: { methods: {
getData(data) {
this.queryForm = data
this.queryForm = { ...this.queryForm }
if (this.$refs.nonConformanceRef) {
this.$refs.nonConformanceRef.getData(this.queryForm)
}
},
activeKeyChange() { activeKeyChange() {
this.$emit('projectStatusForm', this.activeKey) this.$emit('projectStatusForm', this.activeKey)
if (this.activeKey == this.$t('Problemanagement')) {
this.$nextTick(() => {
this.$refs.nonConformanceRef.getData(this.queryForm)
})
}
}, },
currentStatus(item) { currentStatus(item) {
this.$emit('currentStatus', item) this.$emit('currentStatus', item)
@@ -89,10 +89,50 @@
</div> </div>
<a-form-model-item class="itemModel" prop="contentTemplate"> <a-form-model-item class="itemModel" prop="contentTemplate">
<a-select allowClear <a-select allowClear
class="box-input"
v-model="formInline.projectType"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
showSearch
@change="platformChange"
:style="formInline.projectType == 'none' ? 'width:100%' : 'width:50%'"
optionFilterProp="label"
:autoClearSearchValue="false"
:placeholder="$t('PleaseSelect')+$t('type')">
<a-select-option v-for="(item, key) in platformList"
:key="key"
:label="item.name"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name ">
{{ item.name}}
</span>
</a-select-option>
</a-select>
<a-select allowClear
v-if="formInline.projectType == 'numberPlatform' || formInline.projectType == 'carPlatform'"
class="box-input" class="box-input"
v-model="formInline.projectId" v-model="formInline.projectId"
:getPopupContainer="triggerNode=> triggerNode.parentNode" :getPopupContainer="triggerNode=> triggerNode.parentNode"
showSearch showSearch
style="width: 50%;float: right"
optionFilterProp="label"
:autoClearSearchValue="false"
:placeholder="$t('PleaseSelect')+$t('RelatedItems')">
<a-select-option v-for="(item, key) in relatedItemsList"
:key="key"
:label="item"
:value="item">
<span style="display: inline-block;width: 100%" :title="item ">
{{item}}
</span>
</a-select-option>
</a-select>
<a-select allowClear
class="box-input"
v-else-if="formInline.projectType == 'model'"
v-model="formInline.projectId"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
showSearch
style="width: 50%;float: right"
mode="multiple" mode="multiple"
optionFilterProp="label" optionFilterProp="label"
:autoClearSearchValue="false" :autoClearSearchValue="false"
@@ -271,16 +311,16 @@
v-for="(item,index) in formInline.progressTrackingList" :key="index"> v-for="(item,index) in formInline.progressTrackingList" :key="index">
<!-- <span>{{item}}</span>--> <!-- <span>{{item}}</span>-->
<div style="width: calc(100% - 116px);display: inline-block"> <div style="width: calc(100% - 116px);display: inline-block">
<!-- <quill-editor--> <!-- <quill-editor-->
<!-- class="text-editor trackingClass"--> <!-- class="text-editor trackingClass"-->
<!-- ref="myQuillEditorRef"--> <!-- ref="myQuillEditorRef"-->
<!-- :disabled="true"--> <!-- :disabled="true"-->
<!-- v-if="!item.isDescription"--> <!-- v-if="!item.isDescription"-->
<!-- v-model="item.progressTracking"--> <!-- v-model="item.progressTracking"-->
<!-- :content="item.progressTracking"--> <!-- :content="item.progressTracking"-->
<!-- style="width: 100%;height: 200px;display: inline-block"--> <!-- style="width: 100%;height: 200px;display: inline-block"-->
<!-- :options="editorOption"--> <!-- :options="editorOption"-->
<!-- />--> <!-- />-->
<div class="text-box" v-if="!item.isDescription" v-html="item.progressTracking"></div> <div class="text-box" v-if="!item.isDescription" v-html="item.progressTracking"></div>
<a-input class="box-input" <a-input class="box-input"
v-if="item.isDescription" v-if="item.isDescription"
@@ -479,6 +519,24 @@
}, },
data() { data() {
return { return {
platformList: [
{
name: this.$t('DigitalPlatform'),
value: 'numberPlatform'
},
{
name: this.$t('ModelPlatform'),
value: 'carPlatform'
},
{
name: this.$t('Model'),
value: 'model'
},
{
name: this.$t('nothing'),
value: 'none'
}
],
editorOption: { // 富文本框配置 editorOption: { // 富文本框配置
placeholder: '', placeholder: '',
theme: 'snow', // or 'bubble' theme: 'snow', // or 'bubble'
@@ -545,7 +603,7 @@
formInline: { formInline: {
fileLinkList: [{}], fileLinkList: [{}],
progressTrackingList: [{ progressTrackingList: [{
isDescription:true, isDescription: true
}], }],
approvalEvidenceLinkList: [{}], approvalEvidenceLinkList: [{}],
dutyTerritory: undefined, dutyTerritory: undefined,
@@ -561,6 +619,7 @@
chapterContentsList: [], chapterContentsList: [],
firstLevelDutyTerritoryList: [], firstLevelDutyTerritoryList: [],
projectNameList: [], projectNameList: [],
relatedItemsList: [],
ProblemstateList: [this.$t('red'), this.$t('yellow'), this.$t('green')], ProblemstateList: [this.$t('red'), this.$t('yellow'), this.$t('green')],
templateDisabled: false, templateDisabled: false,
contentTemplateList: [ contentTemplateList: [
@@ -641,7 +700,7 @@
this.problemState = this.$t('emptyc') this.problemState = this.$t('emptyc')
} }
let time = moment(new Date()).format('YYYY-MM-DD HH:mm:ss') let time = moment(new Date()).format('YYYY-MM-DD HH:mm:ss')
let text = '<p class="text-class">'+this.userInfo().username + ' ' + time+'</p>' + ' ' + this.$t('Problemstate') + this.$t('by') + '\'' + this.problemState + '\'' + this.$t('Changeto') + '\'' + value + '\'' let text = '<p class="text-class">' + this.userInfo().username + ' ' + time + '</p>' + ' ' + this.$t('Problemstate') + this.$t('by') + '\'' + this.problemState + '\'' + this.$t('Changeto') + '\'' + value + '\''
if (JSON.stringify(this.formInline.progressTrackingList[0]) == '{}' || this.formInline.progressTrackingList[0].progressTracking == '') { if (JSON.stringify(this.formInline.progressTrackingList[0]) == '{}' || this.formInline.progressTrackingList[0].progressTracking == '') {
this.formInline.progressTrackingList.forEach((item, index) => { this.formInline.progressTrackingList.forEach((item, index) => {
item.progressTracking = text item.progressTracking = text
@@ -681,7 +740,7 @@
...mapGetters(['userInfo']), ...mapGetters(['userInfo']),
add() { add() {
this.templateDisabled = false this.templateDisabled = false
this.getNameList() // this.getNameList()
this.getFirstLevelDutyTerritory() this.getFirstLevelDutyTerritory()
this.title = this.$t('newlyAdded') this.title = this.$t('newlyAdded')
this.visible = true this.visible = true
@@ -699,8 +758,17 @@
}) })
}, },
edit(row) { edit(row) {
console.log(row) this.projectNameList = []
if (row.projectType == 'model') {
this.getNameList() this.getNameList()
if (this.formInline.projectId != null) {
this.formInline.projectId = this.formInline.projectId.split(',')
} else {
this.formInline.projectId = undefined
}
} else if (row.projectType == 'numberPlatform' || row.projectType == 'carPlatform') {
this.getPlatform(row.projectType)
}
this.getFirstLevelDutyTerritory() this.getFirstLevelDutyTerritory()
this.title = this.$t('edit') this.title = this.$t('edit')
this.problemState = row.problemState this.problemState = row.problemState
@@ -722,11 +790,6 @@
if (this.formInline.fileLinkList == null) { if (this.formInline.fileLinkList == null) {
this.formInline.fileLinkList = [{}] this.formInline.fileLinkList = [{}]
} }
if (this.formInline.projectId != null) {
this.formInline.projectId = this.formInline.projectId.split(',')
} else {
this.formInline.projectId = undefined
}
this.visible = true this.visible = true
this.disabled = false this.disabled = false
this.templateDisabled = true this.templateDisabled = true
@@ -753,7 +816,7 @@
TrackingModelForm(row) { TrackingModelForm(row) {
let time = moment(new Date()).format('YYYY-MM-DD HH:mm:ss') let time = moment(new Date()).format('YYYY-MM-DD HH:mm:ss')
console.log(row) console.log(row)
let text = '<p class="text-class">'+this.userInfo().username + ' ' + time +'</p>' + row let text = '<p class="text-class">' + this.userInfo().username + ' ' + time + '</p>' + row
console.log(text) console.log(text)
this.formInline.progressTrackingList.forEach((item, index) => { this.formInline.progressTrackingList.forEach((item, index) => {
if (!item.progressTracking) { if (!item.progressTracking) {
@@ -807,7 +870,6 @@
}) })
}, },
handleSubmit() { handleSubmit() {
console.log(this.formInline)
this.$refs.ruleForm.validate(valid => { this.$refs.ruleForm.validate(valid => {
if (valid) { if (valid) {
this.confirmLoading = true this.confirmLoading = true
@@ -970,10 +1032,29 @@
putAwayClick() { putAwayClick() {
this.isDescription = !this.isDescription this.isDescription = !this.isDescription
}, },
openClick(item){ openClick(item) {
item.isDescription = !item.isDescription item.isDescription = !item.isDescription
this.formInline = {...this.formInline} this.formInline = { ...this.formInline }
}, },
platformChange(value) {
this.projectNameList = []
this.relatedItemsList = []
if (value == 'model') {
this.formInline.projectId = []
this.getNameList()
} else if (value == 'numberPlatform' || value == 'carPlatform') {
this.formInline.projectId = undefined
this.getPlatform(value)
}else{
this.formInline.projectId = undefined
}
this.formInline = { ...this.formInline }
},
getPlatform(platform) {
getAction('/project/projectLibraryBase/getPlatform', { platform: platform }).then((res) => {
this.relatedItemsList = res || []
})
}
} }
} }
</script> </script>
@@ -985,11 +1066,13 @@
.ant-input-disabled { .ant-input-disabled {
color: rgba(0, 0, 0, 0.65) !important; color: rgba(0, 0, 0, 0.65) !important;
} }
.text-class{
.text-class {
color: rgba(0, 0, 0, 0.65); color: rgba(0, 0, 0, 0.65);
font-weight: bold; font-weight: bold;
} }
p{
p {
margin: 0; margin: 0;
padding: 0; padding: 0;
} }
@@ -1117,7 +1200,8 @@
::v-deep .itemModel-explain .ql-container { ::v-deep .itemModel-explain .ql-container {
height: calc(100% - 100px); height: calc(100% - 100px);
} }
.text-box{
.text-box {
width: 100%; width: 100%;
height: 200px; height: 200px;
display: inline-block; display: inline-block;
@@ -82,14 +82,56 @@
</div> </div>
<a-form-model-item class="itemModel" prop="contentTemplate"> <a-form-model-item class="itemModel" prop="contentTemplate">
<a-select allowClear <a-select allowClear
class="box-input"
v-model="formInline.projectType"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
showSearch
:disabled="true"
:style="formInline.projectType == 'none' ? 'width:100%' : 'width:50%'"
optionFilterProp="label"
:autoClearSearchValue="false"
:placeholder="$t('PleaseSelect')+$t('type')">
<a-select-option v-for="(item, key) in platformList"
:key="key"
:label="item.name"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name ">
{{ item.name}}
</span>
</a-select-option>
</a-select>
<a-select allowClear
v-if="formInline.projectType == 'numberPlatform' || formInline.projectType == 'carPlatform'"
class="box-input" class="box-input"
v-model="formInline.projectId" v-model="formInline.projectId"
:getPopupContainer="triggerNode=> triggerNode.parentNode" :getPopupContainer="triggerNode=> triggerNode.parentNode"
showSearch showSearch
mode="multiple" :disabled="true"
:disabled="disabled" style="width: 50%;float: right"
optionFilterProp="label" optionFilterProp="label"
:autoClearSearchValue="false"> :autoClearSearchValue="false"
:placeholder="$t('PleaseSelect')+$t('RelatedItems')">
<a-select-option v-for="(item, key) in relatedItemsList"
:key="key"
:label="item"
:value="item">
<span style="display: inline-block;width: 100%" :title="item ">
{{item}}
</span>
</a-select-option>
</a-select>
<a-select allowClear
class="box-input"
v-else-if="formInline.projectType == 'model'"
v-model="formInline.projectId"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
showSearch
:disabled="true"
style="width: 50%;float: right"
mode="multiple"
optionFilterProp="label"
:autoClearSearchValue="false"
:placeholder="$t('PleaseSelect')+$t('RelatedItems')">
<a-select-option v-for="(item, key) in projectNameList" <a-select-option v-for="(item, key) in projectNameList"
:key="key" :key="key"
:label="item.projectName" :label="item.projectName"
@@ -302,6 +344,25 @@
} }
] ]
}, },
relatedItemsList:[],
platformList: [
{
name: this.$t('DigitalPlatform'),
value: 'numberPlatform'
},
{
name: this.$t('ModelPlatform'),
value: 'carPlatform'
},
{
name: this.$t('Model'),
value: 'model'
},
{
name: this.$t('nothing'),
value: 'none'
}
],
visible: false, visible: false,
visibletrack: false, visibletrack: false,
rulestracking: { rulestracking: {
@@ -381,7 +442,18 @@
}, },
...mapGetters(['userInfo']), ...mapGetters(['userInfo']),
edit(row) { edit(row) {
this.projectNameList = []
if (row.projectType == 'model') {
this.getNameList() this.getNameList()
if (this.formInline.projectId != null) {
this.formInline.projectId = this.formInline.projectId.split(',')
} else {
this.formInline.projectId = undefined
}
} else if (row.projectType == 'numberPlatform' || row.projectType == 'carPlatform') {
this.getPlatform(row.projectType)
}
// this.getNameList()
this.getFirstLevelDutyTerritory() this.getFirstLevelDutyTerritory()
this.title = this.$t('view') this.title = this.$t('view')
this.formInline = row this.formInline = row
@@ -420,6 +492,11 @@
}, },
handleCancel() { handleCancel() {
this.visible = false this.visible = false
},
getPlatform(platform) {
getAction('/project/projectLibraryBase/getPlatform', { platform: platform }).then((res) => {
this.relatedItemsList = res || []
})
} }
} }
} }