- GRAYBYTE UNDETECTABLE CODES -

403Webshell
Server IP : 184.154.167.98  /  Your IP : 3.22.242.84
Web Server : Apache
System : Linux pink.dnsnetservice.com 4.18.0-553.22.1.lve.1.el8.x86_64 #1 SMP Tue Oct 8 15:52:54 UTC 2024 x86_64
User : puertode ( 1767)
PHP Version : 8.2.26
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /home/puertode/public_html/fotografico/apps/survey_client/js/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /home/puertode/public_html/fotografico/apps/survey_client/js/admin.js
$(document).ready(function() {
	var $section = $('#survey_client');
	$section.find('.survey_client_category').change(function() {
		var $button = $(this);
		$button.attr('disabled', true);

		OCP.AppConfig.setValue(
			'survey_client',
			$(this).attr('name').substring(14),
			$(this).attr('checked') ? 'yes' : 'no',
			{
				success: function() {
					$button.attr('disabled', false);
				}
			}
		);
	});

	$section.find('#survey_client_monthly_report').change(function() {
		var $button = $(this);
		$button.attr('disabled', true);

		$.ajax({
			url: OC.linkToOCS('apps/survey_client/api/v1', 2) + 'monthly?format=json',
			type: $(this).attr('checked') ? 'POST' : 'DELETE',
			success: function() {
				$button.attr('disabled', false);
			}
		});
	});

	$section.find('button').click(function() {
		var $button = $(this);
		$button.attr('disabled', true);
		$.ajax({
			url: OC.linkToOCS('apps/survey_client/api/v1', 2) + 'report?format=json',
			type: 'POST',
			success: function(response) {
				$button.attr('disabled', false);

				$section.find('.last_report').text(JSON.stringify(response.ocs.data, undefined, 4));
				$section.find('.last_sent').text(t('survey_client', 'Last report sent on: {on}', {
					on: moment().format('LL')
				}));
				$section.find('.last_report').closest('div').removeClass('empty');
			},
			error: function(xhr) {
				$button.attr('disabled', false);
				OCP.Toast.error(t('survey_client', 'An error occurred while sending your report.'));

				var response = xhr.responseJSON;
				$section.find('.last_report').text(JSON.stringify(response.ocs.data, undefined, 4));
			}
		});
	});

	$('#last_report h3').on('click', function(e) {
		if (!$(this).parent().hasClass('empty')) {
			$(this).parent().find('p').toggleClass('hidden');
			$(this).find('.icon').toggleClass('icon-triangle-s');
		}
	});
});

Youez - 2016 - github.com/yon3zu
LinuXploit