@ -748,12 +748,12 @@ export class TbDeviceInstallDialogComponent extends DialogComponent<TbDeviceInst
return { id : result.id.id , name : result.name , url : ` /profiles/deviceProfiles/ ${ result . id . id } ` } ;
return { id : result.id.id , name : result.name , url : ` /profiles/deviceProfiles/ ${ result . id . id } ` } ;
}
}
case InstallStepType . DEVICE : {
case InstallStepType . DEVICE : {
const result = await firstValueFrom ( this . deviceService . saveDevice ( template , { ignoreErrors : tru e} ) ) ;
const result = await firstValueFrom ( this . deviceService . saveDevice ( template , { ignoreErrors : fals e} ) ) ;
const creds = await this . resolveCredentials ( step , result . id . id ) ;
const creds = await this . resolveCredentials ( step , result . id . id ) ;
return { id : result.id.id , name : result.name , url : ` /entities/devices/ ${ result . id . id } ` , token : creds.credentialsId } ;
return { id : result.id.id , name : result.name , url : ` /entities/devices/ ${ result . id . id } ` , token : creds.credentialsId } ;
}
}
case InstallStepType . GATEWAY : {
case InstallStepType . GATEWAY : {
const result = await firstValueFrom ( this . deviceService . saveDevice ( template , { ignoreErrors : tru e} ) ) ;
const result = await firstValueFrom ( this . deviceService . saveDevice ( template , { ignoreErrors : fals e} ) ) ;
const creds = await this . resolveCredentials ( step , result . id . id ) ;
const creds = await this . resolveCredentials ( step , result . id . id ) ;
const output = {
const output = {
id : result.id.id ,
id : result.id.id ,
@ -904,13 +904,13 @@ export class TbDeviceInstallDialogComponent extends DialogComponent<TbDeviceInst
}
}
case InstallStepType . DEVICE : {
case InstallStepType . DEVICE : {
template . id = { id : existing.id , entityType : 'DEVICE' } ;
template . id = { id : existing.id , entityType : 'DEVICE' } ;
const result = await firstValueFrom ( this . deviceService . saveDevice ( template , { ignoreErrors : tru e} ) ) ;
const result = await firstValueFrom ( this . deviceService . saveDevice ( template , { ignoreErrors : fals e} ) ) ;
const creds = await this . resolveCredentials ( step , result . id . id ) ;
const creds = await this . resolveCredentials ( step , result . id . id ) ;
return { id : result.id.id , name : result.name , url : ` /entities/devices/ ${ result . id . id } ` , token : creds.credentialsId } ;
return { id : result.id.id , name : result.name , url : ` /entities/devices/ ${ result . id . id } ` , token : creds.credentialsId } ;
}
}
case InstallStepType . GATEWAY : {
case InstallStepType . GATEWAY : {
template . id = { id : existing.id , entityType : 'DEVICE' } ;
template . id = { id : existing.id , entityType : 'DEVICE' } ;
const result = await firstValueFrom ( this . deviceService . saveDevice ( template , { ignoreErrors : tru e} ) ) ;
const result = await firstValueFrom ( this . deviceService . saveDevice ( template , { ignoreErrors : fals e} ) ) ;
const creds = await this . resolveCredentials ( step , result . id . id ) ;
const creds = await this . resolveCredentials ( step , result . id . id ) ;
const output : EntityStepOutput = {
const output : EntityStepOutput = {
id : result.id.id ,
id : result.id.id ,