|
@@ -58,6 +58,7 @@ import type {
|
|
GroupModuleInfo,
|
|
GroupModuleInfo,
|
|
GroupModuleQuery,
|
|
GroupModuleQuery,
|
|
GroupRegions,
|
|
GroupRegions,
|
|
|
|
+ InfoListByOrg,
|
|
InterfaceData,
|
|
InterfaceData,
|
|
InterfaceLsit,
|
|
InterfaceLsit,
|
|
LimitForm,
|
|
LimitForm,
|
|
@@ -97,6 +98,8 @@ import type {
|
|
SubmitDeviceGroup,
|
|
SubmitDeviceGroup,
|
|
SubmitSorting,
|
|
SubmitSorting,
|
|
TempHumidityControlSettings,
|
|
TempHumidityControlSettings,
|
|
|
|
+ TreeStructure,
|
|
|
|
+ UploadLogo,
|
|
VerificationAgreement,
|
|
VerificationAgreement,
|
|
VerificationEquipment,
|
|
VerificationEquipment,
|
|
WarningItem,
|
|
WarningItem,
|
|
@@ -161,9 +164,23 @@ export const getDictTypeData = async (params: DictTypeDataParams) => {
|
|
return data;
|
|
return data;
|
|
};
|
|
};
|
|
|
|
|
|
|
|
+// 菜单权限表
|
|
|
|
+export const getSubPermList = async (id: number) => {
|
|
|
|
+ const data = await request<TreeStructure[]>(apiSys(`/sysPermission/subPermList/${id}`));
|
|
|
|
+ return data;
|
|
|
|
+};
|
|
|
|
+
|
|
// 组织表
|
|
// 组织表
|
|
export const addOrganization = async (params: OrganizationItem) => {
|
|
export const addOrganization = async (params: OrganizationItem) => {
|
|
- await request(apiSys('/sysOrg/add'), {
|
|
|
|
|
|
+ const data = await request<number>(apiSys('/sysOrg/add'), {
|
|
|
|
+ method: 'POST',
|
|
|
|
+ body: JSON.stringify(params),
|
|
|
|
+ });
|
|
|
|
+ return data;
|
|
|
|
+};
|
|
|
|
+
|
|
|
|
+export const updateOrganization = async (params: OrganizationItem) => {
|
|
|
|
+ request<number>(apiSys('/sysOrg/update'), {
|
|
method: 'POST',
|
|
method: 'POST',
|
|
body: JSON.stringify(params),
|
|
body: JSON.stringify(params),
|
|
});
|
|
});
|
|
@@ -172,10 +189,11 @@ export const addOrganization = async (params: OrganizationItem) => {
|
|
export const addUploadLogo = async (file: Blob) => {
|
|
export const addUploadLogo = async (file: Blob) => {
|
|
const formData = new FormData();
|
|
const formData = new FormData();
|
|
formData.append('file', file);
|
|
formData.append('file', file);
|
|
- await request(apiSys('/sysOrg/uploadLogo'), {
|
|
|
|
|
|
+ const data = await request<UploadLogo>(apiSys('/sysOrg/uploadLogo'), {
|
|
method: 'POST',
|
|
method: 'POST',
|
|
body: formData,
|
|
body: formData,
|
|
});
|
|
});
|
|
|
|
+ return data;
|
|
};
|
|
};
|
|
|
|
|
|
// ----- 业务服务 -----
|
|
// ----- 业务服务 -----
|
|
@@ -453,12 +471,11 @@ export const getDeviceListSimple = async (deviceId: number) => {
|
|
return data;
|
|
return data;
|
|
};
|
|
};
|
|
|
|
|
|
-export const getDeviceParams = async (deviceId: number, isProcessData: boolean) => {
|
|
|
|
|
|
+export const getDeviceParams = async (deviceId: number) => {
|
|
const data = await request<DeviceParamGroup[]>(apiBiz('/device/protocolParamVerify'), {
|
|
const data = await request<DeviceParamGroup[]>(apiBiz('/device/protocolParamVerify'), {
|
|
method: 'POST',
|
|
method: 'POST',
|
|
body: JSON.stringify({
|
|
body: JSON.stringify({
|
|
deviceId,
|
|
deviceId,
|
|
- isProcessData,
|
|
|
|
}),
|
|
}),
|
|
});
|
|
});
|
|
|
|
|
|
@@ -989,6 +1006,11 @@ export const getGroupModuleInfo = async (params: GroupModuleQuery) => {
|
|
method: 'POST',
|
|
method: 'POST',
|
|
body: JSON.stringify(params),
|
|
body: JSON.stringify(params),
|
|
});
|
|
});
|
|
|
|
+ return data;
|
|
|
|
+};
|
|
|
|
|
|
|
|
+// 组织与设备限制
|
|
|
|
+export const getInfoListByOrgId = async (orgId: number) => {
|
|
|
|
+ const data = await request<InfoListByOrg[]>(apiBiz(`/orgDeviceLimit/infoListByOrgId/${orgId}`));
|
|
return data;
|
|
return data;
|
|
};
|
|
};
|