mirror of
https://github.com/SyncrowIOT/backend.git
synced 2025-08-26 09:39:39 +00:00
Merge pull request #107 from SyncrowIOT/add-thouches-gangs-to-schedule
finished add new types to the schedule apis
This commit is contained in:
@ -9,4 +9,7 @@ export enum ProductType {
|
|||||||
ONE_G = '1G',
|
ONE_G = '1G',
|
||||||
WH = 'WH',
|
WH = 'WH',
|
||||||
DS = 'DS',
|
DS = 'DS',
|
||||||
|
THREE_3TG = '3GT',
|
||||||
|
TWO_2TG = '2GT',
|
||||||
|
ONE_1TG = '1GT',
|
||||||
}
|
}
|
||||||
|
@ -53,7 +53,10 @@ export class ScheduleService {
|
|||||||
deviceDetails.productDevice.prodType !== ProductType.THREE_G &&
|
deviceDetails.productDevice.prodType !== ProductType.THREE_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.ONE_G &&
|
deviceDetails.productDevice.prodType !== ProductType.ONE_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.TWO_G &&
|
deviceDetails.productDevice.prodType !== ProductType.TWO_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.WH
|
deviceDetails.productDevice.prodType !== ProductType.WH &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.ONE_1TG &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.TWO_2TG &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.THREE_3TG
|
||||||
) {
|
) {
|
||||||
throw new HttpException(
|
throw new HttpException(
|
||||||
'This device is not supported for schedule',
|
'This device is not supported for schedule',
|
||||||
@ -107,7 +110,10 @@ export class ScheduleService {
|
|||||||
deviceDetails.productDevice.prodType !== ProductType.THREE_G &&
|
deviceDetails.productDevice.prodType !== ProductType.THREE_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.ONE_G &&
|
deviceDetails.productDevice.prodType !== ProductType.ONE_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.TWO_G &&
|
deviceDetails.productDevice.prodType !== ProductType.TWO_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.WH
|
deviceDetails.productDevice.prodType !== ProductType.WH &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.ONE_1TG &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.TWO_2TG &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.THREE_3TG
|
||||||
) {
|
) {
|
||||||
throw new HttpException(
|
throw new HttpException(
|
||||||
'This device is not supported for schedule',
|
'This device is not supported for schedule',
|
||||||
@ -157,7 +163,10 @@ export class ScheduleService {
|
|||||||
deviceDetails.productDevice.prodType !== ProductType.THREE_G &&
|
deviceDetails.productDevice.prodType !== ProductType.THREE_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.ONE_G &&
|
deviceDetails.productDevice.prodType !== ProductType.ONE_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.TWO_G &&
|
deviceDetails.productDevice.prodType !== ProductType.TWO_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.WH
|
deviceDetails.productDevice.prodType !== ProductType.WH &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.ONE_1TG &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.TWO_2TG &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.THREE_3TG
|
||||||
) {
|
) {
|
||||||
throw new HttpException(
|
throw new HttpException(
|
||||||
'This device is not supported for schedule',
|
'This device is not supported for schedule',
|
||||||
@ -221,7 +230,10 @@ export class ScheduleService {
|
|||||||
deviceDetails.productDevice.prodType !== ProductType.THREE_G &&
|
deviceDetails.productDevice.prodType !== ProductType.THREE_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.ONE_G &&
|
deviceDetails.productDevice.prodType !== ProductType.ONE_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.TWO_G &&
|
deviceDetails.productDevice.prodType !== ProductType.TWO_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.WH
|
deviceDetails.productDevice.prodType !== ProductType.WH &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.ONE_1TG &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.TWO_2TG &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.THREE_3TG
|
||||||
) {
|
) {
|
||||||
throw new HttpException(
|
throw new HttpException(
|
||||||
'This device is not supported for schedule',
|
'This device is not supported for schedule',
|
||||||
@ -302,7 +314,10 @@ export class ScheduleService {
|
|||||||
deviceDetails.productDevice.prodType !== ProductType.THREE_G &&
|
deviceDetails.productDevice.prodType !== ProductType.THREE_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.ONE_G &&
|
deviceDetails.productDevice.prodType !== ProductType.ONE_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.TWO_G &&
|
deviceDetails.productDevice.prodType !== ProductType.TWO_G &&
|
||||||
deviceDetails.productDevice.prodType !== ProductType.WH
|
deviceDetails.productDevice.prodType !== ProductType.WH &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.ONE_1TG &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.TWO_2TG &&
|
||||||
|
deviceDetails.productDevice.prodType !== ProductType.THREE_3TG
|
||||||
) {
|
) {
|
||||||
throw new HttpException(
|
throw new HttpException(
|
||||||
'This device is not supported for schedule',
|
'This device is not supported for schedule',
|
||||||
|
Reference in New Issue
Block a user