Ignore:
Timestamp:
12/19/21 19:39:00 (3 years ago)
Author:
Ema <ema_spirova@…>
Branches:
master
Children:
bdd6491
Parents:
1ad8e64
Message:

spring security 2.0

Location:
trip-planner-front/src/app/homepage/register
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trip-planner-front/src/app/homepage/register/register.component.html

    r1ad8e64 r84d0fbb  
    1 <div class="p-grid p-fluid">
    2     <div class="p-col-12 p-md-4">
    3         <div class="p-inputgroup">
    4             <span class="p-inputgroup-addon"><i class="pi pi-user"></i></span>
    5             <input type="text" pInputText placeholder="Full name">         
     1
     2    <div class="p-grid p-fluid">
     3        <div class="p-col-12 p-md-4">
     4            <div class="p-inputgroup">
     5                <span class="p-inputgroup-addon"><i class="pi pi-user"></i></span>
     6                <input type="text" pInputText placeholder="Full name" [(ngModel)]="user.fullName" name="fullName"
     7            >         
     8            </div>
    69        </div>
    7     </div>
    8 
    9     <div class="p-col-12 p-md-4">
    10         <div class="p-inputgroup">
    11             <span class="p-inputgroup-addon"><i class="pi pi-user"></i></span>
    12             <input type="text" pInputText placeholder="Ema address (Username)">         
     10   
     11        <div class="p-col-12 p-md-4">
     12            <div class="p-inputgroup">
     13                <span class="p-inputgroup-addon"><i class="pi pi-user"></i></span>
     14                <input type="text" pInputText placeholder="Email address (Username)" [(ngModel)]="user.username" name="username"
     15              >         
     16            </div>
    1317        </div>
    14     </div>
    15     <div class="p-col-12 p-md-4">
    16         <div class="p-inputgroup">
    17             <span class="p-inputgroup-addon"><i class="pi pi-password"></i></span>
    18             <input type="text" pInputText placeholder="Password">         
     18        <div class="p-col-12 p-md-4">
     19            <div class="p-inputgroup">
     20                <span class="p-inputgroup-addon"><i class="pi pi-password"></i></span>
     21                <input type="password" pInputText placeholder="Password" [(ngModel)]="user.password" name="password"
     22                >         
     23            </div>
    1924        </div>
    20     </div>
    21     <div class="p-col-12 p-md-4">
    22         <div class="p-inputgroup">
    23             <span class="p-inputgroup-addon"><i class="pi pi-password"></i></span>
    24             <input type="text" pInputText placeholder="Repeat password">         
     25        <div class="p-col-12 p-md-4">
     26            <div class="p-inputgroup">
     27                <span class="p-inputgroup-addon"><i class="pi pi-password"></i></span>
     28                <input type="password" pInputText placeholder="Repeat password" [(ngModel)]="user.confirmPassword" name="confirmPassword"
     29                >         
     30            </div>
    2531        </div>
    26     </div>
    27 
    28     <div class="p-col-12 p-md-4">
    29         <button pButton pRipple type="button" label="Submit" class="p-button-secondary"></button>
    30     </div>
    31 </div>
     32   
     33        <div class="p-col-12 p-md-4">
     34            <button pButton pRipple label="Submit" class="p-button-secondary" type="submit" (click)="onFormSubmitSignUp(user)"></button>
     35        </div>
     36    </div> 
  • trip-planner-front/src/app/homepage/register/register.component.ts

    r1ad8e64 r84d0fbb  
    11import { Component, OnInit } from '@angular/core';
     2import { DynamicDialogRef } from 'primeng/dynamicdialog';
     3import { UserDto } from 'src/app/_models/dto/userDto';
    24
    35@Component({
     
    810export class RegisterComponent implements OnInit {
    911
    10   constructor() { }
     12  user : UserDto;
     13
     14  constructor(private ref: DynamicDialogRef) {
     15    this.user = new UserDto();
     16   }
    1117
    1218  ngOnInit(): void {
    1319  }
    14 
     20 
     21  onFormSubmitSignUp(user){
     22    this.ref.close(user);
     23    //window.location.reload();
     24  }
    1525}
Note: See TracChangeset for help on using the changeset viewer.