aboutsummaryrefslogtreecommitdiff
path: root/setup
diff options
context:
space:
mode:
Diffstat (limited to 'setup')
-rw-r--r--setup/default.xml38
-rwxr-xr-xsetup/package.sh2
2 files changed, 37 insertions, 3 deletions
diff --git a/setup/default.xml b/setup/default.xml
index ad23d7bd3..aeb8fbe54 100644
--- a/setup/default.xml
+++ b/setup/default.xml
@@ -206,14 +206,15 @@
</entry>
<entry key='database.insertGeofence'>
- INSERT INTO geofences (name, description, area, attributes)
- VALUES (:name, :description, :area, :attributes)
+ INSERT INTO geofences (name, description, calendarid, area, attributes)
+ VALUES (:name, :description, :calendarid, :area, :attributes)
</entry>
<entry key='database.updateGeofence'>
UPDATE geofences SET
name = :name,
description = :description,
+ calendarid = :calendarid,
area = :area,
attributes = :attributes
WHERE id = :id
@@ -315,6 +316,39 @@
INSERT INTO statistics (captureTime, activeUsers, activeDevices, requests, messagesReceived, messagesStored, attributes)
VALUES (:captureTime, :activeUsers, :activeDevices, :requests, :messagesReceived, :messagesStored, :attributes)
</entry>
+
+ <entry key='database.selectCalendarsAll'>
+ SELECT * FROM calendars
+ </entry>
+
+ <entry key='database.insertCalendar'>
+ INSERT INTO calendars (name, calendarData, attributes)
+ VALUES (:name, :calendarData, :attributes)
+ </entry>
+
+ <entry key='database.updateCalendar'>
+ UPDATE calendars SET
+ name = :name,
+ calendarData = :calendarData,
+ attributes = :attributes
+ WHERE id = :id
+ </entry>
+
+ <entry key='database.deleteCalendar'>
+ DELETE FROM calendars WHERE id = :id
+ </entry>
+
+ <entry key='database.selectCalendarPermissions'>
+ SELECT userId, calendarId FROM user_calendar
+ </entry>
+
+ <entry key='database.linkCalendar'>
+ INSERT INTO user_calendar (userId, calendarId) VALUES (:userId, :calendarId)
+ </entry>
+
+ <entry key='database.unlinkCalendar'>
+ DELETE FROM user_calendar WHERE userId = :userId AND calendarId = :calendarId
+ </entry>
<!-- PROTOCOL CONFIG -->
diff --git a/setup/package.sh b/setup/package.sh
index 404c7b86b..d9276731c 100755
--- a/setup/package.sh
+++ b/setup/package.sh
@@ -142,7 +142,7 @@ fi"
}
package_universal () {
- mkdir -p out/{conf,data,lib,logs,web,schema}
+ mkdir -p out/{conf,data,lib,logs,web,schema,templates}
copy_files