|
@@ -28,7 +28,7 @@
|
|
|
<input type="submit" class="btn btn-success-inverted" onclick="checkChangePWD(); return false;" value="Отправить">
|
|
|
</form>
|
|
|
</div>
|
|
|
- <div id='uploadCertificate'>
|
|
|
+ <div id='ftpFWDownload'>
|
|
|
<div class="section group">
|
|
|
<label for="dev_update_method" class="col span_1_of_2">Способ обновления</label>
|
|
|
<div class="col span_1_of_2">
|
|
@@ -366,7 +366,7 @@
|
|
|
<h4 class="col span_2_of_2">Контроллер мониторинга</h4>
|
|
|
<button type="button" class="btn btn-default" id="change_pass">Смена пароля</button>
|
|
|
<button type="button" class="btn btn-default" id="dev-reboot">Перезагрузка</button>
|
|
|
- <button type="button" class="btn btn-default" id="dev-update_">Обновление ПО</button>
|
|
|
+ <button type="button" class="btn btn-default" id="dev-update">Обновление ПО</button>
|
|
|
</div>
|
|
|
<div class="col span_1_of_3">
|
|
|
<h4 class="col span_2_of_2">Нагрузка</h4>
|
|
@@ -501,27 +501,11 @@ var mainvolt_in_hist = new SpinBox('mainvolt_in_hist', {'name':'mainvolt_in_hist
|
|
|
var test_time = new SpinBox('test_time', {'minimum':1,'maximum':99,'step':1, 'value': 1});
|
|
|
|
|
|
settingsGET();
|
|
|
-// $('dev-update').onclick = function(){
|
|
|
-// $('count-wrap').style.display = 'block';
|
|
|
-// $('checkUpdatePass').style.display = 'block';
|
|
|
-// };
|
|
|
-// $('dev-update').onclick = function(){
|
|
|
-// if( confirm('Перевести контроллер в режим обновления ПО?') ){
|
|
|
-// loadXMLDoc('fw_update.cgi', 'GET');
|
|
|
-// checkPWD();
|
|
|
-// };
|
|
|
-// };
|
|
|
|
|
|
$('change_pass').onclick = function(){
|
|
|
$('count-wrap').style.display = 'block';
|
|
|
$('changePassword').style.display = 'block';
|
|
|
};
|
|
|
-
|
|
|
-$('dev-update_').onclick = function(){
|
|
|
- $('count-wrap').style.display = 'block';
|
|
|
- $('uploadCertificate').style.display = 'block';
|
|
|
-};
|
|
|
-
|
|
|
$('close-pass-change').onclick = function(){
|
|
|
$('changePasswordUser').value = '';
|
|
|
$('oldpwd').value = '';
|
|
@@ -530,35 +514,15 @@ $('close-pass-change').onclick = function(){
|
|
|
$('count-wrap').style.display = 'none';
|
|
|
$('changePassword').style.display = 'none';
|
|
|
};
|
|
|
+
|
|
|
+$('dev-update').onclick = function(){
|
|
|
+ $('count-wrap').style.display = 'block';
|
|
|
+ $('ftpFWDownload').style.display = 'block';
|
|
|
+};
|
|
|
$('close_fw_update').onclick = function(){
|
|
|
$('count-wrap').style.display = 'none';
|
|
|
- $('uploadCertificate').style.display = 'none';
|
|
|
+ $('ftpFWDownload').style.display = 'none';
|
|
|
};
|
|
|
-$('dev_update_method').onchange = ftpSettings;
|
|
|
-
|
|
|
-function ftpSettings() {
|
|
|
- if ($('dev_update_method').value == 'manual') {
|
|
|
- $('ftp_settings').style.display = 'none';
|
|
|
- $('start_fw_update').onclick = function() {
|
|
|
- if( confirm('Перевести контроллер в режим обновления ПО?') ){
|
|
|
- $('uploadCertificate').style.display = 'none';
|
|
|
- loadXMLDoc('fw_update.cgi', 'GET');
|
|
|
- checkPWD();
|
|
|
- };
|
|
|
- }
|
|
|
- } else {
|
|
|
- $('ftp_settings').style.display = 'block';
|
|
|
- $('start_fw_update').onclick = function() {
|
|
|
- var f1 = new FormData(document.forms.ftp_settings);
|
|
|
- var fArr = [];
|
|
|
- f1.forEach(function(a, b) {fArr.push(b+'='+a)});
|
|
|
- loadXMLDoc('ftp_fw_update.cgi', 'POST', function() {
|
|
|
- alert(this.responseText)
|
|
|
- }, fArr.join('&'));
|
|
|
- }
|
|
|
- }
|
|
|
-}
|
|
|
-ftpSettings();
|
|
|
|
|
|
$('dev-reset').onclick = function(){
|
|
|
function foo(){window.location.href = '/settings.html';}
|