Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
so-manage-ui
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
smart-operation
so-manage-ui
Commits
c16e9637
Commit
c16e9637
authored
Nov 15, 2023
by
张耀
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:
修复bug:10652 【研发环境】编辑完成后,未返回到当前位置
parent
a6f0ced0
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
29 additions
and
10 deletions
+29
-10
src/page/main/forewarning/indicator-config/edit/index.vue
src/page/main/forewarning/indicator-config/edit/index.vue
+1
-1
src/page/main/forewarning/indicator-config/modules/slide.vue
src/page/main/forewarning/indicator-config/modules/slide.vue
+28
-8
src/page/main/forewarning/indicator-config/modules/warning-scope.vue
...in/forewarning/indicator-config/modules/warning-scope.vue
+0
-1
No files found.
src/page/main/forewarning/indicator-config/edit/index.vue
View file @
c16e9637
...
@@ -34,7 +34,7 @@ const SaveSubmit = async () => {
...
@@ -34,7 +34,7 @@ const SaveSubmit = async () => {
});
});
};
};
const
Cancle
=
()
=>
{
const
Cancle
=
()
=>
{
router
.
go
(
-
1
);
router
.
push
(
`/forewarning/indicator-config?class_id=
${
class_id
}
`
);
};
};
const
getInfoData
=
()
=>
{
const
getInfoData
=
()
=>
{
axios
axios
...
...
src/page/main/forewarning/indicator-config/modules/slide.vue
View file @
c16e9637
...
@@ -107,6 +107,9 @@ import { nextTick, onBeforeMount, reactive, ref } from "vue";
...
@@ -107,6 +107,9 @@ import { nextTick, onBeforeMount, reactive, ref } from "vue";
import
GapTitle
from
"
@/components/gap-title.vue
"
;
import
GapTitle
from
"
@/components/gap-title.vue
"
;
import
axios
from
"
@/request/http.js
"
;
import
axios
from
"
@/request/http.js
"
;
import
{
ElMessage
}
from
"
element-plus
"
;
import
{
ElMessage
}
from
"
element-plus
"
;
import
{
useRoute
}
from
"
vue-router
"
;
const
route
=
useRoute
();
const
{
class_id
}
=
route
.
query
;
const
props
=
defineProps
({
const
props
=
defineProps
({
modelValue
:
{
modelValue
:
{
type
:
Object
,
type
:
Object
,
...
@@ -123,9 +126,31 @@ const treeProps = {
...
@@ -123,9 +126,31 @@ const treeProps = {
const
treeRef
=
ref
(
null
);
const
treeRef
=
ref
(
null
);
const
selectId
=
ref
(
""
);
const
selectId
=
ref
(
""
);
const
getSlideTree
=
()
=>
{
const
getSlideTree
=
()
=>
{
axios
.
get
(
"
/v1/api/alert_class/tree
"
).
then
(
async
(
res
)
=>
{
axios
.
get
(
"
/v1/api/alert_class/tree
"
).
then
((
res
)
=>
{
if
(
res
.
data
.
code
==
200
)
{
if
(
res
.
data
.
code
==
200
)
{
slideTree
.
value
=
res
.
data
.
data
;
slideTree
.
value
=
res
.
data
.
data
;
async
function
nodeChoose
(
item
)
{
await
nextTick
();
treeRef
.
value
.
setCurrentKey
(
item
.
class_id
);
const
node
=
treeRef
.
value
.
getNode
(
item
);
if
(
node
)
{
treeNodeChoose
(
item
,
node
);
}
}
if
(
class_id
)
{
let
item
=
null
;
slideTree
.
value
.
forEach
((
e
)
=>
{
if
(
e
.
children
&&
e
.
children
.
length
>
0
)
{
e
.
children
.
forEach
((
e
)
=>
{
if
(
e
.
class_id
==
class_id
)
{
item
=
e
;
}
});
}
});
nodeChoose
(
item
);
return
;
}
try
{
try
{
slideTree
.
value
.
forEach
((
e
)
=>
{
slideTree
.
value
.
forEach
((
e
)
=>
{
if
(
e
.
children
&&
e
.
children
.
length
>
0
)
{
if
(
e
.
children
&&
e
.
children
.
length
>
0
)
{
...
@@ -133,12 +158,7 @@ const getSlideTree = () => {
...
@@ -133,12 +158,7 @@ const getSlideTree = () => {
}
}
});
});
}
catch
(
item
)
{
}
catch
(
item
)
{
await
nextTick
();
nodeChoose
(
item
);
treeRef
.
value
.
setCurrentKey
(
item
.
class_id
);
const
node
=
treeRef
.
value
.
getNode
(
item
);
if
(
node
)
{
treeNodeChoose
(
item
,
node
);
}
}
}
}
else
{
}
else
{
ElMessage
.
error
(
res
.
data
.
msg
);
ElMessage
.
error
(
res
.
data
.
msg
);
...
@@ -156,7 +176,7 @@ const Search = async () => {
...
@@ -156,7 +176,7 @@ const Search = async () => {
const
Add
=
()
=>
{
const
Add
=
()
=>
{
addWarnType
.
value
=
true
;
addWarnType
.
value
=
true
;
};
};
const
emits
=
defineEmits
([
"
u
n
date:modelValue
"
]);
const
emits
=
defineEmits
([
"
u
p
date:modelValue
"
]);
const
treeNodeChoose
=
(
data
,
node
)
=>
{
const
treeNodeChoose
=
(
data
,
node
)
=>
{
emits
(
"
update:modelValue
"
,
{
data
,
node
});
emits
(
"
update:modelValue
"
,
{
data
,
node
});
};
};
...
...
src/page/main/forewarning/indicator-config/modules/warning-scope.vue
View file @
c16e9637
...
@@ -349,7 +349,6 @@ const Submit = async () => {
...
@@ -349,7 +349,6 @@ const Submit = async () => {
form_ref
.
value
.
validate
((
res
)
=>
resolve
(
res
));
form_ref
.
value
.
validate
((
res
)
=>
resolve
(
res
));
});
});
let
isFull
=
true
;
let
isFull
=
true
;
console
.
log
(
state
.
form
.
warningScopeRows
);
try
{
try
{
state
.
form
.
warningScopeRows
.
forEach
((
e
,
i
)
=>
{
state
.
form
.
warningScopeRows
.
forEach
((
e
,
i
)
=>
{
if
(
e
.
indicator_scope
==
""
||
e
.
indicator_tag
==
""
)
{
if
(
e
.
indicator_scope
==
""
||
e
.
indicator_tag
==
""
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment