Skip to content
Snippets Groups Projects
Commit d48de82a authored by moon's avatar moon
Browse files

#52: Fixed null id for species list

parent ecb6b87e
No related branches found
No related tags found
No related merge requests found
......@@ -27,7 +27,7 @@
v-model="species"
class="form-control input-sm"
>
<option v-for="item in response.data" :key="item.tax_id">
<option v-for="item in removeNullItems(response.data)" :key="item.tax_id">
{{
item._id && item._id !== 0
? `${item._id} (${item.tax_id})`
......@@ -189,6 +189,9 @@ export default {
},
},
methods: {
removeNullItems(data) {
return _.filter(data, (d) => d._id !== null);
},
getSuggestionList() {
const vm = this;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment