summaryrefslogtreecommitdiff
path: root/app/models
Commit message (Collapse)AuthorAgeFilesLines
* More SystemNoteService cleanuprs-to_referenceRobert Speicher2015-05-262-4/+4
|
* Surround Project.reference_pattern in parenthesis inside other patternsRobert Speicher2015-05-264-4/+7
|
* Make `cross_project_reference?` less magicalRobert Speicher2015-05-261-4/+3
|
* Support only double quotes for multi-word label referencesRobert Speicher2015-05-261-6/+4
|
* Minor documentation updatesRobert Speicher2015-05-262-2/+2
|
* Add `reference_pattern` to Referable modelsRobert Speicher2015-05-2611-9/+114
|
* Update CommitRange#to_reference to use full SHAsRobert Speicher2015-05-261-3/+6
| | | | We only want them shortened by the filter, which calls to_s
* Implement gfm_reference directly in MentionableRobert Speicher2015-05-264-19/+8
| | | | Except for Note, which still overrides it.
* Minor model spec cleanupsRobert Speicher2015-05-261-1/+2
| | | | Snippet model was missing project association
* Add `to_reference` for models that support referencesRobert Speicher2015-05-2610-16/+138
| | | | | Now there is a single source of information for which attribute a model uses to be referenced, and its special character.
* Add Referable concernRobert Speicher2015-05-261-0/+52
|
* Add Commit#==Robert Speicher2015-05-261-0/+4
| | | | | | | | Prior, comparison would use the Ruby object's ID, which got out of sync after a Spring fork and would result in erroneous test failures. Now we just check that the compared object is a Commit and then compare their underlying raw commit objects.
* Merge branch 'milestoneRescue' into 'master'Robert Schilling2015-05-262-2/+2
|\ | | | | | | | | | | | | | | | | | | | | | | | | Change percent_complete rescue value from 100 to 0 The percent_complete method returns a value of 100 when a ZeroDivisionError occurs. That seems like a very strange default for an error case, and results in a bug when a milestone has no corresponding issues (new, empty milestones show 100% completion). This commit changes the rescue value to 0, and subsequently fixes #1656, which reported this problem. See merge request !714
| * Change percent_complete rescue value from 100 to 0Jonah Bishop2015-05-262-2/+2
| | | | | | | | | | | | | | | | | | The percent_complete method returns a value of 100 when a ZeroDivisionError occurs. That seems like a very strange default for an error case, and results in a bug when a milestone has no corresponding issues (new, empty milestones show 100% completion). This commit changes the rescue value to 0, and subsequently fixes #1656, which reported this problem.
* | Use .md as extention for wiki pagesJeroen van Baarsen2015-05-261-1/+1
|/ | | | | | | | | | | | | | | | **What does this do?** It makes sure that when you create a wiki page via the web interface, the extention is .md instead of .markdown **Why is this needed?** When you're using Gollum locally, it will create pages with the .md extention. Also .md is the best known extention for markdown. This fix will make sure that if you're using gollum or the webinterface, the extention will be the same. **What issues does this fix?** Fixes https://github.com/gitlabhq/gitlabhq/issues/5204 Signed-off-by: Jeroen van Baarsen <jeroenvanbaarsen@gmail.com>
* Refactor permission checks to use `can?` instead of `issues_enabled` and ↵Stan Hu2015-05-251-0/+5
| | | | `merge_requests_enabled`
* Merge branch 'disabled-issues-mr-features' into 'master'Douwe Maan2015-05-251-0/+27
|\ | | | | | | | | | | | | | | Disable "New Issue" and "New Merge Request" buttons when features are disabled in project settings Closes #1676 See merge request !691
| * Disable "New Issue" and "New Merge Request" buttons when features are ↵Stan Hu2015-05-251-0/+27
| | | | | | | | | | | | disabled in project settings Closes #1676
* | Add support for Webhook note eventsStan Hu2015-05-214-0/+6
|/ | | | Closes https://github.com/gitlabhq/gitlabhq/issues/6745
* Rename MarkdownHelper to MarkupHelperJakub Jirutka2015-05-181-3/+3
|
* Don't include users without project access in participants.Douwe Maan2015-05-151-6/+14
|
* Fix mentioning of private groups.Douwe Maan2015-05-142-3/+3
|
* Merge branch 'fix-avatar-removal' into 'master'Hannes Rosenögger2015-05-123-4/+4
|\ | | | | | | | | | | | | | | | | | | | | | | | | Fix bug where avatar filenames were not actually deleted from the database during removal This would result in a 404 error in certain views. The `save` call was being rolled back due to an error in the validation step. Relax the validation step so that this works. Closes #1570 See merge request !620
| * Fix bug where avatar filenames were not actually deleted from the database ↵Stan Hu2015-05-073-4/+4
| | | | | | | | | | | | | | | | | | | | | | during removal. This would result in a 404 error in certain views. The `save` call was being rolled back due to an error in the validation step. Relax the validation step so that this works. Closes #1570
* | Merge branch 'rs-system-note' into 'master'Dmitriy Zaporozhets2015-05-122-227/+18
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | Add SystemNoteService class The Note model was basically two models crammed together - one handling user-created notes (i.e., comments on things) and one handling system-created notes (i.e., references). This splits out the system-specific stuff to a new SystemNoteService class. See merge request !595
| * | Check if `system` is truthy in `Note.cross_reference?`Robert Speicher2015-05-111-1/+1
| | |
| * | Add a SystemNoteService classRobert Speicher2015-05-112-210/+7
| | | | | | | | | | | | | | | There's a lot of code in the Note model that only deals with creating system notes, so we're going to split that into its own class.
| * | Simplify `Note#upvote?` and `Note#downvote?`Robert Speicher2015-05-101-17/+11
| | |
* | | Merge branch '2fa' into 'master'Dmitriy Zaporozhets2015-05-121-2/+13
|\ \ \ | |/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Two-factor authentication Implement's Two-factor authentication using tokens. - [X] Authentication logic - [X] Enable/disable 2FA feature - [x] Make 2-step login process if 2FA enabled - [x] Backup codes - [x] Backup code removed after being used - [x] Check backup codes for mysql db (mention mysql limitation if applied) - [x] Add tests - [x] Test if https://github.com/tinfoil/devise-two-factor#disabling-automatic-login-after-password-resets applies, and address if so - [x] Wait for fixed version of `attr_encrypted` or fork and use forked version - https://github.com/attr-encrypted/attr_encrypted/issues/155 Fixes http://feedback.gitlab.com/forums/176466-general/suggestions/4516817-implement-two-factor-authentication-2fa See merge request !474
| * | Remove extra `devise` call that got added by accidentRobert Speicher2015-05-101-3/+0
| | |
| * | Remove unnecessary User#login accessor overrideRobert Speicher2015-05-091-5/+0
| | |
| * | Generate 10 2FA backup codes instead of the default of 5Robert Speicher2015-05-091-1/+1
| | |
| * | Fix 2FA backup code removalRobert Speicher2015-05-091-0/+3
| | |
| * | Re-annotate User modelRobert Speicher2015-05-091-0/+5
| | |
| * | Update User model for two-factor authRobert Speicher2015-05-091-2/+10
| | |
| * | Fix rubocop complainDmitriy Zaporozhets2015-05-091-1/+1
| | |
| * | Init 2 factor authentication for user modelDmitriy Zaporozhets2015-05-091-1/+4
| | |
* | | Merge branch 'bug/fix-duplicate-deploy-keys' into 'master'Marin Jankovski2015-05-101-1/+1
|\ \ \ | |/ / |/| | | | | | | | | | | | | | | | | Don't show duplicate deploy keys This fixes the issue described in [#1516](https://gitlab.com/gitlab-org/gitlab-ce/issues/1516) where you would see the same deploy key multiple times if it was used by multiple projects. See merge request !629
| * | Don't show duplicate deploy keys. Fixes #1516Maran2015-05-081-1/+1
| | |
* | | Merge pull request #9214 from Bugagazavr/hook-eventsValeriy Sizov2015-05-083-6/+16
|\ \ \ | |/ / |/| | Added X-GitLab-Event header for web hooks
| * | Added X-GitLab-Event header for web hooksbugagazavr2015-05-083-6/+16
| |/
* | Change wording for task list summariesRobert Speicher2015-05-061-2/+2
| |
* | Update Taskable to use TaskListRobert Speicher2015-05-061-30/+15
|/
* fix gitlab CI linksfix_ci_servicesValery Sizov2015-05-051-2/+2
|
* Re-annotate modelsStan Hu2015-05-0318-22/+46
|
* Merge branch 'change-primary-email' into 'master'Dmitriy Zaporozhets2015-05-032-7/+26
|\ | | | | | | | | | | | | | | | | | | Allow primary email to be set to an email that you've already added. Fixes gitlab-com/support-forum#106. When the user sets their primary email to an email that they've already added to their account, this patch makes sure that secondary email record is destroyed, and a new email record is created for the old primary email. This is based on the assumption that in this case no email was meant to be deleted, but the user simply wanted to change which of their emails is primary. See merge request !591
| * Allow primary email to be set to an email that you've already added.change-primary-emailDouwe Maan2015-04-302-7/+26
| |
* | Add application setting to restrict user signups to e-mail domainsStan Hu2015-05-022-2/+46
| | | | | | | | | | | | | | | | | | | | | | This feature was requested long ago: http://feedback.gitlab.com/forums/176466-general/suggestions/4118466-ability-to-register-only-from-ceratain-domains This MR is based off !253 but changed to use application settings and use wildcard strings to give more flexibility in pattern matching. Regexps seemed overkill and easy to get wrong. Only restrict e-mail addresses upon creation
* | Improve/add specs for `Project#get_issue` and `#issue_exists?`rs-more-pipeline-filtersRobert Speicher2015-05-011-1/+1
| |
* | Change `external_issue_tracker.blank?` to `!external_issue_tracker`Robert Speicher2015-04-301-1/+1
| |