新增数据,开始安全巡检模块
This commit is contained in:
63
src/api/system/InspectionPlan/index.ts
Normal file
63
src/api/system/InspectionPlan/index.ts
Normal file
@@ -0,0 +1,63 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
import { PlanVO, PlanForm, PlanQuery } from '@/api/system/InspectionPlan/type';
|
||||
|
||||
/**
|
||||
* 查询巡检计划列表
|
||||
* @param query
|
||||
* @returns {*}
|
||||
*/
|
||||
|
||||
export const listPlan = (query?: PlanQuery): AxiosPromise<PlanVO[]> => {
|
||||
return request({
|
||||
url: '/inspection/plan/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询巡检计划详细
|
||||
* @param id
|
||||
*/
|
||||
export const getPlan = (id: string | number): AxiosPromise<PlanVO> => {
|
||||
return request({
|
||||
url: '/inspection/plan/' + id,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 新增巡检计划
|
||||
* @param data
|
||||
*/
|
||||
export const addPlan = (data: PlanForm) => {
|
||||
return request({
|
||||
url: '/inspection/plan',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 修改巡检计划
|
||||
* @param data
|
||||
*/
|
||||
export const updatePlan = (data: PlanForm) => {
|
||||
return request({
|
||||
url: '/inspection/plan',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 删除巡检计划
|
||||
* @param id
|
||||
*/
|
||||
export const delPlan = (id: string | number | Array<string | number>) => {
|
||||
return request({
|
||||
url: '/inspection/plan/' + id,
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
165
src/api/system/InspectionPlan/type.ts
Normal file
165
src/api/system/InspectionPlan/type.ts
Normal file
@@ -0,0 +1,165 @@
|
||||
export interface PlanVO {
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
id: string | number;
|
||||
|
||||
/**
|
||||
* 巡检计划名称
|
||||
*/
|
||||
planName: string;
|
||||
|
||||
/**
|
||||
* 巡检人员ID,多个用逗号分隔
|
||||
*/
|
||||
inspectorIds: string | number;
|
||||
|
||||
/**
|
||||
* 执行周期,如:开始日期-结束日期
|
||||
*/
|
||||
executeCycle: string;
|
||||
|
||||
/**
|
||||
* 任务时间
|
||||
*/
|
||||
taskTime: string;
|
||||
|
||||
/**
|
||||
* 提醒时间
|
||||
*/
|
||||
remindTime: string;
|
||||
|
||||
/**
|
||||
* 巡检设置:0-必须拍照,1-可以跳检
|
||||
*/
|
||||
inspectSetting: number;
|
||||
|
||||
/**
|
||||
* 计划路线,多个用逗号分隔
|
||||
*/
|
||||
routeIds: string | number;
|
||||
|
||||
/**
|
||||
* 状态:0-关闭,1-开启
|
||||
*/
|
||||
status: number;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
remark: string;
|
||||
|
||||
/**
|
||||
* 执行周期具体日期
|
||||
*/
|
||||
executeDay: string;
|
||||
}
|
||||
|
||||
export interface PlanForm extends BaseEntity {
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
id?: string | number;
|
||||
|
||||
/**
|
||||
* 巡检计划名称
|
||||
*/
|
||||
planName?: string;
|
||||
|
||||
/**
|
||||
* 巡检人员ID,多个用逗号分隔
|
||||
*/
|
||||
inspectorIds?: string | number;
|
||||
|
||||
/**
|
||||
* 执行周期,如:开始日期-结束日期
|
||||
*/
|
||||
executeCycle?: string;
|
||||
|
||||
/**
|
||||
* 任务时间
|
||||
*/
|
||||
taskTime?: string;
|
||||
|
||||
/**
|
||||
* 提醒时间
|
||||
*/
|
||||
remindTime?: string;
|
||||
|
||||
/**
|
||||
* 巡检设置:0-必须拍照,1-可以跳检
|
||||
*/
|
||||
inspectSetting?: number;
|
||||
|
||||
/**
|
||||
* 计划路线,多个用逗号分隔
|
||||
*/
|
||||
routeIds?: string | number;
|
||||
|
||||
/**
|
||||
* 状态:0-关闭,1-开启
|
||||
*/
|
||||
status?: number;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
remark?: string;
|
||||
|
||||
/**
|
||||
* 执行周期具体日期
|
||||
*/
|
||||
executeDay?: string;
|
||||
}
|
||||
|
||||
export interface PlanQuery extends PageQuery {
|
||||
/**
|
||||
* 巡检计划名称
|
||||
*/
|
||||
planName?: string;
|
||||
|
||||
/**
|
||||
* 巡检人员ID,多个用逗号分隔
|
||||
*/
|
||||
inspectorIds?: string | number;
|
||||
|
||||
/**
|
||||
* 执行周期,如:开始日期-结束日期
|
||||
*/
|
||||
executeCycle?: string;
|
||||
|
||||
/**
|
||||
* 任务时间
|
||||
*/
|
||||
taskTime?: string;
|
||||
|
||||
/**
|
||||
* 提醒时间
|
||||
*/
|
||||
remindTime?: string;
|
||||
|
||||
/**
|
||||
* 巡检设置:0-必须拍照,1-可以跳检
|
||||
*/
|
||||
inspectSetting?: number;
|
||||
|
||||
/**
|
||||
* 计划路线,多个用逗号分隔
|
||||
*/
|
||||
routeIds?: string | number;
|
||||
|
||||
/**
|
||||
* 状态:0-关闭,1-开启
|
||||
*/
|
||||
status?: number;
|
||||
|
||||
/**
|
||||
* 执行周期具体日期
|
||||
*/
|
||||
executeDay?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
63
src/api/system/InspectionRecord/index.ts
Normal file
63
src/api/system/InspectionRecord/index.ts
Normal file
@@ -0,0 +1,63 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
import { RecordVO, RecordForm, RecordQuery } from '@/api/system/InspectionRecord/type';
|
||||
|
||||
/**
|
||||
* 查询巡检记录主列表
|
||||
* @param query
|
||||
* @returns {*}
|
||||
*/
|
||||
|
||||
export const listRecord = (query?: RecordQuery): AxiosPromise<RecordVO[]> => {
|
||||
return request({
|
||||
url: '/inspection/record/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询巡检记录主详细
|
||||
* @param id
|
||||
*/
|
||||
export const getRecord = (id: string | number): AxiosPromise<RecordVO> => {
|
||||
return request({
|
||||
url: '/inspection/record/' + id,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 新增巡检记录主
|
||||
* @param data
|
||||
*/
|
||||
export const addRecord = (data: RecordForm) => {
|
||||
return request({
|
||||
url: '/inspection/record',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 修改巡检记录主
|
||||
* @param data
|
||||
*/
|
||||
export const updateRecord = (data: RecordForm) => {
|
||||
return request({
|
||||
url: '/inspection/record',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 删除巡检记录主
|
||||
* @param id
|
||||
*/
|
||||
export const delRecord = (id: string | number | Array<string | number>) => {
|
||||
return request({
|
||||
url: '/inspection/record/' + id,
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
109
src/api/system/InspectionRecord/type.ts
Normal file
109
src/api/system/InspectionRecord/type.ts
Normal file
@@ -0,0 +1,109 @@
|
||||
export interface RecordVO {
|
||||
actualEndTime?: null;
|
||||
actualStartTime?: null;
|
||||
createByName?: null;
|
||||
createTime?: string;
|
||||
details?: null;
|
||||
id?: string;
|
||||
inspectorId?: number;
|
||||
inspectorName?: string;
|
||||
planId?: string;
|
||||
planName?: string;
|
||||
remark?: null;
|
||||
routeId?: string;
|
||||
routeName?: string;
|
||||
status?: number;
|
||||
statusLabel?: null;
|
||||
taskName?: string;
|
||||
taskTime?: string;
|
||||
updateTime?: string;
|
||||
}
|
||||
|
||||
export interface RecordForm extends BaseEntity {
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
id?: string | number;
|
||||
|
||||
/**
|
||||
* 关联巡检任务ID
|
||||
*/
|
||||
taskId?: string | number;
|
||||
|
||||
/**
|
||||
* 关联巡检计划ID
|
||||
*/
|
||||
planId?: string | number;
|
||||
|
||||
/**
|
||||
* 巡检人员ID
|
||||
*/
|
||||
inspectorId?: string | number;
|
||||
|
||||
/**
|
||||
* 巡检路线ID
|
||||
*/
|
||||
routeId?: string | number;
|
||||
|
||||
/**
|
||||
* 任务开始时间
|
||||
*/
|
||||
startTime?: string;
|
||||
|
||||
/**
|
||||
* 任务结束时间
|
||||
*/
|
||||
endTime?: string;
|
||||
|
||||
/**
|
||||
* 执行状态(字典:inspection_exec_status 0-按时完成 1-超时完成 2-未完成)
|
||||
*/
|
||||
execStatus?: number;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
remark?: string;
|
||||
}
|
||||
|
||||
export interface RecordQuery extends PageQuery {
|
||||
/**
|
||||
* 关联巡检任务ID
|
||||
*/
|
||||
taskId?: string | number;
|
||||
|
||||
/**
|
||||
* 关联巡检计划ID
|
||||
*/
|
||||
planId?: string | number;
|
||||
|
||||
/**
|
||||
* 巡检人员ID
|
||||
*/
|
||||
inspectorId?: string | number;
|
||||
|
||||
/**
|
||||
* 巡检路线ID
|
||||
*/
|
||||
routeId?: string | number;
|
||||
|
||||
/**
|
||||
* 任务开始时间
|
||||
*/
|
||||
startTime?: string;
|
||||
|
||||
/**
|
||||
* 任务结束时间
|
||||
*/
|
||||
endTime?: string;
|
||||
|
||||
/**
|
||||
* 执行状态(字典:inspection_exec_status 0-按时完成 1-超时完成 2-未完成)
|
||||
*/
|
||||
execStatus?: number;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
@@ -8,7 +8,7 @@ export interface communitylist_rows_type {
|
||||
remark: string;
|
||||
parkingSpaceCount: number;
|
||||
villageImageUrl: string;
|
||||
city: string | string[];
|
||||
city: string;
|
||||
status: '0' | '1';
|
||||
manageName: string;
|
||||
managePhone: string;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
import { HouseRentalVO, HouseRentalForm, HouseRentalQuery } from '@/api/system/type';
|
||||
import { HouseRentalVO, HouseRentalForm, HouseRentalQuery } from '@/api/system/houseRental/type';
|
||||
|
||||
/**
|
||||
* 查询房屋租赁管理列表
|
||||
|
||||
@@ -17,7 +17,7 @@ export interface HouseRentalVO {
|
||||
/**
|
||||
* 0 整租 1 合租
|
||||
*/
|
||||
rentalType: number;
|
||||
rentalType: string;
|
||||
|
||||
/**
|
||||
* 房屋朝向
|
||||
@@ -76,11 +76,18 @@ export interface HouseRentalVO {
|
||||
/**
|
||||
* 房屋用途
|
||||
*/
|
||||
houseUse?: number;
|
||||
houseUse: string;
|
||||
/**
|
||||
* 租赁状态
|
||||
*/
|
||||
rentalStatus?: number;
|
||||
rentalStatus: number;
|
||||
|
||||
house: string;
|
||||
name: string;
|
||||
pubBy: string;
|
||||
pubTime: string;
|
||||
houseImageUrls: string[];
|
||||
facilitieslist: string[];
|
||||
}
|
||||
|
||||
export interface HouseRentalForm extends BaseEntity {
|
||||
|
||||
@@ -155,15 +155,15 @@ export interface ResidentQuery extends PageQuery {
|
||||
* 住户类型
|
||||
* 0业主 1租户
|
||||
*/
|
||||
type: string;
|
||||
type?: string;
|
||||
/**
|
||||
* 住户状态
|
||||
* 0审核中 1 已认证
|
||||
*/
|
||||
status: string;
|
||||
status?: string;
|
||||
|
||||
houseId: number;
|
||||
villageId: number;
|
||||
buildingId: number;
|
||||
unitNo: number;
|
||||
houseId?: number;
|
||||
villageId?: number;
|
||||
buildingId?: number;
|
||||
unitNo?: number;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user