数据抽取配置
This commit is contained in:
parent
4e8b5e4e36
commit
3bdaded6ac
|
@ -132,7 +132,7 @@
|
||||||
<script lang="ts" name="home-screen" setup>
|
<script lang="ts" name="home-screen" setup>
|
||||||
import { onMounted, ref } from 'vue';
|
import { onMounted, ref } from 'vue';
|
||||||
import { Modal as AModal } from 'ant-design-vue';
|
import { Modal as AModal } from 'ant-design-vue';
|
||||||
import HeatanalysisListModal from '@/views/heating/HeatanalysisListModal.vue'
|
import HeatanalysisListModal from '@/views/heating/heatanalysis/HeatanalysisListModal.vue'
|
||||||
import { sourceList,heatanalysisList } from './api';
|
import { sourceList,heatanalysisList } from './api';
|
||||||
|
|
||||||
const list1 = ref();
|
const list1 = ref();
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
<div class="p-2">
|
<div class="p-2">
|
||||||
<!--查询区域-->
|
<!--查询区域-->
|
||||||
<div class="jeecg-basic-table-form-container">
|
<div class="jeecg-basic-table-form-container">
|
||||||
<a-form ref="formRef" @keyup.enter.native="searchQuery" :model="queryParam" :label-col="labelCol" :wrapper-col="wrapperCol">
|
<a-form @keyup.enter.native="searchQuery" :model="queryParam" :label-col="labelCol" :wrapper-col="wrapperCol">
|
||||||
<a-row :gutter="24">
|
<a-row :gutter="24">
|
||||||
<a-col :lg="4">
|
<a-col :lg="4">
|
||||||
<a-form-item>
|
<a-form-item>
|
||||||
|
@ -11,7 +11,6 @@
|
||||||
placeholder="请选择热力公司"
|
placeholder="请选择热力公司"
|
||||||
v-model:value="queryParam.companyId"
|
v-model:value="queryParam.companyId"
|
||||||
style="width: 150px"
|
style="width: 150px"
|
||||||
@focus="focus"
|
|
||||||
@change="handleChange1">
|
@change="handleChange1">
|
||||||
<a-select-option :value="item.id" v-for="item in thermalcompany" :key="item.id">{{item.companyName}}</a-select-option>
|
<a-select-option :value="item.id" v-for="item in thermalcompany" :key="item.id">{{item.companyName}}</a-select-option>
|
||||||
</a-select>
|
</a-select>
|
||||||
|
@ -24,7 +23,6 @@
|
||||||
placeholder="请选择热源站"
|
placeholder="请选择热源站"
|
||||||
v-model:value="queryParam.sourceId"
|
v-model:value="queryParam.sourceId"
|
||||||
style="width: 150px"
|
style="width: 150px"
|
||||||
@focus="focus"
|
|
||||||
@change="handleChange2">
|
@change="handleChange2">
|
||||||
<a-select-option :value="item.id" v-for="item in heatsource" :key="item.id">{{item.sourceName}}</a-select-option>
|
<a-select-option :value="item.id" v-for="item in heatsource" :key="item.id">{{item.sourceName}}</a-select-option>
|
||||||
</a-select>
|
</a-select>
|
||||||
|
@ -37,7 +35,6 @@
|
||||||
placeholder="请选择换热站"
|
placeholder="请选择换热站"
|
||||||
v-model:value="queryParam.stationId"
|
v-model:value="queryParam.stationId"
|
||||||
style="width: 250px"
|
style="width: 250px"
|
||||||
@focus="focus"
|
|
||||||
@change="handleChange3">
|
@change="handleChange3">
|
||||||
<a-select-option :value="item.id" v-for="item in heatsourcestation" :key="item.id">{{item.stationName}}</a-select-option>
|
<a-select-option :value="item.id" v-for="item in heatsourcestation" :key="item.id">{{item.stationName}}</a-select-option>
|
||||||
</a-select>
|
</a-select>
|
||||||
|
@ -137,26 +134,14 @@ import {ref, reactive, onMounted} from 'vue';
|
||||||
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||||
import { useListPage } from '/@/hooks/system/useListPage';
|
import { useListPage } from '/@/hooks/system/useListPage';
|
||||||
import { columns } from './DataExtractConfig.data';
|
import { columns } from './DataExtractConfig.data';
|
||||||
import { list, deleteOne, batchDelete, getImportUrl, getExportUrl } from './DataExtractConfig.api';
|
import { list, deleteOne, batchDelete, getImportUrl, getExportUrl, companylist, heatsourcelist, heatsourcestationlist } from './DataExtractConfig.api';
|
||||||
import { downloadFile } from '/@/utils/common/renderUtils';
|
import { downloadFile } from '/@/utils/common/renderUtils';
|
||||||
import DataExtractConfigModal from './components/DataExtractConfigModal.vue'
|
import DataExtractConfigModal from './components/DataExtractConfigModal.vue'
|
||||||
import { useUserStore } from '/@/store/modules/user';
|
import { useUserStore } from '/@/store/modules/user';
|
||||||
import {
|
|
||||||
companylist,
|
|
||||||
heatsourcelist,
|
|
||||||
heatsourcestationlist
|
|
||||||
} from "@/views/heating1/Heatanalysis.api";
|
|
||||||
|
|
||||||
const formRef = ref();
|
const queryParam = ref<any>({
|
||||||
const queryParam = reactive<any>({
|
|
||||||
companyId : '',
|
|
||||||
sourceId : '',
|
|
||||||
stationId : '',
|
|
||||||
sim : '',
|
|
||||||
flag: '',
|
flag: '',
|
||||||
onePipeSim : '',
|
|
||||||
onePipeType : '',
|
onePipeType : '',
|
||||||
twoPipeSim : '',
|
|
||||||
twoPipeType : '',
|
twoPipeType : '',
|
||||||
});
|
});
|
||||||
const registerModal = ref();
|
const registerModal = ref();
|
||||||
|
@ -234,6 +219,7 @@ import {
|
||||||
*/
|
*/
|
||||||
function handleEdit(record: Recordable) {
|
function handleEdit(record: Recordable) {
|
||||||
registerModal.value.disableSubmit = false;
|
registerModal.value.disableSubmit = false;
|
||||||
|
console.log(record);
|
||||||
registerModal.value.edit(record);
|
registerModal.value.edit(record);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -296,13 +282,21 @@ import {
|
||||||
* 重置
|
* 重置
|
||||||
*/
|
*/
|
||||||
function searchReset() {
|
function searchReset() {
|
||||||
formRef.value.resetFields();
|
queryParam.value = {
|
||||||
|
flag: '',
|
||||||
|
onePipeType : '',
|
||||||
|
twoPipeType : '',
|
||||||
|
};
|
||||||
selectedRowKeys.value = [];
|
selectedRowKeys.value = [];
|
||||||
|
|
||||||
|
getHeatsource();
|
||||||
|
getHeatsourcestation();
|
||||||
//刷新数据
|
//刷新数据
|
||||||
reload();
|
reload();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
const thermalcompany = ref();
|
const thermalcompany = ref();
|
||||||
async function getThermalcompany(){
|
async function getThermalcompany(){
|
||||||
thermalcompany.value = await companylist();
|
thermalcompany.value = await companylist();
|
||||||
|
|
|
@ -5,40 +5,185 @@
|
||||||
<a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol" name="DataExtractConfigForm">
|
<a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol" name="DataExtractConfigForm">
|
||||||
<a-row>
|
<a-row>
|
||||||
<a-col :span="24">
|
<a-col :span="24">
|
||||||
<a-form-item label="手机号" v-bind="validateInfos.sim" id="DataExtractConfigForm-sim" name="sim">
|
<a-row>
|
||||||
<a-input v-model:value="formData.sim" placeholder="请输入手机号" allow-clear ></a-input>
|
<a-col :span="20">
|
||||||
|
<a-form-item label="SIM" v-bind="validateInfos.sim" id="DataExtractConfigForm-sim" name="sim">
|
||||||
|
<a-input v-model:value="formData.sim" placeholder="请输入手机号">
|
||||||
|
<template #suffix >
|
||||||
|
<a-icon v-show="formData.sim!=''" type="close-circle" class="close-icon" @click="handleInputClear" />
|
||||||
|
</template>
|
||||||
|
</a-input>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
|
<a-col :span="4">
|
||||||
|
<a-button type="primary" preIcon="ant-design:search-outlined" @click="searchQuery">选取</a-button>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
<a-row>
|
||||||
<a-col :span="24">
|
<a-col :span="24">
|
||||||
<a-form-item label="一次网抽取sim卡号" v-bind="validateInfos.onePipeSim" id="DataExtractConfigForm-onePipeSim" name="onePipeSim">
|
<a-row>
|
||||||
<a-input v-model:value="formData.onePipeSim" placeholder="请输入一次网抽取sim卡号" allow-clear ></a-input>
|
<a-col :span="6" class="col-width-input">
|
||||||
|
<a-form-item label="" id="DataExtractConfigForm-company" name="company">
|
||||||
|
<a-input v-model:value="formData.company" allow-clear disabled="true"></a-input>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="6" class="col-width-input">
|
||||||
<a-form-item label="一次网抽取类型 0无 1一次网 2二次网" v-bind="validateInfos.onePipeType" id="DataExtractConfigForm-onePipeType" name="onePipeType">
|
<a-form-item label="" id="DataExtractConfigForm-source" name="source">
|
||||||
<a-input v-model:value="formData.onePipeType" placeholder="请输入一次网抽取类型 0无 1一次网 2二次网" allow-clear ></a-input>
|
<a-input v-model:value="formData.source" allow-clear disabled="true"></a-input>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12" class="col-width-input">
|
||||||
<a-form-item label="二次网抽取sim卡号" v-bind="validateInfos.twoPipeSim" id="DataExtractConfigForm-twoPipeSim" name="twoPipeSim">
|
<a-form-item label="" id="DataExtractConfigForm-station" name="station">
|
||||||
<a-input v-model:value="formData.twoPipeSim" placeholder="请输入二次网抽取sim卡号" allow-clear ></a-input>
|
<a-input v-model:value="formData.station" allow-clear disabled="true"></a-input>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
<a-row>
|
||||||
<a-col :span="24">
|
<a-col :span="24">
|
||||||
<a-form-item label="二次网抽取类型 0无 1一次网 2二次网" v-bind="validateInfos.twoPipeType" id="DataExtractConfigForm-twoPipeType" name="twoPipeType">
|
<a-row>
|
||||||
<a-input v-model:value="formData.twoPipeType" placeholder="请输入二次网抽取类型 0无 1一次网 2二次网" allow-clear ></a-input>
|
<a-col :span="20">
|
||||||
|
<a-form-item label="一次网抽取SIM" v-bind="validateInfos.onePipeSim" id="DataExtractConfigForm-onePipeSim" name="onePipeSim">
|
||||||
|
<a-input v-model:value="formData.onePipeSim" placeholder="请输入一次网抽取SIM">
|
||||||
|
<template #suffix >
|
||||||
|
<a-icon v-show="formData.onePipeSim!=''" type="close-circle" class="close-icon" @click="handleInputClearOne" />
|
||||||
|
</template>
|
||||||
|
</a-input>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
|
<a-col :span="4">
|
||||||
|
<a-button type="primary" preIcon="ant-design:search-outlined" @click="searchQueryOne">选取</a-button>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
<a-row>
|
||||||
<a-col :span="24">
|
<a-col :span="24">
|
||||||
<a-form-item label="是否生效 0失效 1生效" v-bind="validateInfos.flag" id="DataExtractConfigForm-flag" name="flag">
|
<a-row>
|
||||||
<a-input v-model:value="formData.flag" placeholder="请输入是否生效 0失效 1生效" allow-clear ></a-input>
|
<a-col :span="6" class="col-width-input">
|
||||||
|
<a-form-item label="" id="DataExtractConfigForm-company" name="oneCompany">
|
||||||
|
<a-input v-model:value="formData.oneCompany" allow-clear disabled="true"></a-input>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
|
<a-col :span="6" class="col-width-input">
|
||||||
|
<a-form-item label="" id="DataExtractConfigForm-source" name="oneSource">
|
||||||
|
<a-input v-model:value="formData.oneSource" allow-clear disabled="true"></a-input>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12" class="col-width-input">
|
||||||
|
<a-form-item label="" id="DataExtractConfigForm-station" name="oneStation">
|
||||||
|
<a-input v-model:value="formData.oneStation" allow-clear disabled="true"></a-input>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
<a-row>
|
||||||
|
<a-col :span="24">
|
||||||
|
<a-row>
|
||||||
|
<a-col :span="20">
|
||||||
|
<a-form-item label="一次网抽取类型" v-bind="validateInfos.onePipeType" id="DataExtractConfigForm-onePipeType" name="onePipeType">
|
||||||
|
<a-select ref="select"
|
||||||
|
placeholder="请选择一次网抽取类型"
|
||||||
|
v-model:value="formData.onePipeType"
|
||||||
|
style="width: 150px">
|
||||||
|
<a-select-option value="1">一次网</a-select-option>
|
||||||
|
<a-select-option value="2">二次网</a-select-option>
|
||||||
|
<a-select-option value="0">无</a-select-option>
|
||||||
|
</a-select>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="4">
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
<a-row>
|
||||||
|
<a-col :span="24">
|
||||||
|
<a-row>
|
||||||
|
<a-col :span="20">
|
||||||
|
<a-form-item label="二次网抽取SIM" v-bind="validateInfos.twoPipeSim" id="DataExtractConfigForm-twoPipeSim" name="twoPipeSim">
|
||||||
|
<a-input v-model:value="formData.twoPipeSim" placeholder="请输入二次网抽取SIM">
|
||||||
|
<template #suffix >
|
||||||
|
<a-icon v-show="formData.twoPipeSim!=''" type="close-circle" class="close-icon" @click="handleInputClearTwo" />
|
||||||
|
</template>
|
||||||
|
</a-input>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="4">
|
||||||
|
<a-button type="primary" preIcon="ant-design:search-outlined" @click="searchQueryTwo">选取</a-button>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
<a-row>
|
||||||
|
<a-col :span="24">
|
||||||
|
<a-row>
|
||||||
|
<a-col :span="6" class="col-width-input">
|
||||||
|
<a-form-item label="" id="DataExtractConfigForm-company" name="twoCompany">
|
||||||
|
<a-input v-model:value="formData.twoCompany" allow-clear disabled="true"></a-input>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="6" class="col-width-input">
|
||||||
|
<a-form-item label="" id="DataExtractConfigForm-source" name="twoSource">
|
||||||
|
<a-input v-model:value="formData.twoSource" allow-clear disabled="true"></a-input>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12" class="col-width-input">
|
||||||
|
<a-form-item label="" id="DataExtractConfigForm-station" name="twoStation">
|
||||||
|
<a-input v-model:value="formData.twoStation" allow-clear disabled="true"></a-input>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
<a-row>
|
||||||
|
<a-col :span="24">
|
||||||
|
<a-row>
|
||||||
|
<a-col :span="20">
|
||||||
|
<a-form-item label="二次网抽取类型" v-bind="validateInfos.twoPipeType" id="DataExtractConfigForm-twoPipeType" name="twoPipeType">
|
||||||
|
<a-select ref="select"
|
||||||
|
placeholder="请选择二次网抽取类型"
|
||||||
|
v-model:value="formData.twoPipeType"
|
||||||
|
style="width: 150px">
|
||||||
|
<a-select-option value="1">一次网</a-select-option>
|
||||||
|
<a-select-option value="2">二次网</a-select-option>
|
||||||
|
<a-select-option value="0">无</a-select-option>
|
||||||
|
</a-select>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="4">
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
<a-row>
|
||||||
|
<a-col :span="24">
|
||||||
|
<a-row>
|
||||||
|
<a-col :span="20">
|
||||||
|
<a-form-item label="是否生效" v-bind="validateInfos.flag" id="DataExtractConfigForm-flag" name="flag">
|
||||||
|
<a-select ref="select"
|
||||||
|
placeholder="请选择是否生效"
|
||||||
|
v-model:value="formData.flag"
|
||||||
|
style="width: 150px">
|
||||||
|
<a-select-option value="1">是</a-select-option>
|
||||||
|
<a-select-option value="0">否</a-select-option>
|
||||||
|
</a-select>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="4">
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-col>
|
||||||
</a-row>
|
</a-row>
|
||||||
</a-form>
|
</a-form>
|
||||||
</template>
|
</template>
|
||||||
</JFormContainer>
|
</JFormContainer>
|
||||||
</a-spin>
|
</a-spin>
|
||||||
|
<DataExtractStationModal ref="registerModal" @success="handleSuccess"></DataExtractStationModal>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
|
@ -49,22 +194,33 @@
|
||||||
import { saveOrUpdate } from '../DataExtractConfig.api';
|
import { saveOrUpdate } from '../DataExtractConfig.api';
|
||||||
import { Form } from 'ant-design-vue';
|
import { Form } from 'ant-design-vue';
|
||||||
import JFormContainer from '/@/components/Form/src/container/JFormContainer.vue';
|
import JFormContainer from '/@/components/Form/src/container/JFormContainer.vue';
|
||||||
|
import DataExtractStationModal from './station/DataExtractStationModal.vue'
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
formDisabled: { type: Boolean, default: false },
|
formDisabled: { type: Boolean, default: false },
|
||||||
formData: { type: Object, default: () => ({})},
|
formData: { type: Object, default: () => ({})},
|
||||||
formBpm: { type: Boolean, default: true }
|
formBpm: { type: Boolean, default: true }
|
||||||
});
|
});
|
||||||
const formRef = ref();
|
const formRef = ref();
|
||||||
|
const registerModal = ref();
|
||||||
const useForm = Form.useForm;
|
const useForm = Form.useForm;
|
||||||
const emit = defineEmits(['register', 'ok']);
|
const emit = defineEmits(['register', 'ok']);
|
||||||
const formData = reactive<Record<string, any>>({
|
const formData = reactive<Record<string, any>>({
|
||||||
id: '',
|
id: '',
|
||||||
sim: '',
|
sim: '',
|
||||||
|
company: '',
|
||||||
|
source: '',
|
||||||
|
station: '',
|
||||||
onePipeSim: '',
|
onePipeSim: '',
|
||||||
onePipeType: '',
|
onePipeType: '1',
|
||||||
|
oneCompany: '',
|
||||||
|
oneSource: '',
|
||||||
|
oneStation: '',
|
||||||
twoPipeSim: '',
|
twoPipeSim: '',
|
||||||
twoPipeType: '',
|
twoPipeType: '2',
|
||||||
flag: '',
|
twoCompany: '',
|
||||||
|
twoSource: '',
|
||||||
|
twoStation: '',
|
||||||
|
flag: '1',
|
||||||
});
|
});
|
||||||
const { createMessage } = useMessage();
|
const { createMessage } = useMessage();
|
||||||
const labelCol = ref<any>({ xs: { span: 24 }, sm: { span: 5 } });
|
const labelCol = ref<any>({ xs: { span: 24 }, sm: { span: 5 } });
|
||||||
|
@ -151,7 +307,7 @@
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
createMessage.success(res.message);
|
createMessage.success(res.message);
|
||||||
emit('ok');
|
emit('ok',);
|
||||||
} else {
|
} else {
|
||||||
createMessage.warning(res.message);
|
createMessage.warning(res.message);
|
||||||
}
|
}
|
||||||
|
@ -161,6 +317,70 @@
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function handleInputClear(){
|
||||||
|
formData.sim = '';
|
||||||
|
formData.company = '';
|
||||||
|
formData.source = '';
|
||||||
|
formData.station = '';
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleInputClearOne(){
|
||||||
|
formData.onePipeSim = '';
|
||||||
|
formData.oneCompany = '';
|
||||||
|
formData.oneSource = '';
|
||||||
|
formData.oneStation = '';
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleInputClearTwo(){
|
||||||
|
formData.twoPipeSim = '';
|
||||||
|
formData.twoCompany = '';
|
||||||
|
formData.twoSource = '';
|
||||||
|
formData.twoStation = '';
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询
|
||||||
|
*/
|
||||||
|
function searchQuery() {
|
||||||
|
registerModal.value.disableSubmit = true;
|
||||||
|
registerModal.value.type = 1;
|
||||||
|
registerModal.value.openModal();
|
||||||
|
}
|
||||||
|
|
||||||
|
function searchQueryOne() {
|
||||||
|
registerModal.value.disableSubmit = true;
|
||||||
|
registerModal.value.type = 2;
|
||||||
|
registerModal.value.openModal();
|
||||||
|
}
|
||||||
|
|
||||||
|
function searchQueryTwo() {
|
||||||
|
registerModal.value.disableSubmit = true;
|
||||||
|
registerModal.value.type = 3;
|
||||||
|
registerModal.value.openModal();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 成功回调
|
||||||
|
*/
|
||||||
|
function handleSuccess(record) {
|
||||||
|
const type = record.type;
|
||||||
|
if(type == 1){
|
||||||
|
formData.sim = record.sim;
|
||||||
|
formData.company = record.view001Name;
|
||||||
|
formData.source = record.view002Name;
|
||||||
|
formData.station = record.view004Name;
|
||||||
|
}else if(type == 2){
|
||||||
|
formData.onePipeSim = record.sim;
|
||||||
|
formData.oneCompany = record.view001Name;
|
||||||
|
formData.oneSource = record.view002Name;
|
||||||
|
formData.oneStation = record.view004Name;
|
||||||
|
}else if(type == 3){
|
||||||
|
formData.twoPipeSim = record.sim;
|
||||||
|
formData.twoCompany = record.view001Name;
|
||||||
|
formData.twoSource = record.view002Name;
|
||||||
|
formData.twoStation = record.view004Name;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
defineExpose({
|
defineExpose({
|
||||||
add,
|
add,
|
||||||
|
@ -173,4 +393,11 @@
|
||||||
.antd-modal-form {
|
.antd-modal-form {
|
||||||
padding: 14px;
|
padding: 14px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.col-width-input {
|
||||||
|
:deep(.ant-col-sm-16){
|
||||||
|
max-width: 90%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -0,0 +1,287 @@
|
||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<!--查询区域-->
|
||||||
|
<div class="jeecg-basic-table-form-container">
|
||||||
|
<a-form @keyup.enter.native="searchQuery" :model="queryParam" :label-col="labelCol" :wrapper-col="wrapperCol">
|
||||||
|
<a-row :gutter="24">
|
||||||
|
<a-col :lg="5">
|
||||||
|
<a-form-item label="SIM">
|
||||||
|
<a-input placeholder="请输入SIM" v-model:value="queryParam.sim"></a-input>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :lg="6">
|
||||||
|
<a-form-item label="热力公司">
|
||||||
|
<a-select ref="select"
|
||||||
|
placeholder="请选择热力公司"
|
||||||
|
v-model:value="queryParam.view001"
|
||||||
|
style="width: 150px"
|
||||||
|
@change="handleChange1">
|
||||||
|
<a-select-option :value="item.id" v-for="item in thermalcompany" :key="item.id">{{item.companyName}}</a-select-option>
|
||||||
|
</a-select>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :lg="6">
|
||||||
|
<a-form-item label="热源站">
|
||||||
|
<a-select ref="select"
|
||||||
|
placeholder="请选择热源站"
|
||||||
|
v-model:value="queryParam.view002"
|
||||||
|
style="width: 150px"
|
||||||
|
@change="handleChange2">
|
||||||
|
<a-select-option :value="item.id" v-for="item in heatsource" :key="item.id">{{item.sourceName}}</a-select-option>
|
||||||
|
</a-select>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :lg="7">
|
||||||
|
<a-form-item label="换热站">
|
||||||
|
<a-select ref="select"
|
||||||
|
placeholder="请选择换热站"
|
||||||
|
v-model:value="queryParam.view004"
|
||||||
|
style="width: 250px"
|
||||||
|
@change="handleChange3">
|
||||||
|
<a-select-option :value="item.id" v-for="item in heatsourcestation" :key="item.id">{{item.stationName}}</a-select-option>
|
||||||
|
</a-select>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
<a-row>
|
||||||
|
<a-col :lg="5">
|
||||||
|
<a-form-item label="上报类型">
|
||||||
|
<a-select ref="select"
|
||||||
|
placeholder="请选择类型"
|
||||||
|
v-model:value="queryParam.reportType"
|
||||||
|
style="width: 150px">
|
||||||
|
<a-select-option value="">全部</a-select-option>
|
||||||
|
<a-select-option value="1">自动上报</a-select-option>
|
||||||
|
<a-select-option value="2">定时模拟</a-select-option>
|
||||||
|
</a-select>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :lg="6">
|
||||||
|
<a-form-item label="已抽取">
|
||||||
|
<a-select ref="select"
|
||||||
|
placeholder="请选择是否抽取"
|
||||||
|
v-model:value="queryParam.isExtract"
|
||||||
|
style="width: 150px">
|
||||||
|
<a-select-option value="">全部</a-select-option>
|
||||||
|
<a-select-option value="0">否</a-select-option>
|
||||||
|
<a-select-option value="1">是</a-select-option>
|
||||||
|
</a-select>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :lg="6">
|
||||||
|
<a-form-item label="被抽取">
|
||||||
|
<a-select ref="select"
|
||||||
|
placeholder="请选择是否抽取"
|
||||||
|
v-model:value="queryParam.isExtracted"
|
||||||
|
style="width: 150px">
|
||||||
|
<a-select-option value="">全部</a-select-option>
|
||||||
|
<a-select-option value="0">否</a-select-option>
|
||||||
|
<a-select-option value="1">是</a-select-option>
|
||||||
|
</a-select>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :lg="7">
|
||||||
|
<span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
|
||||||
|
<a-button type="primary" preIcon="ant-design:search-outlined" @click="searchQuery">查询</a-button>
|
||||||
|
<a-button type="primary" preIcon="ant-design:reload-outlined" @click="searchReset" style="margin-left: 8px">重置</a-button>
|
||||||
|
</span>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-form>
|
||||||
|
</div>
|
||||||
|
<!--引用表格-->
|
||||||
|
<BasicTable @register="registerTable">
|
||||||
|
<template #reportType="{ record }">
|
||||||
|
<span v-if="record.reportType == 1">上报</span>
|
||||||
|
<a-tag v-else color="purple">模拟</a-tag>
|
||||||
|
</template>
|
||||||
|
<template #isExtract="{ record }">
|
||||||
|
<a-tag v-if="record.isExtract == 1" color="green" style="cursor:pointer" @click="showExtract(record)">是</a-tag>
|
||||||
|
<span v-else>否</span>
|
||||||
|
</template>
|
||||||
|
<template #isExtracted="{ record }">
|
||||||
|
<a-tag v-if="record.isExtracted > 0" color="pink" style="cursor:pointer" @click="showExtracted(record)">是</a-tag>
|
||||||
|
<span v-else>否</span>
|
||||||
|
</template>
|
||||||
|
<template #action="{ record }">
|
||||||
|
<TableAction :actions="getTableAction(record)"/>
|
||||||
|
</template>
|
||||||
|
</BasicTable>
|
||||||
|
|
||||||
|
<StationExtractModal ref="registerModal" @success="handleSuccess"></StationExtractModal>
|
||||||
|
<StationExtractedModal ref="registerModalExtracted" @success="handleSuccess"></StationExtractedModal>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" name="post.leve-blPostLeve" setup>
|
||||||
|
import {ref, computed, unref, reactive, onMounted} from 'vue';
|
||||||
|
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||||
|
import { useListPage } from '/@/hooks/system/useListPage';
|
||||||
|
import { columns } from './DataExtractStation.data';
|
||||||
|
import { list, companylist, heatsourcelist, heatsourcestationlist } from './DataExtractStation.api';
|
||||||
|
import StationExtractModal from './extract/StationExtractModal.vue';
|
||||||
|
import StationExtractedModal from './extracted/StationExtractedModal.vue';
|
||||||
|
const emit = defineEmits(['register', 'ok']);
|
||||||
|
const queryParam = ref<any>({});
|
||||||
|
const toggleSearchStatus = ref<boolean>(false);
|
||||||
|
const registerModal = ref();
|
||||||
|
const registerModalExtracted = ref();
|
||||||
|
//注册table数据
|
||||||
|
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||||
|
tableProps: {
|
||||||
|
title: '',
|
||||||
|
api: list,
|
||||||
|
columns,
|
||||||
|
canResize:false,
|
||||||
|
useSearchForm: false,
|
||||||
|
clickToRowSelect:false,
|
||||||
|
showIndexColumn:false,
|
||||||
|
striped:true,
|
||||||
|
// tableSetting:{
|
||||||
|
// // 是否显示刷新按钮
|
||||||
|
// redo: false,
|
||||||
|
// // 是否显示尺寸调整按钮
|
||||||
|
// size: false,
|
||||||
|
// // 是否显示字段调整按钮
|
||||||
|
// setting: false,
|
||||||
|
// // 是否显示全屏按钮
|
||||||
|
// fullScreen: false,
|
||||||
|
// },
|
||||||
|
showTableSetting: false,
|
||||||
|
beforeFetch: (params) => {
|
||||||
|
params.column = '',params.order = '';//新生成的默认不带排序
|
||||||
|
return Object.assign(params, queryParam.value);
|
||||||
|
},
|
||||||
|
},
|
||||||
|
});
|
||||||
|
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource }, { rowSelection, selectedRowKeys }] = tableContext;
|
||||||
|
const labelCol = reactive({
|
||||||
|
xs: { span: 24 },
|
||||||
|
sm: { span: 7 },
|
||||||
|
});
|
||||||
|
const wrapperCol = reactive({
|
||||||
|
xs: { span: 24 },
|
||||||
|
sm: { span: 16 },
|
||||||
|
});
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 抽取
|
||||||
|
*/
|
||||||
|
function handleEdit(record: Recordable) {
|
||||||
|
emit('ok',record);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 操作栏
|
||||||
|
*/
|
||||||
|
function getTableAction(record){
|
||||||
|
return [
|
||||||
|
{
|
||||||
|
label: '抽取',
|
||||||
|
onClick: handleEdit.bind(null, record),
|
||||||
|
},
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 成功回调
|
||||||
|
*/
|
||||||
|
function handleSuccess() {
|
||||||
|
(selectedRowKeys.value = []) && reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询
|
||||||
|
*/
|
||||||
|
function searchQuery() {
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询已抽取列表
|
||||||
|
*/
|
||||||
|
function showExtract(record) {
|
||||||
|
registerModal.value.disableSubmit = true;
|
||||||
|
registerModal.value.openModal(record);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询被抽取列表
|
||||||
|
*/
|
||||||
|
function showExtracted(record) {
|
||||||
|
registerModalExtracted.value.disableSubmit = true;
|
||||||
|
registerModalExtracted.value.openModal(record);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 重置
|
||||||
|
*/
|
||||||
|
function searchReset() {
|
||||||
|
queryParam.value = {};
|
||||||
|
selectedRowKeys.value = [];
|
||||||
|
getHeatsource();
|
||||||
|
getHeatsourcestation();
|
||||||
|
//刷新数据
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
const thermalcompany = ref();
|
||||||
|
async function getThermalcompany(){
|
||||||
|
thermalcompany.value = await companylist();
|
||||||
|
}
|
||||||
|
|
||||||
|
const heatsource = ref();
|
||||||
|
async function getHeatsource(){
|
||||||
|
heatsource.value = await heatsourcelist();
|
||||||
|
}
|
||||||
|
|
||||||
|
const heatsourcestation = ref();
|
||||||
|
async function getHeatsourcestation(){
|
||||||
|
heatsourcestation.value = await heatsourcestationlist();
|
||||||
|
}
|
||||||
|
|
||||||
|
async function handleChange1(record){
|
||||||
|
var params = {companyId:record};
|
||||||
|
heatsource.value = await heatsourcelist(params);
|
||||||
|
heatsourcestation.value = [];
|
||||||
|
}
|
||||||
|
async function handleChange2(record){
|
||||||
|
var params = {sourceId:record};
|
||||||
|
heatsourcestation.value = await heatsourcestationlist(params);
|
||||||
|
}
|
||||||
|
function handleChange3(record){
|
||||||
|
}
|
||||||
|
|
||||||
|
onMounted(() => {
|
||||||
|
getThermalcompany();
|
||||||
|
getHeatsource();
|
||||||
|
getHeatsourcestation();
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.jeecg-basic-table-form-container{
|
||||||
|
padding-top: 5px;
|
||||||
|
padding-bottom: 0px;
|
||||||
|
padding-left: 10px;
|
||||||
|
padding-right: 10px;
|
||||||
|
}
|
||||||
|
.jeecg-basic-table-form-container .ant-form {
|
||||||
|
padding: 5px 10px 0px 10px;
|
||||||
|
margin-bottom: 0px;
|
||||||
|
background-color: #ffffff;
|
||||||
|
border-radius: 2px;
|
||||||
|
}
|
||||||
|
.ant-form-item {
|
||||||
|
margin-bottom: 5px;
|
||||||
|
}
|
||||||
|
.ant-table-wrapper .ant-table.ant-table-middle .ant-table-tbody>tr>th {
|
||||||
|
padding: 2px 2px !important;
|
||||||
|
}
|
||||||
|
.ant-table-wrapper .ant-table.ant-table-middle .ant-table-tbody>tr>td {
|
||||||
|
padding: 2px 2px !important;;
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -0,0 +1,76 @@
|
||||||
|
import {defHttp} from '/@/utils/http/axios';
|
||||||
|
import { useMessage } from "/@/hooks/web/useMessage";
|
||||||
|
|
||||||
|
const { createConfirm } = useMessage();
|
||||||
|
|
||||||
|
enum Api {
|
||||||
|
list = '/heating/heatanalysis/page',
|
||||||
|
save='/heating/heatanalysis/add',
|
||||||
|
edit='/heating/heatanalysis/edit',
|
||||||
|
deleteOne = '/heating/heatanalysis/delete',
|
||||||
|
deleteBatch = '/heating/heatanalysis/deleteBatch',
|
||||||
|
importExcel = '/heating/heatanalysis/importExcel',
|
||||||
|
exportXls = '/heating/heatanalysis/exportXls',
|
||||||
|
companylist = '/heating/thermalcompany/list',
|
||||||
|
heatsourcelist = '/heating/heatsource/list',
|
||||||
|
heatsourcestationlist = '/heating/heatsourcestation/list',
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 导出apif
|
||||||
|
* @param params
|
||||||
|
*/
|
||||||
|
export const getExportUrl = Api.exportXls;
|
||||||
|
/**
|
||||||
|
* 导入api
|
||||||
|
*/
|
||||||
|
export const getImportUrl = Api.importExcel;
|
||||||
|
/**
|
||||||
|
* 列表接口
|
||||||
|
* @param params
|
||||||
|
*/
|
||||||
|
export const list = (params) =>
|
||||||
|
defHttp.get({url: Api.list, params});
|
||||||
|
|
||||||
|
export const companylist = (params) =>
|
||||||
|
defHttp.get({url: Api.companylist, params});
|
||||||
|
|
||||||
|
export const heatsourcelist = (params) =>
|
||||||
|
defHttp.get({url: Api.heatsourcelist, params});
|
||||||
|
|
||||||
|
export const heatsourcestationlist = (params) =>
|
||||||
|
defHttp.get({url: Api.heatsourcestationlist, params});
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除单个
|
||||||
|
*/
|
||||||
|
export const deleteOne = (params,handleSuccess) => {
|
||||||
|
return defHttp.delete({url: Api.deleteOne, params}, {joinParamsToUrl: true}).then(() => {
|
||||||
|
handleSuccess();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 批量删除
|
||||||
|
* @param params
|
||||||
|
*/
|
||||||
|
export const batchDelete = (params, handleSuccess) => {
|
||||||
|
createConfirm({
|
||||||
|
iconType: 'warning',
|
||||||
|
title: '确认删除',
|
||||||
|
content: '是否删除选中数据',
|
||||||
|
okText: '确认',
|
||||||
|
cancelText: '取消',
|
||||||
|
onOk: () => {
|
||||||
|
return defHttp.delete({url: Api.deleteBatch, data: params}, {joinParamsToUrl: true}).then(() => {
|
||||||
|
handleSuccess();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 保存或者更新
|
||||||
|
* @param params
|
||||||
|
*/
|
||||||
|
export const saveOrUpdate = (params, isUpdate) => {
|
||||||
|
let url = isUpdate ? Api.edit : Api.save;
|
||||||
|
return defHttp.post({url: url, params});
|
||||||
|
}
|
|
@ -0,0 +1,142 @@
|
||||||
|
import {BasicColumn} from '/@/components/Table';
|
||||||
|
import {FormSchema} from '/@/components/Table';
|
||||||
|
import { rules} from '/@/utils/helper/validator';
|
||||||
|
import { render } from '/@/utils/common/renderUtils';
|
||||||
|
//列表数据
|
||||||
|
export const columns: BasicColumn[] = [
|
||||||
|
{
|
||||||
|
title: 'SIM',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'sim',
|
||||||
|
width:120,
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '热力公司',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'view001Name',
|
||||||
|
width:140,
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '热源站',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'view002Name',
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '换热站',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'view004Name',
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '数据时间',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'datatime',
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title:'一次网',
|
||||||
|
width:100,
|
||||||
|
children:[
|
||||||
|
{
|
||||||
|
title: '供水温度',
|
||||||
|
align:"center",
|
||||||
|
width:120,
|
||||||
|
dataIndex: 'view005'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '回水温度',
|
||||||
|
align:"center",
|
||||||
|
width:120,
|
||||||
|
dataIndex: 'view006'
|
||||||
|
},
|
||||||
|
// {
|
||||||
|
// title: '供水压力',
|
||||||
|
// align:"center",
|
||||||
|
// width:120,
|
||||||
|
// dataIndex: 'view007'
|
||||||
|
// },
|
||||||
|
// {
|
||||||
|
// title: '回水压力',
|
||||||
|
// align:"center",
|
||||||
|
// width:120,
|
||||||
|
// dataIndex: 'view008'
|
||||||
|
// }
|
||||||
|
]},
|
||||||
|
{
|
||||||
|
title:'二次网',
|
||||||
|
width:100,
|
||||||
|
children:[
|
||||||
|
{
|
||||||
|
title: '供水温度',
|
||||||
|
align:"center",
|
||||||
|
width:120,
|
||||||
|
dataIndex: 'view009'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '回水温度',
|
||||||
|
align:"center",
|
||||||
|
width:120,
|
||||||
|
dataIndex: 'view010'
|
||||||
|
},
|
||||||
|
// {
|
||||||
|
// title: '供水压力',
|
||||||
|
// align:"center",
|
||||||
|
// width:120,
|
||||||
|
// dataIndex: 'view011'
|
||||||
|
// },
|
||||||
|
// {
|
||||||
|
// title: '回水压力',
|
||||||
|
// align:"center",
|
||||||
|
// width:120,
|
||||||
|
// dataIndex: 'view012'
|
||||||
|
// }
|
||||||
|
]},
|
||||||
|
{
|
||||||
|
title: '上报类型',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'reportType',
|
||||||
|
width:120,
|
||||||
|
ellipsis: false,
|
||||||
|
// customRender: ({ record }) =>{
|
||||||
|
// if(record.reportType == 1){
|
||||||
|
// return '上报'
|
||||||
|
// }else{
|
||||||
|
// return '模拟'
|
||||||
|
// }
|
||||||
|
// },
|
||||||
|
slots: { customRender: 'reportType' },
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '已抽取',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'isExtract',
|
||||||
|
width:120,
|
||||||
|
ellipsis: false,
|
||||||
|
// customRender: ({ record }) =>{
|
||||||
|
// if(record.isExtract == 1){
|
||||||
|
// return '是'
|
||||||
|
// }else{
|
||||||
|
// return '否'
|
||||||
|
// }
|
||||||
|
// },
|
||||||
|
slots: { customRender: 'isExtract' },
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '被抽取',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'isExtracted',
|
||||||
|
width:120,
|
||||||
|
ellipsis: false,
|
||||||
|
// customRender: ({ record }) =>{
|
||||||
|
// if(record.isExtracted > 0){
|
||||||
|
// return '是'
|
||||||
|
// }else{
|
||||||
|
// return '否'
|
||||||
|
// }
|
||||||
|
// },
|
||||||
|
slots: { customRender: 'isExtracted' },
|
||||||
|
},
|
||||||
|
];
|
|
@ -0,0 +1,63 @@
|
||||||
|
<template>
|
||||||
|
<a-modal :title="title" :width="width" :centered="true" :visible="visible" @ok="handleOk" :okButtonProps="{ class: { 'jee-hidden': disableSubmit } }" @cancel="handleCancel" cancelText="关闭">
|
||||||
|
<DataExtractStaionList ref="registerModal" @ok="submitCallback" :formDisabled="disableSubmit" :formType="type" :formBpm="false"></DataExtractStaionList>
|
||||||
|
</a-modal>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" setup>
|
||||||
|
import { ref, nextTick, defineExpose } from 'vue';
|
||||||
|
import DataExtractStaionList from './DataExtractStaionList.vue'
|
||||||
|
import {useModal} from "@/components/Modal";
|
||||||
|
|
||||||
|
const title = ref<string>('');
|
||||||
|
const width = ref<number>(2000);
|
||||||
|
const visible = ref<boolean>(false);
|
||||||
|
const disableSubmit = ref<boolean>(false);
|
||||||
|
const type = ref<string>('');
|
||||||
|
//注册model
|
||||||
|
const registerModal = ref();
|
||||||
|
const emit = defineEmits(['register', 'success']);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* form保存回调事件
|
||||||
|
*/
|
||||||
|
function submitCallback(record: Recordable) {
|
||||||
|
// handleCancel();
|
||||||
|
record.type = type.value;
|
||||||
|
visible.value = false;
|
||||||
|
emit('success',record);
|
||||||
|
}
|
||||||
|
|
||||||
|
function openModal(){
|
||||||
|
title.value = '站点选取';
|
||||||
|
visible.value = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 确定按钮点击事件
|
||||||
|
*/
|
||||||
|
function handleOk() {
|
||||||
|
registerModal.value.submitForm();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 取消按钮回调事件
|
||||||
|
*/
|
||||||
|
function handleCancel() {
|
||||||
|
visible.value = false;
|
||||||
|
emit('success');
|
||||||
|
}
|
||||||
|
|
||||||
|
defineExpose({
|
||||||
|
openModal,
|
||||||
|
disableSubmit,
|
||||||
|
type,
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
/**隐藏样式-modal确定按钮 */
|
||||||
|
.jee-hidden {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -0,0 +1,16 @@
|
||||||
|
import {defHttp} from '/@/utils/http/axios';
|
||||||
|
|
||||||
|
enum Api {
|
||||||
|
list1 = '/heating/heatanalysis/onePage',
|
||||||
|
list2 = '/heating/heatanalysis/twoPage',
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 列表接口
|
||||||
|
* @param params
|
||||||
|
*/
|
||||||
|
export const list1 = (params) =>
|
||||||
|
defHttp.get({url: Api.list1, params});
|
||||||
|
|
||||||
|
export const list2 = (params) =>
|
||||||
|
defHttp.get({url: Api.list2, params});
|
|
@ -0,0 +1,81 @@
|
||||||
|
import {BasicColumn} from '/@/components/Table';
|
||||||
|
import {FormSchema} from '/@/components/Table';
|
||||||
|
import { rules} from '/@/utils/helper/validator';
|
||||||
|
import { render } from '/@/utils/common/renderUtils';
|
||||||
|
//列表数据
|
||||||
|
export const columns: BasicColumn[] = [
|
||||||
|
{
|
||||||
|
title: 'SIM',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'sim',
|
||||||
|
width:120,
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '热力公司',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'view001Name',
|
||||||
|
width:140,
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '热源站',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'view002Name',
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '换热站',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'view004Name',
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '数据时间',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'datatime',
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title:'一次网',
|
||||||
|
width:100,
|
||||||
|
children:[
|
||||||
|
{
|
||||||
|
title: '供水温度',
|
||||||
|
align:"center",
|
||||||
|
width:120,
|
||||||
|
dataIndex: 'view005'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '回水温度',
|
||||||
|
align:"center",
|
||||||
|
width:120,
|
||||||
|
dataIndex: 'view006'
|
||||||
|
},
|
||||||
|
]},
|
||||||
|
{
|
||||||
|
title:'二次网',
|
||||||
|
width:100,
|
||||||
|
children:[
|
||||||
|
{
|
||||||
|
title: '供水温度',
|
||||||
|
align:"center",
|
||||||
|
width:120,
|
||||||
|
dataIndex: 'view009'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '回水温度',
|
||||||
|
align:"center",
|
||||||
|
width:120,
|
||||||
|
dataIndex: 'view010'
|
||||||
|
},
|
||||||
|
]},
|
||||||
|
{
|
||||||
|
title: '上报类型',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'reportType',
|
||||||
|
width:120,
|
||||||
|
ellipsis: false,
|
||||||
|
slots: { customRender: 'reportType' },
|
||||||
|
},
|
||||||
|
];
|
|
@ -0,0 +1,142 @@
|
||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<!--查询区域-->
|
||||||
|
<div class="jeecg-basic-table-form-container">
|
||||||
|
<a-row :gutter="24">
|
||||||
|
<a-col :lg="4">
|
||||||
|
<span title="热力公司" class="title">SIM: {{queryParam.sim}}</span>
|
||||||
|
</a-col>
|
||||||
|
<a-col :lg="5">
|
||||||
|
<span title="热力公司" class="title">热力公司: {{queryParam.view001Name}}</span>
|
||||||
|
</a-col>
|
||||||
|
<a-col :lg="6">
|
||||||
|
<span title="热源站" class="title">热源站: {{queryParam.view001Name}}</span>
|
||||||
|
</a-col>
|
||||||
|
<a-col :lg="7">
|
||||||
|
<span title="换热站" class="title">换热站: {{queryParam.view001Name}}</span>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</div>
|
||||||
|
<!--引用表格-->
|
||||||
|
<BasicTable @register="registerTable">
|
||||||
|
<template #reportType="{ record }">
|
||||||
|
<span v-if="record.reportType == 1">上报</span>
|
||||||
|
<a-tag v-else color="purple">模拟</a-tag>
|
||||||
|
</template>
|
||||||
|
</BasicTable>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" name="post.leve-blPostLeve" setup>
|
||||||
|
import {ref, reactive, onMounted, defineExpose} from 'vue';
|
||||||
|
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||||
|
import { useListPage } from '/@/hooks/system/useListPage'
|
||||||
|
import { columns } from './StationExtract.data';
|
||||||
|
import { list1 } from './StationExtract.api';
|
||||||
|
const queryParam = ref<any>({});
|
||||||
|
//注册table数据
|
||||||
|
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||||
|
tableProps: {
|
||||||
|
title: '抽取的一次网数据',
|
||||||
|
api: list1,
|
||||||
|
columns,
|
||||||
|
canResize:false,
|
||||||
|
useSearchForm: false,
|
||||||
|
clickToRowSelect:false,
|
||||||
|
showActionColumn:false,
|
||||||
|
showIndexColumn:false,
|
||||||
|
immediate: false, // 是否立即请求接口
|
||||||
|
striped:true,
|
||||||
|
tableSetting:{
|
||||||
|
// 是否显示刷新按钮
|
||||||
|
redo: false,
|
||||||
|
// 是否显示尺寸调整按钮
|
||||||
|
size: false,
|
||||||
|
// 是否显示字段调整按钮
|
||||||
|
setting: false,
|
||||||
|
// 是否显示全屏按钮
|
||||||
|
fullScreen: false,
|
||||||
|
},
|
||||||
|
beforeFetch: (params) => {
|
||||||
|
params.column = '',params.order = '';//新生成的默认不带排序
|
||||||
|
return Object.assign(params, queryParam.value);
|
||||||
|
},
|
||||||
|
},
|
||||||
|
});
|
||||||
|
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource }, { rowSelection, selectedRowKeys }] = tableContext;
|
||||||
|
const labelCol = reactive({
|
||||||
|
xs: { span: 24 },
|
||||||
|
sm: { span: 7 },
|
||||||
|
});
|
||||||
|
const wrapperCol = reactive({
|
||||||
|
xs: { span: 24 },
|
||||||
|
sm: { span: 16 },
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 成功回调
|
||||||
|
*/
|
||||||
|
function handleSuccess() {
|
||||||
|
(selectedRowKeys.value = []) && reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询
|
||||||
|
*/
|
||||||
|
function searchQuery() {
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 重置
|
||||||
|
*/
|
||||||
|
function searchReset() {
|
||||||
|
queryParam.value = {};
|
||||||
|
selectedRowKeys.value = [];
|
||||||
|
//刷新数据
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
onMounted(() => {
|
||||||
|
});
|
||||||
|
|
||||||
|
function setParams(record: Recordable){
|
||||||
|
queryParam.value = record;
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
defineExpose({
|
||||||
|
setParams
|
||||||
|
});
|
||||||
|
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.jeecg-basic-table-form-container{
|
||||||
|
padding-top: 5px;
|
||||||
|
padding-bottom: 0px;
|
||||||
|
padding-left: 10px;
|
||||||
|
padding-right: 10px;
|
||||||
|
}
|
||||||
|
.jeecg-basic-table-form-container .ant-form {
|
||||||
|
padding: 5px 10px 0px 10px;
|
||||||
|
margin-bottom: 0px;
|
||||||
|
background-color: #ffffff;
|
||||||
|
border-radius: 2px;
|
||||||
|
}
|
||||||
|
.ant-form-item {
|
||||||
|
margin-bottom: 5px;
|
||||||
|
}
|
||||||
|
.ant-table-wrapper .ant-table.ant-table-middle .ant-table-tbody>tr>th {
|
||||||
|
padding: 2px 2px !important;
|
||||||
|
}
|
||||||
|
.ant-table-wrapper .ant-table.ant-table-middle .ant-table-tbody>tr>td {
|
||||||
|
padding: 2px 2px !important;;
|
||||||
|
}
|
||||||
|
|
||||||
|
.title {
|
||||||
|
font-size: 18px;
|
||||||
|
font-weight: 600;
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -0,0 +1,120 @@
|
||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<!--引用表格-->
|
||||||
|
<BasicTable @register="registerTable">
|
||||||
|
<template #reportType="{ record }">
|
||||||
|
<span v-if="record.reportType == 1">上报</span>
|
||||||
|
<a-tag v-else color="purple">模拟</a-tag>
|
||||||
|
</template>
|
||||||
|
</BasicTable>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" name="post.leve-blPostLeve" setup>
|
||||||
|
import {ref, reactive, onMounted, defineExpose} from 'vue';
|
||||||
|
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||||
|
import { useListPage } from '/@/hooks/system/useListPage'
|
||||||
|
import { columns } from './StationExtract.data';
|
||||||
|
import { list2 } from './StationExtract.api';
|
||||||
|
const queryParam = ref<any>({});
|
||||||
|
//注册table数据
|
||||||
|
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||||
|
tableProps: {
|
||||||
|
title: '抽取的二次网数据',
|
||||||
|
api: list2,
|
||||||
|
columns,
|
||||||
|
canResize:false,
|
||||||
|
useSearchForm: false,
|
||||||
|
clickToRowSelect:false,
|
||||||
|
showActionColumn:false,
|
||||||
|
showIndexColumn:false,
|
||||||
|
immediate: false,// 是否立即请求接口
|
||||||
|
striped:true,
|
||||||
|
tableSetting:{
|
||||||
|
// 是否显示刷新按钮
|
||||||
|
redo: false,
|
||||||
|
// 是否显示尺寸调整按钮
|
||||||
|
size: false,
|
||||||
|
// 是否显示字段调整按钮
|
||||||
|
setting: false,
|
||||||
|
// 是否显示全屏按钮
|
||||||
|
fullScreen: false,
|
||||||
|
},
|
||||||
|
beforeFetch: (params) => {
|
||||||
|
params.column = '',params.order = '';//新生成的默认不带排序
|
||||||
|
return Object.assign(params, queryParam.value);
|
||||||
|
},
|
||||||
|
},
|
||||||
|
});
|
||||||
|
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource }, { rowSelection, selectedRowKeys }] = tableContext;
|
||||||
|
const labelCol = reactive({
|
||||||
|
xs: { span: 24 },
|
||||||
|
sm: { span: 7 },
|
||||||
|
});
|
||||||
|
const wrapperCol = reactive({
|
||||||
|
xs: { span: 24 },
|
||||||
|
sm: { span: 16 },
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 成功回调
|
||||||
|
*/
|
||||||
|
function handleSuccess() {
|
||||||
|
(selectedRowKeys.value = []) && reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询
|
||||||
|
*/
|
||||||
|
function searchQuery() {
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 重置
|
||||||
|
*/
|
||||||
|
function searchReset() {
|
||||||
|
queryParam.value = {};
|
||||||
|
selectedRowKeys.value = [];
|
||||||
|
//刷新数据
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
onMounted(() => {
|
||||||
|
});
|
||||||
|
|
||||||
|
function setParams(record: Recordable){
|
||||||
|
queryParam.value = record;
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
defineExpose({
|
||||||
|
setParams
|
||||||
|
});
|
||||||
|
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.jeecg-basic-table-form-container{
|
||||||
|
padding-top: 5px;
|
||||||
|
padding-bottom: 0px;
|
||||||
|
padding-left: 10px;
|
||||||
|
padding-right: 10px;
|
||||||
|
}
|
||||||
|
.jeecg-basic-table-form-container .ant-form {
|
||||||
|
padding: 5px 10px 0px 10px;
|
||||||
|
margin-bottom: 0px;
|
||||||
|
background-color: #ffffff;
|
||||||
|
border-radius: 2px;
|
||||||
|
}
|
||||||
|
.ant-form-item {
|
||||||
|
margin-bottom: 5px;
|
||||||
|
}
|
||||||
|
.ant-table-wrapper .ant-table.ant-table-middle .ant-table-tbody>tr>th {
|
||||||
|
padding: 2px 2px !important;
|
||||||
|
}
|
||||||
|
.ant-table-wrapper .ant-table.ant-table-middle .ant-table-tbody>tr>td {
|
||||||
|
padding: 2px 2px !important;;
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -0,0 +1,66 @@
|
||||||
|
<template>
|
||||||
|
<a-modal :title="title" :width="width" :centered="true" :visible="visible" @ok="handleOk" :okButtonProps="{ class: { 'jee-hidden': disableSubmit } }" @cancel="handleCancel" cancelText="关闭">
|
||||||
|
<StationExtractListOne ref="registerModalOne" @ok="submitCallback" :formDisabled="disableSubmit" :formBpm="false"></StationExtractListOne>
|
||||||
|
<StationExtractListTwo ref="registerModalTwo" @ok="submitCallback" :formDisabled="disableSubmit" :formBpm="false"></StationExtractListTwo>
|
||||||
|
</a-modal>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" setup>
|
||||||
|
import { ref, nextTick, defineExpose } from 'vue';
|
||||||
|
import StationExtractListOne from './StationExtractListOne.vue';
|
||||||
|
import StationExtractListTwo from './StationExtractListTwo.vue';
|
||||||
|
import {useModal} from "@/components/Modal";
|
||||||
|
|
||||||
|
const title = ref<string>('');
|
||||||
|
const width = ref<number>(1600);
|
||||||
|
const visible = ref<boolean>(false);
|
||||||
|
const disableSubmit = ref<boolean>(false);
|
||||||
|
//注册model
|
||||||
|
const registerModalOne = ref();
|
||||||
|
const registerModalTwo = ref();
|
||||||
|
const emit = defineEmits(['register', 'success']);
|
||||||
|
const record = ref<string>({});
|
||||||
|
/**
|
||||||
|
* form保存回调事件
|
||||||
|
*/
|
||||||
|
function submitCallback(record: Recordable) {
|
||||||
|
handleCancel();
|
||||||
|
emit('success');
|
||||||
|
}
|
||||||
|
|
||||||
|
function openModal(record: Recordable){
|
||||||
|
title.value = '已抽取数据';
|
||||||
|
visible.value = true;
|
||||||
|
nextTick(() => {
|
||||||
|
registerModalOne.value.setParams(record);
|
||||||
|
registerModalTwo.value.setParams(record);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 确定按钮点击事件
|
||||||
|
*/
|
||||||
|
function handleOk() {
|
||||||
|
// registerModal.value.submitForm();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 取消按钮回调事件
|
||||||
|
*/
|
||||||
|
function handleCancel() {
|
||||||
|
visible.value = false;
|
||||||
|
emit('success');
|
||||||
|
}
|
||||||
|
|
||||||
|
defineExpose({
|
||||||
|
openModal,
|
||||||
|
disableSubmit
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
/**隐藏样式-modal确定按钮 */
|
||||||
|
.jee-hidden {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -0,0 +1,16 @@
|
||||||
|
import {defHttp} from '/@/utils/http/axios';
|
||||||
|
|
||||||
|
enum Api {
|
||||||
|
list1 = '/heating/heatanalysis/extractedOnePage',
|
||||||
|
list2 = '/heating/heatanalysis/extractedTwoPage',
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 列表接口
|
||||||
|
* @param params
|
||||||
|
*/
|
||||||
|
export const list1 = (params) =>
|
||||||
|
defHttp.get({url: Api.list1, params});
|
||||||
|
|
||||||
|
export const list2 = (params) =>
|
||||||
|
defHttp.get({url: Api.list2, params});
|
|
@ -0,0 +1,81 @@
|
||||||
|
import {BasicColumn} from '/@/components/Table';
|
||||||
|
import {FormSchema} from '/@/components/Table';
|
||||||
|
import { rules} from '/@/utils/helper/validator';
|
||||||
|
import { render } from '/@/utils/common/renderUtils';
|
||||||
|
//列表数据
|
||||||
|
export const columns: BasicColumn[] = [
|
||||||
|
{
|
||||||
|
title: 'SIM',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'sim',
|
||||||
|
width:120,
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '热力公司',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'view001Name',
|
||||||
|
width:140,
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '热源站',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'view002Name',
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '换热站',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'view004Name',
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '数据时间',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'datatime',
|
||||||
|
ellipsis: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title:'一次网',
|
||||||
|
width:100,
|
||||||
|
children:[
|
||||||
|
{
|
||||||
|
title: '供水温度',
|
||||||
|
align:"center",
|
||||||
|
width:120,
|
||||||
|
dataIndex: 'view005'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '回水温度',
|
||||||
|
align:"center",
|
||||||
|
width:120,
|
||||||
|
dataIndex: 'view006'
|
||||||
|
},
|
||||||
|
]},
|
||||||
|
{
|
||||||
|
title:'二次网',
|
||||||
|
width:100,
|
||||||
|
children:[
|
||||||
|
{
|
||||||
|
title: '供水温度',
|
||||||
|
align:"center",
|
||||||
|
width:120,
|
||||||
|
dataIndex: 'view009'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '回水温度',
|
||||||
|
align:"center",
|
||||||
|
width:120,
|
||||||
|
dataIndex: 'view010'
|
||||||
|
},
|
||||||
|
]},
|
||||||
|
{
|
||||||
|
title: '上报类型',
|
||||||
|
align: "center",
|
||||||
|
dataIndex: 'reportType',
|
||||||
|
width:120,
|
||||||
|
ellipsis: false,
|
||||||
|
slots: { customRender: 'reportType' },
|
||||||
|
},
|
||||||
|
];
|
|
@ -0,0 +1,142 @@
|
||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<!--查询区域-->
|
||||||
|
<div class="jeecg-basic-table-form-container">
|
||||||
|
<a-row :gutter="24">
|
||||||
|
<a-col :lg="4">
|
||||||
|
<span title="热力公司" class="title">SIM: {{queryParam.sim}}</span>
|
||||||
|
</a-col>
|
||||||
|
<a-col :lg="5">
|
||||||
|
<span title="热力公司" class="title">热力公司: {{queryParam.view001Name}}</span>
|
||||||
|
</a-col>
|
||||||
|
<a-col :lg="6">
|
||||||
|
<span title="热源站" class="title">热源站: {{queryParam.view001Name}}</span>
|
||||||
|
</a-col>
|
||||||
|
<a-col :lg="7">
|
||||||
|
<span title="换热站" class="title">换热站: {{queryParam.view001Name}}</span>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</div>
|
||||||
|
<!--引用表格-->
|
||||||
|
<BasicTable @register="registerTable">
|
||||||
|
<template #reportType="{ record }">
|
||||||
|
<span v-if="record.reportType == 1">上报</span>
|
||||||
|
<a-tag v-else color="purple">模拟</a-tag>
|
||||||
|
</template>
|
||||||
|
</BasicTable>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" name="post.leve-blPostLeve" setup>
|
||||||
|
import {ref, reactive, onMounted, defineExpose} from 'vue';
|
||||||
|
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||||
|
import { useListPage } from '/@/hooks/system/useListPage'
|
||||||
|
import { columns } from './StationExtracted.data';
|
||||||
|
import { list1 } from './StationExtracted.api';
|
||||||
|
const queryParam = ref<any>({});
|
||||||
|
//注册table数据
|
||||||
|
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||||
|
tableProps: {
|
||||||
|
title: '被抽取的一次网数据',
|
||||||
|
api: list1,
|
||||||
|
columns,
|
||||||
|
canResize:false,
|
||||||
|
useSearchForm: false,
|
||||||
|
clickToRowSelect:false,
|
||||||
|
showActionColumn:false,
|
||||||
|
showIndexColumn:false,
|
||||||
|
immediate: false, // 是否立即请求接口
|
||||||
|
striped:true,
|
||||||
|
tableSetting:{
|
||||||
|
// 是否显示刷新按钮
|
||||||
|
redo: false,
|
||||||
|
// 是否显示尺寸调整按钮
|
||||||
|
size: false,
|
||||||
|
// 是否显示字段调整按钮
|
||||||
|
setting: false,
|
||||||
|
// 是否显示全屏按钮
|
||||||
|
fullScreen: false,
|
||||||
|
},
|
||||||
|
beforeFetch: (params) => {
|
||||||
|
params.column = '',params.order = '';//新生成的默认不带排序
|
||||||
|
return Object.assign(params, queryParam.value);
|
||||||
|
},
|
||||||
|
},
|
||||||
|
});
|
||||||
|
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource }, { rowSelection, selectedRowKeys }] = tableContext;
|
||||||
|
const labelCol = reactive({
|
||||||
|
xs: { span: 24 },
|
||||||
|
sm: { span: 7 },
|
||||||
|
});
|
||||||
|
const wrapperCol = reactive({
|
||||||
|
xs: { span: 24 },
|
||||||
|
sm: { span: 16 },
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 成功回调
|
||||||
|
*/
|
||||||
|
function handleSuccess() {
|
||||||
|
(selectedRowKeys.value = []) && reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询
|
||||||
|
*/
|
||||||
|
function searchQuery() {
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 重置
|
||||||
|
*/
|
||||||
|
function searchReset() {
|
||||||
|
queryParam.value = {};
|
||||||
|
selectedRowKeys.value = [];
|
||||||
|
//刷新数据
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
onMounted(() => {
|
||||||
|
});
|
||||||
|
|
||||||
|
function setParams(record: Recordable){
|
||||||
|
queryParam.value = record;
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
defineExpose({
|
||||||
|
setParams
|
||||||
|
});
|
||||||
|
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.jeecg-basic-table-form-container{
|
||||||
|
padding-top: 5px;
|
||||||
|
padding-bottom: 0px;
|
||||||
|
padding-left: 10px;
|
||||||
|
padding-right: 10px;
|
||||||
|
}
|
||||||
|
.jeecg-basic-table-form-container .ant-form {
|
||||||
|
padding: 5px 10px 0px 10px;
|
||||||
|
margin-bottom: 0px;
|
||||||
|
background-color: #ffffff;
|
||||||
|
border-radius: 2px;
|
||||||
|
}
|
||||||
|
.ant-form-item {
|
||||||
|
margin-bottom: 5px;
|
||||||
|
}
|
||||||
|
.ant-table-wrapper .ant-table.ant-table-middle .ant-table-tbody>tr>th {
|
||||||
|
padding: 2px 2px !important;
|
||||||
|
}
|
||||||
|
.ant-table-wrapper .ant-table.ant-table-middle .ant-table-tbody>tr>td {
|
||||||
|
padding: 2px 2px !important;;
|
||||||
|
}
|
||||||
|
|
||||||
|
.title {
|
||||||
|
font-size: 18px;
|
||||||
|
font-weight: 600;
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -0,0 +1,120 @@
|
||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<!--引用表格-->
|
||||||
|
<BasicTable @register="registerTable">
|
||||||
|
<template #reportType="{ record }">
|
||||||
|
<span v-if="record.reportType == 1">上报</span>
|
||||||
|
<a-tag v-else color="purple">模拟</a-tag>
|
||||||
|
</template>
|
||||||
|
</BasicTable>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" name="post.leve-blPostLeve" setup>
|
||||||
|
import {ref, reactive, onMounted, defineExpose} from 'vue';
|
||||||
|
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||||
|
import { useListPage } from '/@/hooks/system/useListPage'
|
||||||
|
import { columns } from './StationExtracted.data';
|
||||||
|
import { list2 } from './StationExtracted.api';
|
||||||
|
const queryParam = ref<any>({});
|
||||||
|
//注册table数据
|
||||||
|
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||||
|
tableProps: {
|
||||||
|
title: '被抽取的二次网数据',
|
||||||
|
api: list2,
|
||||||
|
columns,
|
||||||
|
canResize:false,
|
||||||
|
useSearchForm: false,
|
||||||
|
clickToRowSelect:false,
|
||||||
|
showActionColumn:false,
|
||||||
|
showIndexColumn:false,
|
||||||
|
immediate: false,// 是否立即请求接口
|
||||||
|
striped:true,
|
||||||
|
tableSetting:{
|
||||||
|
// 是否显示刷新按钮
|
||||||
|
redo: false,
|
||||||
|
// 是否显示尺寸调整按钮
|
||||||
|
size: false,
|
||||||
|
// 是否显示字段调整按钮
|
||||||
|
setting: false,
|
||||||
|
// 是否显示全屏按钮
|
||||||
|
fullScreen: false,
|
||||||
|
},
|
||||||
|
beforeFetch: (params) => {
|
||||||
|
params.column = '',params.order = '';//新生成的默认不带排序
|
||||||
|
return Object.assign(params, queryParam.value);
|
||||||
|
},
|
||||||
|
},
|
||||||
|
});
|
||||||
|
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource }, { rowSelection, selectedRowKeys }] = tableContext;
|
||||||
|
const labelCol = reactive({
|
||||||
|
xs: { span: 24 },
|
||||||
|
sm: { span: 7 },
|
||||||
|
});
|
||||||
|
const wrapperCol = reactive({
|
||||||
|
xs: { span: 24 },
|
||||||
|
sm: { span: 16 },
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 成功回调
|
||||||
|
*/
|
||||||
|
function handleSuccess() {
|
||||||
|
(selectedRowKeys.value = []) && reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询
|
||||||
|
*/
|
||||||
|
function searchQuery() {
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 重置
|
||||||
|
*/
|
||||||
|
function searchReset() {
|
||||||
|
queryParam.value = {};
|
||||||
|
selectedRowKeys.value = [];
|
||||||
|
//刷新数据
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
onMounted(() => {
|
||||||
|
});
|
||||||
|
|
||||||
|
function setParams(record: Recordable){
|
||||||
|
queryParam.value = record;
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
|
||||||
|
defineExpose({
|
||||||
|
setParams
|
||||||
|
});
|
||||||
|
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.jeecg-basic-table-form-container{
|
||||||
|
padding-top: 5px;
|
||||||
|
padding-bottom: 0px;
|
||||||
|
padding-left: 10px;
|
||||||
|
padding-right: 10px;
|
||||||
|
}
|
||||||
|
.jeecg-basic-table-form-container .ant-form {
|
||||||
|
padding: 5px 10px 0px 10px;
|
||||||
|
margin-bottom: 0px;
|
||||||
|
background-color: #ffffff;
|
||||||
|
border-radius: 2px;
|
||||||
|
}
|
||||||
|
.ant-form-item {
|
||||||
|
margin-bottom: 5px;
|
||||||
|
}
|
||||||
|
.ant-table-wrapper .ant-table.ant-table-middle .ant-table-tbody>tr>th {
|
||||||
|
padding: 2px 2px !important;
|
||||||
|
}
|
||||||
|
.ant-table-wrapper .ant-table.ant-table-middle .ant-table-tbody>tr>td {
|
||||||
|
padding: 2px 2px !important;;
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -0,0 +1,66 @@
|
||||||
|
<template>
|
||||||
|
<a-modal :title="title" :width="width" :centered="true" :visible="visible" @ok="handleOk" :okButtonProps="{ class: { 'jee-hidden': disableSubmit } }" @cancel="handleCancel" cancelText="关闭">
|
||||||
|
<StationExtractedListOne ref="registerModalOne" @ok="submitCallback" :formDisabled="disableSubmit" :formBpm="false"></StationExtractedListOne>
|
||||||
|
<StationExtractedListTwo ref="registerModalTwo" @ok="submitCallback" :formDisabled="disableSubmit" :formBpm="false"></StationExtractedListTwo>
|
||||||
|
</a-modal>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" setup>
|
||||||
|
import { ref, nextTick, defineExpose } from 'vue';
|
||||||
|
import StationExtractedListOne from './StationExtractedListOne.vue';
|
||||||
|
import StationExtractedListTwo from './StationExtractedListTwo.vue';
|
||||||
|
import {useModal} from "@/components/Modal";
|
||||||
|
|
||||||
|
const title = ref<string>('');
|
||||||
|
const width = ref<number>(1600);
|
||||||
|
const visible = ref<boolean>(false);
|
||||||
|
const disableSubmit = ref<boolean>(false);
|
||||||
|
//注册model
|
||||||
|
const registerModalOne = ref();
|
||||||
|
const registerModalTwo = ref();
|
||||||
|
const emit = defineEmits(['register', 'success']);
|
||||||
|
const record = ref<string>({});
|
||||||
|
/**
|
||||||
|
* form保存回调事件
|
||||||
|
*/
|
||||||
|
function submitCallback(record: Recordable) {
|
||||||
|
handleCancel();
|
||||||
|
emit('success');
|
||||||
|
}
|
||||||
|
|
||||||
|
function openModal(record: Recordable){
|
||||||
|
title.value = '被抽取数据';
|
||||||
|
visible.value = true;
|
||||||
|
nextTick(() => {
|
||||||
|
registerModalOne.value.setParams(record);
|
||||||
|
registerModalTwo.value.setParams(record);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 确定按钮点击事件
|
||||||
|
*/
|
||||||
|
function handleOk() {
|
||||||
|
// registerModal.value.submitForm();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 取消按钮回调事件
|
||||||
|
*/
|
||||||
|
function handleCancel() {
|
||||||
|
visible.value = false;
|
||||||
|
emit('success');
|
||||||
|
}
|
||||||
|
|
||||||
|
defineExpose({
|
||||||
|
openModal,
|
||||||
|
disableSubmit
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
/**隐藏样式-modal确定按钮 */
|
||||||
|
.jee-hidden {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -82,12 +82,7 @@ import {ref, reactive, onMounted} from 'vue';
|
||||||
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||||
import { useListPage } from '/@/hooks/system/useListPage';
|
import { useListPage } from '/@/hooks/system/useListPage';
|
||||||
import { columns } from './Heatanalysis.data';
|
import { columns } from './Heatanalysis.data';
|
||||||
import { list } from './Heatanalysis.api';
|
import { list, companylist, heatsourcelist, heatsourcestationlist } from './Heatanalysis.api';
|
||||||
import {
|
|
||||||
companylist,
|
|
||||||
heatsourcelist,
|
|
||||||
heatsourcestationlist
|
|
||||||
} from "@/views/heating1/Heatanalysis.api";
|
|
||||||
|
|
||||||
const queryParam = ref<any>({});
|
const queryParam = ref<any>({});
|
||||||
const toggleSearchStatus = ref<boolean>(false);
|
const toggleSearchStatus = ref<boolean>(false);
|
||||||
|
|
|
@ -134,7 +134,7 @@
|
||||||
<script lang="ts" name="home-screen" setup>
|
<script lang="ts" name="home-screen" setup>
|
||||||
import { onMounted, ref } from 'vue';
|
import { onMounted, ref } from 'vue';
|
||||||
import { Modal as AModal } from 'ant-design-vue';
|
import { Modal as AModal } from 'ant-design-vue';
|
||||||
import HeatanalysisListModal from '@/views/heating/HeatanalysisListModal.vue'
|
import HeatanalysisListModal from '@/views/heating/heatanalysis/HeatanalysisListModal.vue'
|
||||||
import { sourceList,heatanalysisList } from './home.api';
|
import { sourceList,heatanalysisList } from './home.api';
|
||||||
|
|
||||||
const list1 = ref();
|
const list1 = ref();
|
||||||
|
|
Loading…
Reference in New Issue