Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • rspeicher/gitlab
  • reprazent/gitlab
  • mwasilewski-gitlab/gitlab
  • mlapierre/gitlab
  • gl-gitaly/gitlab
  • gitlab-org/gitlab
  • 1and1_ebusiness/gitlab-ee
  • marin/gitlab-ee
  • max-group/gitlab-ee
  • cirosantilli/gitlab-ee
  • cernvcs/gitlab-ee
  • chrisrohr/gitlab-ee
  • stanhu/gitlab-ee
  • ealcantara/gitlab
  • sijis/gitlab-ee
  • kalibyrn/gitlab-ee
  • bbodenmiller/gitlab-ee
  • cvd/gitlab-ee
  • alexwarren/gitlab-ee
  • j.seto/gitlab
  • cmiskell/gitlab
  • Ashley/gitlab-ee
  • kkm/gitlab-ee
  • haynes/gitlab-ee
  • dblessing/gitlab-ee
  • allison.browne/gitlab
  • singingwolfboy/gitlab-ee
  • coderhugo/gitlab-ee
  • axil/gitlab-ee
  • truongsinh/gitlab-ee
  • tensky/gitlab-ee
  • rymai/gitlab-ee
  • jt-gitlab/gitlab-ee
  • patricio/gitlab-ee
  • b.lashen/gitlab-ee
  • acroitor/gitlab
  • rosiv/gitlab-ee
  • sune-keller/gitlab-ee
  • wiget/gitlab-ee
  • bandel/gitlab-ee
  • e4r7hbug/gitlab-ee
  • chaosaffe/gitlab-ee
  • yannick-croissant/gitlab-ee
  • jameslopez/gitlab-ee
  • xellor/gitlab-ee
  • ymotiongroup/gitlab-ee
  • cwilcox/gitlab-ee
  • daniel.hoffmann/gitlab-ee
  • johnnyeric/gitlab-ee
  • pidge/gitlab-ee
  • Posp/gitlab-ee
  • jonafato/gitlab-ee
  • Quintasan/gitlab
  • shobra/gitlab-ee
  • sleepyknife/gitlab-ee
  • yorickpeterse/gitlab
  • abualy/gitlab-ee
  • ci-test-user-mk/gitlab
  • jogo/gitlab-ee
  • foxnewsnetwork/gitlab-ee
  • riemers/gitlab-ee
  • pacoguzman/gitlab-ee
  • usr01/gitlab-ee
  • samuel.bernard/gitlab-ee
  • codelust/gitlab-ee
  • takitak/gitlab-ee
  • ftasdelen/gitlab-ee
  • qhcthanh/gitlab-ee
  • clairton/gitlab-ee
  • cuongtm/gitlab-ee
  • m5/gitlab-ee
  • Sivapuram/gitlab-ee
  • sbeleidy/gitlab-ee
  • baparici/gitlab-ee
  • Hubbitus/gitlab-ee
  • lbennett/gitlab-ee
  • klml/gitlab-ee
  • jaydeland/gitlab-ee
  • lupine/gitlab-ee
  • leftathome/gitlab-ee
  • ianb/gitlab-ee
  • mumayank/gitlab-ee
  • nagoyamavps/gitlab-ee
  • pattyhama/gitlab-ee
  • momirza/gitlab-ee
  • BhavaniM/gitlab-ee
  • morefice/gitlab
  • splattael-staging/gitlab
  • toanalien/gitlab-ee
  • clever_usr_name/gitlab-ee
  • oscar-lopez/gitlab-ee
  • svansteenis/gitlab-ee
  • prashtest/gitlab-ee
  • bonsai/gitlab-ee
  • graingert/gitlab-ee
  • niijv/gitlab-ee
  • abdiasshaw/gitlab-ee
  • peter9208/gitlab-ee
  • gforcada/gitlab-ee
  • broftkd/gitlab-ee
  • mkobel/gitlab-ee
  • mikaelz/gitlab-ee
  • OdNairy/gitlab-ee
  • christinebeaubrun/gitlab-ee
  • haakoo/gitlab-ee
  • Rencs/gitlab-ee
  • marcia/gitlab-ee
  • dehvmartins/gitlab-ee
  • rouzbeh84/gitlab-ee
  • gjunker/gitlab-ee
  • nick.thomas/gitlab-ee
  • heijmans/gitlab-ee
  • s.ghafarpour/gitlab-ee
  • markglenfletcher1/gitlab-ee
  • Benno/gitlab-ee
  • s2gluser/gitlab-ee
  • hazelyang/gitlab-ee
  • dewetblomerus/gitlab-ee
  • chrisbelyea/gitlab-ee
  • nick.volynkin/gitlab-ee
  • sevenseacat/gitlab-ee
  • yuanchenxi95/gitlab-ee
  • andyli/gitlab-ee
  • nacredata/gitlab-ee
  • srkaycg_admin/gitlab-ee
  • tagyangyang/gitlab-ee
  • miroslav.meca/gitlab-ee
  • cafed00d/gitlab-ee
  • iOrange/gitlab-ee
  • shackledtodesk/gitlab-ee
  • kalleva/gitlab-ee
  • paulsen.jan/gitlab-ee
  • hu19891110/gitlab-ee
  • gmeans/gitlab-ee
  • nithin2/gitlab-ee
  • dbelova/gitlab-ee
  • GeorgConradi/gitlab-ee
  • iunet/gitlab-ee
  • ephemeric/gitlab-ee
  • wendy0402/gitlab-ee
  • phil7/gitlab-ee
  • Eichi4Eichler/gitlab-ee
  • Munken/gitlab-ee
  • clim/gitlab-ee
  • averyduffin/gitlab-ee
  • DKovel/gitlab-ee
  • katrinleinweber/gitlab-ee
  • tmaier/gitlab-ee
  • Shahriar_Rabbi/gitlab-ee
  • Stretch96/gitlab-ee
  • brennanroberts/gitlab-ee
  • sanyatuning/gitlab-ee
  • hkrutzer/gitlab-ee
  • visualrobots/gitlab-ee
  • jieme/gitlab-ee
  • vansch/gitlab-ee
  • smuthusamy.fivedtech/gitlab-ee
  • almtoolbox/gitlab-ee
  • niketgupta6590/gitlab-ee
  • d.demichelis/gitlab-ee
  • LeclercA/gitlab-ee
  • bpietraga/gitlab-ee
  • ivikash/gitlab-ee
  • TobbenTM/gitlab-ee
  • YarNayar/gitlab-ee
  • dcondrey/gitlab-ee
  • atronah/gitlab-ee
  • mindupper/gitlab-ee
  • zyfran/gitlab-ee
  • savitojs/gitlab-ee
  • vino.v/gitlab-ee
  • athar/gitlab-ee
  • me63/gitlab-ee
  • l00mi/gitlab-ee
  • trentontri/gitlab-ee
  • peterlebrun/gitlab-ee
  • gwawr/gitlab-ee
  • isolation85/gitlab-ee
  • timothyandrew/gitlab-ee
  • shawonsoyket439/gitlab-ee
  • afolson/gitlab-ee
  • ismail-s/gitlab-ee
  • peterramsing/gitlab-ee
  • kason/gitlab-ee
  • al1_andre/gitlab-ee
  • pchojnacki/gitlab-ee
  • juliusv/gitlab-ee
  • scallopedllama/gitlab-ee
  • frech/gitlab-ee
  • z9g9l9/gitlab-ee
  • jamiekaw/gitlab-ee
  • mrburrito/gitlab-ee
  • headcrabmeat/gitlab-ee
  • cristiantmbr/gitlab-ee
  • revuel/gitlab-ee
  • Nnidyu/gitlab-ee
  • MrCirwos/gitlab-ee
  • Gutenevv/gitlab-ee
  • jmeyo/gitlab-ee
  • ollie314/gitlab-ee
  • sang9402/gitlab-ee
  • mickael9/gitlab-ee
  • vsizov/gitlab-ee
  • dosuken123/gitlab-ee
  • geoandri/gitlab-ee
  • afrastgeek/gitlab-ee
  • steveschooncts/gitlab-ee
  • dinsaw/gitlab-ee
  • xqua/gitlab-ee
  • smith-kyle/gitlab-ee
  • Mattlk13/gitlab-ee
  • andy_b_84/gitlab-ee
  • raansari/gitlab-ee
  • abitduck/gitlab-ee
  • mgresko/gitlab-ee
  • sidewinder12s/gitlab-ee
  • andresca/gitlab-ee
  • ccrebolder/gitlab-ee
  • rodrigo.pereira1/gitlab-ee
  • mohideen.rahuman/gitlab-ee
  • hebbet/gitlab-ee
  • smcgivern/gitlab-ee
  • heapifyman/gitlab-ee
  • TeNNoX/gitlab-ee
  • herryLi/gitlab-ee
  • AlexKalinin/gitlab-ee
  • vincedmg/gitlab-ee
  • martflu/gitlab-ee
  • derik/gitlab-ee
  • Ruby-and-Friends/gitlab-ee
  • wojciechlisik/gitlab-ee
  • winniehell-gitlab/gitlab-ee
  • Vaidehee5/gitlab-ee
  • vignesh.ravichandran02/gitlab-ee
  • tanyan2004/gitlab-ee
  • gitlabproject_s/gitlab-ee
  • virth/gitlab-ee
  • tmlee/gitlab-ee
  • hwdegroot/gitlab-ee
  • kybae/gitlab-ee
  • xiaogang_gitlab/gitlab-ee
  • jabber/gitlab-ee
  • eswar.madhira/gitlab-ee
  • alshamiri2/gitlab-ee
  • ba2014sheer/gitlab-ee
  • paulcodiny/gitlab-ee
  • glabio/gitlab-ee
  • lenghan1991/gitlab-ee
  • peterl/gitlab-ee
  • lucianomx/gitlab-ee
  • jbrandhorst/gitlab-ee
  • abushoeb/gitlab-ee
  • shellthor/gitlab-ee
  • jameshclrk/gitlab-ee
  • jontdelorme/gitlab-ee
  • tzc_007/gitlab-ee
  • indobits/gitlab-ee
  • dturner_ts/gitlab-ee
  • gauravkk22/gitlab-ee
  • andy9775/gitlab-ee
  • vladel/gitlab-ee
  • hakulatata99/gitlab-ee
  • lee0824/gitlab-ee
  • pk-codebox-evo/gitlab-ee
  • feshu/gitlab-ee
  • techguru/gitlab-ee
  • ei-grad/gitlab-ee
  • mccomput3rfr3ak/gitlab-ee
  • winnetou/gitlab-ee
  • julian-poidevin/gitlab-ee
  • arihantar/gitlab-ee
  • Trilom/gitlab-ee
  • Waysb1/gitlab-ee
  • jjung/gitlab-ee
  • xiaole/gitlab-ee
  • kikipq/gitlab-ee
  • rpadovani/gitlab-ee
  • zsturgess/gitlab-ee
  • mishunov/gitlab
  • nodeable/gitlab-ee
  • m1guelpiedrafita/gitlab-ee
  • jonas1/gitlab-ee
  • imranh/gitlab-ee
  • vitor.tyburski/gitlab-ee
  • pavel-voronin/gitlab-ee
  • alizadeh/gitlab-ee
  • aaaaaaq/gitlab-ee
  • JaKXz/gitlab-ee
  • umirra/gitlab-ee
  • jjcarstens/gitlab-ee
  • jenibella/gitlab-ee
  • hnk/gitlab-ee
  • roccolangeweg/gitlab-ee
  • batok/gitlab-ee
  • rajgomase24/gitlab-ee
  • qmnguyen0711/gitlab
  • 413063135/gitlab-ee
  • josephmarty/gitlab-ee
  • rdumont/gitlab-ee
  • gucong3000/gitlab-ee
  • ckatanda/gitlab-ee
  • overflowsith/gitlab-ee
  • TheJaredWilcurt/gitlab-ee
  • Riktos/gitlab-ee
  • losingle/gitlab-ee
  • mlushpenko/gitlab-ee
  • ericy_ts/gitlab-ee
  • fadb/gitlab-ee
  • dbvid/gitlab-ee
  • thejacer87/gitlab-ee
  • eli.boyarski/gitlab-ee
  • baldwinSPC/gitlab-ee
  • baldwinmathew/gitlab-ee
  • gsmethells/gitlab-ee
  • funkypenguin/gitlab-ee
  • rrentfro/gitlab-ee
  • M1TKO/gitlab-ee
  • SuriyaaKudoIsc/gitlab-ee
  • lmsurprenant/gitlab-ee
  • kay54088/gitlab-ee
  • pablo.catalina/gitlab-ee
  • xji/gitlab-ee
  • iscorer/gitlab-ee
  • kenny-evitt/gitlab-ee
  • Francis_Jude/gitlab-ee
  • xukaierwen/gitlab-ee
  • mustafayildirim/gitlab-ee
  • hh1/gitlab-ee
  • clamp27/gitlab-ee
  • UIPCO/gitlab-ee
  • chaase/gitlab-ee
  • matt.faure/gitlab-ee
  • wstomv/gitlab-ee
  • childNode/gitlab-ee
  • LockiStrike/gitlab-ee
  • Habiballah786/gitlab-ee
  • natebird/gitlab-ee
  • tamcv/gitlab-ee
  • adligithub/gitlab-ee
  • SuperDragon317/gitlab-ee
  • pkoretic/gitlab-ee
  • schoh/gitlab-ee
  • kpankonen/gitlab-ee
  • madnut_ua/gitlab-ee
  • smoothsailing/gitlab-ee
  • TimoSolo/gitlab-ee
  • collen/gitlab-ee
  • 0_0_0/gitlab-ee
  • innerwhisper/gitlab-ee
  • issue-reproduce-forks/gitlab-ee
  • szpak/gitlab-ee
  • zullusa/gitlab-ee
  • jamatute/gitlab-ee
  • mauriciomeirelles/gitlab-ee
  • anarcat/gitlab-ee
  • Shura/gitlab-ee
  • polarise/gitlab-ee
  • ecbrodie/gitlab-ee
  • odromark/gitlab-ee
  • senk/gitlab-ee
  • hiroponz/gitlab-ee
  • rawkode/gitlab-ee
  • HaPPyWaLLaCe/gitlab-ee
  • FeditskiyRoman/gitlab-ee
  • slrz/gitlab-ee
  • realsobek/gitlab-ee
  • Eternal21/gitlab-ee
  • leungpeng/gitlab-ee
  • nprabhu02/gitlab-ee
  • CodingGroup/gitlab-ee
  • smhoekstra/gitlab-ee
  • zeih/gitlab-ee
  • biancaghiurutan/gitlab-ee
  • bstrong/gitlab-ee
  • nap/gitlab-ee
  • mollybeth/gitlab-ee
  • Jeismeier/gitlab-ee
  • bouland/gitlab-ee
  • poneytruand/gitlab-ee
  • robotmay/gitlab
380 results
Show changes
Commits on Source (9)
Showing
with 182 additions and 52 deletions
Please view this file on the master branch, on stable branches it's out of date. Please view this file on the master branch, on stable branches it's out of date.
   
## 9.2.2 (2017-05-25)
- No changes.
## 9.2.1 (2017-05-23) ## 9.2.1 (2017-05-23)
   
- No changes. - No changes.
Loading
Loading
Loading
@@ -2,6 +2,11 @@
Loading
@@ -2,6 +2,11 @@
documentation](doc/development/changelog.md) for instructions on adding your own documentation](doc/development/changelog.md) for instructions on adding your own
entry. entry.
   
## 9.2.2 (2017-05-25)
- Fix issue where real time pipelines were not cached. !11615
- Make all notes use equal padding.
## 9.2.1 (2017-05-23) ## 9.2.1 (2017-05-23)
   
- Fix placement of note emoji on hover. - Fix placement of note emoji on hover.
Loading
Loading
Loading
@@ -10,4 +10,4 @@ import './filtered_search_tokenizer';
Loading
@@ -10,4 +10,4 @@ import './filtered_search_tokenizer';
import './filtered_search_visual_tokens'; import './filtered_search_visual_tokens';
   
// EE-only // EE-only
import './filtered_search_token_keys_with_weights'; import './filtered_search_token_keys_issues_ee';
Loading
@@ -11,7 +11,7 @@ class FilteredSearchDropdownManager {
Loading
@@ -11,7 +11,7 @@ class FilteredSearchDropdownManager {
this.page = page; this.page = page;
   
if (this.page === 'issues' || this.page === 'boards') { if (this.page === 'issues' || this.page === 'boards') {
this.filteredSearchTokenKeys = gl.FilteredSearchTokenKeysWithWeights; this.filteredSearchTokenKeys = gl.FilteredSearchTokenKeysIssuesEE;
} }
   
this.setupMapping(); this.setupMapping();
Loading
Loading
Loading
@@ -14,7 +14,7 @@ class FilteredSearchManager {
Loading
@@ -14,7 +14,7 @@ class FilteredSearchManager {
this.filteredSearchTokenKeys = gl.FilteredSearchTokenKeys; this.filteredSearchTokenKeys = gl.FilteredSearchTokenKeys;
   
if (page === 'issues' || page === 'boards') { if (page === 'issues' || page === 'boards') {
this.filteredSearchTokenKeys = gl.FilteredSearchTokenKeysWithWeights; this.filteredSearchTokenKeys = gl.FilteredSearchTokenKeysIssuesEE;
} }
   
this.recentSearchesStore = new RecentSearchesStore({ this.recentSearchesStore = new RecentSearchesStore({
Loading
Loading
Loading
@@ -18,15 +18,20 @@ const weightConditions = [{
Loading
@@ -18,15 +18,20 @@ const weightConditions = [{
value: 'any', value: 'any',
}]; }];
   
class FilteredSearchTokenKeysWithWeights extends gl.FilteredSearchTokenKeys { class FilteredSearchTokenKeysIssuesEE extends gl.FilteredSearchTokenKeys {
static get() { static get() {
const tokenKeys = Array.from(super.get()); const tokenKeys = Array.from(super.get());
// Enable multiple assignees
const assigneeTokenKey = tokenKeys.find(tk => tk.key === 'assignee');
assigneeTokenKey.type = 'array';
tokenKeys.push(weightTokenKey); tokenKeys.push(weightTokenKey);
return tokenKeys; return tokenKeys;
} }
   
static getKeys() { static getKeys() {
const tokenKeys = FilteredSearchTokenKeysWithWeights.get(); const tokenKeys = FilteredSearchTokenKeysIssuesEE.get();
return tokenKeys.map(i => i.key); return tokenKeys.map(i => i.key);
} }
   
Loading
@@ -40,18 +45,18 @@ class FilteredSearchTokenKeysWithWeights extends gl.FilteredSearchTokenKeys {
Loading
@@ -40,18 +45,18 @@ class FilteredSearchTokenKeysWithWeights extends gl.FilteredSearchTokenKeys {
} }
   
static searchByKey(key) { static searchByKey(key) {
const tokenKeys = FilteredSearchTokenKeysWithWeights.get(); const tokenKeys = FilteredSearchTokenKeysIssuesEE.get();
return tokenKeys.find(tokenKey => tokenKey.key === key) || null; return tokenKeys.find(tokenKey => tokenKey.key === key) || null;
} }
   
static searchBySymbol(symbol) { static searchBySymbol(symbol) {
const tokenKeys = FilteredSearchTokenKeysWithWeights.get(); const tokenKeys = FilteredSearchTokenKeysIssuesEE.get();
return tokenKeys.find(tokenKey => tokenKey.symbol === symbol) || null; return tokenKeys.find(tokenKey => tokenKey.symbol === symbol) || null;
} }
   
static searchByKeyParam(keyParam) { static searchByKeyParam(keyParam) {
const tokenKeys = FilteredSearchTokenKeysWithWeights.get(); const tokenKeys = FilteredSearchTokenKeysIssuesEE.get();
const alternativeTokenKeys = FilteredSearchTokenKeysWithWeights.getAlternatives(); const alternativeTokenKeys = FilteredSearchTokenKeysIssuesEE.getAlternatives();
const tokenKeysWithAlternative = tokenKeys.concat(alternativeTokenKeys); const tokenKeysWithAlternative = tokenKeys.concat(alternativeTokenKeys);
   
return tokenKeysWithAlternative.find((tokenKey) => { return tokenKeysWithAlternative.find((tokenKey) => {
Loading
@@ -66,16 +71,16 @@ class FilteredSearchTokenKeysWithWeights extends gl.FilteredSearchTokenKeys {
Loading
@@ -66,16 +71,16 @@ class FilteredSearchTokenKeysWithWeights extends gl.FilteredSearchTokenKeys {
} }
   
static searchByConditionUrl(url) { static searchByConditionUrl(url) {
const conditions = FilteredSearchTokenKeysWithWeights.getConditions(); const conditions = FilteredSearchTokenKeysIssuesEE.getConditions();
return conditions.find(condition => condition.url === url) || null; return conditions.find(condition => condition.url === url) || null;
} }
   
static searchByConditionKeyValue(key, value) { static searchByConditionKeyValue(key, value) {
const conditions = FilteredSearchTokenKeysWithWeights.getConditions(); const conditions = FilteredSearchTokenKeysIssuesEE.getConditions();
return conditions return conditions
.find(condition => condition.tokenKey === key && condition.value === value) || null; .find(condition => condition.tokenKey === key && condition.value === value) || null;
} }
} }
   
window.gl = window.gl || {}; window.gl = window.gl || {};
gl.FilteredSearchTokenKeysWithWeights = FilteredSearchTokenKeysWithWeights; gl.FilteredSearchTokenKeysIssuesEE = FilteredSearchTokenKeysIssuesEE;
Loading
@@ -573,3 +573,12 @@ $filter-value-selected-color: #d7d7d7;
Loading
@@ -573,3 +573,12 @@ $filter-value-selected-color: #d7d7d7;
Animation Functions Animation Functions
*/ */
$dropdown-animation-timing: cubic-bezier(0.23, 1, 0.32, 1); $dropdown-animation-timing: cubic-bezier(0.23, 1, 0.32, 1);
/*
GitLab Plans
*/
$gl-gold-plan: #d4af37;
$gl-silver-plan: #91a1ab;
$gl-bronze-plan: #cd7f32;
$gl-no-plan: $gl-gray-light;
Loading
@@ -159,3 +159,38 @@ table.pipeline-project-metrics tr td {
Loading
@@ -159,3 +159,38 @@ table.pipeline-project-metrics tr td {
height: 50px; height: 50px;
} }
} }
.plan-badge {
margin-right: 15px;
svg {
position: relative;
top: 3px;
height: 16px;
width: 16px;
}
&.inline {
display: inline-block;
margin: 0 4px;
}
&[data-plan="gold"] {
color: darken($gl-gold-plan, 20%);
svg g { fill: $gl-gold-plan; }
}
&[data-plan="silver"] {
color: darken($gl-silver-plan, 20%);
svg g { fill: $gl-silver-plan; }
}
&[data-plan="bronze"] {
color: darken($gl-bronze-plan, 20%);
svg g { fill: $gl-bronze-plan; }
}
&:not([data-plan]) {
svg g { fill: $gl-no-plan; }
}
}
Loading
@@ -490,6 +490,7 @@ def wip_title
Loading
@@ -490,6 +490,7 @@ def wip_title
end end
   
def mergeable?(skip_ci_check: false) def mergeable?(skip_ci_check: false)
return false unless approved?
return false unless mergeable_state?(skip_ci_check: skip_ci_check) return false unless mergeable_state?(skip_ci_check: skip_ci_check)
   
check_if_can_be_merged check_if_can_be_merged
Loading
Loading
- namespace = local_assigns[:namespace]
- if current_application_settings.should_check_namespace_plan? && namespace && namespace.plan.present?
%span.plan-badge.has-tooltip{ data: { plan: namespace.plan }, title: "#{namespace.plan.titleize} Plan" }
= custom_icon('icon_premium')
- namespace = local_assigns[:namespace]
- if current_application_settings.should_check_namespace_plan? && namespace
%li
%span.light Plan:
- if namespace.plan.present?
%strong.plan-badge.inline{ data: { plan: namespace.plan } }
= custom_icon('icon_premium')
= namespace.plan.titleize
- else
%strong.plan-badge.inline
= custom_icon('icon_premium')
No Plan
Loading
@@ -8,6 +8,8 @@
Loading
@@ -8,6 +8,8 @@
%span.badge %span.badge
= storage_counter(group.storage_size) = storage_counter(group.storage_size)
   
= render 'admin/namespace_plan_badge', namespace: group
%span %span
= icon('bookmark') = icon('bookmark')
= number_with_delimiter(group.projects.count) = number_with_delimiter(group.projects.count)
Loading
Loading
Loading
@@ -38,6 +38,8 @@
Loading
@@ -38,6 +38,8 @@
%strong %strong
= @group.created_at.to_s(:medium) = @group.created_at.to_s(:medium)
   
= render 'admin/namespace_plan_info', namespace: @group
%li %li
%span.light Storage: %span.light Storage:
%strong= storage_counter(@group.storage_size) %strong= storage_counter(@group.storage_size)
Loading
Loading
Loading
@@ -42,6 +42,12 @@
Loading
@@ -42,6 +42,12 @@
   
= render partial: 'access_levels', locals: { f: f } = render partial: 'access_levels', locals: { f: f }
   
- if current_application_settings.should_check_namespace_plan?
= f.fields_for :namespace do |namespace_form|
%fieldset
%legend Licensed Features
= render 'admin/namespace_plan', f: namespace_form
= render partial: 'limits', locals: { f: f } = render partial: 'limits', locals: { f: f }
   
%fieldset %fieldset
Loading
@@ -70,12 +76,6 @@
Loading
@@ -70,12 +76,6 @@
= f.label :note, 'Note', class: 'control-label' = f.label :note, 'Note', class: 'control-label'
.col-sm-10= f.text_area :note, class: 'form-control' .col-sm-10= f.text_area :note, class: 'form-control'
   
- if current_application_settings.should_check_namespace_plan?
= f.fields_for :namespace do |namespace_form|
%fieldset
%legend Plan
= render 'admin/namespace_plan', f: namespace_form
.form-actions .form-actions
- if @user.new_record? - if @user.new_record?
= f.submit 'Create user', class: "btn btn-create" = f.submit 'Create user', class: "btn btn-create"
Loading
Loading
Loading
@@ -18,6 +18,9 @@
Loading
@@ -18,6 +18,9 @@
.row-second-line.str-truncated-100 .row-second-line.str-truncated-100
= mail_to user.email, user.email = mail_to user.email, user.email
.controls .controls
= render 'admin/namespace_plan_badge', namespace: user.namespace
= link_to 'Edit', edit_admin_user_path(user), id: "edit_#{dom_id(user)}", class: 'btn' = link_to 'Edit', edit_admin_user_path(user), id: "edit_#{dom_id(user)}", class: 'btn'
- unless user == current_user - unless user == current_user
.dropdown.inline .dropdown.inline
Loading
Loading
Loading
@@ -47,6 +47,8 @@
Loading
@@ -47,6 +47,8 @@
- else - else
Disabled Disabled
   
= render 'admin/namespace_plan_info', namespace: @user.namespace
%li %li
%span.light External User: %span.light External User:
%strong %strong
Loading
Loading
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><g fill="#262626" fill-rule="evenodd"><path d="m8 10c-2.761 0-5-2.239-5-5 0-2.761 2.239-5 5-5 2.761 0 5 2.239 5 5 0 2.761-2.239 5-5 5m0-2.5c1.381 0 2.5-1.119 2.5-2.5 0-1.381-1.119-2.5-2.5-2.5-1.381 0-2.5 1.119-2.5 2.5 0 1.381 1.119 2.5 2.5 2.5m0-1c-.828 0-1.5-.672-1.5-1.5 0-.828.672-1.5 1.5-1.5.828 0 1.5.672 1.5 1.5 0 .828-.672 1.5-1.5 1.5m4.893 1.974l2.321 4.02c.138.239.028.447-.245.463l-1.737.104-.959 1.452c-.151.229-.389.214-.524-.019l-2.143-3.712c1.344-.373 2.498-1.201 3.286-2.308m-6.444 2.324l-2.135 3.697c-.135.234-.373.248-.524.019l-.959-1.452-1.737-.104c-.273-.016-.383-.224-.245-.463l2.293-3.971c.798 1.098 1.958 1.914 3.306 2.274" transform="translate(0 1)"/></g></svg>
\ No newline at end of file
---
title: Check if a merge request is approved when merging from API or slash command
merge_request:
author:
import '~/extensions/array'; import '~/extensions/array';
import '~/filtered_search/filtered_search_token_keys_with_weights'; import '~/filtered_search/filtered_search_token_keys_issues_ee';
   
(() => { (() => {
describe('Filtered Search Token Keys With Weights', () => { describe('Filtered Search Token Keys (Issues EE)', () => {
const weightTokenKey = { const weightTokenKey = {
key: 'weight', key: 'weight',
type: 'string', type: 'string',
Loading
@@ -15,7 +15,7 @@ import '~/filtered_search/filtered_search_token_keys_with_weights';
Loading
@@ -15,7 +15,7 @@ import '~/filtered_search/filtered_search_token_keys_with_weights';
let tokenKeys; let tokenKeys;
   
beforeEach(() => { beforeEach(() => {
tokenKeys = gl.FilteredSearchTokenKeysWithWeights.get(); tokenKeys = gl.FilteredSearchTokenKeysIssuesEE.get();
}); });
   
it('should return tokenKeys', () => { it('should return tokenKeys', () => {
Loading
@@ -32,16 +32,21 @@ import '~/filtered_search/filtered_search_token_keys_with_weights';
Loading
@@ -32,16 +32,21 @@ import '~/filtered_search/filtered_search_token_keys_with_weights';
}); });
   
it('should always return the same array', () => { it('should always return the same array', () => {
const tokenKeys2 = gl.FilteredSearchTokenKeysWithWeights.get(); const tokenKeys2 = gl.FilteredSearchTokenKeysIssuesEE.get();
   
expect(tokenKeys).toEqual(tokenKeys2); expect(tokenKeys).toEqual(tokenKeys2);
}); });
it('should return assignee as an array', () => {
const assignee = tokenKeys.find(tokenKey => tokenKey.key === 'assignee');
expect(assignee.type).toEqual('array');
});
}); });
   
describe('getKeys', () => { describe('getKeys', () => {
it('should return keys', () => { it('should return keys', () => {
const getKeys = gl.FilteredSearchTokenKeysWithWeights.getKeys(); const getKeys = gl.FilteredSearchTokenKeysIssuesEE.getKeys();
const keys = gl.FilteredSearchTokenKeysWithWeights.get().map(i => i.key); const keys = gl.FilteredSearchTokenKeysIssuesEE.get().map(i => i.key);
   
keys.forEach((key, i) => { keys.forEach((key, i) => {
expect(key).toEqual(getKeys[i]); expect(key).toEqual(getKeys[i]);
Loading
@@ -53,7 +58,7 @@ import '~/filtered_search/filtered_search_token_keys_with_weights';
Loading
@@ -53,7 +58,7 @@ import '~/filtered_search/filtered_search_token_keys_with_weights';
let conditions; let conditions;
   
beforeEach(() => { beforeEach(() => {
conditions = gl.FilteredSearchTokenKeysWithWeights.getConditions(); conditions = gl.FilteredSearchTokenKeysIssuesEE.getConditions();
}); });
   
it('should return conditions', () => { it('should return conditions', () => {
Loading
@@ -72,89 +77,89 @@ import '~/filtered_search/filtered_search_token_keys_with_weights';
Loading
@@ -72,89 +77,89 @@ import '~/filtered_search/filtered_search_token_keys_with_weights';
   
describe('searchByKey', () => { describe('searchByKey', () => {
it('should return null when key not found', () => { it('should return null when key not found', () => {
const tokenKey = gl.FilteredSearchTokenKeysWithWeights.searchByKey('notakey'); const tokenKey = gl.FilteredSearchTokenKeysIssuesEE.searchByKey('notakey');
expect(tokenKey === null).toBe(true); expect(tokenKey === null).toBe(true);
}); });
   
it('should return tokenKey when found by key', () => { it('should return tokenKey when found by key', () => {
const tokenKeys = gl.FilteredSearchTokenKeysWithWeights.get(); const tokenKeys = gl.FilteredSearchTokenKeysIssuesEE.get();
const result = gl.FilteredSearchTokenKeysWithWeights.searchByKey(tokenKeys[0].key); const result = gl.FilteredSearchTokenKeysIssuesEE.searchByKey(tokenKeys[0].key);
expect(result).toEqual(tokenKeys[0]); expect(result).toEqual(tokenKeys[0]);
}); });
   
it('should return weight tokenKey when found by weight key', () => { it('should return weight tokenKey when found by weight key', () => {
const tokenKeys = gl.FilteredSearchTokenKeysWithWeights.get(); const tokenKeys = gl.FilteredSearchTokenKeysIssuesEE.get();
const match = tokenKeys.find(tk => tk.key === weightTokenKey.key); const match = tokenKeys.find(tk => tk.key === weightTokenKey.key);
const result = gl.FilteredSearchTokenKeysWithWeights.searchByKey(weightTokenKey.key); const result = gl.FilteredSearchTokenKeysIssuesEE.searchByKey(weightTokenKey.key);
expect(result).toEqual(match); expect(result).toEqual(match);
}); });
}); });
   
describe('searchBySymbol', () => { describe('searchBySymbol', () => {
it('should return null when symbol not found', () => { it('should return null when symbol not found', () => {
const tokenKey = gl.FilteredSearchTokenKeysWithWeights.searchBySymbol('notasymbol'); const tokenKey = gl.FilteredSearchTokenKeysIssuesEE.searchBySymbol('notasymbol');
expect(tokenKey === null).toBe(true); expect(tokenKey === null).toBe(true);
}); });
   
it('should return tokenKey when found by symbol', () => { it('should return tokenKey when found by symbol', () => {
const tokenKeys = gl.FilteredSearchTokenKeysWithWeights.get(); const tokenKeys = gl.FilteredSearchTokenKeysIssuesEE.get();
const result = gl.FilteredSearchTokenKeysWithWeights.searchBySymbol(tokenKeys[0].symbol); const result = gl.FilteredSearchTokenKeysIssuesEE.searchBySymbol(tokenKeys[0].symbol);
expect(result).toEqual(tokenKeys[0]); expect(result).toEqual(tokenKeys[0]);
}); });
   
it('should return weight tokenKey when found by weight symbol', () => { it('should return weight tokenKey when found by weight symbol', () => {
const tokenKeys = gl.FilteredSearchTokenKeysWithWeights.get(); const tokenKeys = gl.FilteredSearchTokenKeysIssuesEE.get();
const match = tokenKeys.find(tk => tk.key === weightTokenKey.key); const match = tokenKeys.find(tk => tk.key === weightTokenKey.key);
const result = gl.FilteredSearchTokenKeysWithWeights.searchBySymbol(weightTokenKey.symbol); const result = gl.FilteredSearchTokenKeysIssuesEE.searchBySymbol(weightTokenKey.symbol);
expect(result).toEqual(match); expect(result).toEqual(match);
}); });
}); });
   
describe('searchByKeyParam', () => { describe('searchByKeyParam', () => {
it('should return null when key param not found', () => { it('should return null when key param not found', () => {
const tokenKey = gl.FilteredSearchTokenKeysWithWeights.searchByKeyParam('notakeyparam'); const tokenKey = gl.FilteredSearchTokenKeysIssuesEE.searchByKeyParam('notakeyparam');
expect(tokenKey === null).toBe(true); expect(tokenKey === null).toBe(true);
}); });
   
it('should return tokenKey when found by key param', () => { it('should return tokenKey when found by key param', () => {
const tokenKeys = gl.FilteredSearchTokenKeysWithWeights.get(); const tokenKeys = gl.FilteredSearchTokenKeysIssuesEE.get();
const result = gl.FilteredSearchTokenKeysWithWeights const result = gl.FilteredSearchTokenKeysIssuesEE
.searchByKeyParam(`${tokenKeys[0].key}_${tokenKeys[0].param}`); .searchByKeyParam(`${tokenKeys[0].key}_${tokenKeys[0].param}`);
expect(result).toEqual(tokenKeys[0]); expect(result).toEqual(tokenKeys[0]);
}); });
   
it('should return alternative tokenKey when found by key param', () => { it('should return alternative tokenKey when found by key param', () => {
const tokenKeys = gl.FilteredSearchTokenKeysWithWeights.getAlternatives(); const tokenKeys = gl.FilteredSearchTokenKeysIssuesEE.getAlternatives();
const result = gl.FilteredSearchTokenKeysWithWeights const result = gl.FilteredSearchTokenKeysIssuesEE
.searchByKeyParam(`${tokenKeys[0].key}_${tokenKeys[0].param}`); .searchByKeyParam(`${tokenKeys[0].key}_${tokenKeys[0].param}`);
expect(result).toEqual(tokenKeys[0]); expect(result).toEqual(tokenKeys[0]);
}); });
   
it('should return weight tokenKey when found by weight key param', () => { it('should return weight tokenKey when found by weight key param', () => {
const tokenKeys = gl.FilteredSearchTokenKeysWithWeights.get(); const tokenKeys = gl.FilteredSearchTokenKeysIssuesEE.get();
const match = tokenKeys.find(tk => tk.key === weightTokenKey.key); const match = tokenKeys.find(tk => tk.key === weightTokenKey.key);
const result = gl.FilteredSearchTokenKeysWithWeights.searchByKeyParam(weightTokenKey.key); const result = gl.FilteredSearchTokenKeysIssuesEE.searchByKeyParam(weightTokenKey.key);
expect(result).toEqual(match); expect(result).toEqual(match);
}); });
}); });
   
describe('searchByConditionUrl', () => { describe('searchByConditionUrl', () => {
it('should return null when condition url not found', () => { it('should return null when condition url not found', () => {
const condition = gl.FilteredSearchTokenKeysWithWeights.searchByConditionUrl(null); const condition = gl.FilteredSearchTokenKeysIssuesEE.searchByConditionUrl(null);
expect(condition === null).toBe(true); expect(condition === null).toBe(true);
}); });
   
it('should return condition when found by url', () => { it('should return condition when found by url', () => {
const conditions = gl.FilteredSearchTokenKeysWithWeights.getConditions(); const conditions = gl.FilteredSearchTokenKeysIssuesEE.getConditions();
const result = gl.FilteredSearchTokenKeysWithWeights const result = gl.FilteredSearchTokenKeysIssuesEE
.searchByConditionUrl(conditions[0].url); .searchByConditionUrl(conditions[0].url);
expect(result).toBe(conditions[0]); expect(result).toBe(conditions[0]);
}); });
   
it('should return weight condition when found by weight url', () => { it('should return weight condition when found by weight url', () => {
const conditions = gl.FilteredSearchTokenKeysWithWeights.getConditions(); const conditions = gl.FilteredSearchTokenKeysIssuesEE.getConditions();
const weightConditions = conditions.filter(c => c.tokenKey === 'weight'); const weightConditions = conditions.filter(c => c.tokenKey === 'weight');
const result = gl.FilteredSearchTokenKeysWithWeights const result = gl.FilteredSearchTokenKeysIssuesEE
.searchByConditionUrl(weightConditions[0].url); .searchByConditionUrl(weightConditions[0].url);
expect(result).toBe(weightConditions[0]); expect(result).toBe(weightConditions[0]);
}); });
Loading
@@ -162,22 +167,22 @@ import '~/filtered_search/filtered_search_token_keys_with_weights';
Loading
@@ -162,22 +167,22 @@ import '~/filtered_search/filtered_search_token_keys_with_weights';
   
describe('searchByConditionKeyValue', () => { describe('searchByConditionKeyValue', () => {
it('should return null when condition tokenKey and value not found', () => { it('should return null when condition tokenKey and value not found', () => {
const condition = gl.FilteredSearchTokenKeysWithWeights const condition = gl.FilteredSearchTokenKeysIssuesEE
.searchByConditionKeyValue(null, null); .searchByConditionKeyValue(null, null);
expect(condition === null).toBe(true); expect(condition === null).toBe(true);
}); });
   
it('should return condition when found by tokenKey and value', () => { it('should return condition when found by tokenKey and value', () => {
const conditions = gl.FilteredSearchTokenKeysWithWeights.getConditions(); const conditions = gl.FilteredSearchTokenKeysIssuesEE.getConditions();
const result = gl.FilteredSearchTokenKeysWithWeights const result = gl.FilteredSearchTokenKeysIssuesEE
.searchByConditionKeyValue(conditions[0].tokenKey, conditions[0].value); .searchByConditionKeyValue(conditions[0].tokenKey, conditions[0].value);
expect(result).toEqual(conditions[0]); expect(result).toEqual(conditions[0]);
}); });
   
it('should return weight condition when found by weight tokenKey and value', () => { it('should return weight condition when found by weight tokenKey and value', () => {
const conditions = gl.FilteredSearchTokenKeysWithWeights.getConditions(); const conditions = gl.FilteredSearchTokenKeysIssuesEE.getConditions();
const weightConditions = conditions.filter(c => c.tokenKey === 'weight'); const weightConditions = conditions.filter(c => c.tokenKey === 'weight');
const result = gl.FilteredSearchTokenKeysWithWeights const result = gl.FilteredSearchTokenKeysIssuesEE
.searchByConditionKeyValue(weightConditions[0].tokenKey, weightConditions[0].value); .searchByConditionKeyValue(weightConditions[0].tokenKey, weightConditions[0].value);
expect(result).toEqual(weightConditions[0]); expect(result).toEqual(weightConditions[0]);
}); });
Loading
Loading
Loading
@@ -1187,6 +1187,26 @@ def set_compare(merge_request)
Loading
@@ -1187,6 +1187,26 @@ def set_compare(merge_request)
   
expect(subject.mergeable?).to be_truthy expect(subject.mergeable?).to be_truthy
end end
context 'when using approvals' do
let(:user) { create(:user) }
before do
allow(subject).to receive(:mergeable_state?).and_return(true)
subject.target_project.update_attributes(approvals_before_merge: 1)
project.team << [user, :developer]
end
it 'return false if not approved' do
expect(subject.mergeable?).to be_falsey
end
it 'return true if approved' do
subject.approvals.create(user: user)
expect(subject.mergeable?).to be_truthy
end
end
end end
   
describe '#mergeable_state?' do describe '#mergeable_state?' do
Loading
@@ -1956,6 +1976,22 @@ def create_pipeline(status)
Loading
@@ -1956,6 +1976,22 @@ def create_pipeline(status)
expect(merge_request.mergeable_with_slash_command?(developer, last_diff_sha: mr_sha)).to be_truthy expect(merge_request.mergeable_with_slash_command?(developer, last_diff_sha: mr_sha)).to be_truthy
end end
end end
context 'with approvals' do
before do
merge_request.target_project.update_attributes(approvals_before_merge: 1)
end
it 'is not mergeable when not approved' do
expect(merge_request.mergeable_with_slash_command?(developer, last_diff_sha: mr_sha)).to be_falsey
end
it 'is mergeable when approved' do
merge_request.approvals.create(user: user)
expect(merge_request.mergeable_with_slash_command?(developer, last_diff_sha: mr_sha)).to be_truthy
end
end
end end
end end
   
Loading
Loading