This commit is contained in:
BianLzhaoMin 2025-06-05 10:37:51 +08:00
parent 9a4c6e2eb0
commit dcc2209842
1 changed files with 19 additions and 12 deletions

View File

@ -219,7 +219,7 @@
let dataId = $(this).data('field')
if (item1[`${dataId}-file`] && item1[`${dataId}-file`]['fileName'] != '') {
$(this).find('.layui-table-cell').append(`<i class="layui-icon layui-icon-file-b" style="margin-left:6px;cursor:pointer"></i> `)
$(this).find('.layui-table-cell').append(`<i class="layui-icon layui-icon-file-b file-icon" data-index="${i}" data-id="${dataId}" style="margin-left:6px;cursor:pointer"></i> `)
}
}
@ -425,7 +425,14 @@
$(`#upload-success_${Index} .prepend-content`).remove();
})
$(`#uploadBtn${Index}`).show()
})
$(document).on('click', '.file-icon', function () {
var dataId = $(this).data('id');
var dataIndex = $(this).data('index');
console.log('dataIndex图标', dataIndex)
console.log('dataId图标', dataId)
console.log('tableRowList图标', tableRowList[dataIndex])
})
tableLoading && layer.close(tableLoading);
}
@ -514,17 +521,17 @@
function getTableData() {
/* for (var i = 0; i < tableRowList.length; i++) {
var item = tableRowList[i];
for (var key in item) {
if (key.indexOf("-") !== -1) {
if (item[key] === '' || item[key] === null) {
layer.msg('请对所有指标评价完成,再点击提交!');
return;
}
}
}
}*/
/* for (var i = 0; i < tableRowList.length; i++) {
var item = tableRowList[i];
for (var key in item) {
if (key.indexOf("-") !== -1) {
if (item[key] === '' || item[key] === null) {
layer.msg('请对所有指标评价完成,再点击提交!');
return;
}
}
}
}*/
// //获取表格填写的数据