Log for db
This commit is contained in:
parent
f18afb4471
commit
d8f93c04c0
|
@ -8,6 +8,8 @@ module.exports.index = function(req, res) {
|
|||
"INSERT INTO arrowclicked(exp_id, arrow_id, time) VALUES($1,$2, to_timestamp($3));",
|
||||
[req.session.exp_id, req.body.arrow_id, req.body.time],
|
||||
function(err, result) {
|
||||
if (err !== null)
|
||||
console.log("[DBERROR] " + err);
|
||||
release();
|
||||
}
|
||||
);
|
||||
|
|
|
@ -8,6 +8,8 @@ module.exports.index = function(req, res) {
|
|||
"INSERT INTO coinclicked(exp_id, coin_id, time) VALUES($1,$2, to_timestamp($3));",
|
||||
[req.session.exp_id, req.body.coin_id, req.body.time],
|
||||
function(err, result) {
|
||||
if (err !== null)
|
||||
console.log("[DBERROR] " + err);
|
||||
release();
|
||||
}
|
||||
);
|
||||
|
|
|
@ -8,6 +8,8 @@ module.exports.index = function(req, res) {
|
|||
"INSERT INTO fpscounter(exp_id, fps) VALUES($1,$2);",
|
||||
[req.session.exp_id, req.body.fps],
|
||||
function(err, result) {
|
||||
if (err !== null)
|
||||
console.log("[DBERROR] " + err);
|
||||
release();
|
||||
}
|
||||
);
|
||||
|
|
|
@ -14,6 +14,8 @@ module.exports.index = function(req, res) {
|
|||
req.body.arrow_id
|
||||
],
|
||||
function(err, result) {
|
||||
if (err !== null)
|
||||
console.log("[DBERROR] " + err);
|
||||
release();
|
||||
}
|
||||
);
|
||||
|
|
|
@ -20,6 +20,8 @@ module.exports.index = function(req, res) {
|
|||
req.body.time
|
||||
],
|
||||
function(err, result) {
|
||||
if (err !== null)
|
||||
console.log("[DBERROR] " + err);
|
||||
release();
|
||||
}
|
||||
);
|
||||
|
|
|
@ -19,6 +19,8 @@ module.exports.index = function(req, res) {
|
|||
req.body.camera.target.z
|
||||
],
|
||||
function(err, result) {
|
||||
if (err !== null)
|
||||
console.log("[DBERROR] " + err);
|
||||
release();
|
||||
}
|
||||
);
|
||||
|
|
|
@ -12,6 +12,8 @@ module.exports.index = function(req, res) {
|
|||
req.body.time
|
||||
],
|
||||
function(err, result) {
|
||||
if (err !== null)
|
||||
console.log("[DBERROR] " + err);
|
||||
release();
|
||||
}
|
||||
);
|
||||
|
|
Loading…
Reference in New Issue