Skip to content

Commit de0fc08

Browse files
committed
fix codemirror
1 parent cc8b922 commit de0fc08

File tree

2 files changed

+6
-9
lines changed

2 files changed

+6
-9
lines changed

app/view/command/index.volt

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77
<div class="modal-dialog" role="document">
88
<div class="modal-content">
99
<div class="modal-body">
10-
<p>命令已开始执行</p>
10+
<p class="text-success">命令已开始执行</p>
1111
<p>
12-
<a href="/command/log/{{ command.id }}?server_id={{ server.id }}&ip={{ server.ip }}&port={{ server.port }}" data-nopjax target="_blank" class="btn btn-primary">查看日志</a>
12+
<a href="/command/log/{{ command.id }}?server_id={{ server.id }}&ip={{ server.ip }}&port={{ server.port }}" data-nopjax target="_blank" class="btn btn-success">查看日志</a>
1313
或前往<a href="/command/history?server_id={{ server.id }}" id="link" data-nopjax>命令执行历史</a>页面执行更多操作。
1414
</p>
1515
</div>

app/view/process/nav.volt

+4-7
Original file line numberDiff line numberDiff line change
@@ -78,15 +78,12 @@ $(function() {
7878

7979
editor.setSize('100%', '100%');
8080

81-
$('a[data-toggle="tab"]').on('shown.bs.tab', function (e) {
82-
editor.refresh();
83-
});
84-
85-
$(ini_editor).change(function() {
86-
editor.refresh();
81+
editor.on('change',function(cMirror){
82+
cMirror.refresh();
83+
editor.setSize('100%', '100%');
8784
});
8885

89-
$(ini_editor).blur(function() {
86+
$('a[data-toggle="tab"]').on('shown.bs.tab', function (e) {
9087
editor.refresh();
9188
});
9289
}

0 commit comments

Comments
 (0)