Index: trip-planner-front/src/app/planner/edit-planner/edit-planner.component.html
===================================================================
--- trip-planner-front/src/app/planner/edit-planner/edit-planner.component.html	(revision e29cc2ea91f8c99a4329f6d20188305dfd752279)
+++ trip-planner-front/src/app/planner/edit-planner/edit-planner.component.html	(revision 1ad8e64a349fcc7c996155279b16efc2cfe001dd)
@@ -43,6 +43,4 @@
     </div>
     <button pButton pRipplelabel label="Save" class="p-button-help"></button>
-    <button pButton pRipple label="Back" class="p-button-info" (click)="onClickBack()" [style]="{'margin-left': '.5em'}"></button>
-
 </form>
-
+<button pButton pRipple label="Back" class="p-button-info" (click)="onClickBack()" [style]="{'margin-left': '.11em'}"></button>
Index: trip-planner-front/src/app/planner/edit-planner/edit-planner.component.ts
===================================================================
--- trip-planner-front/src/app/planner/edit-planner/edit-planner.component.ts	(revision e29cc2ea91f8c99a4329f6d20188305dfd752279)
+++ trip-planner-front/src/app/planner/edit-planner/edit-planner.component.ts	(revision 1ad8e64a349fcc7c996155279b16efc2cfe001dd)
@@ -78,5 +78,4 @@
 
   onClickBack(){
-    console.log("promena");
     this.router.navigate(['planners']);
   }
Index: trip-planner-front/src/app/planner/planner.component.html
===================================================================
--- trip-planner-front/src/app/planner/planner.component.html	(revision e29cc2ea91f8c99a4329f6d20188305dfd752279)
+++ trip-planner-front/src/app/planner/planner.component.html	(revision 1ad8e64a349fcc7c996155279b16efc2cfe001dd)
@@ -1,5 +1,5 @@
 <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.1/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-+0n0xVW2eSR5OomGNYDnhzAbDsOXxcvSN1TPprVMTNDbiYZCxYbOOl7+AMvyTG2x" crossorigin="anonymous">
 
-
+<p-toast></p-toast>
 <button pButton pRipple type="button" label="Create initial planner" class="p-button-help " (click)="show()"></button>
 <br>
Index: trip-planner-front/src/app/planner/planner.component.ts
===================================================================
--- trip-planner-front/src/app/planner/planner.component.ts	(revision e29cc2ea91f8c99a4329f6d20188305dfd752279)
+++ trip-planner-front/src/app/planner/planner.component.ts	(revision 1ad8e64a349fcc7c996155279b16efc2cfe001dd)
@@ -5,7 +5,6 @@
 import { Router } from '@angular/router';
 import { PlannerDto } from '../_models/dto/plannerDto';
-import { FormBuilder, FormGroup, Validators } from '@angular/forms';
 import { DialogService, DynamicDialogRef } from 'primeng/dynamicdialog';
-import { PrimeNGConfig } from 'primeng/api';
+import { MessageService, PrimeNGConfig } from 'primeng/api';
 
 
@@ -13,5 +12,6 @@
   selector: 'app-planner',
   templateUrl: './planner.component.html',
-  styleUrls: ['./planner.component.css']
+  styleUrls: ['./planner.component.css'],
+  providers: [DialogService, MessageService]
 })
 export class PlannerComponent implements OnInit {
@@ -19,16 +19,12 @@
   planners: Planner[];
   plannerDto: PlannerDto;
-  editForm: FormGroup;
   ref: DynamicDialogRef;
 
 
   constructor(private plannerService: PlannerService, private router: Router,
-    private fb: FormBuilder, private dialogService: DialogService, private primengConfig: PrimeNGConfig) {
+    private dialogService: DialogService, private primengConfig: PrimeNGConfig, private messageService: MessageService) {
     this.planners = [];
     this.plannerDto = new PlannerDto();
-    this.editForm = fb.group({
-      title: fb.control('initial value', Validators.required)
-    });
-    this.ref = new DynamicDialogRef;   
+    this.ref = new DynamicDialogRef;
   }
 
@@ -51,6 +47,6 @@
       }
     );
+  }
 
-  }
   show() {
     this.ref = this.dialogService.open(CreateInitialPlannerComponent, {
@@ -60,4 +56,16 @@
       baseZIndex: 10000
     });
+    this.ref.onClose.subscribe((planner: Planner) => {
+      console.log("NOVOKREIRANIOT NAME NA PLANNER: " + planner.name);
+      this.plannerService.postInitialPlanner(planner).subscribe(
+        data=>{
+          console.log(data);
+        },
+        error => console.log('oops', error)
+     );
+      this.messageService.add({ severity: 'success', summary: 'The planner: ' + planner.name + ' has been created.' });
+    });
+    
   }
+
 }
