luci-app-attendedsysupgrade: report used client version
authorPaul Spooren <mail@aparcar.org>
Thu, 28 Jul 2022 20:43:46 +0000 (22:43 +0200)
committerPaul Spooren <mail@aparcar.org>
Fri, 29 Jul 2022 15:04:23 +0000 (17:04 +0200)
This allows the backend to track popular app versions and drop support for
unsed version in case of API changes.

Specifically the app sends a version string in the format "luci/GIT_HASH" to
the backend.

Signed-off-by: Paul Spooren <mail@aparcar.org>
(cherry picked from commit f368faf6789a43c2e1a26b721f8115473672eb29)

applications/luci-app-attendedsysupgrade/htdocs/luci-static/resources/view/attendedsysupgrade/overview.js

index cac75d7f1df92f1a49c8a09f87234c1ab530d6a9..1553a011570d2d4b082bb49be8abe5f02e89e43b 100644 (file)
@@ -418,7 +418,7 @@ return view.extend({
        },
 
        render: function (res) {
-               this.data.app_version = res[0].packages['luci-app-attendedsysupgrade'];
+               this.firmware.client = 'luci/' + res[0].packages['luci-app-attendedsysupgrade'];
                this.firmware.packages = res[0].packages;
 
                this.firmware.profile = res[1].board_name;