diff --git a/src/js/yunohost/controllers/tools.js b/src/js/yunohost/controllers/tools.js index 8c7fb36c..cde3a447 100644 --- a/src/js/yunohost/controllers/tools.js +++ b/src/js/yunohost/controllers/tools.js @@ -364,86 +364,4 @@ ); }); - // List available apps lists - app.get('#/tools/appslists', function (c) { - c.api('/appslists', function(data) { - list = []; - $.each(data, function(listname, listinfo) { - list.push({ - 'name': listname, - 'url': listinfo['url'], - 'lastUpdate': listinfo['lastUpdate'] - }); - }); - - c.view('tools/tools_appslists_list', { - appslists: list - }); - }, 'GET'); - }); - - // Add a new apps list - app.post('#/tools/appslists', function (c) { - list = { - 'name' : c.params['appslist_name'], - 'url' : c.params['appslist_url'] - } - - c.api('/appslists', function(data) { - store.clear('slide'); - c.redirect('#/tools/appslists/' + list.name); - }, 'PUT', list); - }); - - // Show appslist info and operations - app.get('#/tools/appslists/:appslist', function (c) { - c.api('/appslists', function(data) { - if (typeof data[c.params['appslist']] !== 'undefined') { - list = { - 'name' : c.params['appslist'], - 'url': data[c.params['appslist']]['url'], - 'lastUpdate': data[c.params['appslist']]['lastUpdate'], - 'removable' : (c.params['appslist'] !== 'yunohost') ? true : false // Do not remove default apps list - }; - c.view('tools/tools_appslists_info', {appslist: list}); - } - else { - c.flash('warning', y18n.t('appslists_unknown_list', [c.params['appslist']])); - store.clear('slide'); - c.redirect('#/tools/appslists'); - } - }, 'GET'); - }); - - // Refresh available apps list - app.get('#/tools/appslists/refresh', function (c) { - c.api('/appslists', function(data) { - // c.redirect(store.get('path')); - c.redirect('#/apps/install'); - }, 'PUT'); - }); - - // Refresh specific apps list - app.get('#/tools/appslists/:appslist/refresh', function (c) { - c.api('/appslists', function(data) { - c.redirect('#/tools/appslists'); - }, 'PUT', {'name' : c.params['appslist']}); - }); - - // Remove apps list - app.get('#/tools/appslists/:appslist/remove', function (c) { - c.confirm( - y18n.t('appslist'), - y18n.t('appslists_confirm_remove', [c.params['app']]), - function() { - c.api('/appslists', function() { - c.redirect('#/tools/appslists'); - }, 'DELETE', {'name' : c.params['appslist']}); - }, - function() { - store.clear('slide'); - c.redirect('#/tools/appslists/'+ c.params['appslist']); - } - ); - }); })(); diff --git a/src/locales/en.json b/src/locales/en.json index cd0d4c4b..5ed30007 100644 --- a/src/locales/en.json +++ b/src/locales/en.json @@ -29,7 +29,6 @@ "app_info_uninstall_desc": "Remove this application.", "app_install_cancel": "Installation cancelled.", "app_install_custom_no_manifest": "No manifest.json file", - "app_list": "App list", "app_level": "App level", "app_make_default": "Make default", "app_no_actions": "This application doesn't have any actions", @@ -287,7 +286,6 @@ "read": "Read", "read_more": "Read more", "reception": "Reception", - "refresh_app_list": "Refresh list", "remove_access": "Remove access", "request_adoption": "waiting adoption", "request_adoption_details": "The current maintainer would like to stop maintaining this app. Feel free to propose yourself as the new maintainer!", @@ -418,15 +416,6 @@ "regenerate_selfsigned_cert": "Regenerate self-signed certificate", "revert_to_selfsigned_cert_message": "If you really want to, you can reinstall a self-signed certificate. (Not recommended)", "revert_to_selfsigned_cert": "Revert to a self-signed certificate", - "appslists": "Applications lists", - "appslists_no_lists": "No applications lists", - "appslists_custom": "Custom applications list", - "appslists_manage": "Manage applications lists", - "appslists_confirm_remove": "Are you sure you want to remove this applications list?", - "appslists_info_refresh_desc": "Refresh applications status for this list.", - "appslists_info_remove_desc": "Applications from this list will not be available anymore.", - "appslists_last_update": "Last update", - "appslists_unknown_list": "Unknown apps list: %s", "name": "Name", "purge_user_data_checkbox": "Purge %s's data? (This will remove the content of it's home and mail directories.)", "purge_user_data_warning": "Purging user's data is not reversible. Be sure you know what you're doing!" diff --git a/src/views/tools/tools_appslists_info.ms b/src/views/tools/tools_appslists_info.ms deleted file mode 100644 index bb41beb6..00000000 --- a/src/views/tools/tools_appslists_info.ms +++ /dev/null @@ -1,49 +0,0 @@ -
- {{t 'home'}} - {{t 'tools'}} - {{t 'appslists'}} - {{appslist.name}} -
- -
- -
-
-

{{t 'infos'}}

-
-
-
-
{{t 'name'}}
-
{{appslist.name}}
-
{{t 'url'}}
-
{{appslist.url}}
-
{{t 'appslists_last_update'}}
-
{{formatTime appslist.lastUpdate day="numeric" month="long" year="numeric" hour="numeric" minute="numeric"}}
-
-
-
- -
-
-

- {{t 'operations'}} -

-
-
-
-

{{t 'appslists_info_refresh_desc'}}

- - {{t 'refresh_app_list'}} - -
- {{#appslist.removable}} -
-
-

{{t 'appslists_info_remove_desc'}}

- - {{t 'remove'}} - -
- {{/appslist.removable}} -
-
diff --git a/src/views/tools/tools_appslists_list.ms b/src/views/tools/tools_appslists_list.ms deleted file mode 100644 index 3357de3e..00000000 --- a/src/views/tools/tools_appslists_list.ms +++ /dev/null @@ -1,57 +0,0 @@ -
- {{t 'home'}} - {{t 'tools'}} - {{t 'appslists'}} -
- -
- -
-
-

{{t 'appslists'}}

-
- -
- {{#appslists}} - - -

- {{name}} -

-
- {{/appslists}} - {{^appslists}} -

- - {{t 'appslists_no_lists'}} -

- {{/appslists}} -
-
- -
-
-

{{t 'appslists_custom'}}

-
-
-
-
- -
- -
-
-
- -
- -
-
-
-
- -
-
-
-
-
diff --git a/src/views/tools/tools_list.ms b/src/views/tools/tools_list.ms index 1442b625..9aa13265 100644 --- a/src/views/tools/tools_list.ms +++ b/src/views/tools/tools_list.ms @@ -46,10 +46,6 @@

{{t 'tools_security_feed'}}

- - -

{{t 'appslists'}}

-

{{t 'tools_download_ca'}}