|
@@ -266,16 +266,34 @@ export default {
|
|
|
return obj;
|
|
|
})
|
|
|
// 这里循环
|
|
|
- // console.log(this.soundList)
|
|
|
- this.soundList.forEach((item, i) => {
|
|
|
- item.subjects.forEach((some, j) => {
|
|
|
- res.data.musicGroupSubjectPlans.forEach((sub, x) => {
|
|
|
- if (sub.subjectId == some.id) {
|
|
|
- item.subjects.splice(j, 1)
|
|
|
+ for (let x = 0; x < this.soundList.length; x++) {
|
|
|
+ // console.log(this.soundList[x])
|
|
|
+ for (let y = 0; y < this.soundList[x].subjects.length; y++) {
|
|
|
+ // console.log(this.soundList[x].subjects[y].id)
|
|
|
+ for (let z = 0; z < this.activeSoundList.length; z++) {
|
|
|
+ // console.log(this.soundList[x].subjects, y)
|
|
|
+ if (this.soundList[x].subjects[y].id == this.activeSoundList[z].id) {
|
|
|
+ this.soundList[x].subjects.splice(y, 1)
|
|
|
+ // this.soundList[x].subjects[y] = null
|
|
|
+ y--
|
|
|
+ if (y < 0) y = 0
|
|
|
}
|
|
|
- })
|
|
|
- })
|
|
|
- })
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ // this.soundList.forEach((item, i) => {
|
|
|
+ // item.subjects.forEach((some, j) => {
|
|
|
+
|
|
|
+ // this.activeSoundList.forEach((sub, x) => {
|
|
|
+ // console.log(some.name + '-' + sub.sound)
|
|
|
+ // console.log(some.id + '-' + sub.id)
|
|
|
+ // if (sub.id == some.id) {
|
|
|
+ // console.log(1)
|
|
|
+ // item.subjects.splice(x, 1)
|
|
|
+ // }
|
|
|
+ // })
|
|
|
+ // })
|
|
|
+ // })
|
|
|
// 循环列表里的声部 拿取商品
|
|
|
for (let i in this.activeSoundList) {
|
|
|
for (let j in res.data.musicGroupSubjectGoodsGroups) {
|