Fix selected nominees name not showing properly
This commit is contained in:
@@ -5,8 +5,13 @@
|
||||
<hr />
|
||||
<ul class="list-group">
|
||||
<li class="list-group-item" v-for="position in data.positions">
|
||||
<b>{{ position.name }} : </b>{{ getName(position.id) }}
|
||||
<b>{{ position.name }} : </b>
|
||||
</li>
|
||||
<ul class="list-group">
|
||||
<li class="list-group-item" v-for="nominee_id in selected[0].nominee_id">
|
||||
<b> - {{ getSelectedNomineeName(nominee_id) }}</b>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<!-- <ul class="list-group">
|
||||
<li class="list-group-item" v-for="result in data.result">
|
||||
@@ -171,9 +176,14 @@ export default {
|
||||
console.log(this.selected[0])
|
||||
},
|
||||
|
||||
getSelectedNomineeName: function(id) {
|
||||
return this.getNominee(id);
|
||||
},
|
||||
|
||||
getName: function (id) {
|
||||
let positions = this.data.positions;
|
||||
let selected = this.selected;
|
||||
|
||||
for (var i in selected)
|
||||
if (selected[i]['position_id'] == id)
|
||||
return this.getNominee(selected[i]['nominee_id']);
|
||||
|
||||
Reference in New Issue
Block a user