update
This commit is contained in:
@@ -70,6 +70,19 @@ export async function reworkBaustein(id, instructions) {
|
||||
})
|
||||
}
|
||||
|
||||
export async function sortBausteine(topic, instructions = '') {
|
||||
await fetch(`${BASE}/bausteine/sort?topic=${encodeURIComponent(topic)}`, {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({ instructions }),
|
||||
})
|
||||
}
|
||||
|
||||
export async function fetchSortStatus(topic) {
|
||||
const res = await fetch(`${BASE}/bausteine/sort/status?topic=${encodeURIComponent(topic)}`)
|
||||
return res.json()
|
||||
}
|
||||
|
||||
export async function fetchSuggestions(topic) {
|
||||
const res = await fetch(`${BASE}/bausteine/suggestions?topic=${encodeURIComponent(topic)}`)
|
||||
return res.json()
|
||||
|
||||
Reference in New Issue
Block a user