fill in additional null fields for coinatmradar
This commit is contained in:
parent
2797c75a31
commit
737eacc0ec
1 changed files with 19 additions and 0 deletions
|
|
@ -65,6 +65,18 @@ function mapMachine (info, machineRow) {
|
||||||
|
|
||||||
return {
|
return {
|
||||||
machineId: deviceId,
|
machineId: deviceId,
|
||||||
|
address: {
|
||||||
|
streetAddress: null,
|
||||||
|
city: null,
|
||||||
|
region: null,
|
||||||
|
postalCode: null,
|
||||||
|
country: null
|
||||||
|
},
|
||||||
|
location: {
|
||||||
|
name: null,
|
||||||
|
url: null,
|
||||||
|
phone: null
|
||||||
|
},
|
||||||
status,
|
status,
|
||||||
lastOnline,
|
lastOnline,
|
||||||
cashIn: true,
|
cashIn: true,
|
||||||
|
|
@ -99,6 +111,8 @@ function sendRadar (data) {
|
||||||
maxContentLength: MAX_CONTENT_LENGTH
|
maxContentLength: MAX_CONTENT_LENGTH
|
||||||
}
|
}
|
||||||
|
|
||||||
|
console.log('%j', data)
|
||||||
|
|
||||||
return axios(config)
|
return axios(config)
|
||||||
.then(r => console.log(r.status))
|
.then(r => console.log(r.status))
|
||||||
}
|
}
|
||||||
|
|
@ -108,6 +122,11 @@ function mapRecord (info) {
|
||||||
return getMachines(info)
|
return getMachines(info)
|
||||||
.then(machines => ({
|
.then(machines => ({
|
||||||
operatorId: options.operatorId,
|
operatorId: options.operatorId,
|
||||||
|
operator: {
|
||||||
|
name: null,
|
||||||
|
phone: null,
|
||||||
|
email: null
|
||||||
|
},
|
||||||
timestamp,
|
timestamp,
|
||||||
machines
|
machines
|
||||||
}))
|
}))
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue