Click on "start reading" now removes "want to read"
This commit is contained in:
@@ -64,6 +64,7 @@ function onWantReadIconClick() {
|
||||
async function onStartReadIconClick() {
|
||||
if (!data.value.startReadDate) {
|
||||
data.value.startReadDate = today
|
||||
data.value.wantread = false
|
||||
putStartReadDate(props.id, data.value.startReadDate)
|
||||
} else if (!data.value.read) {
|
||||
data.value.startReadDate = null
|
||||
|
||||
@@ -94,6 +94,7 @@ async function userBookStartRead() {
|
||||
if (resp.ok) {
|
||||
currentStartReadDate.value = today
|
||||
isRead.value = false
|
||||
isWantRead.value = false
|
||||
} else {
|
||||
resp.json().then((json) => (error.value = json))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user