diff --git a/src/api/dataCollection/powerPlant.ts b/src/api/dataCollection/powerPlant.ts new file mode 100644 index 00000000..18cc2d18 --- /dev/null +++ b/src/api/dataCollection/powerPlant.ts @@ -0,0 +1,47 @@ +import request from '@/utils/request'; +import type { AxiosPromise } from 'axios'; + +/** 电厂信息 */ +export interface PowerPlantInfo { + plantId?: number; + plantCode: string; + plantName: string; + plantShortName?: string; + plantType?: string; + installedCapacity?: number; + address?: string; + ownerUnit?: string; + operationDate?: string; + remark?: string; + createTime?: string; +} + +/** 分页查询 */ +export function listPowerPlant(query: any) { + return request({ url: '/dataCollection/powerPlant/list', method: 'get', params: query }); +} + +/** 查询详情 */ +export function getPowerPlant(plantId: number) { + return request({ url: '/dataCollection/powerPlant/' + plantId, method: 'get' }); +} + +/** 新增 */ +export function addPowerPlant(data: PowerPlantInfo) { + return request({ url: '/dataCollection/powerPlant', method: 'post', data }); +} + +/** 修改 */ +export function updatePowerPlant(data: PowerPlantInfo) { + return request({ url: '/dataCollection/powerPlant', method: 'put', data }); +} + +/** 删除 */ +export function delPowerPlant(plantIds: number | number[]) { + return request({ url: '/dataCollection/powerPlant/' + plantIds, method: 'delete' }); +} + +/** 导出 */ +export function exportPowerPlant(query: any) { + return request({ url: '/dataCollection/powerPlant/export', method: 'post', params: query, responseType: 'blob' }); +} diff --git a/src/views/phaseOne/dataCollection/powerPlant/index.vue b/src/views/phaseOne/dataCollection/powerPlant/index.vue new file mode 100644 index 00000000..8590e647 --- /dev/null +++ b/src/views/phaseOne/dataCollection/powerPlant/index.vue @@ -0,0 +1,314 @@ + + +