Commit Graph

87 Commits

Author SHA1 Message Date
Martin Wortschack 8ce09a1d42 Externalize strings in admin controllers
- Update PO file
2019-03-21 14:31:34 +01:00
Alejandro Rodríguez 585fcfb9e7 Fix undefined variable error on json project views
This mistake seems to have always been there, but it only resulted in
errors on the `/explore*.json` since they were the one that _actually_
relied on the local variables.
2019-03-18 21:27:28 -03:00
gfyoung 73322a0e55 Enable frozen string in app/controllers/**/*.rb
Enables frozen string for the following:

* app/controllers/*.rb
* app/controllers/admin/**/*.rb
* app/controllers/boards/**/*.rb
* app/controllers/ci/**/*.rb
* app/controllers/concerns/**/*.rb

Partially addresses #47424.
2018-09-18 21:22:45 -07:00
Yorick Peterse 2039c8280d
Disable existing offenses for the CodeReuse cops
This whitelists all existing offenses for the various CodeReuse cops, of
which most are triggered by the CodeReuse/ActiveRecord cop.
2018-09-11 17:32:00 +02:00
Rémy Coutable 50d7c356c2
Present member collection at the controller level
Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-12-12 18:14:58 +01:00
Mehdi Lahmam d184f27ed3 Refactor Admin::ProjectsFinder by extracting finders as private methods 2017-08-24 10:11:00 +02:00
Maxim Rydkin fab1b0f1d1 Decrease ABC threshold to 56.96 2017-07-24 10:54:16 +00:00
Douwe Maan fe13f11041 Create and use project path helpers that only need a project, no namespace 2017-07-05 11:11:59 -05:00
Jacopo b996a82ff4 ProjectsFinder should handle more options
Extended ProjectFinder in order to handle the following options:
 - current_user - which user use
 - project_ids_relation: int[] - project ids to use
 - params:
   -  trending: boolean
   -  non_public: boolean
   -  starred: boolean
   -  sort: string
   -  visibility_level: int
   -  tags: string[]
   -  personal: boolean
   -  search: string
   -  non_archived: boolean

GroupProjectsFinder now inherits from ProjectsFinder.
Changed the code in order to use the new available options.
2017-04-06 07:11:37 +02:00
Dmitriy Zaporozhets 5bb6a85b90
Refactor projects filtering by name
Reuse same search form and behavior for dashboard#projects, group#projects
and admin#projects. Repsect all other options like sorting, personal
filter when search projects by name. Create FilterableList JS class to
handle identical behaviour of projects and groups lists.

This change also makes filtering and sorting availabe on explore#projects
and explore#groups no matter if you are logged in or not.

Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2017-03-03 18:39:30 +02:00
Adam Pahlevi a0586dbc16 replace `find_with_namespace` with `find_by_full_path`
add complete changelog for !8949
2017-02-03 07:14:04 +07:00
Markus Koller 3ef4f74b1a
Add more storage statistics
This adds counters for build artifacts and LFS objects, and moves
the preexisting repository_size and commit_count from the projects
table into a new project_statistics table.

The counters are displayed in the administration area for projects
and groups, and also available through the API for admins (on */all)
and normal users (on */owned)

The statistics are updated through ProjectCacheWorker, which can now
do more granular updates with the new :statistics argument.
2016-12-21 16:39:49 +01:00
Rémy Coutable 924a6b7d33 New AccessRequestsFinder
Signed-off-by: Rémy Coutable <remy@rymai.me>
2016-09-28 08:46:59 +02:00
Alfredo Sumaran 338072cc4b Layout for Users Groups and Projects on admin area 2016-07-07 13:25:58 -05:00
Rémy Coutable bd78f5733c Exclude requesters from Project#members, Group#members and User#members
And create new Project#requesters, Group#requesters scopes.

Signed-off-by: Rémy Coutable <remy@rymai.me>
2016-07-01 17:44:46 +02:00
Jacob Vosmaer 0f602be99f Clear repository check columns asynchronously 2016-04-13 15:56:05 +02:00
Jacob Vosmaer 3170e5d226 Basta 2016-04-12 18:09:45 +02:00
Jacob Vosmaer 7b1bb0f4db Merge branch 'master' of https://gitlab.com/gitlab-org/gitlab-ce into auto-fsck 2016-04-12 17:44:02 +02:00
Jacob Vosmaer ea787165b3 Move 'clear checks' button to applicatoin settings 2016-04-12 17:32:58 +02:00
PotHix 222e1dc59c Fixes #14638.
The SQL query was ambiguous and in this case we want to filter projects.
2016-04-06 13:56:28 -03:00
Jacob Vosmaer 5cf56e5647 Rename almost all the things 2016-04-06 13:47:05 +02:00
Jacob Vosmaer bf9526739b Rebase repo check MR 2016-04-04 17:23:43 +02:00
Douwe Maan ae7b2ef62c Merge branch 'master' into issue_12658
# Conflicts:
#	app/models/issue.rb
#	app/views/projects/_home_panel.html.haml
#	app/views/shared/projects/_project.html.haml
#	db/schema.rb
#	spec/models/project_spec.rb
2016-03-21 23:22:21 +01:00
Douwe Maan 7c51d5efec Fix some specs 2016-03-20 22:55:08 +01:00
Robert Speicher 085538c2bd Use the configured Kaminari "per page" default 2016-03-19 17:37:54 -04:00
Artem Sidorenko 3ebbed25f0 Allow listing of archived projects
Resolves #9285
2015-08-19 13:46:59 +02:00
Douwe Maan b93053695a Fix transferring of project to another group using the API. 2015-07-11 16:47:33 -04:00
zenati b0de6e9ae2 An `in_namespace` scope is already present 2015-06-09 13:42:01 +02:00
Jeroen van Baarsen 5a4ebfb47a Fixed the Rails/ActionFilter cop
Signed-off-by: Jeroen van Baarsen <jeroenvanbaarsen@gmail.com>
2015-04-20 15:39:37 +02:00
Dmitriy Zaporozhets f0cbbd70bb Use same constant for amount of items per page 2015-03-12 15:37:00 -07:00
Vinnie Okada 76aad9b76e Upgrade to Rails 4.1.9
Make the following changes to deal with new behavior in Rails 4.1.2:

* Use nested resources to avoid slashes in arguments to path helpers.
2015-02-14 11:09:23 -07:00
Ciro Santilli 2c98584a9c Remove unused admin/projects#repository method
Already defined on the ApplicationController base class.
2014-10-21 10:56:11 +02:00
Dmitriy Zaporozhets 5ce9f89c7b Merge pull request #8102 from cirosantilli/use-memoized-project
Use @project on controllers, don't call method
2014-10-21 11:41:03 +03:00
Ciro Santilli 9e1b97ad99 Use @project on controllers, don't call method
Also memoize the method to ensure that other methods in
ApplicationController that rely on it can call it efficiently.
2014-10-19 23:36:23 +02:00
Ciro Santilli 6a73b76c5f Remove param[:project_id] at admin controller
The route never passes that parameter to the helpers.
2014-10-19 23:02:19 +02:00
Dmitriy Zaporozhets c69b8e0459
Huge replace of old users_project and users_group references
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-09-14 19:32:51 +03:00
Dmitriy Zaporozhets f3369e3a00
Fix project trasnfer for admin area
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-06-19 13:20:42 +03:00
Dmitriy Zaporozhets 95d61a094d
Improve admin/projects page
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-06-03 14:19:11 +03:00
Dmitriy Zaporozhets 5a064b0249
Get group members only if group not nil
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-06-02 21:25:01 +03:00
Dmitriy Zaporozhets 144212fba2
Add members paginations to admin/project page
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-06-02 19:31:43 +03:00
Dmitriy Zaporozhets c608a5dcea
Add sort dropdown for admin projects page
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-05-02 17:02:57 +03:00
skv a3f645ef51 Remove deprecated finders 2014-01-19 23:39:56 +04:00
Dmitriy Zaporozhets 1d2bdb4d58
Move all Context classes into Services
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-01-16 19:03:42 +02:00
skv d89527839e fix most of warnings 2013-12-15 00:05:10 +04:00
Jason Hollingsworth d9bb4230cc Adding authenticated public mode (internal).
Added visibility_level icons to project view (rather than just text).
Added public projects to search results.
Added ability to restrict visibility levels standard users can set.
2013-11-26 22:22:07 -06:00
Dmitriy Zaporozhets 0815098d3a
Admin can transfer project to any namespace
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2013-11-15 15:25:37 +02:00
Dmitriy Zaporozhets dc0f08f8d8 Show also group members on project page at admin area 2013-06-22 00:11:06 +03:00
Dmitriy Zaporozhets cf8b465cb9 Remove Global namespace from options. Prepared file for migration of global projects 2013-06-19 18:32:08 +03:00
Dmitriy Zaporozhets 6eb045fc98 Prevent Project.all & User.all in selectboxes 2013-06-11 14:17:37 +03:00
Dmitriy Zaporozhets c5f56ee8a0 Restyle admin:group:show. Remove .all calls fro users, projects here 2013-06-10 15:58:51 +03:00