Pre Merge pull request !108 from CoderHank/master

This commit is contained in:
CoderHank 2024-02-20 04:05:27 +00:00 committed by Gitee
commit 7cd873b98b
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 10 additions and 0 deletions

View File

@ -556,6 +556,16 @@ export class RequestOption {
loadError = (err:BusinessError|string)=>{
LogUtil.log("loadError:" + err);
//失败回调
if(this.requestListeners != undefined) {
for (let i = 0;i < this.requestListeners.length; i++) {
let requestListener = this.requestListeners[i];
let boolInterception = requestListener.callback(err.toString(), new ImageKnifeData());
if (boolInterception) {
break;
}
}
}
// 失败占位图展示规则
if (this.retryholderFunc) {
// 重试图层优先于加载失败展示