浏览代码

debug

master
Pascal Gloor 6 年前
父节点
当前提交
8f96963d82
共有 1 个文件被更改,包括 5 次插入1 次删除
  1. 5
    1
      www/js/autodoc.js

+ 5
- 1
www/js/autodoc.js 查看文件

$.each(temp.upload, function(id, file) { $.each(temp.upload, function(id, file) {
console.log(id,file); console.log(id,file);
var obj = $(".autodoc_template_progress").children(); var obj = $(".autodoc_template_progress").children();
$(obj).children().html(file.name);
$(obj).children().html(file.obj.name);
$(obj).children().css('width', "50%"); $(obj).children().css('width', "50%");
if ( file.progress==1) { if ( file.progress==1) {
if ( file.error ) { if ( file.error ) {
$(obj).children().html(file.name + ': ' + file.error); $(obj).children().html(file.name + ': ' + file.error);
$(obj).children().addClass('bg-danger'); $(obj).children().addClass('bg-danger');
$(obj).children().removeClass("progress-bar-animated");
$(obj).children().css('width', "100%"); $(obj).children().css('width', "100%");
} }
else { else {
finished=0; finished=0;
$(obj).children().addClass('bg-success'); $(obj).children().addClass('bg-success');
$(obj).children().css('width', "100%"); $(obj).children().css('width', "100%");
$(obj).children().removeClass("progress-bar-animated");

} }
} }
console.log(obj); console.log(obj);
$('.autodoc_upload_status').append(obj); $('.autodoc_upload_status').append(obj);
}); });
if ( !finished || temp.upload.length == 0 ) { if ( !finished || temp.upload.length == 0 ) {
console.log("status again");
setTimeout(upload_status, 1000); setTimeout(upload_status, 1000);
} }
} }

正在加载...
取消
保存