Example #1
0
            public static void UpdateNotification(long id, string schedulingId, DateTimeOffset dateTime)
            {
                ISQLiteStatement statement = dbConn.Prepare(UPDATE_NOTIFICATION);

                statement.Bind(1, TimeUtil.ConvertDateTimeOffsetToString(dateTime));
                Debug.WriteLine("Updating notification: data to string " + TimeUtil.ConvertDateTimeOffsetToString(dateTime));
                statement.Bind(2, schedulingId);
                statement.Bind(3, TimeUtil.GetStringTimestamp());
                statement.Bind(4, id);
                statement.Step();
            }
Example #2
0
            public static long AddNotification(string schedulingId, DateTimeOffset dateTime)

            {
                Debug.WriteLine("Adding notificaiton");
                ISQLiteStatement statement = dbConn.Prepare(INSERT_SIMPLE_NOTE_NOTIFICATION);

                statement.Bind(1, TimeUtil.ConvertDateTimeOffsetToString(dateTime));
                statement.Bind(2, schedulingId);
                statement.Bind(3, TimeUtil.GetStringTimestamp());
                Debug.WriteLine(statement.Step());
                Debug.WriteLine("Last inserted notification id: " + GetLastInsertedNotificationId());
                return(GetLastInsertedNotificationId());
            }