Commit Graph
8955 Commits
Author SHA1 Message Date
Douwe Maan 0795698162 Merge branch 'new-mr-disable-change-target-branch' into 'master'
Disable changing of target branch in new merge request page when a branch has already been specified

### What does this MR do?

This MR prevents a user from changing the target branch inside a new merge request page if the target branch has already been specified (e.g. from the shortcut in the activity feed). A link to "Change branches" is provided to allow the user to do this properly.

### Why was this MR needed?

If a user attempted to create a merge request from a shortcut with a pre-specified target branch (e.g. `master`), the dropdown would suggest that the user could change the branch. However, this did not actually work due to duplicate data elements (see #1830 for more details), and the target branch would always be set to the original, default branch. This would lead to confusion, potentially causing an improper merge request to be created.

### What are the relevant issue numbers?

Closes #1830

### Screenshot

![image](https://gitlab.com/stanhu/gitlab-ce/uploads/eeec4f5d4b66625a14be41e5ecbdc016/image.png)

See merge request !846
2015-06-20 10:41:07 +00:00
Douwe Maan b2eef41d41 Merge branch 'fix-error-500-internal-snippet' into 'master'
Fix Error 500 when one user attempts to access another's personal, internal snippet

### What does this MR do?

This MR fixes an Error 500 that occurred if one user tried to access another's personal, internal snippet. Steps to reproduce:

### Why was this MR needed?

1. Go to `<hostname>/snippets/new`.
2. Select "Internal".
3. Create a snippet. Save the URL (e.g. `<hostname>/snippets/20`)
4. Logout and sign in as another user.
5. Go to the URL in step 3.

### What are the relevant issue numbers?

Closes #1815

See merge request !854
2015-06-20 10:38:33 +00:00
Stan Hu e785b9d2e2 Fix Error 500 when one user attempts to access a personal, internal snippet
Closes #1815
2015-06-19 21:23:46 -07:00
Nicolas aecc989154 Make snippet filename optional.
Fixes #2384.
2015-06-20 01:06:57 +02:00
Stan Hu c8d4a408f8 Disable changing of target branch in new merge request page when a branch has already been specified
Closes #1830
2015-06-19 15:39:56 -07:00
Robert Speicher efa0146c7f Merge branch 'rs-blobview-js-refactor' into 'master'
Refactor and spec line highlighting Javascript

- Replaces the fragile Spinach tests for this feature with Jasmine tests
- The "Don't scroll the page when we click a line number" behavior now works as expected

See merge request !820
2015-06-19 21:27:25 +00:00
Robert Speicher 7f5b255c08 Minor style fixes for LineHighlighter 2015-06-19 16:43:09 -04:00
Robert Speicher 516b4c1248 Allow Admin to filter users by 2FA status 2015-06-19 16:35:53 -04:00
Robert Speicher b6318297fc Use User#two_factor_enabled instead of otp_required_for_login 2015-06-19 15:14:37 -04:00
Robert Speicher 22dd2240a6 Add 2FA status to Admin::Users#show 2015-06-19 15:04:47 -04:00
Robert Speicher 6c8f0fe906 Add convenience methods to User for getting and setting 2FA status 2015-06-19 14:59:42 -04:00
Robert Speicher 7964e7d6a1 Move the User dashboard enum further up in the class 2015-06-19 14:59:07 -04:00
Darby 9209f43b32 Edited the CSS of header and sidebar; added a new class of logo-container to the html to make things easier 2015-06-19 09:54:26 -07:00
Dmitriy Zaporozhets 7524d7c082 Revert merge request states renaming
Replaced:
* "Accepted" with "Merged"
* "Rejected" with "Closed"

Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-06-19 17:09:50 +02:00
Dmitriy Zaporozhets f5e0e5c0a3 Replace old logo with new one
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-06-19 16:59:16 +02:00
Dmitriy Zaporozhets d059c69db7 Move identities list to own controller action
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-06-19 15:29:53 +02:00
Dmitriy Zaporozhets 270b7ce810 Add ability for admin to edit user identity
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-06-19 15:29:53 +02:00
Dmitriy Zaporozhets 228da2dd28 Admin can see and remove user identities
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-06-19 15:29:52 +02:00
Robert Speicher e59aad6e83 Refactor LineHighlighter 2015-06-19 04:31:24 -04:00
Robert Speicher 32366d1811 Rename BlobView to LineHighlighter 2015-06-19 04:31:24 -04:00
Robert Speicher da15428340 Simplify line numbering 2015-06-19 04:31:24 -04:00
Robert Speicher 15582293b9 Use pushState instead of the temporary div hack 2015-06-19 04:31:24 -04:00
Robert Speicher b3f9be0639 Refactor and spec BlobView JS 2015-06-19 04:31:23 -04:00
Darby e2e8e384bb Revert "Changed the placeholder text and modified the css class to make it visible"
This reverts commit c39c823421.
2015-06-18 13:50:33 -07:00
Douwe Maan 0e615a4863 Merge branch 'fix-labels-permisssion-check' into 'master'
Fix 403 Access Denied error messages when accessing Labels section in a project

This would occur if the project's issues or merge requests features were disabled. The change in 9bcd36396b caused `can?(current_user, :read_merge_request, project)` to be false if the merge request feature were disabled, so `authorize_labels!` needs to be changed accordingly.

Closes #1813

See merge request !836
2015-06-18 11:43:32 +00:00
Stan Hu 07efb17e10 Fix 403 Access Denied error messages when accessing Labels section in a project that has MRs disabled but issues enabled
Closes #1813
2015-06-18 03:15:05 -07:00
Robert Speicher 54365ecc7a Remove overridden link_to helper
The purpose for this override is now handled by `ExternalLinkFilter`.
2015-06-17 17:23:16 -04:00
Robert Speicher 1c4bf0e474 Use skip_js for commit timestamps
This greatly improves frontend rendering times.
2015-06-17 16:59:51 -04:00
Robert Speicher bc027c5183 Load the Merge Request > Commits tab lazily 2015-06-17 16:59:51 -04:00
Robert Speicher ce20400628 Extract MergeRequest tab behavior to its own JS class 2015-06-17 16:59:50 -04:00
Robert Speicher 7e31a369f5 Spec and refactor User.find_for_commit
Now it executes a single query instead of a possible three at the cost
of some scary-looking ARel calls.
2015-06-17 16:37:11 -04:00
Robert Speicher 2efb0b6e93 Remove duplicate timeago call 2015-06-17 16:37:10 -04:00
Robert Speicher 8c8cd8be43 Update time_ago_with_tooltip helper
Minor refactoring, add specs, changes arguments to use keywords.
2015-06-17 16:37:10 -04:00
Dmitriy Zaporozhets 79e24886ec Merge branch 'master' of gitlab.com:gitlab-org/gitlab-ce 2015-06-17 11:56:43 +02:00
Dmitriy Zaporozhets 1eb51e1706 Merge branch 'placeholder_text'
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>

Conflicts:
	Gemfile.lock
2015-06-17 11:43:08 +02:00
Dmitriy Zaporozhets 73918efb27 Merge branch 'swellard-issue-6123' into 'master'
Fix duplicate 'Email has already been taken' message when creating a user

devise :validatable and validates uniqueness set on the user email field cause 2 validations to fire when creating a new user with an email address already in use, Issue 6123

@stanhu Thanks for your input on merge request 807, I'll close that one in favour of this as I have added tests

See merge request !817
2015-06-17 09:01:41 +00:00
Dmitriy Zaporozhets de5c9b795d Merge branch 'rs-dev-issue-2373' into 'master'
Prefix 2FA issuer with the GitLab host (e.g., 'dev.gitlab.org')

https://dev.gitlab.org/gitlab/gitlabhq/issues/2373

See merge request !821
2015-06-17 09:00:57 +00:00
Darby c39c823421 Changed the placeholder text and modified the css class to make it visible 2015-06-16 14:44:13 -07:00
Robert Speicher 0d7a0675ac Bootlint: Fix incorrectly nested form-group element 2015-06-16 13:33:48 -04:00
Robert Speicher 09b4e11d26 Bootlint: Add missing type attribute for buttons 2015-06-16 13:33:48 -04:00
Robert Speicher e3c1818a3e Bootlint: Modals no longer need a '.hide' class 2015-06-16 13:32:33 -04:00
Robert Speicher 7400cfc114 Bootlint: Use offset grid classes instead of empty divs 2015-06-16 13:32:32 -04:00
Robert Speicher ad049a8e52 Prefix 2FA issuer with the GitLab host (e.g., 'dev.gitlab.org') 2015-06-16 13:08:29 -04:00
Douwe Maan adffe47d3c Merge branch 'support-comment-parallel-diff' into 'master'
Support commenting on a diff in side-by-side view

### What does this MR do?

This MR adds support for commenting on a diff in side-by-side (aka parallel) view. It also fixes a JavaScript bug (see !779) when the comment button is clicked on a line that already has a comment.

There is an existing bug where the comment count is not updated when a new comment is added. I'll send a MR for that later.

### Why was this MR needed?

Commenting only worked in "inline" mode. Often the side-by-side view is more conducive to writing comments.

### What are the relevant issue numbers?

Closes https://github.com/gitlabhq/gitlabhq/issues/9283

### Screenshot

![image](https://gitlab.com/stanhu/gitlab-ce/uploads/3d0a3213fde38844a681a826da18139b/image.png)

See merge request !810
2015-06-16 14:43:15 +00:00
swellard 19e5b043fe Fix duplicate 'Email has already been taken' message when creating a user, updated comments 2015-06-16 14:24:05 +01:00
swellard 98615ef536 Fix duplicate 'Email has already been taken' message when creating a user 2015-06-16 14:24:05 +01:00
Stan Hu a7932fe2fd Support commenting on a diff in side-by-side view
Closes https://github.com/gitlabhq/gitlabhq/issues/9283
2015-06-16 06:11:59 -07:00
Dmitriy Zaporozhets fb5ffa89a6 Merge branch 'master' of gitlab.com:gitlab-org/gitlab-ce 2015-06-16 14:45:10 +02:00
Douwe Maan 9af2bc8907 Merge branch 'header_layout_issue' into 'master'
Fix layout issue in header title truncation.

@douwe Thanks for reviewing this fix for the issue mentioned in https://dev.gitlab.org/gitlab/gitlabhq/issues/2314#note_48539.

**BEFORE**

![before](https://dev.gitlab.org/gitlab/gitlabhq/uploads/4ffb35f77155a92c64cfe36c66987eb0/before.gif)

**AFTER**

![after](https://dev.gitlab.org/gitlab/gitlabhq/uploads/2bb2d0c4a93164f6d47e24cdcb9a106b/after.gif)

See merge request !1867
2015-06-16 12:34:21 +00:00
Douwe Maan 63969337a9 Merge branch 'applications_form' into 'master'
Fix UI issues in Applications form

@douwe Thanks for reviewing this small fix.

---

Before:

![application_form_before](https://dev.gitlab.org/gitlab/gitlabhq/uploads/11fbee17ad6a4c9456cd7d6cba5ae429/application_form_before.png)

---

After:

![application_form_after](https://dev.gitlab.org/gitlab/gitlabhq/uploads/0c64214ccda6c77095f468fcb8c748f3/application_form_after.png)

See merge request !1859
2015-06-16 11:50:13 +00:00