chore: apis
This commit is contained in:
@@ -35,3 +35,16 @@ export const turnStatus = async (stationCode: string, ipAddress: string, circuit
|
|||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export const rebootSecurityBox = async (stationCode: string, ipAddress: string) => {
|
||||||
|
const prefix = stationCode ? `/${stationCode}` : '';
|
||||||
|
const resp = await ndmClient.post<boolean>(`${prefix}/api/ndm/ndmSecurityBox/reboot`, {
|
||||||
|
community: 'public',
|
||||||
|
ipAddress,
|
||||||
|
});
|
||||||
|
const [err, result] = resp;
|
||||||
|
if (err || !result) {
|
||||||
|
throw err;
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
};
|
||||||
|
|||||||
@@ -64,3 +64,13 @@ export const reloadRecordCheckByGbId = async (stationCode: string, channel: Clie
|
|||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export const reloadAllRecordCheck = async (stationCode: string, dayOffset: number) => {
|
||||||
|
const prefix = stationCode ? `/${stationCode}` : '';
|
||||||
|
const resp = await ndmClient.post<boolean>(`${prefix}/api/ndm/ndmRecordCheck/reloadAllRecordCheck`, dayOffset);
|
||||||
|
const [err, result] = resp;
|
||||||
|
if (err || !result) {
|
||||||
|
throw err;
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user