fix: 运维管理 流媒体服务修复部分bug
This commit is contained in:
parent
05045768d2
commit
90d33baffd
|
@ -779,14 +779,15 @@
|
|||
height: 400px;
|
||||
"
|
||||
>
|
||||
<MonacoEditor
|
||||
<j-monaco-editor
|
||||
theme="vs"
|
||||
v-model:modelValue="
|
||||
v-model:value="
|
||||
cluster
|
||||
.configuration
|
||||
.parserConfiguration
|
||||
.script
|
||||
"
|
||||
language="javascript"
|
||||
/>
|
||||
</div>
|
||||
</j-form-item>
|
||||
|
@ -998,7 +999,6 @@ import {
|
|||
import { cloneDeep } from 'lodash-es';
|
||||
import type { FormData2Type, FormDataType } from '../type';
|
||||
import { Store } from 'jetlinks-store';
|
||||
import MonacoEditor from '@/components/MonacoEditor/index.vue';
|
||||
|
||||
const route = useRoute();
|
||||
const NetworkType = route.query.type as string;
|
||||
|
|
|
@ -81,17 +81,17 @@
|
|||
},
|
||||
]"
|
||||
>
|
||||
<div class="form-label">
|
||||
<template #label>
|
||||
API Host
|
||||
<span class="form-label-required">*</span>
|
||||
<j-tooltip>
|
||||
<template #title>
|
||||
<p>调用流媒体接口时请求的服务地址</p>
|
||||
</template>
|
||||
<AIcon type="QuestionCircleOutlined" />
|
||||
<j-tooltip
|
||||
title="调用流媒体接口时请求的服务地址"
|
||||
>
|
||||
<AIcon
|
||||
type="QuestionCircleOutlined"
|
||||
style="margin-left: 2px"
|
||||
/>
|
||||
</j-tooltip>
|
||||
</div>
|
||||
|
||||
</template>
|
||||
<j-input
|
||||
placeholder="请输入API Host"
|
||||
v-model:value="formData.configuration.apiHost"
|
||||
|
@ -135,19 +135,17 @@
|
|||
},
|
||||
]"
|
||||
>
|
||||
<div class="form-label">
|
||||
<template #label>
|
||||
RTP IP
|
||||
<span class="form-label-required">*</span>
|
||||
<j-tooltip>
|
||||
<template #title>
|
||||
<p>
|
||||
视频设备将流推送到该IP地址下,部分设备仅支持IP地址,建议全是用IP地址
|
||||
</p>
|
||||
</template>
|
||||
<AIcon type="QuestionCircleOutlined" />
|
||||
<j-tooltip
|
||||
title="视频设备将流推送到该IP地址下,部分设备仅支持IP地址,建议全是用IP地址"
|
||||
>
|
||||
<AIcon
|
||||
type="QuestionCircleOutlined"
|
||||
style="margin-left: 2px"
|
||||
/>
|
||||
</j-tooltip>
|
||||
</div>
|
||||
|
||||
</template>
|
||||
<j-input
|
||||
placeholder="请输入RTP IP"
|
||||
v-model:value="formData.configuration.rtpIp"
|
||||
|
@ -250,7 +248,6 @@
|
|||
<j-form-item>
|
||||
<j-button
|
||||
v-if="view === 'false'"
|
||||
class="form-submit"
|
||||
html-type="submit"
|
||||
type="primary"
|
||||
@click.prevent="onSubmit"
|
||||
|
@ -302,7 +299,7 @@ const formData = ref<FormDataType>({
|
|||
});
|
||||
|
||||
const onSubmit = async () => {
|
||||
let data = await formRef.value?.validate();
|
||||
let data: any = await formRef.value?.validate();
|
||||
let params = { ...data };
|
||||
const { configuration } = data;
|
||||
if (configuration.dynamicRtpPort) {
|
||||
|
@ -327,8 +324,8 @@ const onSubmit = async () => {
|
|||
|
||||
const detail = async (id: string) => {
|
||||
loading.value = true;
|
||||
const resp = await queryProviders();
|
||||
options.value = resp.result.map((item) => ({
|
||||
const resp: any = await queryProviders();
|
||||
options.value = resp.result.map((item: any) => ({
|
||||
value: item.id,
|
||||
label: item.name,
|
||||
}));
|
||||
|
@ -368,9 +365,6 @@ watch(
|
|||
|
||||
<style lang="less" scoped>
|
||||
.form {
|
||||
.form-submit {
|
||||
background-color: @primary-color !important;
|
||||
}
|
||||
.form-item-checked {
|
||||
padding: 0;
|
||||
padding-top: 35px;
|
||||
|
@ -381,10 +375,6 @@ watch(
|
|||
.form-label {
|
||||
height: 30px;
|
||||
padding-bottom: 8px;
|
||||
.form-label-required {
|
||||
color: red !important;
|
||||
margin: 0 4px 0 -2px;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
|
|
@ -1,7 +1,11 @@
|
|||
<template>
|
||||
<page-container>
|
||||
<div>
|
||||
<Search :columns="columns" target="search" @search="handleSearch" />
|
||||
<pro-search
|
||||
:columns="columns"
|
||||
target="search"
|
||||
@search="handleSearch"
|
||||
/>
|
||||
|
||||
<j-pro-table
|
||||
ref="tableRef"
|
||||
|
@ -211,8 +215,6 @@ const getActions = (data: Partial<Record<string, any>>): ActionsType[] => {
|
|||
if (res.success) {
|
||||
message.success('操作成功');
|
||||
tableRef.value?.reload();
|
||||
} else {
|
||||
message.error('操作失败!');
|
||||
}
|
||||
},
|
||||
},
|
||||
|
@ -231,8 +233,6 @@ const getActions = (data: Partial<Record<string, any>>): ActionsType[] => {
|
|||
if (res.success) {
|
||||
message.success('操作成功');
|
||||
tableRef.value.reload();
|
||||
} else {
|
||||
message.error('操作失败!');
|
||||
}
|
||||
},
|
||||
},
|
||||
|
|
|
@ -1,19 +1,17 @@
|
|||
|
||||
export interface Configuration = {
|
||||
secret: string,
|
||||
apiHost: string,
|
||||
apiPort: number,
|
||||
rtpIp: string,
|
||||
rtpPort: number,
|
||||
dynamicRtpPort: boolean,
|
||||
dynamicRtpPortRange?: array,
|
||||
dynamicRtpPortRange0?: number,
|
||||
dynamicRtpPortRange1?: number,
|
||||
};
|
||||
export type FormDataType = {
|
||||
export interface Configuration {
|
||||
secret: string;
|
||||
apiHost: string;
|
||||
apiPort: number | string;
|
||||
rtpIp: string | string;
|
||||
rtpPort: number | string;
|
||||
dynamicRtpPort: boolean;
|
||||
dynamicRtpPortRange?: array<any>;
|
||||
dynamicRtpPortRange0?: number | string | undefined;
|
||||
dynamicRtpPortRange1?: number | string | undefined;
|
||||
}
|
||||
export interface FormDataType {
|
||||
name: string;
|
||||
provider: undefined;
|
||||
provider: string | undefined;
|
||||
configuration: Configuration;
|
||||
id?: string;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue