Autohouse year parsing upddate.
This commit is contained in:
@@ -93,6 +93,7 @@ exports.default = async (req, res) => {
|
||||
.end({ allowEmptyTags: true });
|
||||
|
||||
allxmlsToUpload.push({
|
||||
count: autoHouseObject.AutoHouseExport.RepairOrder.length,
|
||||
xml: ret,
|
||||
filename: `IM_${bodyshop.autohouseid}_${moment().format(
|
||||
"DDMMYYYY_HHMMSS"
|
||||
@@ -227,7 +228,11 @@ const CreateRepairOrderTag = (job, errorCallback) => {
|
||||
InsuredorClaimantFlag: null,
|
||||
},
|
||||
VehicleInformation: {
|
||||
Year: parseInt(job.v_model_yr.match(/\d/g).join(""), 10) || "",
|
||||
Year: job.v_model_yr
|
||||
? parseInt(job.v_model_yr.match(/\d/g))
|
||||
? parseInt(job.v_model_yr.match(/\d/g).join(""), 10)
|
||||
: ""
|
||||
: "",
|
||||
Make: job.v_make_desc || "",
|
||||
Model: job.v_model_desc || "",
|
||||
VIN: job.v_vin || "",
|
||||
|
||||
Reference in New Issue
Block a user