mirror of
https://github.com/Litlyx/litlyx
synced 2025-12-10 07:48:37 +01:00
fix devices
This commit is contained in:
2
TODO
2
TODO
@@ -2,11 +2,9 @@
|
|||||||
|
|
||||||
- Reactivity on project delete (update dropdown) + test guest
|
- Reactivity on project delete (update dropdown) + test guest
|
||||||
|
|
||||||
- Devices remove empty (Fix devices Dashboard card, replace empty with "unkwnwn")
|
|
||||||
- docs vertical navigation not wfull
|
- docs vertical navigation not wfull
|
||||||
- project creation
|
- project creation
|
||||||
- Event funnel / metadata analyzer / user flow
|
- Event funnel / metadata analyzer / user flow
|
||||||
- Test guest actions
|
|
||||||
- Refactor UI Data analyst
|
- Refactor UI Data analyst
|
||||||
- Remove Top Events from web analytics and move to custom events (with raw data access)
|
- Remove Top Events from web analytics and move to custom events (with raw data access)
|
||||||
- Fix email on plan upgrade and resub
|
- Fix email on plan upgrade and resub
|
||||||
@@ -1,22 +1,29 @@
|
|||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
|
|
||||||
|
|
||||||
|
function transform(data: { _id: string, count: number }[]) {
|
||||||
|
console.log(data);
|
||||||
|
return data.map(e => ({ ...e, _id: e._id == null ? 'unknown' : e._id }))
|
||||||
|
}
|
||||||
|
|
||||||
const devicesData = useFetch('/api/data/devices', {
|
const devicesData = useFetch('/api/data/devices', {
|
||||||
headers: useComputedHeaders({ limit: 10, }), lazy: true
|
headers: useComputedHeaders({ limit: 10, }), lazy: true,
|
||||||
|
transform
|
||||||
});
|
});
|
||||||
|
|
||||||
const { showDialog, dialogBarData, isDataLoading } = useBarCardDialog();
|
const { showDialog, dialogBarData, isDataLoading } = useBarCardDialog();
|
||||||
|
|
||||||
async function showMore() {
|
async function showMore() {
|
||||||
dialogBarData.value=[];
|
dialogBarData.value = [];
|
||||||
showDialog.value = true;
|
showDialog.value = true;
|
||||||
isDataLoading.value = true;
|
isDataLoading.value = true;
|
||||||
|
|
||||||
const res = await $fetch('/api/data/devices', {
|
const res = await $fetch('/api/data/devices', {
|
||||||
headers: useComputedHeaders({ limit: 1000 }).value
|
headers: useComputedHeaders({ limit: 1000 }).value,
|
||||||
});
|
});
|
||||||
|
|
||||||
dialogBarData.value = res || [];
|
|
||||||
|
dialogBarData.value = transform(res || []);
|
||||||
|
|
||||||
isDataLoading.value = false;
|
isDataLoading.value = false;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user