|
@@ -548,9 +548,14 @@ export default {
|
|
const find = (arr) => {
|
|
const find = (arr) => {
|
|
arr.forEach(elm => {
|
|
arr.forEach(elm => {
|
|
if (elm.title === '线上问题') {
|
|
if (elm.title === '线上问题') {
|
|
- // console.log(532, elm, rowData)
|
|
|
|
- // console.log(elm.content[0].tableRows, rowData)
|
|
|
|
- elm.content[0].tableRows.push(rowData[0])
|
|
|
|
|
|
+ const newQuestion = rowData[0].tableItems[1].value
|
|
|
|
+ const isQuestion = elm.content[0].tableRows.map(elm => elm.tableItems[1]).filter(
|
|
|
|
+ elm => elm.value === newQuestion
|
|
|
|
+ )
|
|
|
|
+ // 判断数据是否冲突
|
|
|
|
+ if (!isQuestion.length) {
|
|
|
|
+ elm.content[0].tableRows.push(rowData[0])
|
|
|
|
+ }
|
|
}
|
|
}
|
|
if (elm.children && elm.children.length) {
|
|
if (elm.children && elm.children.length) {
|
|
find(elm.children)
|
|
find(elm.children)
|