mirror of
https://github.com/szkolny-eu/szkolny-android.git
synced 2024-11-09 19:50:26 -06:00
[Vulcan/Hebe] Add next sync and data removing in grades.
This commit is contained in:
parent
c7d2ac4e3e
commit
2aaf713d58
@ -5,8 +5,10 @@ import pl.szczodrzynski.edziennik.data.api.VULCAN_HEBE_ENDPOINT_GRADES
|
|||||||
import pl.szczodrzynski.edziennik.data.api.edziennik.vulcan.DataVulcan
|
import pl.szczodrzynski.edziennik.data.api.edziennik.vulcan.DataVulcan
|
||||||
import pl.szczodrzynski.edziennik.data.api.edziennik.vulcan.ENDPOINT_VULCAN_HEBE_GRADES
|
import pl.szczodrzynski.edziennik.data.api.edziennik.vulcan.ENDPOINT_VULCAN_HEBE_GRADES
|
||||||
import pl.szczodrzynski.edziennik.data.api.edziennik.vulcan.data.VulcanHebe
|
import pl.szczodrzynski.edziennik.data.api.edziennik.vulcan.data.VulcanHebe
|
||||||
|
import pl.szczodrzynski.edziennik.data.api.models.DataRemoveModel
|
||||||
import pl.szczodrzynski.edziennik.data.db.entity.Grade
|
import pl.szczodrzynski.edziennik.data.db.entity.Grade
|
||||||
import pl.szczodrzynski.edziennik.data.db.entity.Metadata
|
import pl.szczodrzynski.edziennik.data.db.entity.Metadata
|
||||||
|
import pl.szczodrzynski.edziennik.data.db.entity.SYNC_ALWAYS
|
||||||
import java.text.DecimalFormat
|
import java.text.DecimalFormat
|
||||||
import kotlin.math.roundToInt
|
import kotlin.math.roundToInt
|
||||||
|
|
||||||
@ -114,6 +116,11 @@ class VulcanHebeGrades(
|
|||||||
}
|
}
|
||||||
|
|
||||||
onSuccess(ENDPOINT_VULCAN_HEBE_GRADES)
|
onSuccess(ENDPOINT_VULCAN_HEBE_GRADES)
|
||||||
|
data.toRemove.add(
|
||||||
|
DataRemoveModel.Grades.semesterWithType(data.studentSemesterNumber,
|
||||||
|
Grade.TYPE_NORMAL
|
||||||
|
))
|
||||||
|
data.setSyncNext(ENDPOINT_VULCAN_HEBE_GRADES, SYNC_ALWAYS)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user