feat: add async post in gateway controller (#1963)

This commit is contained in:
vkamn
2025-10-29 23:24:24 +08:00
committed by GitHub
parent f6e7d3ccf1
commit f1481b1b1f
5 changed files with 143 additions and 46 deletions
+14 -2
View File
@@ -14,6 +14,19 @@ import "../Config"
PageType {
id: root
Connections {
target: ApiNewsController
function onFetchNewsFinished() {
PageController.showBusyIndicator(false)
}
function onErrorOccurred(errorCode) {
PageController.showErrorMessage(errorCode)
PageController.closePage()
PageController.showBusyIndicator(false)
}
}
ListViewType {
id: listView
@@ -140,9 +153,8 @@ PageType {
return;
}
PageController.showBusyIndicator(true)
ApiNewsController.fetchNews();
ApiNewsController.fetchNews()
PageController.goToPage(PageEnum.PageSettingsNewsNotifications)
PageController.showBusyIndicator(false)
}
}