Skip to content

Commit 454fd8d

Browse files
authored
Merge pull request hestiacp#318 from Lupul/Bugfix-0518
Bugfix 0518
2 parents 8e58e27 + abe14f8 commit 454fd8d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+65
-50
lines changed

.gitignore

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,11 @@
77

88
.vscode
99
.DS_Store
10+
11+
.env
12+
composer.phar
13+
composer.lock
14+
test/vendor/
15+
test/node_modules/
16+
npm-debug.log
17+
.phpunit.result.cache

web/js/init.js

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,18 @@ $(document).ready(function(){
1111
var selectedOption = $(this).find(":selected").text();
1212
$(this).next(".holder").text(selectedOption);
1313
}).trigger('change');
14-
$('.to-top').bind('click', function(evt) {
14+
$('.to-top').on('click', function(evt) {
1515
$("html, body").animate({ scrollTop: 0 }, "normal");
1616
});
1717

18+
$('.ui-button').on('click',function(evt){
19+
var action = $(this).data('action');
20+
var id = $(this).data('id');
21+
if(action=='submit' && document.getElementById(id)){
22+
evt.preventDefault();
23+
$(document.getElementById(id)).submit();
24+
}
25+
});
1826

1927
var isMobile = false; //initiate as false
2028
// device detection
@@ -194,7 +202,7 @@ $(document).ready(function(){
194202
}
195203
);
196204

197-
$(window).bind('keypress', function(evt) {
205+
$(window).on('keypress', function(evt) {
198206
var tag = evt.target.tagName.toLowerCase();
199207
if (evt.charCode == 97 && tag != 'input' && tag != 'textarea' && tag != 'selectbox') {
200208
evt.preventDefault();
@@ -588,7 +596,7 @@ $(document).ready(function(){
588596
}
589597

590598
//
591-
$('form#objects').bind('submit', function(evt) {
599+
$('form#objects').on('submit', function(evt) {
592600
$('.l-unit').find('.ch-toggle').prop('checked', false);
593601
$('.l-unit.selected').find('.ch-toggle').prop('checked', true);
594602
});

web/js/iviewer/test/lightbox-gallery/main.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@
6060
close();
6161
});
6262

63-
$("#iviewer").bind('fadein', function() {
63+
$("#iviewer").on('fadein', function() {
6464
$(window).keydown(function(e) {
6565
if (e.which == 27) close();
6666
});

web/js/iviewer/test/lightbox/main.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
close();
5050
});
5151

52-
$("#iviewer").bind('fadein', function() {
52+
$("#iviewer").on('fadein', function() {
5353
$(window).keydown(function(e) {
5454
if (e.which == 27) close();
5555
});

web/js/pages/add_mail_acc.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ App.Helpers.isUnlimitedValue = function(value) {
6666
// Trigger listeners
6767
App.Listeners.MAIL_ACC.init();
6868
App.Listeners.MAIL_ACC.checkbox_unlimited_feature();
69-
$('form[name="v_quota"]').bind('submit', function(evt) {
69+
$('form[name="v_quota"]').on('submit', function(evt) {
7070
$('input:disabled').each(function(i, elm) {
7171
$(elm).attr('disabled', false);
7272
if (App.Helpers.isUnlimitedValue($(elm).val())) {

web/js/pages/add_package.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ App.Helpers.isUnlimitedValue = function(value) {
6767
// Trigger listeners
6868
App.Listeners.PACKAGE.init();
6969
App.Listeners.PACKAGE.checkbox_unlimited_feature();
70-
$('form[name="v_add_package"]').bind('submit', function(evt) {
70+
$('form[name="v_add_package"]').on('submit', function(evt) {
7171
$('input:disabled').each(function(i, elm) {
7272
$(elm).attr('disabled', false);
7373
if (App.Helpers.isUnlimitedValue($(elm).val())) {

web/js/pages/add_web.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ function FTPrandom(elm) {
211211
$(elm).parents('.ftptable').find('.v-ftp-user-psw').val(ftprandomstring);
212212
}
213213

214-
$('#vstobjects').bind('submit', function(evt) {
214+
$('#vstobjects').on('submit', function(evt) {
215215
$('input[disabled]').each(function(i, elm) {
216216
$(elm).removeAttr('disabled');
217217
});

web/js/pages/edit_mail.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ function elementHideShow(elementToHideOrShow){
2626
el.style.display = el.style.display === 'none' ? 'block' : 'none';
2727
}
2828

29-
$('#vstobjects').bind('submit', function(evt) {
29+
$('#vstobjects').on('submit', function(evt) {
3030
$('input[disabled]').each(function(i, elm) {
3131
var copy_elm = $(elm).clone(true);
3232
$(copy_elm).attr('type', 'hidden');

web/js/pages/edit_mail_acc.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ App.Helpers.isUnlimitedValue = function(value) {
6767
// Trigger listeners
6868
App.Listeners.MAIL_ACC.init();
6969
App.Listeners.MAIL_ACC.checkbox_unlimited_feature();
70-
$('form[name="v_quota"]').bind('submit', function(evt) {
70+
$('form[name="v_quota"]').on('submit', function(evt) {
7171
$('input:disabled').each(function(i, elm) {
7272
$(elm).attr('disabled', false);
7373
if (App.Helpers.isUnlimitedValue($(elm).val())) {

web/js/pages/edit_package.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ App.Helpers.isUnlimitedValue = function(value) {
6767
// Trigger listeners
6868
App.Listeners.PACKAGE.init();
6969
App.Listeners.PACKAGE.checkbox_unlimited_feature();
70-
$('form[name="v_edit_package"]').bind('submit', function(evt) {
70+
$('form[name="v_edit_package"]').on('submit', function(evt) {
7171
$('input:disabled').each(function(i, elm) {
7272
$(elm).attr('disabled', false);
7373
if (App.Helpers.isUnlimitedValue($(elm).val())) {

0 commit comments

Comments
 (0)