From ce408a489fc79c9f2558aef127a72cb445e6001e Mon Sep 17 00:00:00 2001 From: ysheng1234 Date: Thu, 22 Sep 2022 14:38:31 +0800 Subject: [PATCH] fix httperrorreceive Signed-off-by: ysheng1234 --- .../entry/src/main/ets/MainAbility/pages/web.ets | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/arkui/ace_ets_web_dev/entry/src/main/ets/MainAbility/pages/web.ets b/arkui/ace_ets_web_dev/entry/src/main/ets/MainAbility/pages/web.ets index 630f93a12..789e36492 100644 --- a/arkui/ace_ets_web_dev/entry/src/main/ets/MainAbility/pages/web.ets +++ b/arkui/ace_ets_web_dev/entry/src/main/ets/MainAbility/pages/web.ets @@ -622,9 +622,12 @@ struct Index { break; } case "emitOnHttpErrorReceive":{ - this.controller.loadUrl({url:'http://example.com/path/does/not/exist/index.jsp'}) - setTimeout(()=>{ - Utils.emitEvent(this.httpErrorReceive,66) + this.controller.loadUrl({url:'https://example1.com/path/does/not/exist/index.jsp'}) + setTimeout(()=>{ + this.controller.loadUrl({url:'https://example1.com/path/does/not/exist/index.jsp'}) + setTimeout(()=>{ + Utils.emitEvent(this.httpErrorReceive,66) + },3000) },3000) break; } -- GitLab