Update main.js
This commit is contained in:
parent
bcebdfe797
commit
d585b3cf5c
27
main.js
27
main.js
@ -316,6 +316,33 @@ function checkObjects(options, regType, regName, regFullName, tasks, newObjects)
|
||||
|
||||
adapter.log.info("id=" + id);
|
||||
|
||||
regs[i].fullId = id;
|
||||
objects[id] = {
|
||||
_id: regs[i].deviceId,
|
||||
type: 'state',
|
||||
common: {
|
||||
name: regs[i].description,
|
||||
role: regs[i].role,
|
||||
type: 'string',
|
||||
read: true,
|
||||
write: true,
|
||||
def: ""
|
||||
},
|
||||
native: {
|
||||
regType: regType,
|
||||
address: regs[i].address,
|
||||
ip: regs[i].ip
|
||||
}
|
||||
};
|
||||
|
||||
tasks.push({
|
||||
id: regs[i].deviceId,
|
||||
name: 'add',
|
||||
obj: objects[id]
|
||||
});
|
||||
newObjects.push(id);
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user