Adds buttons to test availability of server from public internet
This commit is contained in:
@ -42,6 +42,9 @@
|
||||
<% if (provider === 'letsencrypt') { %>
|
||||
<a href="#" class="renew dropdown-item"><i class="dropdown-icon fe fe-refresh-cw"></i> <%- i18n('certificates', 'force-renew') %></a>
|
||||
<a href="#" class="download dropdown-item"><i class="dropdown-icon fe fe-download"></i> <%- i18n('certificates', 'download') %></a>
|
||||
<% if (meta.dns_challenge === false) { %>
|
||||
<a href="#" class="test dropdown-item"><i class="dropdown-icon fe fe-globe"></i> <%- i18n('certificates', 'test-reachability') %></a>
|
||||
<% } %>
|
||||
<div class="dropdown-divider"></div>
|
||||
<% } %>
|
||||
<a href="#" class="delete dropdown-item"><i class="dropdown-icon fe fe-trash-2"></i> <%- i18n('str', 'delete') %></a>
|
||||
|
@ -2,7 +2,7 @@ const Mn = require('backbone.marionette');
|
||||
const moment = require('moment');
|
||||
const App = require('../../../main');
|
||||
const template = require('./item.ejs');
|
||||
const dns_providers = require('../../../../../../global/certbot-dns-plugins')
|
||||
const dns_providers = require('../../../../../../global/certbot-dns-plugins');
|
||||
|
||||
module.exports = Mn.View.extend({
|
||||
template: template,
|
||||
@ -12,7 +12,8 @@ module.exports = Mn.View.extend({
|
||||
host_link: '.host-link',
|
||||
renew: 'a.renew',
|
||||
delete: 'a.delete',
|
||||
download: 'a.download'
|
||||
download: 'a.download',
|
||||
test: 'a.test'
|
||||
},
|
||||
|
||||
events: {
|
||||
@ -31,11 +32,16 @@ module.exports = Mn.View.extend({
|
||||
let win = window.open($(e.currentTarget).attr('rel'), '_blank');
|
||||
win.focus();
|
||||
},
|
||||
|
||||
|
||||
'click @ui.download': function (e) {
|
||||
e.preventDefault();
|
||||
App.Api.Nginx.Certificates.download(this.model.get('id'))
|
||||
}
|
||||
App.Api.Nginx.Certificates.download(this.model.get('id'));
|
||||
},
|
||||
|
||||
'click @ui.test': function (e) {
|
||||
e.preventDefault();
|
||||
App.Controller.showNginxCertificateTestReachability(this.model);
|
||||
},
|
||||
},
|
||||
|
||||
templateContext: {
|
||||
|
Reference in New Issue
Block a user