@iotready/nextjs-components-library 1.0.0-preview3 → 1.0.0-preview31
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/accounts/AccountMenu.js +1 -1
- package/components/accounts/AccountProfile.js +1 -1
- package/components/charts/TrendChart.d.ts +27 -6
- package/components/charts/TrendChart.js +580 -170
- package/components/groups/GroupUpdate.d.ts +4 -8
- package/components/groups/GroupUpdate.js +1 -31
- package/components/groups/GroupsDevices.d.ts +15 -10
- package/components/groups/GroupsDevices.js +92 -79
- package/components/groups/Map.d.ts +3 -8
- package/components/settings/DynamicMenu.d.ts +1 -0
- package/components/settings/DynamicMenu.js +2 -1
- package/components/users/UsersDataGrid.d.ts +5 -2
- package/components/users/UsersDataGrid.js +49 -32
- package/package.json +6 -3
- package/server-actions/annotations.d.ts +4 -0
- package/server-actions/annotations.js +12 -0
- package/server-actions/groups.d.ts +12 -16
- package/server-actions/groups.js +71 -72
- package/server-actions/index.d.ts +1 -0
- package/server-actions/index.js +1 -0
- package/server-actions/influx.d.ts +17 -13
- package/server-actions/influx.js +207 -98
- package/server-actions/trackle.d.ts +10 -4
- package/server-actions/trackle.js +29 -24
- package/server-actions/types.d.ts +16 -0
- package/server-actions/types.js +6 -0
- package/types/device.d.ts +19 -0
- package/types/device.js +1 -0
- package/types/index.d.ts +1 -0
- package/types/index.js +1 -0
- package/types/user.d.ts +1 -0
|
@@ -1,15 +1,23 @@
|
|
|
1
|
-
import { jsx as _jsx,
|
|
2
|
-
import { useState, useEffect } from 'react';
|
|
3
|
-
import { DataGrid,
|
|
4
|
-
import { Card, Box,
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
|
|
8
|
-
const UsersDataGrid = ({ handleGetUsersList, pageSize, container = 'Box', containerProps = {}, props = {}, loadingComponent = _jsx(CircularProgress, {}), theme }) => {
|
|
9
|
-
const router = useRouter();
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { useState, useEffect, useMemo } from 'react';
|
|
3
|
+
import { DataGrid, GridLogicOperator, GridToolbarExport } from '@mui/x-data-grid';
|
|
4
|
+
import { Card, Box, CircularProgress, ThemeProvider, FormControl, IconButton, InputLabel, MenuItem, Select, TextField } from '@mui/material';
|
|
5
|
+
import { ClearIcon } from "@mui/x-date-pickers";
|
|
6
|
+
import debounce from 'lodash.debounce';
|
|
7
|
+
const UsersDataGrid = ({ handleGetUsersList, pageSize, container = 'Box', containerProps = {}, props = {}, loadingComponent = _jsx(CircularProgress, {}), theme, columns }) => {
|
|
10
8
|
const [usersList, setUsersList] = useState(undefined);
|
|
11
9
|
const [userCount, setUserCount] = useState(undefined);
|
|
10
|
+
const filterType = {
|
|
11
|
+
email: 'Email',
|
|
12
|
+
name: 'Full name',
|
|
13
|
+
role: 'Role'
|
|
14
|
+
};
|
|
15
|
+
const [selectedFilterValue, setSelectedFilterValue] = useState(undefined);
|
|
16
|
+
const [selectedFilterType, setSelectedFilterType] = useState('email');
|
|
12
17
|
const [isLoading, setIsLoading] = useState(true);
|
|
18
|
+
const [sortModel, setSortModel] = useState([
|
|
19
|
+
{ field: "email", sort: "desc" },
|
|
20
|
+
]);
|
|
13
21
|
const [paginationModel, setPaginationModel] = useState({
|
|
14
22
|
page: 0,
|
|
15
23
|
pageSize: pageSize || 1,
|
|
@@ -29,7 +37,8 @@ const UsersDataGrid = ({ handleGetUsersList, pageSize, container = 'Box', contai
|
|
|
29
37
|
{ value: filterModel.quickFilterValues[0] }
|
|
30
38
|
: filterModel.items.length > 0 ?
|
|
31
39
|
{ field: filterModel.items[0].field, operator: filterModel.items[0].operator, value: filterModel.items[0].value }
|
|
32
|
-
: undefined
|
|
40
|
+
: undefined,
|
|
41
|
+
sortModel
|
|
33
42
|
});
|
|
34
43
|
setUsersList(usersList.users);
|
|
35
44
|
setUserCount(usersList.rowCount);
|
|
@@ -41,36 +50,44 @@ const UsersDataGrid = ({ handleGetUsersList, pageSize, container = 'Box', contai
|
|
|
41
50
|
setIsLoading(false);
|
|
42
51
|
}
|
|
43
52
|
};
|
|
53
|
+
const debouncedUpdateFilter = useMemo(() => debounce((value) => {
|
|
54
|
+
setFilterModel({
|
|
55
|
+
items: [{
|
|
56
|
+
field: selectedFilterType || 'email',
|
|
57
|
+
operator: 'startsWith',
|
|
58
|
+
value: value
|
|
59
|
+
}],
|
|
60
|
+
});
|
|
61
|
+
}, 500), [selectedFilterType]);
|
|
62
|
+
const handleFilterModelChange = (value) => {
|
|
63
|
+
setSelectedFilterValue(value);
|
|
64
|
+
// const value = newModel.quickFilterValues?.[0] || '';
|
|
65
|
+
if (value.length >= 3 || value.length === 0) {
|
|
66
|
+
debouncedUpdateFilter(value);
|
|
67
|
+
}
|
|
68
|
+
};
|
|
44
69
|
useEffect(() => {
|
|
45
70
|
getUsersList();
|
|
46
|
-
}, [paginationModel, filterModel]);
|
|
71
|
+
}, [paginationModel, filterModel, sortModel]);
|
|
47
72
|
if (!usersList && isLoading) {
|
|
48
73
|
return loadingComponent;
|
|
49
74
|
}
|
|
50
|
-
const
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
{
|
|
58
|
-
field: 'email', filterOperators: getGridStringOperators().filter((operator) => operator.value === 'contains' || operator.value === 'equals'), display: 'flex', flex: 0.400, minWidth: 180, headerName: 'Email address', renderCell: (params) => (_jsx(_Fragment, { children: params.value }))
|
|
59
|
-
},
|
|
60
|
-
{
|
|
61
|
-
field: 'lastSignInAt', filterable: false, disableColumnMenu: true, display: 'flex', minWidth: 160, headerName: 'Last Signed In', renderCell: (params) => (_jsx(_Fragment, { children: params.value ? moment(params.value).format('DD/MM/YYYY HH:mm:ss') : '' }))
|
|
62
|
-
},
|
|
63
|
-
{
|
|
64
|
-
field: 'id', filterable: false, disableExport: true, disableColumnMenu: true, headerName: '', display: 'flex', align: 'right', renderCell: (params) => (_jsxs(Button, { onClick: () => router.push(`/users/${params.value}`), variant: 'contained', color: 'secondary', size: 'small', children: [_jsx(EditIcon, { fontSize: 'small', sx: { mr: 1 } }), " EDIT"] }))
|
|
65
|
-
}
|
|
66
|
-
], rows: usersList, slots: {
|
|
67
|
-
toolbar: GridToolbar,
|
|
75
|
+
const handleSortModelChange = (model) => {
|
|
76
|
+
setSortModel(model);
|
|
77
|
+
setPaginationModel(prev => ({ ...prev, page: 0 }));
|
|
78
|
+
};
|
|
79
|
+
const CustomToolbar = () => (_jsx(Box, { sx: { display: 'flex', alignItems: 'center', p: 1, justifyContent: 'space-between' }, children: _jsx(GridToolbarExport, {}) }));
|
|
80
|
+
const renderUsersList = () => (_jsx("div", { style: { display: 'flex', flexDirection: 'column', minHeight: 323 }, children: _jsx(DataGrid, { disableDensitySelector: true, disableColumnSelector: true, disableRowSelectionOnClick: true, onSortModelChange: handleSortModelChange, disableColumnResize: true, columns: columns, rows: usersList, slots: {
|
|
81
|
+
toolbar: CustomToolbar,
|
|
68
82
|
}, slotProps: {
|
|
69
83
|
toolbar: {
|
|
70
84
|
printOptions: { disableToolbarButton: true },
|
|
71
|
-
showQuickFilter:
|
|
85
|
+
showQuickFilter: false,
|
|
72
86
|
},
|
|
73
|
-
}, rowCount: userCount, loading: isLoading, pageSizeOptions: [], paginationModel: paginationModel, paginationMode: "server", onPaginationModelChange: setPaginationModel,
|
|
74
|
-
|
|
87
|
+
}, rowCount: userCount, loading: isLoading, pageSizeOptions: [], paginationModel: paginationModel, paginationMode: "server", onPaginationModelChange: setPaginationModel, ...props }) }));
|
|
88
|
+
const renderFilter = () => (_jsxs(Box, { sx: { display: 'flex', alignItems: 'center', justifyContent: 'flex-end', mb: 2 }, children: [_jsxs(FormControl, { children: [_jsx(InputLabel, { shrink: true, id: "filter-by-select-label", children: "Filter by" }), _jsx(Select, { value: selectedFilterType || '', onChange: (e) => setSelectedFilterType(e.target.value), labelId: "filter-by-select-label", label: "Filter by", size: "small", sx: { mr: 2 }, children: Object.entries(filterType).map(([key, label]) => (_jsx(MenuItem, { value: key, children: label }, key))) })] }), _jsx(TextField, { value: selectedFilterValue || "", onChange: (e) => handleFilterModelChange(e.target.value), placeholder: "Search...", size: "small", InputProps: {
|
|
89
|
+
endAdornment: selectedFilterValue ? (_jsx(IconButton, { size: "small", onClick: () => handleFilterModelChange(""), children: _jsx(ClearIcon, { fontSize: "small" }) })) : null,
|
|
90
|
+
} })] }));
|
|
91
|
+
return _jsx(ThemeProvider, { theme: theme, children: container === "Card" ? (_jsxs(_Fragment, { children: [renderFilter(), _jsx(Card, { ...containerProps, children: renderUsersList() })] })) : (_jsxs(_Fragment, { children: [renderFilter(), _jsx(Box, { ...containerProps, children: renderUsersList() })] })) });
|
|
75
92
|
};
|
|
76
93
|
export default UsersDataGrid;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@iotready/nextjs-components-library",
|
|
3
|
-
"version": "1.0.0-
|
|
3
|
+
"version": "1.0.0-preview31",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "rm -rf dist && tsc --project tsconfig.build.json && cp package.json dist/",
|
|
@@ -19,9 +19,11 @@
|
|
|
19
19
|
"chartjs-adapter-moment": "^1.0.1",
|
|
20
20
|
"chartjs-plugin-annotation": "^3.1.0",
|
|
21
21
|
"chartjs-plugin-zoom": "^2.0.1",
|
|
22
|
-
"
|
|
22
|
+
"csv-parse": "^5.6.0",
|
|
23
|
+
"firebase-admin": "^13.4.0",
|
|
23
24
|
"leaflet": "^1.9.4",
|
|
24
25
|
"leaflet-defaulticon-compatibility": "^0.1.2",
|
|
26
|
+
"lodash.debounce": "^4.0.8",
|
|
25
27
|
"material-ui-confirm": "^3.0.16",
|
|
26
28
|
"moment": "^2.30.1",
|
|
27
29
|
"next": "^14.2.9",
|
|
@@ -34,6 +36,7 @@
|
|
|
34
36
|
},
|
|
35
37
|
"devDependencies": {
|
|
36
38
|
"@types/leaflet": "^1.9.13",
|
|
39
|
+
"@types/lodash.debounce": "^4.0.9",
|
|
37
40
|
"@types/node": "^20",
|
|
38
41
|
"@types/react": "^18",
|
|
39
42
|
"@types/react-csv": "^1.1.10",
|
|
@@ -42,4 +45,4 @@
|
|
|
42
45
|
"eslint-config-next": "14.2.9",
|
|
43
46
|
"typescript": "^5"
|
|
44
47
|
}
|
|
45
|
-
}
|
|
48
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use server";
|
|
2
|
+
export const getAnnotations = async (db, deviceID) => {
|
|
3
|
+
const annotationsRef = db.collection("annotations");
|
|
4
|
+
const snapshot = await annotationsRef
|
|
5
|
+
.where("target", "==", deviceID)
|
|
6
|
+
.orderBy("createdAt", "desc")
|
|
7
|
+
.get();
|
|
8
|
+
return snapshot.docs.map((doc) => ({
|
|
9
|
+
id: doc.id,
|
|
10
|
+
...doc.data()
|
|
11
|
+
}));
|
|
12
|
+
};
|
|
@@ -1,22 +1,18 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
authDomain: string;
|
|
4
|
-
projectId: string;
|
|
5
|
-
storageBucket: string;
|
|
6
|
-
messagingSenderId: string;
|
|
7
|
-
appId: string;
|
|
8
|
-
};
|
|
9
|
-
export declare const getGroups: (firebaseConfig: FirebaseConfig, productID: number, userID?: string) => Promise<{
|
|
1
|
+
import { Firestore } from "firebase-admin/firestore";
|
|
2
|
+
export declare const getGroups: (db: Firestore, productID: number, userID?: string, assetID?: string) => Promise<{
|
|
10
3
|
id: string;
|
|
11
4
|
}[]>;
|
|
12
|
-
export declare const getGroupById: (
|
|
5
|
+
export declare const getGroupById: (db: Firestore, id: string) => Promise<{
|
|
13
6
|
id: string;
|
|
14
7
|
}>;
|
|
15
|
-
export declare const createGroup: (
|
|
16
|
-
export declare const updateGroup: (
|
|
17
|
-
export declare const deleteGroup: (
|
|
18
|
-
export declare const getUsersGroup: (
|
|
8
|
+
export declare const createGroup: (db: Firestore, group: any) => Promise<string>;
|
|
9
|
+
export declare const updateGroup: (db: Firestore, id: string, group: any) => Promise<any>;
|
|
10
|
+
export declare const deleteGroup: (db: Firestore, id: string) => Promise<void>;
|
|
11
|
+
export declare const getUsersGroup: (db: Firestore, groupID: string) => Promise<{
|
|
19
12
|
id: string;
|
|
20
13
|
}[]>;
|
|
21
|
-
export declare const
|
|
22
|
-
|
|
14
|
+
export declare const getGroupsUser: (db: Firestore, userID: string) => Promise<{
|
|
15
|
+
id: string;
|
|
16
|
+
}[]>;
|
|
17
|
+
export declare const addUsersGroup: (db: Firestore, groupID: string, userName: string, userID: string) => Promise<string>;
|
|
18
|
+
export declare const removeUserGroup: (db: Firestore, groupID: string, userID: string) => Promise<string | undefined>;
|
package/server-actions/groups.js
CHANGED
|
@@ -1,87 +1,86 @@
|
|
|
1
1
|
"use server";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
const groupsQuery = query(collection(db, "groups"), where("productID", "==", productID), orderBy("created", "desc"));
|
|
2
|
+
// 1. GET GROUPS
|
|
3
|
+
export const getGroups = async (db, productID, userID, assetID) => {
|
|
4
|
+
let groupsRef = db.collection("groups").where("productID", "==", productID);
|
|
5
|
+
if (assetID) {
|
|
6
|
+
groupsRef = groupsRef.where("assets", "array-contains", assetID);
|
|
7
|
+
}
|
|
8
|
+
groupsRef = groupsRef.orderBy("created", "desc");
|
|
10
9
|
let groupIds = null;
|
|
11
10
|
if (userID) {
|
|
12
|
-
const
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
if (groupIds) {
|
|
18
|
-
return groupsSnapshot.docs
|
|
19
|
-
.filter((entry) => groupIds?.includes(entry.id))
|
|
20
|
-
.map((doc) => ({
|
|
21
|
-
id: doc.id,
|
|
22
|
-
...doc.data()
|
|
23
|
-
}));
|
|
11
|
+
const userGroupsSnapshot = await db
|
|
12
|
+
.collection("userGroups")
|
|
13
|
+
.where("user.userId", "==", userID)
|
|
14
|
+
.get();
|
|
15
|
+
groupIds = userGroupsSnapshot.docs.map((doc) => doc.data().groupId);
|
|
24
16
|
}
|
|
25
|
-
|
|
17
|
+
const groupsSnapshot = await groupsRef.get();
|
|
18
|
+
return groupsSnapshot.docs
|
|
19
|
+
.filter((doc) => !groupIds || groupIds.includes(doc.id))
|
|
20
|
+
.map((doc) => ({
|
|
26
21
|
id: doc.id,
|
|
27
22
|
...doc.data()
|
|
28
23
|
}));
|
|
29
24
|
};
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
const
|
|
33
|
-
const groupSnapshot = await getDoc(doc(db, "groups", id));
|
|
25
|
+
// 2. GET GROUP BY ID
|
|
26
|
+
export const getGroupById = async (db, id) => {
|
|
27
|
+
const docSnapshot = await db.collection("groups").doc(id).get();
|
|
34
28
|
return {
|
|
35
|
-
id:
|
|
36
|
-
...
|
|
29
|
+
id: docSnapshot.id,
|
|
30
|
+
...docSnapshot.data()
|
|
37
31
|
};
|
|
38
32
|
};
|
|
39
|
-
|
|
40
|
-
|
|
33
|
+
// 3. CREATE GROUP
|
|
34
|
+
export const createGroup = async (db, group) => {
|
|
41
35
|
const newGroup = {
|
|
42
36
|
...group,
|
|
43
|
-
created
|
|
37
|
+
created: new Date().toISOString()
|
|
44
38
|
};
|
|
45
|
-
const
|
|
46
|
-
const db = getFirestore(app);
|
|
47
|
-
const docRef = await addDoc(collection(db, "groups"), newGroup);
|
|
39
|
+
const docRef = await db.collection("groups").add(newGroup);
|
|
48
40
|
return docRef.id;
|
|
49
41
|
};
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
const groupRef = doc(db, "groups", id);
|
|
54
|
-
await updateDoc(groupRef, group);
|
|
42
|
+
// 4. UPDATE GROUP
|
|
43
|
+
export const updateGroup = async (db, id, group) => {
|
|
44
|
+
await db.collection("groups").doc(id).update(group);
|
|
55
45
|
return group;
|
|
56
46
|
};
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
const
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
47
|
+
// 5. DELETE GROUP
|
|
48
|
+
export const deleteGroup = async (db, id) => {
|
|
49
|
+
const userGroupsSnapshot = await db
|
|
50
|
+
.collection("userGroups")
|
|
51
|
+
.where("groupId", "==", id)
|
|
52
|
+
.get();
|
|
53
|
+
const batch = db.batch();
|
|
54
|
+
userGroupsSnapshot.docs.forEach((doc) => {
|
|
55
|
+
batch.delete(doc.ref);
|
|
65
56
|
});
|
|
66
|
-
|
|
67
|
-
await
|
|
57
|
+
batch.delete(db.collection("groups").doc(id));
|
|
58
|
+
await batch.commit();
|
|
59
|
+
};
|
|
60
|
+
// 6. GET USERS GROUP
|
|
61
|
+
export const getUsersGroup = async (db, groupID) => {
|
|
62
|
+
const snapshot = await db
|
|
63
|
+
.collection("userGroups")
|
|
64
|
+
.where("groupId", "==", groupID)
|
|
65
|
+
.get();
|
|
66
|
+
return snapshot.docs.map((doc) => ({
|
|
67
|
+
id: doc.id,
|
|
68
|
+
...doc.data()
|
|
69
|
+
}));
|
|
68
70
|
};
|
|
69
|
-
//
|
|
70
|
-
export const
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
return groupsSnapshot.docs.map((doc) => ({
|
|
71
|
+
// 6b. GET GROUPS USER
|
|
72
|
+
export const getGroupsUser = async (db, userID) => {
|
|
73
|
+
const snapshot = await db
|
|
74
|
+
.collection("userGroups")
|
|
75
|
+
.where("user.userId", "==", userID)
|
|
76
|
+
.get();
|
|
77
|
+
return snapshot.docs.map((doc) => ({
|
|
77
78
|
id: doc.id,
|
|
78
79
|
...doc.data()
|
|
79
80
|
}));
|
|
80
81
|
};
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
const app = initializeApp(firebaseConfig);
|
|
84
|
-
const db = getFirestore(app);
|
|
82
|
+
// 7. ADD USER TO GROUP
|
|
83
|
+
export const addUsersGroup = async (db, groupID, userName, userID) => {
|
|
85
84
|
const created = new Date().toISOString();
|
|
86
85
|
const newUserGroup = {
|
|
87
86
|
user: {
|
|
@@ -91,19 +90,19 @@ export const addUsersGroup = async (firebaseConfig, groupID, userName, userID) =
|
|
|
91
90
|
groupId: groupID,
|
|
92
91
|
created
|
|
93
92
|
};
|
|
94
|
-
const docRef = await
|
|
93
|
+
const docRef = await db.collection("userGroups").add(newUserGroup);
|
|
95
94
|
return docRef.id;
|
|
96
95
|
};
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
const
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
await
|
|
107
|
-
return
|
|
96
|
+
// 8. REMOVE USER FROM GROUP
|
|
97
|
+
export const removeUserGroup = async (db, groupID, userID) => {
|
|
98
|
+
const snapshot = await db
|
|
99
|
+
.collection("userGroups")
|
|
100
|
+
.where("groupId", "==", groupID)
|
|
101
|
+
.where("user.userId", "==", userID)
|
|
102
|
+
.get();
|
|
103
|
+
const doc = snapshot.docs[0];
|
|
104
|
+
if (doc) {
|
|
105
|
+
await doc.ref.delete();
|
|
106
|
+
return doc.id;
|
|
108
107
|
}
|
|
109
108
|
};
|
package/server-actions/index.js
CHANGED
|
@@ -1,13 +1,17 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
1
|
+
import { FilterTagMode, InfluxConfig, InfluxFillType } from "./types";
|
|
2
|
+
export declare function getInfluxAlerts(influxConfig: InfluxConfig, fields: string[], limit: number, offset: number, sort: any, filter: {
|
|
3
|
+
field: string;
|
|
4
|
+
value: string;
|
|
5
|
+
}, timeStart: number, timeEnd: number, aggregate?: boolean): Promise<any>;
|
|
6
|
+
export declare function getDwSlots(influxConfig: InfluxConfig, timeStart: number, timeEnd: number, filter: {
|
|
7
|
+
field: string;
|
|
8
|
+
value: string;
|
|
9
|
+
}): Promise<any>;
|
|
10
|
+
export declare function getInfluxDataV1(influxConfig: InfluxConfig, field: string, timeStart: number, timeEnd: number, filter: {
|
|
11
|
+
field: string;
|
|
12
|
+
value: string;
|
|
13
|
+
}, timeGroup: string, raw: boolean, fill?: InfluxFillType, filterTag?: number, tagInclude?: FilterTagMode): Promise<any>;
|
|
14
|
+
export declare function exportDataV1(influxConfig: InfluxConfig, field: string, timeStart: number, timeEnd: number, filter: {
|
|
15
|
+
field: string;
|
|
16
|
+
value: string;
|
|
17
|
+
}): Promise<any>;
|