diff --git a/config/index.js b/config/index.js index 9f058323..c0c85e98 100644 --- a/config/index.js +++ b/config/index.js @@ -11,8 +11,8 @@ const config = { database: process.env.DB_DATABASE || 'discounts' }, core: { - url: 'http://oms-core-elixir', - port: 4000 + url: 'http://oms-core-js', + port: 8084 }, mailer: { url: 'http://oms-mailer', diff --git a/lib/integrations.js b/lib/integrations.js index bdfafea6..c6280715 100644 --- a/lib/integrations.js +++ b/lib/integrations.js @@ -140,8 +140,7 @@ exports.claimCode = async (req, res) => { await codeToClaim.update({ claimed_by: req.user.id }); await mailer.sendMail({ - from: 'oms-mailer@aegee.org', - to: req.user.user.email, + to: req.user.email, subject: `Your ${req.integration.name} discount code`, template: 'custom.html', parameters: { diff --git a/test/assets/oms-core-permissions-full.json b/test/assets/oms-core-permissions-full.json index 83b46aad..45febf58 100644 --- a/test/assets/oms-core-permissions-full.json +++ b/test/assets/oms-core-permissions-full.json @@ -8,7 +8,6 @@ "description": "Manage discounts", "combined": "global:manage:discounts", "circles": null, - "always_assigned": false, "action": "manage" }] } diff --git a/test/assets/oms-core-valid.json b/test/assets/oms-core-valid.json index 451760d4..6a2ce067 100644 --- a/test/assets/oms-core-valid.json +++ b/test/assets/oms-core-valid.json @@ -1,17 +1,13 @@ { "success": true, "data": { - "user_id": 1, - "user": { - "superadmin": true, - "name": "admin", - "member_id": null, - "inserted_at": "2018-05-03T23:12:01.111566", - "id": 1, - "email": "admin@aegee.org", - "active": true - }, - "seo_url": "microservice", + "superadmin": true, + "username": "admin", + "member_id": null, + "inserted_at": "2018-05-03T23:12:01.111566", + "id": 1, + "email": "admin@aegee.org", + "active": true, "primary_body_id": null, "primary_body": null, "phone": "+123456789", @@ -62,7 +58,6 @@ "approved": true } ], - "id": 1, "gender": "machine", "first_name": "Microservice", "date_of_birth": "2010-04-17",