mirror of
https://github.com/myvesta/vesta
synced 2025-08-14 10:37:42 -07:00
Correct indentation
This commit is contained in:
parent
d1b1f97ff4
commit
c57e10156e
21 changed files with 515 additions and 515 deletions
|
@ -1,41 +1,41 @@
|
|||
<script>
|
||||
function randomString() {
|
||||
var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
|
||||
var string_length = 10;
|
||||
var randomstring = '';
|
||||
for (var i = 0; i < string_length; i++) {
|
||||
var rnum = Math.floor(Math.random() * chars.length);
|
||||
randomstring += chars.substr(rnum, 1);
|
||||
}
|
||||
document.v_edit_user.v_password.value = randomstring;
|
||||
<script>
|
||||
function randomString() {
|
||||
var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
|
||||
var string_length = 10;
|
||||
var randomstring = '';
|
||||
for (var i = 0; i < string_length; i++) {
|
||||
var rnum = Math.floor(Math.random() * chars.length);
|
||||
randomstring += chars.substr(rnum, 1);
|
||||
}
|
||||
document.v_edit_user.v_password.value = randomstring;
|
||||
}
|
||||
|
||||
$(document).ready(function(){
|
||||
$('.add-ns-button').click(function(){
|
||||
var n = $("input[name^=v_ns]").length;
|
||||
if(n < 8){
|
||||
var t = $($('input[name=v_ns1]').parents('tr')[0]).clone(true, true);
|
||||
t.find('input').attr({value:'', name:'v_ns'+(n+1)});
|
||||
t.find('span').show();
|
||||
$('tr.add-ns').before(t);
|
||||
}
|
||||
if( n == 7 ) {
|
||||
$('.add-ns').hide();
|
||||
}
|
||||
});
|
||||
|
||||
$(document).ready(function(){
|
||||
$('.add-ns-button').click(function(){
|
||||
var n = $("input[name^=v_ns]").length;
|
||||
if(n < 8){
|
||||
var t = $($('input[name=v_ns1]').parents('tr')[0]).clone(true, true);
|
||||
t.find('input').attr({value:'', name:'v_ns'+(n+1)});
|
||||
t.find('span').show();
|
||||
$('tr.add-ns').before(t);
|
||||
}
|
||||
if( n == 7 ) {
|
||||
$('.add-ns').hide();
|
||||
}
|
||||
});
|
||||
|
||||
$('.remove-ns').click(function(){
|
||||
$(this).parents('tr')[0].remove();
|
||||
$('input[name^=v_ns]').each(function(i, ns){
|
||||
$(ns).attr({name: 'v_ns'+(i+1)});
|
||||
i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
|
||||
});
|
||||
$('.add-ns').show();
|
||||
});
|
||||
|
||||
$('input[name^=v_ns]').each(function(i, ns){
|
||||
i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
|
||||
});
|
||||
|
||||
$('.remove-ns').click(function(){
|
||||
$(this).parents('tr')[0].remove();
|
||||
$('input[name^=v_ns]').each(function(i, ns){
|
||||
$(ns).attr({name: 'v_ns'+(i+1)});
|
||||
i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
|
||||
});
|
||||
</script>
|
||||
$('.add-ns').show();
|
||||
});
|
||||
|
||||
$('input[name^=v_ns]').each(function(i, ns){
|
||||
i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
|
||||
});
|
||||
|
||||
});
|
||||
</script>
|
||||
|
|
|
@ -1,42 +1,42 @@
|
|||
<script>
|
||||
function WEBrandom() {
|
||||
var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
|
||||
var string_length = 10;
|
||||
var webrandom = '';
|
||||
for (var i = 0; i < string_length; i++) {
|
||||
var rnum = Math.floor(Math.random() * chars.length);
|
||||
webrandom += chars.substr(rnum, 1);
|
||||
}
|
||||
document.v_edit_web.v_stats_password.value = webrandom;
|
||||
}
|
||||
<script>
|
||||
function WEBrandom() {
|
||||
var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
|
||||
var string_length = 10;
|
||||
var webrandom = '';
|
||||
for (var i = 0; i < string_length; i++) {
|
||||
var rnum = Math.floor(Math.random() * chars.length);
|
||||
webrandom += chars.substr(rnum, 1);
|
||||
}
|
||||
document.v_edit_web.v_stats_password.value = webrandom;
|
||||
}
|
||||
|
||||
function FTPrandom(elm) {
|
||||
var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
|
||||
var string_length = 10;
|
||||
var webrandom = '';
|
||||
for (var i = 0; i < string_length; i++) {
|
||||
var rnum = Math.floor(Math.random() * chars.length);
|
||||
webrandom += chars.substr(rnum, 1);
|
||||
}
|
||||
function FTPrandom(elm) {
|
||||
var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
|
||||
var string_length = 10;
|
||||
var webrandom = '';
|
||||
for (var i = 0; i < string_length; i++) {
|
||||
var rnum = Math.floor(Math.random() * chars.length);
|
||||
webrandom += chars.substr(rnum, 1);
|
||||
}
|
||||
|
||||
$(elm).parents('.ftptable').find('.v-ftp-user-psw').val(ftprandomstring);
|
||||
App.Actions.WEB.randomPasswordGenerated && App.Actions.WEB.randomPasswordGenerated(elm);
|
||||
}
|
||||
$(elm).parents('.ftptable').find('.v-ftp-user-psw').val(ftprandomstring);
|
||||
App.Actions.WEB.randomPasswordGenerated && App.Actions.WEB.randomPasswordGenerated(elm);
|
||||
}
|
||||
|
||||
function elementHideShow(elementToHideOrShow){
|
||||
var el = document.getElementById(elementToHideOrShow);
|
||||
el.style.display = el.style.display === 'none' ? 'block' : 'none';
|
||||
}
|
||||
function elementHideShow(elementToHideOrShow){
|
||||
var el = document.getElementById(elementToHideOrShow);
|
||||
el.style.display = el.style.display === 'none' ? 'block' : 'none';
|
||||
}
|
||||
|
||||
$('#vstobjects').bind('submit', function(evt) {
|
||||
$('input[disabled]').each(function(i, elm) {
|
||||
var copy_elm = $(elm).clone(true);
|
||||
$(copy_elm).attr('type', 'hidden');
|
||||
$(copy_elm).removeAttr('disabled');
|
||||
$(elm).after(copy_elm);
|
||||
});
|
||||
});
|
||||
$('#vstobjects').bind('submit', function(evt) {
|
||||
$('input[disabled]').each(function(i, elm) {
|
||||
var copy_elm = $(elm).clone(true);
|
||||
$(copy_elm).attr('type', 'hidden');
|
||||
$(copy_elm).removeAttr('disabled');
|
||||
$(elm).after(copy_elm);
|
||||
});
|
||||
});
|
||||
|
||||
GLOBAL.FTP_USER_PREFIX = <?=json_encode($user.'_')?>;
|
||||
</script>
|
||||
<script src="/js/pages/edit.web.js"></script>
|
||||
GLOBAL.FTP_USER_PREFIX = <?=json_encode($user.'_')?>;
|
||||
</script>
|
||||
<script src="/js/pages/edit.web.js"></script>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue