Test auto deploy and VPN

This commit is contained in:
=bhagwanSingh 2025-12-02 12:32:00 +05:30
parent a7d770498c
commit c04264f054
4 changed files with 56 additions and 55 deletions

View File

@ -6,7 +6,7 @@
"scripts": { "scripts": {
"start": "nodemon --inspect src/server.js", "start": "nodemon --inspect src/server.js",
"test": "echo \"Error: no test specified\" && exit 1", "test": "echo \"Error: no test specified\" && exit 1",
"deploy": "curl -X POST http://16.170.168.132:9000/hooks/deploy-va-middleware", "deploy": "curl -X POST http://35.162.222.18:9000/hooks/deploy-va-middleware",
"build": "npx webpack --mode production", "build": "npx webpack --mode production",
"dev": "npx webpack --mode development" "dev": "npx webpack --mode development"
}, },

View File

@ -147,12 +147,13 @@ async function va_leave_apply_function(req, res) {
await leaveRequest.save(); await leaveRequest.save();
try { try {
const salesforceUrl = `${process.env.SF_DOCTRACKER_API_URL}services/apexrest/docva/api/timesheet-adjustment`; const salesforceUrl = `${process.env.SF_DOCTRACKER_API_URL}services/apexrest/docva/api/leave-request`;
const sfData = { const sfData = {
"id": leaveRequest._id, "leaveId": leaveRequest._id.toString(),
"va": { // "va": {
"id": vaId // "id": vaId
}, // },
"va": vaId.toString(),
"dateFrom": startDate.toISOString().split('T')[0], "dateFrom": startDate.toISOString().split('T')[0],
"dateTo": endDate.toISOString().split('T')[0], "dateTo": endDate.toISOString().split('T')[0],
"totalDays": totalDays, "totalDays": totalDays,

View File

@ -138,12 +138,12 @@ async function va_timesheet_adjustment_function(req, res) {
try { try {
const salesforceUrl = `${process.env.SF_DOCTRACKER_API_URL}services/apexrest/docva/api/timesheet-adjustment`; const salesforceUrl = `${process.env.SF_DOCTRACKER_API_URL}services/apexrest/docva/api/timesheet-adjustment`;
const sfData = { const sfData = {
"id": adjustmentRequest._id, "id": adjustmentRequest._id.toString(),
"va": { "va": {
"id": vaId "id": vaId.toString()
}, },
"project": { "project": {
"id": projectId "id": projectId.toString()
}, },
"date": adjustmentDate.toISOString().split('T')[0], "date": adjustmentDate.toISOString().split('T')[0],
"loginTime": loginDateTime.toISOString(), "loginTime": loginDateTime.toISOString(),

View File

@ -4,7 +4,7 @@
<head> <head>
<meta charset="UTF-8" /> <meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Download DocTracker</title> <title>DocTracker</title>
<style> <style>
body { body {