You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dlab.apache.org by an...@apache.org on 2019/08/13 12:20:13 UTC

[incubator-dlab] branch DLAB-934 created (now 6408ba2)

This is an automated email from the ASF dual-hosted git repository.

ankovalyshyn pushed a change to branch DLAB-934
in repository https://gitbox.apache.org/repos/asf/incubator-dlab.git.


      at 6408ba2  [DLAB-934]: extended group name validation on roles widget

This branch includes the following new commits:

     new 4741a61  [DLAB-991]: extra class for error messages
     new 6408ba2  [DLAB-934]: extended group name validation on roles widget

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@dlab.apache.org
For additional commands, e-mail: commits-help@dlab.apache.org


[incubator-dlab] 01/02: [DLAB-991]: extra class for error messages

Posted by an...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

ankovalyshyn pushed a commit to branch DLAB-934
in repository https://gitbox.apache.org/repos/asf/incubator-dlab.git

commit 4741a6104d3dc4c0ee6a788b4bd55f93a199e36d
Author: Andriana Kovalyshyn <An...@epam.com>
AuthorDate: Tue Aug 13 13:21:36 2019 +0200

    [DLAB-991]: extra class for error messages
---
 .../exploratory/create-environment/create-environment.component.html    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/services/self-service/src/main/resources/webapp/src/app/resources/exploratory/create-environment/create-environment.component.html b/services/self-service/src/main/resources/webapp/src/app/resources/exploratory/create-environment/create-environment.component.html
index 61dea30..94e0c29 100644
--- a/services/self-service/src/main/resources/webapp/src/app/resources/exploratory/create-environment/create-environment.component.html
+++ b/services/self-service/src/main/resources/webapp/src/app/resources/exploratory/create-environment/create-environment.component.html
@@ -135,7 +135,7 @@
           </div>
         </div>
 
-        <div class="control-group">
+        <div class="control-group m-bott-10">
           <label class="label">Custom tag</label>
           <div class="control">
             <input type="text" class="form-control" placeholder="Enter custom tag" formControlName="custom_tag">


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@dlab.apache.org
For additional commands, e-mail: commits-help@dlab.apache.org


[incubator-dlab] 02/02: [DLAB-934]: extended group name validation on roles widget

Posted by an...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

ankovalyshyn pushed a commit to branch DLAB-934
in repository https://gitbox.apache.org/repos/asf/incubator-dlab.git

commit 6408ba2a7fb1fec1b29ddcd94e383269e945c92b
Author: Andriana Kovalyshyn <An...@epam.com>
AuthorDate: Tue Aug 13 14:19:57 2019 +0200

    [DLAB-934]: extended group name validation on roles widget
---
 .../src/app/administration/roles/roles.component.html   | 17 +++++++++--------
 .../src/app/administration/roles/roles.component.ts     |  2 +-
 2 files changed, 10 insertions(+), 9 deletions(-)

diff --git a/services/self-service/src/main/resources/webapp/src/app/administration/roles/roles.component.html b/services/self-service/src/main/resources/webapp/src/app/administration/roles/roles.component.html
index fe499ae..fcba45d 100644
--- a/services/self-service/src/main/resources/webapp/src/app/administration/roles/roles.component.html
+++ b/services/self-service/src/main/resources/webapp/src/app/administration/roles/roles.component.html
@@ -28,15 +28,15 @@
   </div>
 
   <mat-card *ngIf="stepperView" class="m-top-10">
-    <mat-horizontal-stepper #stepper  class="stepper ani">
+    <mat-horizontal-stepper #stepper class="stepper ani">
       <mat-step>
         <ng-template matStepLabel>Groups</ng-template>
         <div class="inner-step mat-reset">
           <input [validator]="groupValidarion()" type="text" placeholder="Enter group name" [(ngModel)]="setupGroup"
             #setupGroupName="ngModel">
-          <div class="danger_color" *ngIf="setupGroupName.errors?.patterns && setupGroupName.dirty">Group name can only
+          <div class="error" *ngIf="setupGroupName.errors?.patterns && setupGroupName.dirty">Group name can only
             contain letters, numbers, hyphens and '_'</div>
-          <div class="danger_color" *ngIf="setupGroupName.errors?.duplicate && setupGroupName.dirty">Group name already
+          <div class="error" *ngIf="setupGroupName.errors?.duplicate && setupGroupName.dirty">Group name already
             exists</div>
         </div>
         <div class="text-center m-bott-10">
@@ -88,7 +88,7 @@
               class="material-icons">keyboard_arrow_left</i>Back</button>
           <button mat-raised-button (click)="resetDialog()" class="butt">Cancel</button>
           <button mat-raised-button (click)="manageAction('create', 'group')" class="butt butt-success"
-            [disabled]="!setupGroup || setupGroupName.errors?.pattern || !setupRoles.length > 0">Create</button>
+            [disabled]="!setupGroup || setupGroupName.errors?.patterns || setupGroupName.errors?.duplicate || !setupRoles.length > 0">Create</button>
         </div>
       </mat-step>
     </mat-horizontal-stepper>
@@ -107,8 +107,8 @@
         <td mat-cell *matCellDef="let element" class="roles mat-reset">
           <div class="selector-wrapper-edit">
             <mat-form-field>
-              <mat-select multiple [compareWith]="compareObjects" name="selected_roles" [(value)]="element.selected_roles"
-                placeholder="Select roles">
+              <mat-select multiple [compareWith]="compareObjects" name="selected_roles"
+                [(value)]="element.selected_roles" placeholder="Select roles">
                 <mat-option class="multiple-select" disabled>
                   <a class="select ani" (click)="selectAllOptions(element, rolesList, 'selected_roles')">
                     <i class="material-icons">playlist_add_check</i>&nbsp;All
@@ -157,8 +157,9 @@
             <mat-icon>delete_forever</mat-icon>
           </span>
           <span class="apply ani" matTooltip="Group cannot be updated without any selected role"
-                matTooltipPosition="above" [matTooltipDisabled]="element.selected_roles.length > 0"
-                [ngClass]="{ 'not-allowed' : !element.selected_roles.length }" (click)="manageAction('update', 'group', element)">
+            matTooltipPosition="above" [matTooltipDisabled]="element.selected_roles.length > 0"
+            [ngClass]="{ 'not-allowed' : !element.selected_roles.length }"
+            (click)="manageAction('update', 'group', element)">
             <mat-icon>done</mat-icon>
           </span>
         </td>
diff --git a/services/self-service/src/main/resources/webapp/src/app/administration/roles/roles.component.ts b/services/self-service/src/main/resources/webapp/src/app/administration/roles/roles.component.ts
index 2e94b25..95bd233 100644
--- a/services/self-service/src/main/resources/webapp/src/app/administration/roles/roles.component.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/administration/roles/roles.component.ts
@@ -176,7 +176,7 @@ export class RolesComponent implements OnInit {
   public groupValidarion(): ValidatorFn {
     const duplicateList: any = this.groupsData.map(item => item.group);
     return <ValidatorFn>((control: FormControl) => {
-      if (control.value && duplicateList.includes(CheckUtils.delimitersFiltering(control.value))) {
+      if (control.value && duplicateList.includes(CheckUtils.delimitersFiltering(control.value.trim()))) {
         return { duplicate: true };
       }
 


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@dlab.apache.org
For additional commands, e-mail: commits-help@dlab.apache.org