Commit Graph

26 Commits

Author SHA1 Message Date
Felipe Artur b5f596c3ff Native group milestones 2017-07-07 15:08:49 +00:00
Valery Sizov 387c4b2c21 Backport of multiple_assignees_feature [ci skip] 2017-05-04 17:11:53 +03:00
Alex Braha Stoll 50a8f16e16 Add count badges to both dashboard and group milestones 2017-03-10 13:04:19 +01:00
Adam Niedzielski f13c650c16 Speed up group milestone index by passing group_id to IssuesFinder 2017-01-06 13:47:18 +01:00
James Edwards-Jones 27c936adf9 Milestoneish SQL performance partially improved and memoized
Memoize Milestoneish#issues_visible_to_user and counts to reduce lookups
Milstoneish SQL optimised with project, but still slow on GlobalMilestone
2016-12-20 12:45:29 +00:00
Valery Sizov 3789cfe056 Add a starting date to milestones 2016-11-23 13:41:04 +02:00
Nick Thomas e94cd6fdfe Add markdown cache columns to the database, but don't use them yet
This commit adds a number of _html columns and, with the exception of Note,
starts updating them whenever the content of their partner fields changes.

Note has a collision with the note_html attr_accessor; that will be fixed later

A background worker for clearing these cache columns is also introduced - use
`rake cache:clear` to set it off. You can clear the database or Redis caches
separately by running `rake cache:clear:db` or `rake cache:clear:redis`,
respectively.
2016-10-07 02:54:25 +01:00
Ahmad Sherif 2161c72da0 Use select(:foo) instead of map(&:foo) in GlobalMilestone 2016-09-23 13:35:11 +02:00
Ahmad Sherif b5132118cd Ensure milestones passed to GlobalMilestone is an ActiveRecord::Relation 2016-09-23 13:34:39 +02:00
Ahmad Sherif b8bfe50a50 Reduce number of queries when calling GlobalMilestone#{labels,participants} 2016-09-23 13:19:16 +02:00
Ahmad Sherif ac3470280d Eager-load assignee and labels associations for GlobalMilestore issuables 2016-09-23 13:19:16 +02:00
Phil Hughes b5ece0886a Ruby fixes 2016-03-29 12:19:09 +01:00
Phil Hughes 88024b17c0 Standardised the output of the JSON to always include the name
The frontend will then always use the name as the ID - like previous
2016-03-29 11:59:13 +01:00
Rubén Dávila 95b06a62c0 Updates from last code review. 2016-03-06 23:07:19 -05:00
Rubén Dávila ed48085558 Refactor Merge Requests tab into a custom partial
* Add Labels tab to Groups
* Add decorator for label so it's aware of Milestones.
2016-03-04 22:37:03 -05:00
Rubén Dávila e805becfe8 Eager load Issues/MRs project for Milestone.
With this change we avoid doing N+1 queries when viewing Milestone's
Issues/MRs from a Group context.
2016-03-04 22:37:03 -05:00
Rubén Dávila a056dfa9a0 Refactor GlobalMilestone queries.
Make methods return ActiveRecord Relations instead of Arrays.
2016-03-04 22:37:03 -05:00
Robert Speicher fa36749bce Add two custom Date/Time conversion formats 2016-01-07 20:01:08 -05:00
Robert Speicher 59305715e9 Remove stamp gem
Closes #5908
2016-01-07 16:28:33 -05:00
Stan Hu 34695569da Fix Error 500 when global milestones have slashes
Closes #4226
2015-12-22 13:15:32 -08:00
Douwe Maan a468bf346a Merge branch 'gsmethells/gitlab-ce-sort-by-due-date' 2015-12-07 13:45:16 +01:00
Douwe Maan ff08ce9ca4 Satisfy Rubocop 2015-12-07 13:45:00 +01:00
Stan Hu d800a949d2 Fix Error 500 when creating global milestones with Unicode characters
Two issues:

1. The constraints in the resources were incorrect. Here's what it was before:
```
group_milestone  GET /groups/:group_id/milestones/:id(.:format)  groups/milestones#show {:id=>/[a-zA-Z.0-9_\-]+(?<!\.atom)/, :group_id=>/[a-zA-Z.0-9_\-]+(?<!\.atom)/}
```

In this case, id is actually the title of the milestone, which can be anything at the moment.

After:

```
group_milestone  GET /groups/:group_id/milestones/:id(.:format)  groups/milestones#show {:id=>/[^\/]+/, :group_id=>/[a-zA-Z.0-9_\-]+(?<!\.atom)/}
```

2. `parameterize` would strip all Unicode characters, leaving a blank string. Rails would report something like:

ActionView::Template::Error (No route matches {:action=>"show", :controller=>"groups/milestones", :group_id=>#<Group id: 48, name: "ops-dev", path: "ops-dev", owner_id: nil, created_at: "2015-11-15 08:55:30", updated_at: "2015-12-02 06:23:26", type: "Group", description: "", avatar: "sha1.c71e73d51af1865c1bbbf6208e10044d46c9bb93.png", public: false>, :id=>"", :title=>"肯定不是中文的问题"} missing required keys: [:id]):

This change uses the babosa library to create a better slug, which surprisingly
isn't actually used by the global milestone controllers. Instead, they use the
title passed as a query string for some reason.

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

Fix constraints
2015-12-05 00:04:44 -08:00
Greg Smethells dbbd2b863b sort milestones by due_date 2015-12-03 08:53:34 -06:00
Dmitriy Zaporozhets b093f50986
Some code and doc improvements
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-11-16 19:55:58 +01:00
Dmitriy Zaporozhets 986695e136 Refactor global and group milestones logic
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-11-16 14:07:38 +01:00