|
@@ -357,7 +357,7 @@
|
|
|
>
|
|
|
<template slot="title">
|
|
|
<span style="color: #fff;">预览</span>
|
|
|
- <el-select v-model="selectPart" placeholder="请选择分谱">
|
|
|
+ <el-select v-model="selectPart" placeholder="请选择分谱" @change="onPartChange">
|
|
|
<el-option
|
|
|
v-for="(item, index) in parts"
|
|
|
:key="item"
|
|
@@ -371,7 +371,7 @@
|
|
|
v-if="lookVisible"
|
|
|
style="width: 667px; height: 386px"
|
|
|
ref="iframe"
|
|
|
- :src="accompanyUrl + '?part-index=' + selectPart + '&isMove=1'"
|
|
|
+ :src="accompanyUrl"
|
|
|
/>
|
|
|
<div class="iframe_back"></div>
|
|
|
<div class="iframe_help"></div>
|
|
@@ -409,6 +409,8 @@ export default {
|
|
|
activeUrl: "",
|
|
|
songUseType,
|
|
|
lookVisible: false,
|
|
|
+ lookNum: 0,
|
|
|
+ lookRow: {},
|
|
|
accompanyUrl: null, // 预览地址
|
|
|
accompanyUrl2: null, // 预览地址
|
|
|
audioVisible: false,
|
|
@@ -570,8 +572,10 @@ export default {
|
|
|
"&platform=web&isOpenMetronome=" +
|
|
|
num +
|
|
|
"#/detail/" +
|
|
|
- row.id;
|
|
|
+ row.id + '?part-index=' + this.selectPart + '&isMove=1';
|
|
|
this.lookVisible = true;
|
|
|
+ this.lookNum = num
|
|
|
+ this.lookRow = row
|
|
|
|
|
|
// this.$nextTick(() => {
|
|
|
// console.log(this.$refs.iframe)
|
|
@@ -582,6 +586,24 @@ export default {
|
|
|
// }
|
|
|
// })
|
|
|
},
|
|
|
+ onPartChange(val) {
|
|
|
+ console.log(val, 'val', this.$refs.iframe)
|
|
|
+ let url = location.origin +
|
|
|
+ "/accompany-web/"
|
|
|
+ if(/dayaedu.com/.test(location.origin)) {
|
|
|
+ url = location.origin +
|
|
|
+ "/accompany/"
|
|
|
+ }
|
|
|
+ // url +
|
|
|
+ this.accompanyUrl =
|
|
|
+ url +
|
|
|
+ "?Authorization=" +
|
|
|
+ getToken() +
|
|
|
+ "&platform=web&isOpenMetronome=" +
|
|
|
+ this.lookNum + '&t=' + new Date().getTime() +
|
|
|
+ "#/detail/" +
|
|
|
+ this.lookRow.id + '?part-index=' + val + '&isMove=1';
|
|
|
+ },
|
|
|
player(row) {
|
|
|
this.activeUrl = row.url;
|
|
|
this.audioVisible = true;
|