|
@@ -44,7 +44,7 @@
|
|
|
<div class="pb_content_body">
|
|
|
<div class="student_table" v-loading="loading">
|
|
|
<div class="source-box" v-for="(item, index) in res" :key="index">
|
|
|
- <img class="checkImg" src="../../../assets/icon/source/checka.png" @click="checka(item)" v-if="json[item.id]"/>
|
|
|
+ <img class="checkImg" src="../../../assets/icon/source/checka.png" @click="checka(item)" v-if="sourceData[item.id]"/>
|
|
|
<img class="checkImg" src="../../../assets/icon/source/check.png" @click="checka(item)" v-else/>
|
|
|
<div class="iamge"><img src="../../../assets/icon/source/image.png" alt=""></div>
|
|
|
<div class="title"><span>{{ item.name }}</span></div>
|
|
@@ -114,6 +114,11 @@
|
|
|
|
|
|
<script>
|
|
|
export default {
|
|
|
+ props: {
|
|
|
+ sourceData: {
|
|
|
+ type: Object,
|
|
|
+ },
|
|
|
+ },
|
|
|
data() {
|
|
|
return {
|
|
|
page: 1,
|
|
@@ -141,7 +146,7 @@ export default {
|
|
|
s_url: "",
|
|
|
s_detail: "",
|
|
|
s_label: [],
|
|
|
- json:{}
|
|
|
+ sourceData:{}
|
|
|
};
|
|
|
},
|
|
|
mounted() {
|
|
@@ -149,13 +154,13 @@ export default {
|
|
|
},
|
|
|
methods: {
|
|
|
checka(item){
|
|
|
- if(this.json[item.id]){
|
|
|
- delete this.json[item.id]
|
|
|
+ if(this.sourceData[item.id]){
|
|
|
+ delete this.sourceData[item.id]
|
|
|
}else{
|
|
|
- this.json[item.id] = item
|
|
|
+ this.sourceData[item.id] = item
|
|
|
}
|
|
|
this.$forceUpdate()
|
|
|
- this.$emit("update",this.json)
|
|
|
+ this.$emit("update:sourceData",this.sourceData)
|
|
|
},
|
|
|
check(url){
|
|
|
window.open(url)
|