Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
scc-net
netvs
netvs-core
Commits
d628830b
Commit
d628830b
authored
Jan 28, 2021
by
Janis Streib
🦉
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ADD: default value for A record create (closes
#228
)
parent
0d02dca3
Pipeline
#130090
passed with stages
in 6 minutes and 19 seconds
Changes
1
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
0 deletions
+17
-0
frontend/src/views/dnsvs/BCDRecords.vue
frontend/src/views/dnsvs/BCDRecords.vue
+17
-0
No files found.
frontend/src/views/dnsvs/BCDRecords.vue
View file @
d628830b
...
...
@@ -496,6 +496,9 @@ export default {
reverseIfDesc
(
rec_type
,
arr
)
{
return
(
this
.
sort_dir
[
rec_type
]
===
'
ascending
'
)
?
arr
:
[...
arr
].
reverse
()
},
reverseIfAsc
(
rec_type
,
arr
)
{
return
(
this
.
sort_dir
[
rec_type
]
===
'
descending
'
)
?
arr
:
[...
arr
].
reverse
()
},
upperIfAsc
(
rec_type
)
{
return
(
this
.
sort_dir
[
rec_type
]
===
'
ascending
'
)
?
this
.
asc_v4_blocklist_by_upper
:
this
.
asc_v4_blocklist_by_lower
},
...
...
@@ -608,6 +611,20 @@ export default {
this
.
db_editor_presets
.
data
=
sub
.
cidr
.
split
(
'
/
'
)[
0
]
}
}
if
(
record_type
===
'
A
'
)
{
let
res_ip
=
null
for
(
const
bl
of
this
.
reverseIfAsc
(
'
A
'
,
this
.
asc_v4_blocklist
))
{
for
(
const
b
of
bl
.
containing_blocks
)
{
if
(
b
.
type
===
'
free
'
)
{
res_ip
=
b
.
first
break
}
}
}
if
(
res_ip
!==
null
)
{
this
.
db_editor_presets
.
data
=
res_ip
}
}
this
.
create_record_reducer
=
{
type
:
false
}
this
.
$root
.
$emit
(
'
bv::show::modal
'
,
'
create_record
'
)
},
...
...
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