Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
aaPanel
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kulya
aaPanel
Commits
824cf8ad
Commit
824cf8ad
authored
Jun 26, 2019
by
jose
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add panel run log view button
parent
91b071c0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
64 additions
and
1 deletion
+64
-1
config.js
BTPanel/static/js/config.js
+64
-1
No files found.
BTPanel/static/js/config.js
View file @
824cf8ad
...
...
@@ -519,4 +519,67 @@ function SetIPv6() {
layer
.
close
(
loadT
);
bt
.
msg
(
rdata
);
});
}
\ No newline at end of file
}
function
modify_basic_auth_to
()
{
var
pdata
=
{
open
:
$
(
"
select[name='open']
"
).
val
(),
basic_user
:
$
(
"
input[name='basic_user']
"
).
val
(),
basic_pwd
:
$
(
"
input[name='basic_pwd']
"
).
val
()
}
var
loadT
=
layer
.
msg
(
lan
.
config
.
set_basicauth
,
{
icon
:
16
,
time
:
0
,
shade
:
[
0.3
,
'
#000
'
]
});
$
.
post
(
'
/config?action=set_basic_auth
'
,
pdata
,
function
(
rdata
)
{
layer
.
close
(
loadT
);
if
(
rdata
.
status
)
{
layer
.
closeAll
();
setTimeout
(
function
()
{
window
.
location
.
reload
();
},
3000
);
}
layer
.
msg
(
rdata
.
msg
,
{
icon
:
rdata
.
status
?
1
:
2
});
});
}
function
modify_basic_auth
()
{
var
loadT
=
layer
.
msg
(
lan
.
config
.
setting_basicauth
,
{
icon
:
16
,
time
:
0
,
shade
:
[
0.3
,
'
#000
'
]
});
$
.
post
(
'
/config?action=get_basic_auth_stat
'
,
{},
function
(
rdata
)
{
layer
.
close
(
loadT
);
layer
.
open
({
type
:
1
,
area
:
"
500px
"
,
title
:
lan
.
config
.
set_basicauth
,
closeBtn
:
2
,
shift
:
5
,
shadeClose
:
false
,
content
:
'
<div class="bt-form bt-form" style="padding:15px 25px">
\
<div class="line">
\
<span class="tname">
'
+
lan
.
public
.
server_status
+
'
</span>
\
<div class="info-r" style="height:28px;">
\
<select class="bt-input-text" name="open">
\
<option value="True"
'
+
(
rdata
.
open
?
'
selected
'
:
''
)
+
'
>
'
+
lan
.
public
.
on
+
'
</option>
\
<option value="False"
'
+
(
rdata
.
open
?
''
:
'
selected
'
)
+
'
>
'
+
lan
.
public
.
off
+
'
</option>
\
</select>
\
</div>
\
</div>
\
<div class="line">
\
<span class="tname">
'
+
lan
.
public
.
username
+
'
</span>
\
<div class="info-r">
\
<input name="basic_user" class="bt-input-text mr5" type="text" style="width: 310px" value="" placeholder="
'
+
(
rdata
.
basic_user
?
lan
.
crontab
.
not_modified
:
lan
.
crontab
.
set_username
)
+
'
">
\
</div>
\
</div>
\
<div class="line">
\
<span class="tname">
'
+
lan
.
public
.
pass
+
'
</span>
\
<div class="info-r">
\
<input name="basic_pwd" class="bt-input-text mr5" type="text" style="width: 310px" value="" placeholder="
'
+
(
rdata
.
basic_pwd
?
lan
.
crontab
.
not_modified
:
lan
.
crontab
.
set_passwd
)
+
'
">
\
</div>
\
</div>
\
<span><button class="btn btn-success btn-sm" style=" margin-left: 340px;" onclick="modify_basic_auth_to()">
'
+
lan
.
public
.
save
+
'
</button></span>
\
<ul class="help-info-text c7">
\
<li style="color:red;">
'
+
lan
.
config
.
basic_auth_tips1
+
'
</li>
\
<li>
'
+
lan
.
config
.
basic_auth_tips2
+
'
</li>
\
<li>
'
+
lan
.
config
.
basic_auth_tips3
+
'
</li>
\
</ul>
\
</div>
'
})
});
}
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