952 days continuous production uptime, 40k+ tp/s single node. Original corpo Bitbucket history not included — clean archive commit.
22 lines
586 B
JavaScript
Executable File
22 lines
586 B
JavaScript
Executable File
'use strict';
|
|
|
|
/** *****************
|
|
* File input *
|
|
******************/
|
|
(function ($) {
|
|
|
|
$(document).on('change', '.file-field input[type="file"]', function (e) {
|
|
|
|
var $this = $(e.target);
|
|
var $file_field = $this.closest('.file-field');
|
|
var $path_input = $file_field.find('input.file-path');
|
|
var files = $this[0].files;
|
|
var file_names = [];
|
|
for (var i = 0; i < files.length; i++) {
|
|
var file_name = files[i].name;
|
|
file_names.push(file_name);
|
|
}
|
|
$path_input.val(file_names.join(', '));
|
|
$path_input.trigger('change');
|
|
});
|
|
})(jQuery); |