潘志宝
2025-02-28 4a859a6d69984c77fa8166255c65f5a94eb0bd71
src/views/data/ind/item/index.vue
@@ -91,11 +91,16 @@
                修改
              </el-button>
              <el-button
                v-hasPermi="['data:ind-item:update']"
                link
                type="primary"
                @click="getCurrentData(scope.row.itemNo)">
                当前值
              </el-button>
              <el-button
                link
                type="primary"
                @click="getHistoryData(scope.row)">
                历史值
              </el-button>
              <el-button
                v-hasPermi="['data:ind-item:delete']"
@@ -124,7 +129,8 @@
  <DerIndDefineForm ref="derFormRef" @success="getList" />
  <CalIndDefineForm ref="calFormRef" @success="getList" />
  <SelectItemType ref="itemTypeSel"/>
  <IndCurrentData ref="indCurrentData" />
  <IndCurrentData ref="indCurrentData"/>
  <IndHistoryChart ref="indHistoryChart"/>
</template>
<script lang="ts" setup>
@@ -139,6 +145,7 @@
  import * as ItemApi from '@/api/data/ind/item/item'
  import * as CategoryApi from "@/api/data/ind/category";
  import IndCurrentData from './IndCurrentData.vue'
  import IndHistoryChart from './IndHistoryChart.vue'
  import {handleTree} from "@/utils/tree";
@@ -219,11 +226,15 @@
    }
  }
  const indCurrentData = ref()
  const getCurrentData = (itemNo: string) => {
    indCurrentData.value.open(itemNo)
  }
  const indHistoryChart = ref()
  const getHistoryData = (raw: object) => {
    indHistoryChart.value.open(raw)
  }
  /** 删除按钮操作 */
  const handleDelete = async (id: number) => {
    try {