aboutsummaryrefslogtreecommitdiff
path: root/setup/default.xml
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2017-07-14 21:19:53 +1200
committerGitHub <noreply@github.com>2017-07-14 21:19:53 +1200
commit26f1cf12867d6f8bfe86d562a3beecb590b3a9b5 (patch)
treeef3b8d2644aae5c5263241640ebb2e2b251f7b0c /setup/default.xml
parenta2e1f56adf50746425565557dd38f0e2c81a0222 (diff)
parentb6a318daabbaf485e327cab77adba98413462516 (diff)
downloadtrackermap-server-26f1cf12867d6f8bfe86d562a3beecb590b3a9b5.tar.gz
trackermap-server-26f1cf12867d6f8bfe86d562a3beecb590b3a9b5.tar.bz2
trackermap-server-26f1cf12867d6f8bfe86d562a3beecb590b3a9b5.zip
Merge pull request #3349 from Abyss777/drivers
Drivers implementation
Diffstat (limited to 'setup/default.xml')
-rw-r--r--setup/default.xml57
1 files changed, 57 insertions, 0 deletions
diff --git a/setup/default.xml b/setup/default.xml
index 2fc6c3cf0..04530104a 100644
--- a/setup/default.xml
+++ b/setup/default.xml
@@ -431,6 +431,63 @@
DELETE FROM device_attribute WHERE deviceId = :deviceId AND attributeId = :attributeId
</entry>
+ <entry key='database.selectDrivers'>
+ SELECT * FROM drivers
+ </entry>
+
+ <entry key='database.insertDriver'>
+ INSERT INTO drivers (name, uniqueId, attributes)
+ VALUES (:name, :uniqueId, :attributes)
+ </entry>
+
+ <entry key='database.updateDriver'>
+ UPDATE drivers SET
+ name = :name,
+ uniqueId = :uniqueId,
+ attributes = :attributes
+ WHERE id = :id
+ </entry>
+
+ <entry key='database.deleteDriver'>
+ DELETE FROM drivers WHERE id = :id
+ </entry>
+
+ <entry key='database.selectDriverPermissions'>
+ SELECT userId, driverId FROM user_driver
+ </entry>
+
+ <entry key='database.linkDriver'>
+ INSERT INTO user_driver (userId, driverId) VALUES (:userId, :driverId)
+ </entry>
+
+ <entry key='database.unlinkDriver'>
+ DELETE FROM user_driver WHERE userId = :userId AND driverId = :driverId
+ </entry>
+
+ <entry key='database.selectGroupDrivers'>
+ SELECT groupId, driverId FROM group_driver
+ </entry>
+
+ <entry key='database.linkGroupDriver'>
+ INSERT INTO group_driver (groupId, driverId) VALUES (:groupId, :driverId)
+ </entry>
+
+ <entry key='database.unlinkGroupDriver'>
+ DELETE FROM group_driver WHERE groupId = :groupId AND driverId = :driverId
+ </entry>
+
+ <entry key='database.selectDeviceDrivers'>
+ SELECT deviceId, driverId FROM device_driver
+ </entry>
+
+ <entry key='database.linkDeviceDriver'>
+ INSERT INTO device_driver (deviceId, driverId) VALUES (:deviceId, :driverId)
+ </entry>
+
+ <entry key='database.unlinkDeviceDriver'>
+ DELETE FROM device_driver WHERE deviceId = :deviceId AND driverId = :driverId
+ </entry>
+
<!-- PROTOCOL CONFIG -->
<entry key='gps103.port'>5001</entry>