making the event Id field mandatory

This commit is contained in:
tibbi 2018-11-10 15:25:06 +01:00
parent dcdac6b1a1
commit 94abbaebf5
2 changed files with 2 additions and 2 deletions

View file

@ -92,7 +92,7 @@ class EventActivity : SimpleActivity() {
cancelNotification(mEvent.id!!)
} else {
mEvent = Event()
mEvent = Event(null)
config.apply {
mReminder1Minutes = if (usePreviousEventReminders) lastEventReminderMinutes1 else defaultReminder1
mReminder2Minutes = if (usePreviousEventReminders) lastEventReminderMinutes2 else defaultReminder2

View file

@ -7,7 +7,7 @@ import org.joda.time.DateTime
import java.io.Serializable
import java.util.*
data class Event(var id: Int? = 0, var startTS: Int = 0, var endTS: Int = 0, var title: String = "", var description: String = "",
data class Event(var id: Int?, var startTS: Int = 0, var endTS: Int = 0, var title: String = "", var description: String = "",
var reminder1Minutes: Int = -1, var reminder2Minutes: Int = -1, var reminder3Minutes: Int = -1, var repeatInterval: Int = 0,
var importId: String = "", var flags: Int = 0, var repeatLimit: Int = 0, var repeatRule: Int = 0,
var eventType: Long = DBHelper.REGULAR_EVENT_TYPE_ID, var ignoreEventOccurrences: ArrayList<Int> = ArrayList(),