Answer the question
In order to leave comments, you need to log in
How to show data from an array of objects in a list?
There is a function that receives the policies[] array:
getPolicies() {
let self = this;
HttpService.methods.get('/policies')
.then(function (response) {
self.policies = response.data.data
console.log(self.policies);
})
.catch(function (error) {
console.log(error);
})
}
<div class="dropdown-checkbox form-group">
<label class="label-title"><p>Select</p></label>
<ul>
<li><label><input value="1"
type="checkbox">1</label></li>
<li><label><input value="2"
type="checkbox">2</label></li>
<li><label><input value="3"
type="checkbox">3</label></li>
</ul>
</div>
Answer the question
In order to leave comments, you need to log in
Bind with a model or via v-for - I don’t really understand what exactly should be a list - menus or checkboxes.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question