Adding changes in vertical stepper 53/78753/1
authorSwapnali Shadanan Pode <sp00501638@techmahindra.com>
Tue, 19 Feb 2019 13:03:31 +0000 (18:33 +0530)
committerSwapnali Shadanan Pode <sp00501638@techmahindra.com>
Tue, 19 Feb 2019 13:03:31 +0000 (18:33 +0530)
Adding existing template in vertical stepper

Change-Id: Ic016eb7032ba8de67885b6375e225a1fb98c92eb
Issue-ID: CCSDK-804
Signed-off-by: sp00501638 <sp00501638@techmahindra.com>
cds-ui/client/src/app/feature-modules/resource-definition/resource-creation/resource-creation.component.html
cds-ui/client/src/app/feature-modules/resource-definition/resource-creation/resource-creation.component.scss
cds-ui/client/src/app/feature-modules/resource-definition/resource-creation/resource-creation.component.ts
cds-ui/client/src/app/feature-modules/resource-definition/resource-creation/resource-creation.module.ts

index dad727c..83c9ae2 100644 (file)
 * ============LICENSE_END=========================================================
 */-->
 
+<mat-card class="ver-card">
+<mat-card-header>
+</mat-card-header>
+<mat-card-content>
 <mat-vertical-stepper linear>
-  <mat-step >
+  <mat-step [stepControl]="step1FormGroup">
     <ng-template matStepLabel>Choose Resource file</ng-template>
     <br>
-    <app-resource-template-options></app-resource-template-options>
+    <app-resource-template-options (options)="selectedOption($event)"></app-resource-template-options>
     <br>
     <div>
       <button mat-button matStepperNext class="matStepNextBtn">Proceed</button>
     </div>
   </mat-step>
-  <mat-step >
+  <mat-step [stepControl]="step2FormGroup">
     <ng-template matStepLabel>Browse Template file</ng-template>
-  <app-upload-resource (change)="fileChange(fileupload.files)"></app-upload-resource>
+  <app-upload-resource (change)="fileChange(fileupload.files)"></app-upload-resource><br><br>
+  <app-existing-model></app-existing-model>
     <div>
       <button mat-button matStepperNext class="matStepNextBtn">Upload</button>
     </div>
   </mat-step>
-</mat-vertical-stepper>
-
-<!-- <router-outlet></router-outlet> -->
\ No newline at end of file
+ </mat-vertical-stepper>
+ </mat-card-content>
+</mat-card>
\ No newline at end of file
index b1d0ac5..1d113d4 100644 (file)
     background:gray; 
     margin-top: 10px; 
     position: absolute;
+    
+}
+.ver-card {
+  width: 100%;  
+  background-color: #f1f1f1;
+   padding: 0.01em 16px;
+    margin: 20px 0;
+    box-shadow: 0 2px 2px 0 rgba(0,0,0,0.16),0 2px 10px 0 rgba(0,0,0,0.12)!important;
+    height: auto;
+}
+.mat-card-header{
+    height:35px;
+}
+.mat-card-content{
+    width: auto;
+    background-color: #fff;
+    padding: 8px 8px;
+    // border-left: 4px solid #4CAF50;
+    word-wrap: break-word;
+    min-height:350px;
+    height: auto;
 }
\ No newline at end of file
index 32dc380..bb8ceea 100644 (file)
@@ -30,10 +30,10 @@ import { Store } from '@ngrx/store';
 export class ResourceCreationComponent implements OnInit {
 
   myFile: File; /* property of File type */
-
+  selectedValue: any;
   constructor() {
   }
-    
+
   ngOnInit() {  
   }
     
@@ -41,8 +41,13 @@ export class ResourceCreationComponent implements OnInit {
     console.log(files);
     this.myFile = files[0].nativeElement;
   }
-    
   upload(){
     
   }
+
+  selectedOption(value){
+    this.selectedValue=value;
+    console.log(this.selectedValue);        
+}
 }
index e4fcf13..7003f4c 100644 (file)
@@ -24,22 +24,39 @@ import { CommonModule } from '@angular/common';
 import { ResourceCreationRoutingModule } from './resource-creation-routing.module';
 import { ResourceCreationComponent } from './resource-creation.component';
 import { ResourceTemplateOptionsComponent } from './resource-template-options/resource-template-options.component';
-import { MatToolbarModule,MatIconModule, MatButtonModule, MatSidenavModule,  MatCheckboxModule, MatListModule, MatGridListModule, MatCardModule, MatMenuModule, MatTableModule, MatPaginatorModule, MatSortModule, MatInputModule, MatSelectModule, MatRadioModule, MatFormFieldModule, MatStepperModule} from '@angular/material';
+import { MatAutocompleteModule,MatToolbarModule,MatIconModule, MatButtonModule, MatSidenavModule,  MatCheckboxModule, MatListModule, MatGridListModule, MatCardModule, MatMenuModule, MatTableModule, MatPaginatorModule, MatSortModule, MatInputModule, MatSelectModule, MatRadioModule, MatFormFieldModule, MatStepperModule} from '@angular/material';
 import { UploadResourceComponent } from './upload-resource/upload-resource.component';
+import { NewTemplateComponent } from './new-template/new-template.component';
+import { ExistingModelComponent } from './existing-model/existing-model.component';
+import { SearchResourceComponent } from './existing-model/search-resource/search-resource.component';
+import { SharedModule } from '../../../../app/common/shared/shared.module';
+import { FormsModule,ReactiveFormsModule } from '@angular/forms';
 
 @NgModule({
-  declarations: [
+    
+ declarations: [
     ResourceCreationComponent,
     ResourceTemplateOptionsComponent,
-    UploadResourceComponent
+    UploadResourceComponent,
+    NewTemplateComponent,
+    ExistingModelComponent,
+    SearchResourceComponent,
+    
   ],
   exports: [
     ResourceCreationComponent,
     ResourceTemplateOptionsComponent,
-    UploadResourceComponent
+    UploadResourceComponent,
+    NewTemplateComponent,
+    ExistingModelComponent,
+    SearchResourceComponent,
+    SharedModule
   ],
   imports: [
     CommonModule,
+    SharedModule,
+    FormsModule,
+    ReactiveFormsModule,
     ResourceCreationRoutingModule,
     MatToolbarModule,
     MatIconModule, 
@@ -57,7 +74,8 @@ import { UploadResourceComponent } from './upload-resource/upload-resource.compo
     MatSelectModule, 
     MatRadioModule, 
     MatFormFieldModule, 
-    MatStepperModule
-  ]
+    MatStepperModule,
+    MatAutocompleteModule
+    ]
 })
 export class ResourceCreationModule { }