fix: bug#17556、17555
* fix: bug#17299 * fix: bug#17148 * fix: bug#17392 * fix: bug#17416 * fix: bug#17417 * fix: bug#17418 * fix: bug#17421 * fix: bug#17510 * fix: bug#17510 * fix: bug#17299 * fix: 修改tree样式 * fix: 修改样式 * fix: bug#17425 * fix: 跳转bug * fix: bug#17556、17555
This commit is contained in:
parent
6eeed06171
commit
5970fa368f
|
@ -10,6 +10,11 @@ export const getProductList = (parmas?:any) => server.get('/device/product/_qu
|
||||||
*/
|
*/
|
||||||
export const getDeviceList = (parmas?:any) => server.get('/device-instance/_query/no-paging?paging=false',parmas);
|
export const getDeviceList = (parmas?:any) => server.get('/device-instance/_query/no-paging?paging=false',parmas);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取有设备的告警的产品名称
|
||||||
|
*/
|
||||||
|
export const getAlarmProduct = (parmas:any) => server.post('/device-instance/_query',parmas)
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取组织列表
|
* 获取组织列表
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -166,7 +166,9 @@
|
||||||
<div class="card-item-content-text">
|
<div class="card-item-content-text">
|
||||||
平台对接
|
平台对接
|
||||||
</div>
|
</div>
|
||||||
|
<Ellipsis style="width: calc(100% - 20px)">
|
||||||
<div>{{ slotProps.platformConfigName }}</div>
|
<div>{{ slotProps.platformConfigName }}</div>
|
||||||
|
</Ellipsis>
|
||||||
</j-col>
|
</j-col>
|
||||||
<j-col :span="6">
|
<j-col :span="6">
|
||||||
<div class="card-item-content-text">类型</div>
|
<div class="card-item-content-text">类型</div>
|
||||||
|
|
|
@ -676,8 +676,10 @@ const saveData = () => {
|
||||||
onlyMessage('操作成功', 'success');
|
onlyMessage('操作成功', 'success');
|
||||||
if (route.query.save) {
|
if (route.query.save) {
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
window?.onTabSaveSuccess(resp);
|
if((window as any).onTabSaveSuccess){
|
||||||
|
(window as any).onTabSaveSuccess(resp);
|
||||||
setTimeout(() => window.close(), 300);
|
setTimeout(() => window.close(), 300);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
history.back();
|
history.back();
|
||||||
}
|
}
|
||||||
|
|
|
@ -124,8 +124,10 @@ const onFinish = async (values: any) => {
|
||||||
|
|
||||||
if (route.query.save) {
|
if (route.query.save) {
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
window?.onTabSaveSuccess(resp.result);
|
if((window as any).onTabSaveSuccess){
|
||||||
|
(window as any).onTabSaveSuccess(resp.result);
|
||||||
setTimeout(() => window.close(), 300);
|
setTimeout(() => window.close(), 300);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
history.back();
|
history.back();
|
||||||
}
|
}
|
||||||
|
|
|
@ -52,7 +52,7 @@
|
||||||
</div>
|
</div>
|
||||||
</j-spin>
|
</j-spin>
|
||||||
</template>
|
</template>
|
||||||
m
|
|
||||||
<script lang="ts" setup name="Cpu">
|
<script lang="ts" setup name="Cpu">
|
||||||
import { dashboard } from '@/api/link/dashboard';
|
import { dashboard } from '@/api/link/dashboard';
|
||||||
import dayjs from 'dayjs';
|
import dayjs from 'dayjs';
|
||||||
|
@ -95,6 +95,9 @@ const serverData = reactive({
|
||||||
|
|
||||||
const pickerTimeChange = () => {
|
const pickerTimeChange = () => {
|
||||||
data.value.type = undefined;
|
data.value.type = undefined;
|
||||||
|
if(props.isNoCommunity){
|
||||||
|
getCPUEcharts(data.value)
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
const echartsOptions = computed(() => {
|
const echartsOptions = computed(() => {
|
||||||
|
|
|
@ -95,6 +95,9 @@ const serverData = reactive({
|
||||||
|
|
||||||
const pickerTimeChange = () => {
|
const pickerTimeChange = () => {
|
||||||
data.value.type = undefined;
|
data.value.type = undefined;
|
||||||
|
if(props.isNoCommunity){
|
||||||
|
getJVMEcharts(data.value)
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
const getJVMEcharts = async (val: any) => {
|
const getJVMEcharts = async (val: any) => {
|
||||||
|
|
|
@ -560,8 +560,10 @@ const handleSubmit = () => {
|
||||||
onlyMessage('保存成功');
|
onlyMessage('保存成功');
|
||||||
if (route.query?.notifyType) {
|
if (route.query?.notifyType) {
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
window?.onTabSaveSuccess(res.result);
|
if((window as any).onTabSaveSuccess){
|
||||||
|
(window as any).onTabSaveSuccess(res.result);
|
||||||
setTimeout(() => window.close(), 300);
|
setTimeout(() => window.close(), 300);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
router.back();
|
router.back();
|
||||||
}
|
}
|
||||||
|
@ -587,8 +589,10 @@ const handleSubmit = () => {
|
||||||
onlyMessage('保存成功');
|
onlyMessage('保存成功');
|
||||||
if (route.query?.notifyType) {
|
if (route.query?.notifyType) {
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
window?.onTabSaveSuccess(res.result);
|
if((window as any).onTabSaveSuccess){
|
||||||
|
(window as any).onTabSaveSuccess(res.result);
|
||||||
setTimeout(() => window.close(), 300);
|
setTimeout(() => window.close(), 300);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
router.back();
|
router.back();
|
||||||
}
|
}
|
||||||
|
|
|
@ -1261,8 +1261,10 @@ const handleSubmit = () => {
|
||||||
onlyMessage('保存成功');
|
onlyMessage('保存成功');
|
||||||
if (route.query?.notifyType) {
|
if (route.query?.notifyType) {
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
window?.onTabSaveSuccess(res.result);
|
if((window as any).onTabSaveSuccess){
|
||||||
|
(window as any).onTabSaveSuccess(res.result);
|
||||||
setTimeout(() => window.close(), 300);
|
setTimeout(() => window.close(), 300);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
router.back();
|
router.back();
|
||||||
}
|
}
|
||||||
|
|
|
@ -133,6 +133,7 @@ import {
|
||||||
getDeviceList,
|
getDeviceList,
|
||||||
getOrgList,
|
getOrgList,
|
||||||
query,
|
query,
|
||||||
|
getAlarmProduct
|
||||||
} from '@/api/rule-engine/log';
|
} from '@/api/rule-engine/log';
|
||||||
import { queryLevel } from '@/api/rule-engine/config';
|
import { queryLevel } from '@/api/rule-engine/config';
|
||||||
import Search from '@/components/Search';
|
import Search from '@/components/Search';
|
||||||
|
@ -294,24 +295,18 @@ const newColumns = computed(() => {
|
||||||
type: 'select',
|
type: 'select',
|
||||||
options: async () => {
|
options: async () => {
|
||||||
const termType = [
|
const termType = [
|
||||||
|
{
|
||||||
|
column:"id$alarm-record",
|
||||||
|
value:[
|
||||||
{
|
{
|
||||||
column: "targetType",
|
column: "targetType",
|
||||||
termType: "eq",
|
termType: "eq",
|
||||||
type: "and",
|
value: "device",
|
||||||
value: "product",
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
||||||
if (props.id) {
|
|
||||||
termType.push({
|
|
||||||
termType: 'eq',
|
|
||||||
column: 'alarmConfigId',
|
|
||||||
value: props.id,
|
|
||||||
type: 'and',
|
|
||||||
},)
|
|
||||||
}
|
}
|
||||||
|
]
|
||||||
const resp: any = await handleSearch({
|
const resp: any = await getAlarmProduct({
|
||||||
sorts: [{ name: 'alarmTime', order: 'desc' }],
|
sorts: [{ name: 'alarmTime', order: 'desc' }],
|
||||||
terms: termType
|
terms: termType
|
||||||
});
|
});
|
||||||
|
@ -319,15 +314,14 @@ const newColumns = computed(() => {
|
||||||
|
|
||||||
if (resp.status === 200) {
|
if (resp.status === 200) {
|
||||||
resp.result.data.forEach(item => {
|
resp.result.data.forEach(item => {
|
||||||
if (item.targetId) {
|
if (item.productId) {
|
||||||
listMap.set(item.targetId, {
|
listMap.set(item.productId, {
|
||||||
label: item.targetName,
|
label: item.productName,
|
||||||
value: item.targetId,
|
value: item.productId,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
|
|
||||||
return [...listMap.values()]
|
return [...listMap.values()]
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -412,8 +406,6 @@ const search = (data: any) => {
|
||||||
data?.terms[0]?.terms[0]
|
data?.terms[0]?.terms[0]
|
||||||
]
|
]
|
||||||
}]
|
}]
|
||||||
// delete params.value.terms
|
|
||||||
console.log(params.value)
|
|
||||||
}
|
}
|
||||||
if (props.id) {
|
if (props.id) {
|
||||||
params.value.terms.push({
|
params.value.terms.push({
|
||||||
|
|
|
@ -243,7 +243,7 @@ const deleteScene = async (id: string) => {
|
||||||
|
|
||||||
const deleteModal = (id: string) => {
|
const deleteModal = (id: string) => {
|
||||||
Modal.confirm({
|
Modal.confirm({
|
||||||
title: '改场景已绑定告警,确定删除?',
|
title: '该场景已绑定告警,确定删除?',
|
||||||
onOk: async () => {
|
onOk: async () => {
|
||||||
await deleteScene(id)
|
await deleteScene(id)
|
||||||
}
|
}
|
||||||
|
|
|
@ -155,6 +155,7 @@ const search = debounce(() => {
|
||||||
treeArray.set(item.id, item);
|
treeArray.set(item.id, item);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
expandedKeys.value = []
|
||||||
dig(searchTree);
|
dig(searchTree);
|
||||||
treeData.value = ArrayToTree(cloneDeep([...treeArray.values()]));
|
treeData.value = ArrayToTree(cloneDeep([...treeArray.values()]));
|
||||||
} else {
|
} else {
|
||||||
|
@ -172,6 +173,9 @@ const search = debounce(() => {
|
||||||
pIds.push(_item.parentId);
|
pIds.push(_item.parentId);
|
||||||
treeArray.set(item, _item);
|
treeArray.set(item, _item);
|
||||||
expandedKeys.value.push(_item.id)
|
expandedKeys.value.push(_item.id)
|
||||||
|
if(pIds.length > 0){
|
||||||
|
dig(pIds)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -196,8 +200,10 @@ function delDepartment(id: string) {
|
||||||
}
|
}
|
||||||
function refresh(id: string) {
|
function refresh(id: string) {
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
window?.onTabSaveSuccess && window.onTabSaveSuccess(id);
|
if(window?.onTabSaveSuccess){
|
||||||
|
window.onTabSaveSuccess(id);
|
||||||
setTimeout(() => window.close(), 300);
|
setTimeout(() => window.close(), 300);
|
||||||
|
}
|
||||||
getTree();
|
getTree();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -253,6 +253,7 @@
|
||||||
<ChooseIconDialog
|
<ChooseIconDialog
|
||||||
v-if="dialogVisible"
|
v-if="dialogVisible"
|
||||||
v-model:visible="dialogVisible"
|
v-model:visible="dialogVisible"
|
||||||
|
:icon="form.data.icon"
|
||||||
@confirm="(typeStr:string)=>choseIcon(typeStr)"
|
@confirm="(typeStr:string)=>choseIcon(typeStr)"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -235,7 +235,6 @@ const filterMenus = (menus: any[]) => {
|
||||||
item.children = filterMenus(item.children);
|
item.children = filterMenus(item.children);
|
||||||
}
|
}
|
||||||
if (!filterProtocolList.length && item.code == 'link/DataCollect') {
|
if (!filterProtocolList.length && item.code == 'link/DataCollect') {
|
||||||
debugger
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return item
|
return item
|
||||||
|
|
|
@ -24,6 +24,10 @@ import iconKeys from './fields';
|
||||||
const emits = defineEmits(['confirm', 'update:visible']);
|
const emits = defineEmits(['confirm', 'update:visible']);
|
||||||
const props = defineProps<{
|
const props = defineProps<{
|
||||||
visible: boolean;
|
visible: boolean;
|
||||||
|
icon:{
|
||||||
|
type:string,
|
||||||
|
default:''
|
||||||
|
}
|
||||||
}>();
|
}>();
|
||||||
|
|
||||||
const confirm = () => {
|
const confirm = () => {
|
||||||
|
@ -31,7 +35,13 @@ const confirm = () => {
|
||||||
emits('update:visible', false);
|
emits('update:visible', false);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
const selected = ref<string>('');
|
const selected = ref<string>('');
|
||||||
|
|
||||||
|
onMounted(()=>{
|
||||||
|
console.log(props)
|
||||||
|
props?.icon ? selected.value = props.icon : ''
|
||||||
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="less" scoped>
|
<style lang="less" scoped>
|
||||||
|
|
|
@ -23,6 +23,7 @@
|
||||||
hasPermission="system/Platforms/Setting:update"
|
hasPermission="system/Platforms/Setting:update"
|
||||||
@click="save"
|
@click="save"
|
||||||
v-if="props.mode !== 'home'"
|
v-if="props.mode !== 'home'"
|
||||||
|
style="margin-left: 20px;"
|
||||||
>
|
>
|
||||||
保存
|
保存
|
||||||
</PermissionButton>
|
</PermissionButton>
|
||||||
|
|
|
@ -157,7 +157,7 @@ const filterPath = (path: object, filterArr: string[]) => {
|
||||||
.ant-tree-list {
|
.ant-tree-list {
|
||||||
.ant-tree-list-holder-inner {
|
.ant-tree-list-holder-inner {
|
||||||
.ant-tree-switcher-noop {
|
.ant-tree-switcher-noop {
|
||||||
display: none !important;
|
// display: none !important;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,11 +3,11 @@
|
||||||
<div class="top">
|
<div class="top">
|
||||||
<slot name="top" />
|
<slot name="top" />
|
||||||
</div>
|
</div>
|
||||||
<j-row :gutter="24" class="content">
|
<j-row class="content" :style="{padding:'24px'}" >
|
||||||
<j-col
|
<j-col
|
||||||
:span="24"
|
:span="24"
|
||||||
v-if="props.showTitle"
|
v-if="props.showTitle"
|
||||||
style="font-size: 16px; margin-bottom: 48px"
|
style="font-size: 16px;margin-bottom: 48px;"
|
||||||
>
|
>
|
||||||
API文档
|
API文档
|
||||||
</j-col>
|
</j-col>
|
||||||
|
@ -180,7 +180,6 @@ watch(
|
||||||
.api-page-container {
|
.api-page-container {
|
||||||
.content {
|
.content {
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
padding: 24px;
|
|
||||||
margin: 0 !important;
|
margin: 0 !important;
|
||||||
.tree-content {
|
.tree-content {
|
||||||
padding-bottom: 30px;
|
padding-bottom: 30px;
|
||||||
|
|
|
@ -64,8 +64,10 @@ const confirm = () => {
|
||||||
|
|
||||||
if (route.query.save) {
|
if (route.query.save) {
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
window?.onTabSaveSuccess(resp.result.id);
|
if((window as any).onTabSaveSuccess){
|
||||||
|
(window as any).onTabSaveSuccess(resp.result.id);
|
||||||
setTimeout(() => window.close(), 300);
|
setTimeout(() => window.close(), 300);
|
||||||
|
}
|
||||||
} else jumpPage(`system/Role/Detail`, { id: resp.result.id });
|
} else jumpPage(`system/Role/Detail`, { id: resp.result.id });
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in New Issue