水电表基本搭建完成
This commit is contained in:
63
src/api/system/SdbBill/index.ts
Normal file
63
src/api/system/SdbBill/index.ts
Normal file
@@ -0,0 +1,63 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
import { BillVO, BillForm, BillQuery } from './type';
|
||||
|
||||
/**
|
||||
* 查询账单管理列表
|
||||
* @param query
|
||||
* @returns {*}
|
||||
*/
|
||||
|
||||
export const listBill = (query?: BillQuery): AxiosPromise<BillVO[]> => {
|
||||
return request({
|
||||
url: '/bill/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询账单管理详细
|
||||
* @param id
|
||||
*/
|
||||
export const getBill = (id: string | number): AxiosPromise<BillVO> => {
|
||||
return request({
|
||||
url: '/bill/' + id,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 新增账单管理
|
||||
* @param data
|
||||
*/
|
||||
export const addBill = (data: BillForm) => {
|
||||
return request({
|
||||
url: '/bill',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 修改账单管理
|
||||
* @param data
|
||||
*/
|
||||
export const updateBill = (data: BillForm) => {
|
||||
return request({
|
||||
url: '/bill',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 删除账单管理
|
||||
* @param id
|
||||
*/
|
||||
export const delBill = (id: string | number | Array<string | number>) => {
|
||||
return request({
|
||||
url: '/bill/' + id,
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
150
src/api/system/SdbBill/type.ts
Normal file
150
src/api/system/SdbBill/type.ts
Normal file
@@ -0,0 +1,150 @@
|
||||
export interface BillVO {
|
||||
/**
|
||||
* 账单管理表id
|
||||
*/
|
||||
id: string;
|
||||
|
||||
/**
|
||||
* 账单编号
|
||||
*/
|
||||
billCode: string;
|
||||
|
||||
/**
|
||||
* 收费项目id
|
||||
*/
|
||||
chargeItemId: string;
|
||||
|
||||
/**
|
||||
* 收费范围 0全体业主 1部分业主
|
||||
*/
|
||||
chargeScope: string;
|
||||
|
||||
/**
|
||||
* 收费周期 0年 1月 2日
|
||||
*/
|
||||
chargePeriod: string;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
startDate: string;
|
||||
|
||||
/**
|
||||
* 结束日期
|
||||
*/
|
||||
endDate: string;
|
||||
|
||||
/**
|
||||
* 小区id
|
||||
*/
|
||||
villageId: number;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
remark: string;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
cerateTime: string;
|
||||
}
|
||||
|
||||
export interface BillForm extends BaseEntity {
|
||||
/**
|
||||
* 账单管理表id
|
||||
*/
|
||||
id?: string | number;
|
||||
|
||||
/**
|
||||
* 账单编号
|
||||
*/
|
||||
billCode?: string;
|
||||
|
||||
/**
|
||||
* 收费项目id
|
||||
*/
|
||||
chargeItemId?: string | number;
|
||||
|
||||
/**
|
||||
* 收费范围 0全体业主 1部分业主
|
||||
*/
|
||||
chargeScope?: string;
|
||||
|
||||
/**
|
||||
* 收费周期 0年 1月 2日
|
||||
*/
|
||||
chargePeriod?: string;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
startDate?: string;
|
||||
|
||||
/**
|
||||
* 结束日期
|
||||
*/
|
||||
endDate?: string;
|
||||
|
||||
/**
|
||||
* 小区id
|
||||
*/
|
||||
villageId?: string | number;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
remark?: string;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
cerateTime?: string;
|
||||
}
|
||||
|
||||
export interface BillQuery extends PageQuery {
|
||||
/**
|
||||
* 账单编号
|
||||
*/
|
||||
billCode?: string;
|
||||
|
||||
/**
|
||||
* 收费项目id
|
||||
*/
|
||||
chargeItemId?: string | number;
|
||||
|
||||
/**
|
||||
* 收费范围 0全体业主 1部分业主
|
||||
*/
|
||||
chargeScope?: string;
|
||||
|
||||
/**
|
||||
* 收费周期 0年 1月 2日
|
||||
*/
|
||||
chargePeriod?: string;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
startDate?: string;
|
||||
|
||||
/**
|
||||
* 结束日期
|
||||
*/
|
||||
endDate?: string;
|
||||
|
||||
/**
|
||||
* 小区id
|
||||
*/
|
||||
villageId?: string | number;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
cerateTime?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
@@ -61,3 +61,14 @@ export const delChargeItem = (id: string | number | Array<string | number>) => {
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 启停 收费项目
|
||||
* @param id
|
||||
*/
|
||||
export const changChargeItem = (data: { id: string; status: string }) => {
|
||||
return request({
|
||||
url: '/chargeItem/',
|
||||
method: 'PUT'
|
||||
});
|
||||
};
|
||||
|
||||
@@ -2,7 +2,7 @@ export interface ChargeItemVO {
|
||||
/**
|
||||
* 收费项目管理表id
|
||||
*/
|
||||
id: string | number;
|
||||
id: string;
|
||||
|
||||
/**
|
||||
* 项目名称
|
||||
|
||||
@@ -61,3 +61,27 @@ export const delElectricityDevice = (id: string | number | Array<string | number
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 生成条形码
|
||||
* @param id
|
||||
*/
|
||||
export const ElectricityDeviceMakerQrcode = (data: { deviceCode: string; id: string }[]) => {
|
||||
return request({
|
||||
url: '/electricityDevice/generateBarCodee',
|
||||
method: 'POST',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 获取设备指定时间段的用电量
|
||||
* @param id
|
||||
*/
|
||||
export const getElectricityDeviceTimeRangeUsedWater = (data: { deviceCode: string; 'startTime': string; 'endTime': string }) => {
|
||||
return request({
|
||||
url: '/electricityDevice/getEle',
|
||||
method: 'POST',
|
||||
data
|
||||
});
|
||||
};
|
||||
|
||||
@@ -19,6 +19,8 @@ export interface ElectricityDeviceVO {
|
||||
*/
|
||||
deleted: number;
|
||||
|
||||
houseName: string;
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
|
||||
63
src/api/system/SdbPayRecord/index.ts
Normal file
63
src/api/system/SdbPayRecord/index.ts
Normal file
@@ -0,0 +1,63 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
import { PayRecordVO, PayRecordForm, PayRecordQuery } from './type';
|
||||
|
||||
/**
|
||||
* 查询 抄表周期管理列表
|
||||
* @param query
|
||||
* @returns {*}
|
||||
*/
|
||||
|
||||
export const listPayRecord = (query?: PayRecordQuery): AxiosPromise<PayRecordVO[]> => {
|
||||
return request({
|
||||
url: '/payRecord/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询 抄表周期管理详细
|
||||
* @param id
|
||||
*/
|
||||
export const getPayRecord = (id: string | number): AxiosPromise<PayRecordVO> => {
|
||||
return request({
|
||||
url: '/payRecord/' + id,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 新增 抄表周期管理
|
||||
* @param data
|
||||
*/
|
||||
export const addPayRecord = (data: PayRecordForm) => {
|
||||
return request({
|
||||
url: '/payRecord',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 修改 抄表周期管理
|
||||
* @param data
|
||||
*/
|
||||
export const updatePayRecord = (data: PayRecordForm) => {
|
||||
return request({
|
||||
url: '/payRecord',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 删除 抄表周期管理
|
||||
* @param id
|
||||
*/
|
||||
export const delPayRecord = (id: string | number | Array<string | number>) => {
|
||||
return request({
|
||||
url: '/payRecord/' + id,
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
110
src/api/system/SdbPayRecord/type.ts
Normal file
110
src/api/system/SdbPayRecord/type.ts
Normal file
@@ -0,0 +1,110 @@
|
||||
export interface PayRecordVO {
|
||||
/**
|
||||
* 抄表周期管理表id
|
||||
*/
|
||||
id: string | number;
|
||||
|
||||
/**
|
||||
* 设备类型 0电表 1水表
|
||||
*/
|
||||
deviceType: string;
|
||||
|
||||
/**
|
||||
* 房屋id
|
||||
*/
|
||||
houseId: string | number;
|
||||
|
||||
/**
|
||||
* 收费项目 0电费 1水费
|
||||
*/
|
||||
payType: string;
|
||||
|
||||
/**
|
||||
* 抄表月份
|
||||
*/
|
||||
recordMonth: string;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
startTime: string;
|
||||
|
||||
/**
|
||||
* 结束日期
|
||||
*/
|
||||
endTime: string;
|
||||
}
|
||||
|
||||
export interface PayRecordForm extends BaseEntity {
|
||||
/**
|
||||
* 抄表周期管理表id
|
||||
*/
|
||||
id?: string | number;
|
||||
|
||||
/**
|
||||
* 设备类型 0电表 1水表
|
||||
*/
|
||||
deviceType?: string;
|
||||
|
||||
/**
|
||||
* 房屋id
|
||||
*/
|
||||
houseId?: string | number;
|
||||
|
||||
/**
|
||||
* 收费项目 0电费 1水费
|
||||
*/
|
||||
payType?: string;
|
||||
|
||||
/**
|
||||
* 抄表月份
|
||||
*/
|
||||
recordMonth?: string;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
startTime?: string;
|
||||
|
||||
/**
|
||||
* 结束日期
|
||||
*/
|
||||
endTime?: string;
|
||||
}
|
||||
|
||||
export interface PayRecordQuery extends PageQuery {
|
||||
/**
|
||||
* 设备类型 0电表 1水表
|
||||
*/
|
||||
deviceType?: string;
|
||||
|
||||
/**
|
||||
* 房屋id
|
||||
*/
|
||||
houseId?: string | number;
|
||||
|
||||
/**
|
||||
* 收费项目 0电费 1水费
|
||||
*/
|
||||
payType?: string;
|
||||
|
||||
/**
|
||||
* 抄表月份
|
||||
*/
|
||||
recordMonth?: string;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
startTime?: string;
|
||||
|
||||
/**
|
||||
* 结束日期
|
||||
*/
|
||||
endTime?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
@@ -93,48 +93,14 @@ export interface TopupRecordForm extends BaseEntity {
|
||||
}
|
||||
|
||||
export interface TopupRecordQuery extends PageQuery {
|
||||
/**
|
||||
* 用户ID
|
||||
*/
|
||||
userId?: string | number;
|
||||
|
||||
/**
|
||||
* 充值金额
|
||||
*/
|
||||
rechargeAmount?: number;
|
||||
|
||||
/**
|
||||
* 充值时间
|
||||
*/
|
||||
rechargeTime?: string;
|
||||
|
||||
/**
|
||||
* 设备ID
|
||||
*/
|
||||
deviceCode?: string;
|
||||
|
||||
/**
|
||||
* 订单表
|
||||
*/
|
||||
orderId?: string | number;
|
||||
|
||||
/**
|
||||
* 1.电表 2.水表
|
||||
*/
|
||||
type?: string;
|
||||
|
||||
/**
|
||||
* 订单状态(0.未支付 1.已支付 2.支付中,3.支付失败 4.退款)
|
||||
*/
|
||||
status?: number;
|
||||
|
||||
/**
|
||||
* 0.待接收 1.已接收
|
||||
*/
|
||||
getOver?: number;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
id?: string;
|
||||
}
|
||||
|
||||
@@ -61,3 +61,27 @@ export const delWaterDevice = (id: string | number | Array<string | number>) =>
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 获取设备指定时间段的用水量
|
||||
* @param id
|
||||
*/
|
||||
export const getWaterDeviceTimeRangeUsedWater = (data: { deviceCode: string; 'startTime': string; 'endTime': string }) => {
|
||||
return request({
|
||||
url: '/waterDevice/getEle',
|
||||
method: 'POST',
|
||||
data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 生成条形码
|
||||
* @param id
|
||||
*/
|
||||
export const WaterDeviceMakerQrcode = (data: { deviceCode: string; id: string }[]) => {
|
||||
return request({
|
||||
url: '/waterDevice/generateBarCode',
|
||||
method: 'POST',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
@@ -2,7 +2,7 @@ export interface WaterDeviceVO {
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
id: string | number;
|
||||
id: string;
|
||||
|
||||
/**
|
||||
* 水表设备编码
|
||||
@@ -27,14 +27,14 @@ export interface WaterDeviceVO {
|
||||
/**
|
||||
*
|
||||
*/
|
||||
openid: string | number;
|
||||
openid: string;
|
||||
}
|
||||
|
||||
export interface WaterDeviceForm extends BaseEntity {
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
id?: string | number;
|
||||
id?: string;
|
||||
|
||||
/**
|
||||
* 水表设备编码
|
||||
@@ -86,7 +86,7 @@ export interface WaterDeviceQuery extends PageQuery {
|
||||
/**
|
||||
*
|
||||
*/
|
||||
openid?: string | number;
|
||||
openid?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
|
||||
Reference in New Issue
Block a user