Import External SMR Codes file
Some customers utilize back-office solutions that rely on external job codes. So in order to prevent the invoices from being rejected it is essential to include these external codes in the invoice details sent from ViSN.
Fields
Field Name | Description | Data type | Validation | Max length | Mandatory | Example |
---|---|---|---|---|---|---|
Job Code | ViSN/ Haynes Pro codes | String | A-Z a-z & 0-9 | 20 | Yes | 1A00039950WV0 |
External Code | External codes | Number | 0-9 | 5 | Yes | 65 |
Importing a file
Preparation
Create a new branch with Jira task number in the branch name
Delete all the files in importFiles folder
Create a folder with the current sprint number
Copy the file that needs to be imported
Go to
package.json
, find the linevalidate:externalSMRCodes
Modify
--file
with the relative path of the fileSave package.json
Validating locally
In a terminal run
npm run validate:externalSMRCodes
If there are no errors, push the code
Validating in workflow
Go to Action of Import-manger
Find
<Environment> - on-demand-import
Select the branch that was created for this import
Enter script name as
validate:externalSMRCodes
Leave Overrides empty
Importing the file
If the validation has passed
Go to Action of Import-manger
Find
<Environment> - on-demand-import
Select the branch that was created for this import
Enter script name as
import:externalSMRCodes
Enter
--persist
in Overrides field
Testing
The glass job descriptions will be stored in Firestore, under
/config/lookUp/externalSMRCodes/
.The imported smr codes for the job descriptions should be exported into the daily invoice export csv.
Status: Accepted
Category: Protected
Authored By: Rama on Dec 06, 2024