summaryrefslogtreecommitdiff
path: root/spec/models
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'improve-contributions-calendar' into 'master'Dmitriy Zaporozhets2015-03-231-38/+7
|\ | | | | | | | | | | | | | | | | | | | | Replace commits calendar with contributions calendar * count opening of issues and merge requests * dont trigger git repository - use events from database * count pushes instead of commits for faster and easier counting * much-much faster since does not affected by repository size See merge request !420
| * Refactor repository specsDmitriy Zaporozhets2015-03-221-38/+7
| |
* | Fix dots in Wiki slug causing errorsStan Hu2015-03-211-0/+41
|/ | | | Closes #1263, #431
* Link to CI with refValery Sizov2015-03-202-3/+3
|
* Fix cross references when usernames, milestones, or project names contain ↵Stan Hu2015-03-191-11/+142
| | | | | | underscores. Remove emphasis from system notes to avoid Markdown conflicts in names.
* Extend the commit calendar to show the actual commits for a dateHannes Rosenögger2015-03-181-2/+17
|
* Merge branch 'external_wiki' into 'master'Dmitriy Zaporozhets2015-03-181-0/+39
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support for external wikis ## What does this MR do? This MR adds the possibility to replace the link to the internal wiki of gitlab with a custom link. Currently this is realised as a service. ## What Use Case does this MR solve? In my Company we already have a wiki System (Confluence). We have a policy to use the existing wiki, so we can't switch to the internal wiki Gitlab provides. This currently only leaves us two choices: 1. Disable the gitlab wiki. That means we completly loose the connection between wiki and code from the gitlab ui. 2. Create a simple wiki page with a link to our external wiki and hope that no one uses the internal one. Both solutions are not really good. So what can be done to improve the situation while making it as easy as possible for new developers to access both, wiki and gitlab? Replacing the wiki link kinda like the JIRA integration replaces the issues link looks like a good first step to me. :) This can probably be extended later to completly prevent access to the internal wiki (currently that's still possible if you know the link) or maybe to check if the link really points to a wiki. ## Screenshot: ![external_wiki_service](https://gitlab.com/uploads/gitlab-org/gitlab-ce/89b27cf068/external_wiki_service.png) See merge request !291
| * Add a service to support external wikisHannes Rosenögger2015-03-121-0/+39
| |
* | Delete deploy key when last connection to a project is destroyed.Douwe Maan2015-03-171-0/+33
| |
* | Merge branch 'fix-restricted-visibility' into 'master'Dmitriy Zaporozhets2015-03-161-11/+13
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Restricted visibility levels - bug fix and new feature This allows admin users to override restricted visibility settings when creating and updating projects and snippets, and moves the restricted visibility configuration from gitlab.yml to the web UI. See #1903. ## Move configuration location I added a new section to the application settings page for restricted visibility levels. Each level has a checkbox, styled with Bootstrap to look like a toggle button. A checked box means that the level is restricted. I added a glowing text shadow and changed the background color for checked buttons because the default styles made it hard to distinguish between checked and unchecked. This image shows the new section with the "Public" box checked: ![restricted_visibility_settings](https://dev.gitlab.org/Okada/gitlabhq/uploads/629562e4313f89b795e81c3bb0f95893/restricted_visibility_settings.png) ## Allow admins to override To allow admin users to override the restricted visibility levels, I had to remove the `visibility_level` validation from the `Project` class. The model doesn't know about the `current_user`, which should determine whether the restrictions can be overridden. We could use the creator in the validation, but that wouldn't work correctly for projects where a non-admin user is the creator and an admin tries to change the project to a restricted visibility level. The `Project::UpdateService` and `Project::CreateService` classes already had code to determine whether the current user is allowed to use a given visibility level; now all visibility level validation is done in those classes. Currently, when a non-admin tries to create or update a project using a restricted level, these classes silently set the visibility level to the global default (create) or the project's existing value (update). I changed this behavior to be more like an Active Model validation, where using a restricted level causes the entire request to be rejected. Project and personal snippets didn't have service classes, and restricted visibility levels weren't being enforced in the model or the controllers. The UI disabled radio buttons for restricted levels, but that wouldn't be difficult to circumvent. I created the `CreateSnippetService` and `UpdateSnippetService` classes to do the same restricted visibility check that the project classes do. And since I was dealing with snippet visibility levels, I updated the API endpoints for project snippets to allow users to set and update the visibility level. ## TODO * [x] Add more tests for restricted visibility functionality cc @sytse @dzaporozhets See merge request !1655
| * \ Merge branch 'master' into fix-restricted-visibilityVinnie Okada2015-03-143-4/+27
| |\ \ | | |/ | | | | | | | | | Conflicts: db/schema.rb
| * | Move restricted visibility settings to the UIVinnie Okada2015-03-071-11/+13
| | | | | | | | | | | | | | | Add checkboxes to the application settings page for restricted visibility levels, and remove those settings from gitlab.yml.
* | | Use `group_member` instead of `users_group` or `membership`.Douwe Maan2015-03-151-6/+6
| |/ |/|
* | Merge branch 'master' of gitlab.com:gitlab-org/gitlab-ceDmitriy Zaporozhets2015-03-101-0/+23
|\ \
| * | This MR extends the commit calendar so it searches for commits made with ↵Stan Hu2015-03-091-0/+23
| |/ | | | | | | | | | | | | every email address the user has associated with his account. This fixes one of the problems mentioned in gitlab-org/gitlab-ce#1162 and makes the behavior of the commit calendar as described in the profile. "All email addresses will be used to identify your commits."
* | Use Gitlab::Git helper methods and constants as much as possible.Douwe Maan2015-03-102-4/+4
|/
* Add tag_push event notification to HipChat and Slack services.Stan Hu2015-03-065-23/+74
| | | | | | | Normalize output to use: - User name instead of username - Include first line of title in message description - Link to "Issue #X" instead of "#X"
* Added comment notification events to HipChat and Slack services.Stan Hu2015-03-063-7/+275
| | | | | | | | | Supports four different event types all bundled under the "note" event type: - comments on a commit - comments on an issue - comments on a merge request - comments on a code snippet
* Add merge and issue event notification for HipChatStan Hu2015-03-051-0/+102
|
* Re-annotate modelsDmitriy Zaporozhets2015-03-0414-132/+166
|
* Merge branch 'add-more-slack-notifications' into 'master'Dmitriy Zaporozhets2015-03-0411-66/+236
|\ | | | | | | | | | | | | | | Add more Slack notifications for issue and merge request events From https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/237 by Stan Hu. See merge request !1556
| * Fix specs.Douwe Maan2015-03-031-3/+3
| |
| * Fix specs.Douwe Maan2015-03-033-8/+8
| |
| * Issue #595: Support Slack notifications upon issue and merge request eventsStan Hu2015-03-0311-61/+231
| | | | | | | | | | | | | | | | | | | | | | 1) Adds a DB migration for all services to toggle on push, issue, and merge events. 2) Upon an issue or merge request event, fire service hooks. 3) Slack service supports custom messages for each of these events. Other services not supported at the moment. 4) Label merge request hooks with their corresponding actions.
* | Fix import check for case sensetive namespacesDmitriy Zaporozhets2015-03-021-0/+10
|/
* Merge branch 'add-irker-service' of https://github.com/Aorimn/gitlabhq into ↵Dmitriy Zaporozhets2015-03-021-0/+103
|\ | | | | | | | | | | | | Aorimn-add-irker-service Conflicts: app/controllers/projects/services_controller.rb
| * Add Irker serviceAorimn2015-03-011-0/+103
| | | | | | | | | | | | | | | | | | | | Irker is a gateway which sends IRC messages on git updates. This new service provides an interface to this gateway, integrated in Gitlab, for each updates. As per the guidelines, this commit adds the new feature in the CHANGELOG, tests and documentation. See http://www.catb.org/esr/irker/
* | Merge pull request #8501 from AKoetsier/slack_channel_and_usernameDmitriy Zaporozhets2015-03-021-0/+22
|\ \ | |/ |/| Allow a user to specify a channel and username for the slack-webhook
| * Allow a user to specify a channel and username for the slack-webhookAndrès Koetsier2015-02-281-0/+22
| |
* | Merge pull request #8890 from sue445/feature/project_api_avatar_urlJeroen van Baarsen2015-03-011-0/+31
|\ \ | |/ |/| Expose avatar_url in projects API
| * Expose avatar_url in projects APIsue4452015-03-011-0/+31
| | | | | | | | | | | | * Impl Project#avatar_url * Refactor ApplicationHelper: Use Project#avatar_url * Update changelog
* | Fix and test User#contributed_projects_ids.Douwe Maan2015-02-271-0/+28
|/
* Using gitlab url to build links for gitlab issue tracker and add a spec. Fix ↵Marin Jankovski2015-02-231-0/+60
| | | | rubocop warnings in path.
* Upgrade to Rails 4.1.9Vinnie Okada2015-02-141-1/+1
| | | | | | 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.
* Prevent autogenerated OAuth username to clash with existing namespace.Douwe Maan2015-02-131-2/+2
|
* Merge branch 'master' of github.com:gitlabhq/gitlabhqDmitriy Zaporozhets2015-02-1245-628/+758
|\
| * Merge pull request #8785 from jvanbaarsen/rspec-upgradeDmitriy Zaporozhets2015-02-1245-628/+758
| |\ | | | | | | Rspec upgrade
| | * Updated rspec to rspec 3.x syntaxJeroen van Baarsen2015-02-1245-628/+758
| | | | | | | | | | | | Signed-off-by: Jeroen van Baarsen <jeroenvanbaarsen@gmail.com>
* | | Merge branch 'clean-oauth-username' into 'master'Dmitriy Zaporozhets2015-02-131-0/+10
|\ \ \ | |/ / |/| | | | | | | | | | | | | | | | | | | | Clean username acquired from OAuth/LDAP. Fixes #1967. Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/813 See merge request !1500
| * | Clean username acquired from OAuth/LDAP.Douwe Maan2015-02-121-0/+10
| |/ | | | | | | Fixes #1967.
* | Add a test for service template.Marin Jankovski2015-02-121-0/+25
| |
* | Annotate services. Add a link to service template.Marin Jankovski2015-02-111-1/+2
|/
* Merge pull request #8580 from j0k3r/asanaDmitriy Zaporozhets2015-02-082-0/+61
|\ | | | | Add Asana service
| * Fix testJeremy2015-02-021-1/+0
| | | | | | | | | | Related https://semaphoreapp.com/gitlabhq/gitlabhq/branches/pull-request-8580/builds/9 Asana service doesn't check if restrict_to_branch is defined since it can be undefined
| * Fix HoundCIJeremy2015-02-021-3/+0
| |
| * Add restrict_to_branch to service controllerJeremy2015-02-021-1/+3
| | | | | | | | And add restrict_to_branch to spec
| * Add Asana serviceJeremy2015-02-022-0/+63
| | | | | | | | Also add ability to render "service.help" in markdown
* | Refactor issuable sorting a bitDmitriy Zaporozhets2015-02-051-3/+3
| |
* | Merge branch 'master' into mwessel/gitlab-ce-configure-protectionDmitriy Zaporozhets2015-02-0317-2/+16
|\ \
| * | Annotate modelsDmitriy Zaporozhets2015-02-022-1/+15
| | |