@things-factory/integration-sftp 4.3.24 → 4.3.25

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@things-factory/integration-sftp",
3
- "version": "4.3.24",
3
+ "version": "4.3.25",
4
4
  "main": "dist-server/index.js",
5
5
  "browser": "client/index.js",
6
6
  "things-factory": true,
@@ -32,5 +32,5 @@
32
32
  "aws-sdk": "^2.960.0",
33
33
  "xml-js": "^1.6.11"
34
34
  },
35
- "gitHead": "43ba20d3476c8604e94f6a6b0bd7e84b6ec1bfd8"
35
+ "gitHead": "bdcecd8454d7a76df3c5676a39440d57bc21d5cb"
36
36
  }
@@ -1,13 +1,14 @@
1
- import { BACKUPPATH } from '../../../sftp-const'
1
+ import { BACKUPPATH, SNSUBMITDATAPATH } from '../../../sftp-const'
2
2
 
3
3
  export function createSerialNumber() {
4
4
  return {
5
5
  method: 'post',
6
- path: '{folderPath}/{folderType}/sn/data',
6
+ path: '{folderPath}/{folderType}{snPath}',
7
7
  denormalize(req) {
8
8
  let { releaseGood, inventoryItems, sftp } = req
9
9
  let { folderPath, platform } = sftp
10
10
  const folderType: string = sftp.isDevelopment ? `dev` : `prd`
11
+ const snPath: string = SNSUBMITDATAPATH
11
12
  const backupPath: string = `${BACKUPPATH}${platform}/${folderType}`
12
13
 
13
14
  let responseFilePattern: any = JSON.parse(sftp.responseFilePattern)
@@ -39,7 +40,7 @@ export function createSerialNumber() {
39
40
  }
40
41
 
41
42
  return {
42
- resource: { folderPath, folderType },
43
+ resource: { folderPath, folderType, snPath },
43
44
  payload: { title, content, sftp, backupPath }
44
45
  }
45
46
  },
@@ -1,13 +1,14 @@
1
- import { BACKUPPATH } from '../../../sftp-const'
1
+ import { BACKUPPATH, COMPLETEDATAPATH } from '../../../sftp-const'
2
2
 
3
3
  export function createShipment() {
4
4
  return {
5
5
  method: 'post',
6
- path: '{folderPath}/{folderType}/oc/data',
6
+ path: '{folderPath}/{folderType}{shipmentCompletePath}',
7
7
  denormalize(req) {
8
8
  let { releaseGood, orderInventories, sftp } = req
9
9
  let { folderPath, platform } = sftp
10
10
  const folderType: string = sftp.isDevelopment ? `dev` : `prd`
11
+ const shipmentCompletePath: string = COMPLETEDATAPATH
11
12
  const backupPath: string = `${BACKUPPATH}${platform}/${folderType}`
12
13
 
13
14
  let responseFilePattern: any = JSON.parse(sftp.responseFilePattern)
@@ -75,7 +76,7 @@ export function createShipment() {
75
76
  }
76
77
 
77
78
  return {
78
- resource: { folderPath, folderType },
79
+ resource: { folderPath, folderType, shipmentCompletePath },
79
80
  payload: { title, backupTitle, content, sftp, backupPath }
80
81
  }
81
82
  },