ztxkui 3.9.7 → 3.9.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -395,11 +395,15 @@ var Sinatures = function (_a) {
|
|
|
395
395
|
React.createElement(Button, { type: "link" }, "\u6DFB\u52A0\u9644\u4EF6")))),
|
|
396
396
|
isUpload && (React.createElement(Button, { type: "link", onClick: function () {
|
|
397
397
|
setIsOnlyQj(true);
|
|
398
|
-
|
|
398
|
+
var onlyQjRecords = [
|
|
399
399
|
{
|
|
400
400
|
attachId: '123456789',
|
|
401
401
|
},
|
|
402
|
-
]
|
|
402
|
+
];
|
|
403
|
+
if (onSigValuesChange) {
|
|
404
|
+
onSigValuesChange(sigValuesChange('fileList', onlyQjRecords));
|
|
405
|
+
}
|
|
406
|
+
setRecords(onlyQjRecords);
|
|
403
407
|
} }, "\u4EC5\u9700\u8981\u7FA4\u6770\u5370\u7AE0"))));
|
|
404
408
|
},
|
|
405
409
|
key: 'attachId',
|
|
@@ -423,10 +427,16 @@ var Sinatures = function (_a) {
|
|
|
423
427
|
if (xhr.status === 200) {
|
|
424
428
|
setTbLoading(false);
|
|
425
429
|
if ((response === null || response === void 0 ? void 0 : response.success) === true) {
|
|
426
|
-
|
|
427
|
-
var newRecords =
|
|
430
|
+
var getNewRecord_1 = function (data) {
|
|
431
|
+
var newRecords = data.slice();
|
|
428
432
|
newRecords.splice(index, 1);
|
|
429
433
|
return newRecords;
|
|
434
|
+
};
|
|
435
|
+
if (records.length > 0 && onSigValuesChange) {
|
|
436
|
+
onSigValuesChange(sigValuesChange('fileList', getNewRecord_1(records)));
|
|
437
|
+
}
|
|
438
|
+
setRecords(function (preRecords) {
|
|
439
|
+
return getNewRecord_1(preRecords);
|
|
430
440
|
});
|
|
431
441
|
message.success('文件删除成功!');
|
|
432
442
|
}
|
|
@@ -687,13 +697,19 @@ var Sinatures = function (_a) {
|
|
|
687
697
|
});
|
|
688
698
|
console.log(successFileList_1);
|
|
689
699
|
setRecords(function (preRecords) {
|
|
690
|
-
|
|
700
|
+
var _records = __spreadArray(__spreadArray([], preRecords), successFileList_1).filter(function (item) { return item.attachId !== '123456789'; });
|
|
701
|
+
if (onSigValuesChange) {
|
|
702
|
+
onSigValuesChange(sigValuesChange('fileList', _records));
|
|
703
|
+
}
|
|
704
|
+
return _records;
|
|
691
705
|
});
|
|
692
706
|
}
|
|
693
707
|
if (filelist.every(function (item) { return item.status === 'error'; })) {
|
|
694
708
|
message.error('文件上传失败!');
|
|
695
709
|
}
|
|
696
|
-
},
|
|
710
|
+
},
|
|
711
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
712
|
+
[setRecords]);
|
|
697
713
|
/** 群杰印章修改 */
|
|
698
714
|
function qunjSealChangeHandle(value) {
|
|
699
715
|
qunjSealChange && qunjSealChange(value);
|