summaryrefslogtreecommitdiff
path: root/app/models
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch ↵Douwe Maan2016-06-223-30/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | '18755-fix-destroy-project-causes-post_decline_request-to-be-executed' into 'master' Resolve "Destroying a project causes post_decline_request to be executed" ## What does this MR do? Ensure we don't send "access request declined" to access requesters when a project is deleted. ## Are there points in the code the reviewer needs to double check? I've created a service to decouple the notification sending from the AR model. ## Why was this MR needed? Because there was an issue. ## What are the relevant issue numbers? Fixes #18755, #18750. ## Does this MR meet the acceptance criteria? - [x] No CHANGELOG needed. - [x] Tests - [x] Added for this feature/bug - [x] All builds are passing - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [x] Branch has no merge conflicts with `master` (if you do - rebase it please) - [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) See merge request !4744
| * New Members::DestroyServiceRémy Coutable2016-06-183-30/+1
| | | | | | | | | | | | | | This is to ensure we don't send unwanted notifications when deleting a project. In other words, stop abusing AR callbacks and use services. Signed-off-by: Rémy Coutable <remy@rymai.me>
* | Merge branch '18590-banzai-filter-relativelinkfilter-is-slow' into 'master' Yorick Peterse2016-06-211-0/+26
|\ \ | | | | | | | | | | | | Optimize Banzai::Filter::RelativeLinkFilter See merge request !4813
| * | Optimize Banzai::Filter::RelativeLinkFilterAlejandro Rodríguez2016-06-211-0/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A lot of git operations were being repeated, for example, to build a url you would ask if the path was a Tree, which would call a recursive routine in Gitlab::Git::Tree#where, then ask if the path was a Blob, which would call a recursive routine at Gitlab::Git::Blob#find, making reference to the same git objects several times. Now we call Rugged::Tree#path, which allows us to determine the type of the path in one pass. Some other minor improvement added, like saving commonly used references instead of calculating them each time.
* | | Merge branch 'fix/builds-api-nil-commit' into 'master' Rémy Coutable2016-06-212-4/+6
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix builds API response that did not include commit data ## What does this MR do? This is fix for problem with builds API response not including information about commit this build is created for. ## What are the relevant issue numbers? Closes #18476 ## Does this MR meet the acceptance criteria? - [x] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added - [x] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md) - [x] API support added - Tests - [x] Added for this feature/bug - [x] All builds are passing - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [x] Branch has no merge conflicts with `master` (if you do - rebase it please) - [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) See merge request !4827
| * | | Rename commit_data in Pipeline to commitfix/builds-api-nil-commitGrzegorz Bizon2016-06-212-12/+6
| | | |
| * | | Fix builds API response not including commit dataGrzegorz Bizon2016-06-211-0/+8
| | | |
* | | | Cache Participable#participants in instance variablePaco Guzman2016-06-211-0/+10
|/ / /
* | | Merge branch 'feature/runner-lock-on-project' into 'master' Rémy Coutable2016-06-212-9/+22
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make it possible to lock runner on a specific project Make it possible to lock runner on a specific project. ![Screen_Shot_2016-06-20_at_4.03.08_PM](/uploads/186378643a20106ff0b67b6fd8bd7f28/Screen_Shot_2016-06-20_at_4.03.08_PM.png) ---- ![Screen_Shot_2016-06-20_at_9.54.52_PM](/uploads/c479abdffaf19f383bb6b5a42bdd6cc3/Screen_Shot_2016-06-20_at_9.54.52_PM.png) ---- ![Screen_Shot_2016-06-20_at_9.56.26_PM](/uploads/6ad838679b0c28a1fe2e20e9224387ea/Screen_Shot_2016-06-20_at_9.56.26_PM.png) Closes #3407 See merge request !4093
| * \ \ Merge remote-tracking branch 'upstream/master' into ↵Lin Jen-Shin2016-06-2017-16/+173
| |\ \ \ | | |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | feature/runner-lock-on-project * upstream/master: (353 commits) Put some admin settings in dropdown Add styleguide on configuration settings documentation Remove Duplicated keys add UNIQUE index to fingerprint Avoid autoload issue such as 'Mail::Parsers::AddressStruct' Move appearance settings as sub tab to application settings use rails root join fixed a couple of errors spotted in production Fix RangeError exceptions when referring to issues or merge requests outside of max database values Fix bug in `WikiLinkFilter`. Grammar and typographic changes to artifacts documentation Tweak grammar Small frontend code fixes and restore 8a2d88f commit Warn about admin privilege to disable GitHub Webhooks Listing GH Webhooks doesn't stop import process for non GH admin users fixup! updated docs for api endpoint award emoji Update CHANGELOG Ensure Todos counters doesn't count Todos for projects pending delete Add endpoints for award emoji on notes Sort API endpoints and implement feedback Add endpoints for Award Emoji ...
| * | | Rename according to:Lin Jen-Shin2016-06-201-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/4093#note_12563922 For clarification and consistency
| * | | Merge remote-tracking branch 'upstream/master' into ↵Lin Jen-Shin2016-06-1723-162/+369
| |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | feature/runner-lock-on-project * upstream/master: (337 commits) Update CHANGELOG for !4659 Center the header logo for all Devise emails Add previews for all customized Devise emails Customize the Devise `unlock_instructions` email Customize the Devise `reset_password_instructions` email Customize the Devise `password_change` emails Use gitlab-git 10.2.0 Use Git cached counters on project show page Fix indentation scss-lint errors Added title attribute to enties in tree view Closes #18353 Banzai::Filter::ExternalLinkFilter use XPath Reduce queries in IssueReferenceFilter Use gitlab_git 10.1.4 Fixed ordering in Project.find_with_namespace Fix images in emails Banzai::Filter::UploadLinkFilter use XPath Turn Group#owners into a has_many association Make project_id nullable CHANGELOG [ci skip] CHANGELOG [ci skip] ...
| * | | | Use FIXME instead, feedback from:Lin Jen-Shin2016-06-161-2/+2
| | | | | | | | | | | | | | | | | | | | https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/4093/diffs#note_12501400
| * | | | Return the association and check it in controller instead:Lin Jen-Shin2016-06-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | Feedback: https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/4641#note_12444891
| * | | | Merge branch 'prefer-assign_to' into feature/runner-lock-on-projectLin Jen-Shin2016-06-141-1/+1
| |\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * prefer-assign_to: Give 409 Conflict whenever the runner was already enabled We're checking return value rather than rescuing exceptions Prefer Runner#assign_to instead of creating directly
| | * | | | Give 409 Conflict whenever the runner was already enabledprefer-assign_toLin Jen-Shin2016-06-141-1/+1
| | | | | |
| | * | | | We're checking return value rather than rescuing exceptionsLin Jen-Shin2016-06-141-1/+1
| | | | | |
| * | | | | Merge branch 'master' into feature/runner-lock-on-projectLin Jen-Shin2016-06-148-51/+116
| |\ \ \ \ \ | | |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master: (147 commits) Update CHANGELOG Remove deprecated issues_tracker and issues_tracker_id from project Schema doesn’t reflect the changes of the last 3 migrations Revert CHANGELOG Also rename "find" in the specs Change to new Notes styleguide Add guide on changing a document's location Change logs.md location in README Move logs/logs.md to administration/logs.md Make "four phase test" Only show branches for revert / cherry-pick Instrument all Banzai::ReferenceParser classes Removed old comment from update_column_in_batches Update columns in batches until no rows are left Remove counters from Pipeline navigation Handle NULL migration errors in migration helpers Fix typo causing related branches to Error 500 Improved SVG sanitizer specs to include smoke tests for clean. Refactored SVG sanitizer Added SVG sanitizer fix to the changelog ...
| * | | | | Rename specific_for to available_for:Lin Jen-Shin2016-06-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Feedback from: https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/4093#note_12413950
| * | | | | Merge conditions. Not worth an additional pointless method:Lin Jen-Shin2016-06-091-9/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Feedback from: https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/4093#note_12321267
| * | | | | Renamed to available_for? Feedback from:Lin Jen-Shin2016-06-091-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/4093#note_12321240
| * | | | | Remove Build#can_be_served? and rename Runner#can_serve? to can_pick?Lin Jen-Shin2016-06-092-6/+2
| | | | | | | | | | | | | | | | | | | | | | | | This also moves tests from build_spec.rb to runner_spec.rb
| * | | | | Manually build the SQL so that it properly skips Rails.Lin Jen-Shin2016-06-091-1/+2
| | | | | |
| * | | | | Found a workaround for that weird SQL error:Lin Jen-Shin2016-06-091-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Without that, Rails would complain: > bind message supplies 5 parameters, but prepared statement "a4" requires 4 However without this workaround it would still work in Rails console, so I still think this is a Rails bug somewhere.
| * | | | | WIP, try to add views for locked runnersLin Jen-Shin2016-06-091-1/+1
| | | | | |
| * | | | | Introduced Ci::Runner.specific_for for getting specific runners:Lin Jen-Shin2016-06-091-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | for a particular project.
| * | | | | Implement the logic for locking runnerLin Jen-Shin2016-06-092-3/+19
| | | | | |
* | | | | | Get ref_names from branch_names/tag_names cachedPaco Guzman2016-06-201-0/+4
| | | | | |
* | | | | | Unify check branch name existPaco Guzman2016-06-202-7/+3
| |_|_|/ / |/| | | |
* | | | | Remove Duplicated keys add UNIQUE index to fingerprint18697-uniqueness-key-validationPaco Guzman2016-06-201-1/+1
| | | | |
* | | | | Fix RangeError exceptions when referring to issues or merge requests outside ↵Stan Hu2016-06-183-0/+12
| |_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | of max database values When using #XYZ in Markdown text, if XYZ exceeds the maximum value of a signed 32-bit integer, we get an exception when the Markdown render attempts to run `where(iids: XYZ)`. Introduce a method that will throw out out-of-bounds values. Closes #18777
* | | | Merge branch 'issue_12758' into 'master' Douwe Maan2016-06-171-1/+36
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implement custom notification level options ![Screen_Shot_2016-06-17_at_15.31.43](/uploads/3fc47d2f461b3e8b67bb8acaa304cf99/Screen_Shot_2016-06-17_at_15.31.43.png) ![Screenshot_from_2016-06-15_10-52-27](/uploads/88dbdd21d97e80ee772fe08fa0c9b393/Screenshot_from_2016-06-15_10-52-27.png) part of #12758 See merge request !4389
| * \ \ \ Merge master into issue_12758issue_12758Felipe Artur2016-06-179-25/+76
| |\ \ \ \
| * | | | | Implement custom notification level optionsFelipe Artur2016-06-151-1/+36
| | | | | |
* | | | | | Cache todo counters (pending/done)18034-cache-todo-counterPaco Guzman2016-06-171-0/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - As todos are created/updated inside the TodoService we repopulate the cache just there for both pending/done todos - Todos as mark as done from the TodosController we update cache there too - All the added methods are kept in the User class for cohesion
* | | | | | Merge branch '14918-add-filter-dropdown-to-tag-page' into 'master' Rémy Coutable2016-06-171-0/+19
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add sorting dropdown to tag page ## What does this MR do? Adds a sorting dropdown to the tags page just like the one on the branches page. ## Are there points in the code the reviewer needs to double check? No ## Why was this MR needed? Clients were asking for this ## What are the relevant issue numbers? Closes #14918 ## Screenshots (if relevant) ![Captura_de_pantalla_2016-06-01_a_las_4.07.58_p.m.](/uploads/4530683ddd91d3bdbdce77748fe63f87/Captura_de_pantalla_2016-06-01_a_las_4.07.58_p.m..png) See merge request !4423
| * | | | | | Add sorting dropdown to tag page14918-add-filter-dropdown-to-tag-pageAlejandro Rodríguez2016-06-161-0/+19
| | | | | | |
* | | | | | | Merge branch 'feature/project-export' into 'master' Douwe Maan2016-06-179-14/+61
|\ \ \ \ \ \ \ | |_|_|/ / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Export project functionality This is a MR for the export functionality of https://gitlab.com/gitlab-org/gitlab-ce/issues/3050, which adds the ability to export single projects. - [x] members - DB data - [x] issues - [x] issue comments - [x] merge requests - [x] merge request diff - [x] merge request comments - [x] labels - [x] milestones - [x] snippets - [x] releases - [x] events - [x] commit statuses - [x] CI builds - File system data - [x] Git repository - [x] wiki - [x] uploads - [ ] ~~CI build traces~~ - [ ] ~~CI build artifacts~~ - [ ] ~~LFS objects~~ - DB configuration - [x] services - [x] web hooks - [x] protected branches - [x] deploy keys - [x] CI variables - [x] CI triggers See merge request !3114
| * | | | | | a few changes based on MR feedbackJames Lopez2016-06-171-1/+1
| | | | | | |
| * | | | | | fixed merge conflicts on UI branchJames Lopez2016-06-1624-172/+344
| |\ \ \ \ \ \
| | * \ \ \ \ \ fixed merge conflictsJames Lopez2016-06-1624-172/+344
| | |\ \ \ \ \ \
| | | * \ \ \ \ \ Merge branch 'master' of gitlab.com:gitlab-org/gitlab-ce into ↵feature/project-exportJames Lopez2016-06-1624-172/+344
| | | |\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | feature/project-export # Conflicts: # app/models/ci/pipeline.rb
| | | * | | | | | | Revert "squashed merge and fixed conflicts"James Lopez2016-06-1624-344/+172
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 13e37a3ee5c943525a99481b855d654e97e8597c.
| | | * | | | | | | squashed merge and fixed conflictsJames Lopez2016-06-1624-172/+344
| | | | | | | | | |
| * | | | | | | | | lots of refactoring again based on feedback. Changed the UI slightly and ↵James Lopez2016-06-151-2/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | also fixed a small bug
| * | | | | | | | | some refactoring - renaming things, etc..James Lopez2016-06-151-3/+3
| | | | | | | | | |
| * | | | | | | | | project export archiverJames Lopez2016-06-141-0/+9
| | | | | | | | | |
| * | | | | | | | | adapted current services stuff to use new project import, plus fixes a few ↵James Lopez2016-06-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | issues, updated routes, etc...
| * | | | | | | | | new export stuff and viewJames Lopez2016-06-141-10/+0
| | | | | | | | | |
| * | | | | | | | | lots of refactoring to reuse import serviceJames Lopez2016-06-142-4/+4
| | | | | | | | | |