forked from drone/command-center-dashboard

chenyao
2025-03-29 efab54d762db66fa208be819ec73c667ad0efc4c
src/views/Home/components/HomeLeft/OverviewNext.vue
@@ -32,7 +32,7 @@
          <img width="13" height="15" src="@/assets/images/home/homeLeft/table-icon.png" alt="" />
          {{ item.name }}
        </div>
        <div class="status">{{ item.status }}</div>
        <div class="status" @click="signMachineNestClick">{{ item.status }}</div>
      </div>
    </div>
  </div>
@@ -41,6 +41,8 @@
import { pxToRem } from '@/utils/rem';
import { Search } from '@element-plus/icons-vue';
import CommonTitle from '@/components/CommonTitle.vue';
import { getDeviceInfoNum } from '@/api/home/machineNest.js'
import router from '@/router/';
const list = ref([
  { name: '执行中', value: 89, color: '#FFA768' },
@@ -56,9 +58,29 @@
  { name: '小兰工业园3号', status: '预计执行' },
]);
// 获取机巢列表
const getList = () => {
  getDeviceInfoNum().then((res) => {
    console.log(res);
  });
}
// 单个机巢详情
const signMachineNestClick = () => {
  router.push({
    path: '/signMachineNest',
    query: {
      id: '123'  // 这里可以传递你需要的参数
    }
  });
}
const detailsFun = () => {
  console.log('details');
};
onMounted(() => {
  getList();
});
</script>
<style scoped lang="scss">
.overview-next {
@@ -163,6 +185,7 @@
      }
      .status {
        color: #6fc3ff;
        cursor: pointer;
      }
      .atcive {
        color: #04f020;