mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-08-14 02:26:58 -07:00
Refactor browse path function
This commit is contained in:
parent
f0d4fd5523
commit
3dc36c3b92
3 changed files with 22 additions and 22 deletions
|
@ -62,26 +62,20 @@
|
|||
</div>
|
||||
</div>
|
||||
<script>
|
||||
$('#import_config_path_browse').click(function () {
|
||||
$('#browse-path-type').text('Config File');
|
||||
$('#browse-path-modal').modal('show');
|
||||
browsePath(null, null, '.ini');
|
||||
});
|
||||
$('#select-browse-file').click(function () {
|
||||
$('#browse-path-modal').modal('hide');
|
||||
$("#import_config_path").val($('#browse-path').val());
|
||||
$("#import_config_path_browse").click(function () {
|
||||
openBrowsePath(null, null, '.ini', 'Configuration File', 'import_config_path');
|
||||
});
|
||||
|
||||
$('#import_config_file').change(function() {
|
||||
$("#import_config_file").change(function() {
|
||||
if ($(this)[0].files[0]) {
|
||||
$('#import_config_file_name').val($(this)[0].files[0].name);
|
||||
$("#import_config_file_name").val($(this)[0].files[0].name);
|
||||
}
|
||||
});
|
||||
|
||||
$("#import_config").click(function() {
|
||||
$(this).prop('disabled', true);
|
||||
|
||||
var config_file = $('#import_config_file')[0].files[0];
|
||||
var config_file = $("#import_config_file")[0].files[0];
|
||||
var config_path = $("#import_config_path").val();
|
||||
var backup = $("#import_backup_config").is(':checked');
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue