created sync for server
This commit is contained in:
@@ -20,3 +20,17 @@
|
||||
//= require ace/mode-apache_conf
|
||||
//= require ace/mode-ini
|
||||
//= require ace/mode-dockerfile
|
||||
|
||||
// $(".click-to-select-all").click(function() {
|
||||
// var $this = $(this);
|
||||
// $this.select();
|
||||
//
|
||||
// // Work around Chrome's little problem
|
||||
// $this.mouseup(function() {
|
||||
// // Prevent further mouseup intervention
|
||||
// $this.unbind("mouseup");
|
||||
// return false;
|
||||
// });
|
||||
// });
|
||||
|
||||
$(".click-to-select-all").click(function() { $(this).select(); });
|
||||
|
||||
@@ -42,12 +42,12 @@
|
||||
<div class="col-md-6">
|
||||
<% command = pull_command(@record) %>
|
||||
CHUB -> Your Server<br />
|
||||
<%= text_field_tag 'command_pull', command, readonly: true, class: 'form-control-sm', size: command.length %>
|
||||
<%= text_field_tag 'command_pull', command, readonly: true, class: 'form-control-sm click-to-select-all', size: command.length %>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<% command = push_command(@record) %>
|
||||
Your Server -> CHUB<br />
|
||||
<%= text_field_tag 'command_push', command, readonly: true, class: 'form-control-sm', size: command.length %>
|
||||
<%= text_field_tag 'command_push', command, readonly: true, class: 'form-control-sm click-to-select-all', size: command.length %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -14,5 +14,12 @@ CHUB
|
||||
<div class="container-fluid">
|
||||
<%= yield %>
|
||||
</div>
|
||||
|
||||
<footer>
|
||||
<br /> <br />
|
||||
<p>
|
||||
Saburly Configuration Hub (c) 2016
|
||||
</p>
|
||||
</footer>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@@ -60,6 +60,30 @@
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<%
|
||||
pull_commands = @record.configuration_files.map do |file|
|
||||
pull_command(file)
|
||||
end.join("\n")
|
||||
|
||||
push_commands = @record.configuration_files.map do |file|
|
||||
push_command(file)
|
||||
end.join("\n")
|
||||
|
||||
%>
|
||||
<h3>Sync Server: </h3>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
|
||||
CHUB -> Your Server<br />
|
||||
<%= text_area_tag 'command_pull', pull_commands, readonly: true, class: 'form-control-sm click-to-select-all', size: "80x10" %>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
Your Server -> CHUB<br />
|
||||
<%= text_area_tag 'command_push', push_commands, readonly: true, class: 'form-control-sm click-to-select-all', size: "80x10" %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<% end %>
|
||||
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user