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 13:40:32 +0000 (15:40 +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>
applications/luci-app-attendedsysupgrade/htdocs/luci-static/resources/view/attendedsysupgrade/overview.js

index 8d85f866bab490c60590596013a3bd159ed6bee0..9054b78878d0f5d20428a9fc2dbdf39e607aadc7 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;