feature/IO-3255-simplified-parts-management - Expand Joblines Parser, remove body-parser reference in favor of express.raw
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
const express = require("express");
|
||||
const router = express.Router();
|
||||
const bodyParser = require("body-parser");
|
||||
|
||||
// Pull secrets from env
|
||||
const { VSSTA_INTEGRATION_SECRET, PARTS_MANAGEMENT_INTEGRATION_SECRET } = process.env;
|
||||
@@ -29,7 +28,7 @@ if (typeof PARTS_MANAGEMENT_INTEGRATION_SECRET === "string" && PARTS_MANAGEMENT_
|
||||
*/
|
||||
router.post(
|
||||
"/parts-management/VehicleDamageEstimateAddRq",
|
||||
bodyParser.raw({ type: "application/xml", limit: XML_BODY_LIMIT }), // Parse XML body
|
||||
express.raw({ type: "application/xml", limit: XML_BODY_LIMIT }), // Parse XML body
|
||||
partsManagementIntegrationMiddleware,
|
||||
partsManagementVehicleDamageEstimateAddRq
|
||||
);
|
||||
@@ -39,7 +38,7 @@ if (typeof PARTS_MANAGEMENT_INTEGRATION_SECRET === "string" && PARTS_MANAGEMENT_
|
||||
*/
|
||||
router.post(
|
||||
"/parts-management/VehicleDamageEstimateChqRq",
|
||||
bodyParser.raw({ type: "application/xml", limit: XML_BODY_LIMIT }), // Parse XML body
|
||||
express.raw({ type: "application/xml", limit: XML_BODY_LIMIT }), // Parse XML body
|
||||
partsManagementIntegrationMiddleware,
|
||||
partsManagementVehicleDamageEstimateChqRq
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user