|
@@ -1,12 +1,13 @@
|
|
<script setup>
|
|
<script setup>
|
|
import { dayjs } from 'element-plus';
|
|
import { dayjs } from 'element-plus';
|
|
-import { getContinuousAssayList } from '@/api/report/lab';
|
|
|
|
|
|
+import { getContinuousAssayList, getDeviceList } from '@/api/report/lab';
|
|
|
|
|
|
const { proxy } = getCurrentInstance();
|
|
const { proxy } = getCurrentInstance();
|
|
|
|
|
|
const queryParams = ref({
|
|
const queryParams = ref({
|
|
pageNum: 1,
|
|
pageNum: 1,
|
|
pageSize: 10,
|
|
pageSize: 10,
|
|
|
|
+ deviceNo: '',
|
|
activeRadioName: 'week'
|
|
activeRadioName: 'week'
|
|
});
|
|
});
|
|
|
|
|
|
@@ -18,6 +19,7 @@ const tempDataValue = ref({timeBegin: dayjs(new Date()).startOf('week').format('
|
|
|
|
|
|
const tableData = ref([]);
|
|
const tableData = ref([]);
|
|
const columns = ref([]);
|
|
const columns = ref([]);
|
|
|
|
+const options = ref([]);
|
|
|
|
|
|
const format = computed(() => {
|
|
const format = computed(() => {
|
|
return queryParams.value.activeRadioName === 'week' ? tempDataValue.value.timeBegin + ' 第 ww 周' : 'YYYY-MM'
|
|
return queryParams.value.activeRadioName === 'week' ? tempDataValue.value.timeBegin + ' 第 ww 周' : 'YYYY-MM'
|
|
@@ -53,207 +55,7 @@ const initPageData = async() => {
|
|
tableLoading.value = true;
|
|
tableLoading.value = true;
|
|
loading.value = true;
|
|
loading.value = true;
|
|
const dateResult = getStartTimeAndEndTime();
|
|
const dateResult = getStartTimeAndEndTime();
|
|
- const { data } = await getContinuousAssayList({...dateResult});
|
|
|
|
- // const data = {
|
|
|
|
- // "二段1池": {
|
|
|
|
- // "正磷酸盐": [
|
|
|
|
- // {
|
|
|
|
- // "assayName": "正磷酸盐",
|
|
|
|
- // "assayCounts": 1,
|
|
|
|
- // "minVal": 1.04,
|
|
|
|
- // "maxVal": 1.04,
|
|
|
|
- // "passedRates": "100.0%",
|
|
|
|
- // "bx": "90.00%",
|
|
|
|
- // "ratesDeviation": "10.00%",
|
|
|
|
- // "unitPrice": null,
|
|
|
|
- // "totalPrice": null
|
|
|
|
- // }
|
|
|
|
- // ],
|
|
|
|
- // "硝酸盐氮": [
|
|
|
|
- // {
|
|
|
|
- // "assayName": "硝酸盐氮",
|
|
|
|
- // "assayCounts": 1,
|
|
|
|
- // "minVal": 8.87,
|
|
|
|
- // "maxVal": 8.87,
|
|
|
|
- // "passedRates": "100.0%",
|
|
|
|
- // "bx": "90.00%",
|
|
|
|
- // "ratesDeviation": "10.00%",
|
|
|
|
- // "unitPrice": null,
|
|
|
|
- // "totalPrice": null
|
|
|
|
- // }
|
|
|
|
- // ]
|
|
|
|
- // },
|
|
|
|
- // "回流一池": {
|
|
|
|
- // "正磷酸盐": [
|
|
|
|
- // {
|
|
|
|
- // "assayName": "正磷酸盐",
|
|
|
|
- // "assayCounts": 3,
|
|
|
|
- // "minVal": 1.85,
|
|
|
|
- // "maxVal": 2.16,
|
|
|
|
- // "passedRates": "100.0%",
|
|
|
|
- // "bx": "90.00%",
|
|
|
|
- // "ratesDeviation": "10.00%",
|
|
|
|
- // "unitPrice": null,
|
|
|
|
- // "totalPrice": null
|
|
|
|
- // }
|
|
|
|
- // ],
|
|
|
|
- // "硝酸盐氮": [
|
|
|
|
- // {
|
|
|
|
- // "assayName": "硝酸盐氮",
|
|
|
|
- // "assayCounts": 5,
|
|
|
|
- // "minVal": 9.81,
|
|
|
|
- // "maxVal": 11,
|
|
|
|
- // "passedRates": "100.0%",
|
|
|
|
- // "bx": "90.00%",
|
|
|
|
- // "ratesDeviation": "10.00%",
|
|
|
|
- // "unitPrice": null,
|
|
|
|
- // "totalPrice": null
|
|
|
|
- // }
|
|
|
|
- // ]
|
|
|
|
- // },
|
|
|
|
- // "缺氧二池": {
|
|
|
|
- // "氨氮": [
|
|
|
|
- // {
|
|
|
|
- // "assayName": "氨氮",
|
|
|
|
- // "assayCounts": 2,
|
|
|
|
- // "minVal": 13.59,
|
|
|
|
- // "maxVal": 13.61,
|
|
|
|
- // "passedRates": "100.0%",
|
|
|
|
- // "bx": "90.00%",
|
|
|
|
- // "ratesDeviation": "10.00%",
|
|
|
|
- // "unitPrice": null,
|
|
|
|
- // "totalPrice": null
|
|
|
|
- // }
|
|
|
|
- // ],
|
|
|
|
- // "硝酸盐氮": [
|
|
|
|
- // {
|
|
|
|
- // "assayName": "硝酸盐氮",
|
|
|
|
- // "assayCounts": 5,
|
|
|
|
- // "minVal": 0.49,
|
|
|
|
- // "maxVal": 0.64,
|
|
|
|
- // "passedRates": "100.0%",
|
|
|
|
- // "bx": "90.00%",
|
|
|
|
- // "ratesDeviation": "10.00%",
|
|
|
|
- // "unitPrice": null,
|
|
|
|
- // "totalPrice": null
|
|
|
|
- // }
|
|
|
|
- // ]
|
|
|
|
- // },
|
|
|
|
- // "二沉池": {
|
|
|
|
- // "正磷酸盐": [
|
|
|
|
- // {
|
|
|
|
- // "assayName": "正磷酸盐",
|
|
|
|
- // "assayCounts": 3,
|
|
|
|
- // "minVal": 0.39,
|
|
|
|
- // "maxVal": 0.8,
|
|
|
|
- // "passedRates": "100.0%",
|
|
|
|
- // "bx": "90.00%",
|
|
|
|
- // "ratesDeviation": "10.00%",
|
|
|
|
- // "unitPrice": null,
|
|
|
|
- // "totalPrice": null
|
|
|
|
- // }
|
|
|
|
- // ]
|
|
|
|
- // },
|
|
|
|
- // "回流二池": {
|
|
|
|
- // "正磷酸盐": [
|
|
|
|
- // {
|
|
|
|
- // "assayName": "正磷酸盐",
|
|
|
|
- // "assayCounts": 3,
|
|
|
|
- // "minVal": 2.08,
|
|
|
|
- // "maxVal": 2.44,
|
|
|
|
- // "passedRates": "100.0%",
|
|
|
|
- // "bx": "90.00%",
|
|
|
|
- // "ratesDeviation": "10.00%",
|
|
|
|
- // "unitPrice": null,
|
|
|
|
- // "totalPrice": null
|
|
|
|
- // }
|
|
|
|
- // ],
|
|
|
|
- // "硝酸盐氮": [
|
|
|
|
- // {
|
|
|
|
- // "assayName": "硝酸盐氮",
|
|
|
|
- // "assayCounts": 5,
|
|
|
|
- // "minVal": 11.43,
|
|
|
|
- // "maxVal": 12.22,
|
|
|
|
- // "passedRates": "100.0%",
|
|
|
|
- // "bx": "90.00%",
|
|
|
|
- // "ratesDeviation": "10.00%",
|
|
|
|
- // "unitPrice": null,
|
|
|
|
- // "totalPrice": null
|
|
|
|
- // }
|
|
|
|
- // ]
|
|
|
|
- // },
|
|
|
|
- // "缺氧一池": {
|
|
|
|
- // "氨氮": [
|
|
|
|
- // {
|
|
|
|
- // "assayName": "氨氮",
|
|
|
|
- // "assayCounts": 2,
|
|
|
|
- // "minVal": 11.9,
|
|
|
|
- // "maxVal": 11.97,
|
|
|
|
- // "passedRates": "100.0%",
|
|
|
|
- // "bx": "90.00%",
|
|
|
|
- // "ratesDeviation": "10.00%",
|
|
|
|
- // "unitPrice": null,
|
|
|
|
- // "totalPrice": null
|
|
|
|
- // }
|
|
|
|
- // ],
|
|
|
|
- // "硝酸盐氮": [
|
|
|
|
- // {
|
|
|
|
- // "assayName": "硝酸盐氮",
|
|
|
|
- // "assayCounts": 5,
|
|
|
|
- // "minVal": 0.52,
|
|
|
|
- // "maxVal": 0.62,
|
|
|
|
- // "passedRates": "100.0%",
|
|
|
|
- // "bx": "90.00%",
|
|
|
|
- // "ratesDeviation": "10.00%",
|
|
|
|
- // "unitPrice": null,
|
|
|
|
- // "totalPrice": null
|
|
|
|
- // }
|
|
|
|
- // ]
|
|
|
|
- // },
|
|
|
|
- // "二段2池": {
|
|
|
|
- // "正磷酸盐": [
|
|
|
|
- // {
|
|
|
|
- // "assayName": "正磷酸盐",
|
|
|
|
- // "assayCounts": 1,
|
|
|
|
- // "minVal": 1.55,
|
|
|
|
- // "maxVal": 1.55,
|
|
|
|
- // "passedRates": "100.0%",
|
|
|
|
- // "bx": "90.00%",
|
|
|
|
- // "ratesDeviation": "10.00%",
|
|
|
|
- // "unitPrice": null,
|
|
|
|
- // "totalPrice": null
|
|
|
|
- // }
|
|
|
|
- // ],
|
|
|
|
- // "硝酸盐氮": [
|
|
|
|
- // {
|
|
|
|
- // "assayName": "硝酸盐氮",
|
|
|
|
- // "assayCounts": 1,
|
|
|
|
- // "minVal": 8.24,
|
|
|
|
- // "maxVal": 8.24,
|
|
|
|
- // "passedRates": "100.0%",
|
|
|
|
- // "bx": "90.00%",
|
|
|
|
- // "ratesDeviation": "10.00%",
|
|
|
|
- // "unitPrice": null,
|
|
|
|
- // "totalPrice": null
|
|
|
|
- // }
|
|
|
|
- // ]
|
|
|
|
- // },
|
|
|
|
- // "total": {
|
|
|
|
- // "合计": [
|
|
|
|
- // {
|
|
|
|
- // "assayName": null,
|
|
|
|
- // "assayCounts": 37,
|
|
|
|
- // "minVal": null,
|
|
|
|
- // "maxVal": null,
|
|
|
|
- // "passedRates": null,
|
|
|
|
- // "bx": "90.00%",
|
|
|
|
- // "ratesDeviation": "10.00%",
|
|
|
|
- // "unitPrice": null,
|
|
|
|
- // "totalPrice": null
|
|
|
|
- // }
|
|
|
|
- // ]
|
|
|
|
- // }
|
|
|
|
- // }
|
|
|
|
|
|
+ const { data } = await getContinuousAssayList({...dateResult, deviceNo: queryParams.value.deviceNo});
|
|
|
|
|
|
const whiteTableList = [
|
|
const whiteTableList = [
|
|
// { title: '检测指标', key: 'assayName' },
|
|
// { title: '检测指标', key: 'assayName' },
|
|
@@ -320,7 +122,13 @@ const handleExport = () => {
|
|
}, `${new Date().getTime()}.xlsx`);
|
|
}, `${new Date().getTime()}.xlsx`);
|
|
}
|
|
}
|
|
|
|
|
|
-onMounted(() => {
|
|
|
|
|
|
+onMounted(async() => {
|
|
|
|
+ getDeviceList().then(({ data }) => {
|
|
|
|
+ // const [ item ] = data;
|
|
|
|
+ // queryParams.value.deviceNo = item?.deviceNo;
|
|
|
|
+ options.value = data
|
|
|
|
+ });
|
|
|
|
+
|
|
initPageData();
|
|
initPageData();
|
|
})
|
|
})
|
|
</script>
|
|
</script>
|
|
@@ -335,7 +143,14 @@ onMounted(() => {
|
|
</p>
|
|
</p>
|
|
</template>
|
|
</template>
|
|
<el-row class="pt-[5px]" justify="space-between" :gutter="20">
|
|
<el-row class="pt-[5px]" justify="space-between" :gutter="20">
|
|
- <el-col :span="18">
|
|
|
|
|
|
+ <el-col :span="6">
|
|
|
|
+ <el-form-item label="设备编号">
|
|
|
|
+ <el-select v-model="queryParams.deviceNo" placeholder="请选择" filterable>
|
|
|
|
+ <el-option v-for="item in options" :key="item.deviceNo" :label="item.deviceName" :value="item.deviceNo" />
|
|
|
|
+ </el-select>
|
|
|
|
+ </el-form-item>
|
|
|
|
+ </el-col>
|
|
|
|
+ <el-col :span="12">
|
|
<div class="flex items-center space-x-[20px]">
|
|
<div class="flex items-center space-x-[20px]">
|
|
<el-form-item label="统计时段">
|
|
<el-form-item label="统计时段">
|
|
<el-radio-group v-model="queryParams.activeRadioName" @change="onRadioChange">
|
|
<el-radio-group v-model="queryParams.activeRadioName" @change="onRadioChange">
|
|
@@ -346,7 +161,6 @@ onMounted(() => {
|
|
<el-form-item :label="label">
|
|
<el-form-item :label="label">
|
|
<el-date-picker
|
|
<el-date-picker
|
|
v-model="datePickerValue"
|
|
v-model="datePickerValue"
|
|
- style="width: 300px"
|
|
|
|
:editable="false"
|
|
:editable="false"
|
|
:clearable="false"
|
|
:clearable="false"
|
|
:type="queryParams.activeRadioName"
|
|
:type="queryParams.activeRadioName"
|
|
@@ -357,7 +171,7 @@ onMounted(() => {
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</div>
|
|
</div>
|
|
</el-col>
|
|
</el-col>
|
|
- <el-col :span="6">
|
|
|
|
|
|
+ <el-col :span="4">
|
|
<div class="flex justify-end">
|
|
<div class="flex justify-end">
|
|
<el-button type="primary" @click="handlerQuery" :loading="loading">查询</el-button>
|
|
<el-button type="primary" @click="handlerQuery" :loading="loading">查询</el-button>
|
|
<el-button @click="handlerReset" :loading="loading">重置</el-button>
|
|
<el-button @click="handlerReset" :loading="loading">重置</el-button>
|