fix(fe smartblock): fixed showing smart block criteria on edit
This commit is contained in:
parent
5daec331f8
commit
c2b1ebee80
2 changed files with 60 additions and 15 deletions
|
@ -65,5 +65,19 @@ export function blocks_page() {
|
|||
})
|
||||
}
|
||||
|
||||
return { items, listData, headers, selected, loading, search, getItems, editItem, deleteItem }
|
||||
const getTracklist = async (item) => {
|
||||
let params = null;
|
||||
if (item.id === 0) {
|
||||
params = item
|
||||
}
|
||||
return await axios.get(`/smartblock/${item.id}/tracks`, {
|
||||
params: params
|
||||
}).then((response) => {
|
||||
return response.data
|
||||
}).catch((error) => {
|
||||
console.log("Error: "+error);
|
||||
})
|
||||
}
|
||||
|
||||
return { items, listData, headers, selected, loading, search, getItems, editItem, deleteItem, getTracklist }
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue