]> source.dussan.org Git - nextcloud-server.git/commitdiff
Add a warning on the apps list when the version is missing
authorJoas Schilling <nickvergessen@owncloud.com>
Thu, 7 Jan 2016 13:55:23 +0000 (14:55 +0100)
committerJoas Schilling <nickvergessen@owncloud.com>
Thu, 7 Jan 2016 14:03:55 +0000 (15:03 +0100)
settings/controller/appsettingscontroller.php
settings/templates/apps.php

index 765fe2d2850660eb9f69aaf746a8645d9dd2e650..79b7589027b5a57cf3e79c945109f956b3253b17 100644 (file)
@@ -296,6 +296,9 @@ class AppSettingsController extends Controller {
                        $app['canInstall'] = empty($missing);
                        $app['missingDependencies'] = $missing;
 
+                       $app['missingMinOwnCloudVersion'] = !isset($app['dependencies']['owncloud']['@attributes']['min-version']);
+                       $app['missingMaxOwnCloudVersion'] = !isset($app['dependencies']['owncloud']['@attributes']['max-version']);
+
                        return $app;
                }, $apps);
 
index 7213d552c084758c2fcb9c1e24bb9b5fe49a7f55..94efd76c7c298a4fea7db22d0c1c790cf83c32cf 100644 (file)
@@ -97,6 +97,18 @@ script(
        <div class="app-description-toggle-show"><?php p($l->t("Show description …"));?></div>
        <div class="app-description-toggle-hide hidden"><?php p($l->t("Hide description …"));?></div>
 
+       {{#if missingMinOwnCloudVersion}}
+               <div class="app-dependencies">
+                       <p><?php p($l->t('This app has no minimum ownCloud version assigned. This will be an error in ownCloud 11 and later.')); ?></p>
+               </div>
+       {{else}}
+               {{#if missingMaxOwnCloudVersion}}
+                       <div class="app-dependencies">
+                               <p><?php p($l->t('This app has no maximum ownCloud version assigned. This will be an error in ownCloud 11 and later.')); ?></p>
+                       </div>
+               {{/if}}
+       {{/if}}
+
        {{#unless canInstall}}
        <div class="app-dependencies">
        <p><?php p($l->t('This app cannot be installed because the following dependencies are not fulfilled:')); ?></p>