$(document).ready(function () { var type = $('#sslCertificate').data('type'); $('#sslCertificate').on('click', 'td.remove', function () { var row = $(this).parent(); $.ajax(OC.generateUrl('settings/' + type + '/certificate/{certificate}', {certificate: row.data('name')}), { type: 'DELETE' }); row.remove(); if ($('#sslCertificate > tbody > tr').length === 0) { $('#sslCertificate').hide(); } return true; }); $('#sslCertificate tr > td').tipsy({gravity: 'n', live: true}); $('#rootcert_import').fileupload({ pasteZone: null, submit: function (e, data) { data.formData = _.extend(data.formData || {}, { requesttoken: OC.requestToken }); }, success: function (data) { if (typeof data === 'string') { data = JSON.parse(data); } else if (data && data.length) { // fetch response from iframe data = JSON.parse(data[0].body.innerText); } if (!data || typeof(data) === 'string') { // IE8 iframe workaround comes here instead of fail() OC.Notification.showTemporary( t('settings', 'An error occurred. Please upload an ASCII-encoded PEM certificate.')); return; } var issueDate = new Date(data.validFrom * 1000); var expireDate = new Date(data.validTill * 1000); var now = new Date(); var isExpired = !(issueDate <= now && now <= expireDate); var row = $(''); row.data('name', data.name); row.addClass(isExpired ? 'expired' : 'valid'); row.append($('').attr('title', data.organization).text(data.commonName)); row.append($('').attr('title', t('core,', 'Valid until {date}', {date: data.validTillString})) .text(data.validTillString)); row.append($('').attr('title', data.issuerOrganization).text(data.issuer)); row.append($('').addClass('remove').append( $('').attr({ alt: t('core', 'Delete'), title: t('core', 'Delete'), src: OC.imagePath('core', 'actions/delete.svg') }).addClass('action') )); $('#sslCertificate tbody').append(row); $('#sslCertificate').show(); }, fail: function () { OC.Notification.showTemporary( t('settings', 'An error occurred. Please upload an ASCII-encoded PEM certificate.')); } }); if ($('#sslCertificate > tbody > tr').length === 0) { $('#sslCertificate').hide(); } }); event-listeners Nextcloud server, a safe home for all your data: https://github.com/nextcloud/serverwww-data
summaryrefslogtreecommitdiffstats
path: root/lib/l10n/pt_PT.php
blob: e6dd459a7e10f56ec8c7b65f89220b06eb14966a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66