萤石摄像头

This commit is contained in:
Teo
2025-06-17 09:49:15 +08:00
parent f122dc30d2
commit 0ff1e74157
17 changed files with 1614 additions and 85 deletions

View File

@ -0,0 +1,80 @@
import request from '@/utils/request';
import { AxiosPromise } from 'axios';
import { Ys7DeviceVO, Ys7DeviceForm, Ys7DeviceQuery } from '@/api/other/ys7Device/types';
/**
* 查询萤石摄像头列表
* @param query
* @returns {*}
*/
export const listYs7Device = (query?: Ys7DeviceQuery): AxiosPromise<Ys7DeviceVO[]> => {
return request({
url: '/other/ys7Device/list',
method: 'get',
params: query
});
};
/**
* 查询萤石摄像头详细
* @param id
*/
export const getYs7Device = (id: string | number): AxiosPromise<Ys7DeviceVO> => {
return request({
url: '/other/ys7Device/' + id,
method: 'get'
});
};
/**
* 新增萤石摄像头
* @param data
*/
export const addYs7Device = (data: Ys7DeviceForm) => {
return request({
url: '/other/ys7Device',
method: 'post',
data: data
});
};
/**
* 修改萤石摄像头
* @param data
*/
export const updateYs7Device = (data: Ys7DeviceForm) => {
return request({
url: '/other/ys7Device',
method: 'put',
data: data
});
};
/**
* 删除萤石摄像头
* @param id
*/
export const delYs7Device = (id: string | number | Array<string | number>) => {
return request({
url: '/other/ys7Device/' + id,
method: 'delete'
});
};
/// 修改加密状态
export const toggleEncrypt = (data?: any): AxiosPromise<{}> => {
return request({
url: '/other/ys7Device/video/encrypted',
method: 'put',
data
});
};
export const devicesLinkPro = (data: { id: string | number; projectId: string | number }): AxiosPromise<Ys7DeviceVO> => {
return request({
url: '/other/ys7Device/with/project',
method: 'put',
data
});
};

View File

@ -0,0 +1,131 @@
export interface Ys7DeviceVO {
id: any;
/**
* 项目id
*/
projectId: string | number;
/**
* 设备序列号
*/
deviceSerial: string;
/**
* 设备名称
*/
deviceName: string;
/**
* 设备型号
*/
deviceType: string;
/**
* 设备在线状态(0离线 1在线)
*/
status: number;
/**
* 固件版本号
*/
deviceVersion: string;
/**
* 设备添加时间
*/
deviceCreateTime: string;
/**
* 视频加密(0关闭 1开启)
*/
videoEncrypted: string | number;
/**
* 备注
*/
remark: string;
}
export interface Ys7DeviceForm extends BaseEntity {
/**
* 主键id
*/
id?: string | number;
/**
* 项目id
*/
projectId?: string | number;
/**
* 设备序列号
*/
deviceSerial?: string;
/**
* 设备名称
*/
deviceName?: string;
/**
* 设备型号
*/
deviceType?: string;
/**
* 设备在线状态(0离线 1在线)
*/
status?: number;
/**
* 固件版本号
*/
deviceVersion?: string;
/**
* 视频加密(0关闭 1开启)
*/
videoEncrypted?: string | number;
/**
* 备注
*/
remark?: string;
}
export interface Ys7DeviceQuery extends PageQuery {
/**
* 项目id
*/
projectId?: string | number;
/**
* 设备序列号
*/
deviceSerial?: string;
/**
* 设备名称
*/
deviceName?: string;
/**
* 设备型号
*/
deviceType?: string;
/**
* 设备在线状态(0离线 1在线)
*/
status?: number;
/**
* 固件版本号
*/
deviceVersion?: string;
/**
* 日期范围参数
*/
params?: any;
}

View File

@ -1,6 +1,17 @@
import request from '@/utils/request';
import { AxiosPromise } from 'axios';
import { ProgressCategoryVO, ProgressCategoryForm, ProgressCategoryQuery, ProgressPlanForm, lastTimeVo, workScheduleListVO, workScheduleListQuery, progressPlanDetailForm, pvModuleListQuery, pvModuleListVO } from '@/api/progress/plan/types';
import {
ProgressCategoryVO,
ProgressCategoryForm,
ProgressCategoryQuery,
ProgressPlanForm,
lastTimeVo,
workScheduleListVO,
workScheduleListQuery,
progressPlanDetailForm,
pvModuleListQuery,
pvModuleListVO
} from '@/api/progress/plan/types';
/**
* 查询进度类别列表
@ -68,9 +79,8 @@ export const delProgressCategory = (id: string | number | Array<string | number>
*/
export const getProjectSquare = (projectId: string) => {
return request({
url: '/facility/matrix/list',
method: 'get',
params: {projectId}
url: '/project/project/list/sub/matrix/' + projectId,
method: 'get'
});
};
@ -78,7 +88,7 @@ export const getProjectSquare = (projectId: string) => {
* 获取进度类别最后一次进度信息
* @param id
*/
export const lastTime = (id: string | number ):AxiosPromise<lastTimeVo> => {
export const lastTime = (id: string | number): AxiosPromise<lastTimeVo> => {
return request({
url: '/progress/progressCategory/lastTime/' + id,
method: 'get'
@ -101,7 +111,7 @@ export const workScheduleAddPlan = (data: ProgressPlanForm) => {
* 获取进度计划详细信息
* @param params
*/
export const workScheduleList = (query: workScheduleListQuery):AxiosPromise<workScheduleListVO[]> => {
export const workScheduleList = (query: workScheduleListQuery): AxiosPromise<workScheduleListVO[]> => {
return request({
url: '/progress/progressPlan/list',
method: 'get',
@ -113,10 +123,10 @@ export const workScheduleList = (query: workScheduleListQuery):AxiosPromise<work
* 获取进度类别坐标信息
* @param params
*/
export const workScheduleListPosition = (id: string):AxiosPromise<any> => {
export const workScheduleListPosition = (id: string): AxiosPromise<any> => {
return request({
url: '/progress/progressCategory/coordinate/' + id,
method: 'get',
method: 'get'
});
};
@ -136,11 +146,11 @@ export const workScheduleSubmit = (data: progressPlanDetailForm) => {
* 获取进度计划详情未完成设施详细信息
* @param params
*/
export const pvModuleList = (query: pvModuleListQuery):AxiosPromise<pvModuleListVO[]> => {
export const pvModuleList = (query: pvModuleListQuery): AxiosPromise<pvModuleListVO[]> => {
return request({
url: '/progress/progressPlanDetail/detail/unFinish/' + query.id ,
url: '/progress/progressPlanDetail/detail/unFinish/' + query.id,
method: 'get',
params:query
params: query
});
};
@ -160,9 +170,9 @@ export const addDaily = (data: progressPlanDetailForm) => {
* 获取进度计划详情已完成设施详细信息
* @param params
*/
export const getDailyBook = (query: pvModuleListQuery):AxiosPromise<pvModuleListVO[]> => {
export const getDailyBook = (query: pvModuleListQuery): AxiosPromise<pvModuleListVO[]> => {
return request({
url: '/progress/progressPlanDetail/detail/finished/'+ query.id,
url: '/progress/progressPlanDetail/detail/finished/' + query.id,
method: 'get',
params: query
});
@ -172,7 +182,7 @@ export const getDailyBook = (query: pvModuleListQuery):AxiosPromise<pvModuleList
* 删除进度计划详情
* @param id
*/
export const deleteDaily = (query: {id:string,detailIdList:string[]}) => {
export const deleteDaily = (query: { id: string; detailIdList: string[] }) => {
return request({
url: '/progress/progressPlanDetail/remove/detail',
method: 'delete',
@ -180,4 +190,4 @@ export const deleteDaily = (query: {id:string,detailIdList:string[]}) => {
});
};
export const workScheduleDel=()=>{}
export const workScheduleDel = () => {};

View File

@ -29,8 +29,8 @@ export interface ProgressCategoryVO {
*/
children: ProgressCategoryVO[];
threeChildren: any[];
hasChildren:any;
detailChildren:any;
hasChildren: any;
detailChildren: any;
}
export interface ProgressCategoryForm extends BaseEntity {

View File

@ -84,7 +84,10 @@ export const addProjectFacilities = (data: any) => {
return request({
url: '/facility/photovoltaicPanel/geoJson',
method: 'post',
data: data
data: data,
headers: {
'X-No-Cache': 'true'
}
});
};
@ -93,8 +96,8 @@ export const addProjectFacilities = (data: any) => {
* @param data
*/
export const addProjectPilePoint = (data: any) => {
console.log("🚀 ~ addProjectPilePoint ~ data:", data)
console.log('🚀 ~ addProjectPilePoint ~ data:', data);
return request({
url: '/facility/photovoltaicPanelPoint/parts/geoJson',
method: 'post',
@ -114,8 +117,6 @@ export const addProjectSquare = (data: any) => {
});
};
/**
* 通过GeoJson新增设施-箱变
* @param data
@ -172,4 +173,4 @@ export const getChildProject = (id: string | number): AxiosPromise<childProjectQ
url: '/project/project/list/sub/' + id,
method: 'get'
});
};
};