fix: adiciona JWT_SECRET e ALLOWED_ORIGINS no docker-compose, e corrige enabled=1 para PostgreSQL nas rotas de imagens
continuous-integration/webhook Deploy concluido (rx.scoreodonto.com)
continuous-integration/webhook Deploy concluido (rx.scoreodonto.com)
This commit is contained in:
@@ -139,7 +139,7 @@ router.get('/:id', async (req, res) => {
|
||||
router.get('/stats', async (req, res) => {
|
||||
try {
|
||||
const total = await db.get('SELECT COUNT(*) as count FROM images');
|
||||
const enabled = await db.get('SELECT COUNT(*) as count FROM images WHERE enabled = 1');
|
||||
const enabled = await db.get('SELECT COUNT(*) as count FROM images WHERE enabled = true');
|
||||
const withTooth = await db.get('SELECT COUNT(*) as count FROM images WHERE tooth_number IS NOT NULL');
|
||||
|
||||
res.json({
|
||||
@@ -305,7 +305,7 @@ router.put('/:id/patient-info', async (req, res) => {
|
||||
patient_name_resumed = $1,
|
||||
tooth_number = $2,
|
||||
tooth_side = $3,
|
||||
enabled = 1
|
||||
enabled = true
|
||||
WHERE id = $4`,
|
||||
[patientNameResumed, toothNumber, toothSide, req.params.id]
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user