Skip to content
This repository has been archived by the owner on Jan 24, 2023. It is now read-only.

org/space: allowed quota to be specified on creation/edition #3593

Merged
merged 7 commits into from
Jun 3, 2019

Conversation

vitoravelino
Copy link
Contributor

Previously the org/space quotas weren't able to be selected during
the creation and edition of them. The user can now select which quota
definition they want.

Signed-off-by: Vítor Avelino vavelino@suse.com

Motivation and Context

There was no way to select the org/space quota during its creation/edition.

How Has This Been Tested?

A few e2e tests.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • Docs update
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

@cfdreddbot
Copy link

✅ Hey vitoravelino! The commit authors and yourself have already signed the CLA.

@codecov
Copy link

codecov bot commented May 16, 2019

Codecov Report

Merging #3593 into v2-master will decrease coverage by 0.16%.
The diff coverage is 28.88%.

@@              Coverage Diff              @@
##           v2-master    #3593      +/-   ##
=============================================
- Coverage      51.84%   51.68%   -0.17%     
=============================================
  Files            720      723       +3     
  Lines          20226    20381     +155     
  Branches        3613     3641      +28     
=============================================
+ Hits           10487    10533      +46     
- Misses          9739     9848     +109

@vitoravelino vitoravelino force-pushed the assign-quota-org-spaces branch 3 times, most recently from 8428c4a to 41a2c8e Compare May 17, 2019 20:12
Copy link
Contributor

@richard-cox richard-cox left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • It looks like the create org process will always assign a quota regardless of if one is specified, so the drop down should start with the first entry selected
  • If there are zero space quotas don't show the drop down in either case (not sure if this is possible for org but we should probably cover the case
  • There should be a blank option in the space quota drop down that will allow the user to return to the 'none selected' state after an initial change of selection
  • After creating a space with following error is shown
    core.js:15714 ERROR TypeError: Cannot read property 'length' of undefined
      at SpaceQuotaHelper._this.getOrgOrSpaceCardStatus (cloud-foundry-space-quota.ts:31)
      at MapSubscriber.project (cloud-foundry-org-space-quota.ts:54)
    
    I can't remember if this was a previous bug or not, but it looks like whatever space is passed in comes from an entity service's action that doesn't specify the space-route inline relationship
  • In the space summary page, when there's no space quota we take the quota limits from the org. This leads to us displaying the org quota name as the space quota. I'll fix this in this branch

@richard-cox richard-cox added needs attention This PR needs attention and removed in review labels May 21, 2019
Vítor Avelino and others added 3 commits May 27, 2019 07:09
Previously the org/space quotas weren't able to be selected during
the creation and edition of them. The user can now select which quota
definition they want.

Signed-off-by: Vítor Avelino <vavelino@suse.com>
A few enhancements were done like not showing the quota field if there's
no space quota and preselecting default/first org quota.

Signed-off-by: Vítor Avelino <vavelino@suse.com>
When navigating directly to create/update space an exception was being
thrown when the user was redirected to summary page.

Signed-off-by: Vítor Avelino <vavelino@suse.com>
Vítor Avelino and others added 3 commits May 28, 2019 18:19
Combined create and edit test cases into one file and removed previous
org/space manage tests.

Signed-off-by: Vítor Avelino <vavelino@suse.com>
@richard-cox richard-cox removed the needs attention This PR needs attention label Jun 3, 2019
Copy link
Contributor

@richard-cox richard-cox left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, will merge once passed gates

@richard-cox richard-cox merged commit a7d8af4 into v2-master Jun 3, 2019
@richard-cox richard-cox deleted the assign-quota-org-spaces branch June 3, 2019 11:57
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants