add 继电器Api及前端数据实体

This commit is contained in:
Asoka 2025-06-09 15:03:23 +08:00
parent 860fd02bbb
commit bd5cbdf5a0
2 changed files with 306 additions and 0 deletions

View File

@ -0,0 +1,156 @@
/* eslint-disable */
/* tslint:disable */
/*
* ---------------------------------------------------------------
* ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ##
* ## ##
* ## AUTHOR: adademo / https://github.com/adademo/swagger-typescript-api ##
* ## SOURCE: https://github.com/adademo/swagger-typescript-api ##
* ---------------------------------------------------------------
*/
import {
RelayAddInput,
RelayGetOutput,
RelayUpdateInput,
PageInputRelayGetPageInput,
ResultOutputRelayGetOutput,
ResultOutputPageOutputRelayGetPageOutput,
ResultOutputInt64,
} from './data-contracts'
import { ContentType, HttpClient, RequestParams } from './http-client'
import { AxiosResponse } from 'axios'
export class UspRelayApi<SecurityDataType = unknown> extends HttpClient<SecurityDataType> {
/**
* No description
*
* @tags relay
* @name Get
* @summary
* @request GET:/api/admin/usp-relay/get
* @secure
*/
get = (
query?: {
/** @format int64 */
id?: number
},
params: RequestParams = {}
) =>
this.request<ResultOutputRelayGetOutput, any>({
path: `/api/admin/usp-relay/get`,
method: 'GET',
query: query,
secure: true,
format: 'json',
...params,
})
/**
* No description
*
* @tags relay
* @name GetPage
* @summary
* @request POST:/api/admin/usp-relay/get-page
* @secure
*/
getPage = (data: PageInputRelayGetPageInput, params: RequestParams = {}) =>
this.request<ResultOutputPageOutputRelayGetPageOutput, any>({
path: `/api/admin/usp-relay/get-page`,
method: 'POST',
body: data,
secure: true,
type: ContentType.Json,
format: 'json',
...params,
})
/**
* No description
*
* @tags relay
* @name Add
* @summary
* @request POST:/api/admin/usp-relay/add
* @secure
*/
add = (data: RelayAddInput, params: RequestParams = {}) =>
this.request<ResultOutputInt64, any>({
path: `/api/admin/usp-relay/add`,
method: 'POST',
body: data,
secure: true,
type: ContentType.Json,
format: 'json',
...params,
})
/**
* No description
*
* @tags relay
* @name Update
* @summary
* @request PUT:/api/admin/usp-relay/update
* @secure
*/
update = (data: RelayUpdateInput, params: RequestParams = {}) =>
this.request<AxiosResponse, any>({
path: `/api/admin/usp-relay/update`,
method: 'PUT',
body: data,
secure: true,
type: ContentType.Json,
...params,
})
/**
* No description
*
* @tags relay
* @name Delete
* @summary
* @request DELETE:/api/admin/usp-relay/delete
* @secure
*/
delete = (
query?: {
/** @format int64 */
id?: number
},
params: RequestParams = {}
) =>
this.request<AxiosResponse, any>({
path: `/api/admin/usp-relay/delete`,
method: 'DELETE',
query: query,
secure: true,
...params,
})
/**
* No description
*
* @tags relay
* @name SoftDelete
* @summary
* @request DELETE:/api/admin/usp-relay/soft-delete
* @secure
*/
softDelete = (
query?: {
/** @format int64 */
id?: number
},
params: RequestParams = {}
) =>
this.request<AxiosResponse, any>({
path: `/api/admin/usp-relay/soft-delete`,
method: 'DELETE',
query: query,
secure: true,
...params,
})
}

View File

@ -7637,3 +7637,153 @@ export type PageInputEquPrinterGetPageInput = {
/** 每页条数 */
pageSize?: number
}
/** 继电器设备 */
export interface RelayGetOutput {
/** 设备编号 */
deviceNo?: string | null
/** 资产编号 */
assetNo?: string | null
/** IP地址 */
ip?: string | null
/** 端口号 */
port?: string | null
/** 服务名称 */
serviceName?: string | null
/** 启用 */
enabled?: boolean
/**
* Id
* @format int64
*/
id: number
}
/** 结果输出 */
export interface ResultOutputRelayGetOutput {
/** 是否成功标记 */
success?: boolean
/** 编码 */
code?: string | null
/** 消息 */
msg?: string | null
/** 继电器设备 */
data?: RelayGetOutput
}
/** 添加 */
export interface RelayAddInput {
/** 设备编号 */
deviceNo?: string | null
/** 资产编号 */
assetNo?: string | null
/** IP地址 */
ip?: string | null
/** 端口号 */
port?: string | null
/** 服务名称 */
serviceName?: string | null
/** 启用 */
enabled?: boolean
}
/** 修改 */
export interface RelayUpdateInput {
/** 设备编号 */
deviceNo?: string | null
/** 资产编号 */
assetNo?: string | null
/** IP地址 */
ip?: string | null
/** 端口号 */
port?: string | null
/** 服务名称 */
serviceName?: string | null
/** 启用 */
enabled?: boolean
/**
* Id
* @format int64
*/
id: number
}
/** 分页请求 */
export interface RelayGetPageInput {
/** 关键词 */
keyWord?: string | null
/** 开始日期 */
stDate?: string | null
/** 结束日期 */
edDate?: string | null
}
/** 分页信息输入 */
export interface PageInputRelayGetPageInput {
dynamicFilter?: DynamicFilterInfo
/** 排序列表 */
sortList?: SortInput[] | null
/**
*
* @format int32
*/
currentPage?: number
/**
*
* @format int32
*/
pageSize?: number
/** 分页请求 */
filter?: RelayGetPageInput
}
/** 分页信息输出 */
export interface PageOutputRelayGetPageOutput {
/**
*
* @format int64
*/
total?: number
/** 数据 */
list?: RelayGetPageOutput[] | null
}
/** 分页响应 */
export interface RelayGetPageOutput {
/**
*
* @format int64
*/
id?: number
/** 设备编号 */
deviceNo?: string | null
/** 资产编号 */
assetNo?: string | null
/** IP地址 */
ip?: string | null
/** 端口号 */
port?: string | null
/** 服务名称 */
serviceName?: string | null
/** 启用 */
enabled?: boolean
/** 创建者 */
createdUserName?: string | null
/**
*
* @format date-time
*/
createdTime?: string | null
}
/** 结果输出 */
export interface ResultOutputPageOutputRelayGetPageOutput {
/** 是否成功标记 */
success?: boolean
/** 编码 */
code?: string | null
/** 消息 */
msg?: string | null
/** 分页信息输出 */
data?: PageOutputRelayGetPageOutput
}